TUT HEVC Encoder
Loading...
Searching...
No Matches
cu.c File Reference
#include <string.h>
#include <stdlib.h>
#include "cu.h"
#include "threads.h"
Include dependency graph for cu.c:

Functions

cu_info_tkvz_cu_array_at (cu_array_t *cua, unsigned x_px, unsigned y_px)
 
const cu_info_tkvz_cu_array_at_const (const cu_array_t *cua, unsigned x_px, unsigned y_px)
 
cu_array_tkvz_cu_array_alloc (const int width, const int height)
 Allocate a CU array.
 
cu_array_tkvz_cu_subarray (cu_array_t *base, const unsigned x_offset, const unsigned y_offset, const unsigned width, const unsigned height)
 
void kvz_cu_array_free (cu_array_t **cua_ptr)
 
cu_array_tkvz_cu_array_copy_ref (cu_array_t *cua)
 Get a new pointer to a cu array.
 
void kvz_cu_array_copy_from_lcu (cu_array_t *dst, int dst_x, int dst_y, const lcu_t *src)
 Copy an lcu to a cu array.
 

Variables

const uint8_t kvz_part_mode_num_parts []
 Number of PUs in a CU.
 
const uint8_t kvz_part_mode_offsets [][4][2]
 PU offsets.
 
const uint8_t kvz_part_mode_sizes [][4][2]
 PU sizes.
 

Function Documentation

◆ kvz_cu_array_alloc()

cu_array_t * kvz_cu_array_alloc ( const int width,
const int height )
Parameters
widthwidth of the array in luma pixels
heightheight of the array in luma pixels
Here is the caller graph for this function:

◆ kvz_cu_array_at()

cu_info_t * kvz_cu_array_at ( cu_array_t * cua,
unsigned x_px,
unsigned y_px )
Here is the call graph for this function:
Here is the caller graph for this function:

◆ kvz_cu_array_at_const()

const cu_info_t * kvz_cu_array_at_const ( const cu_array_t * cua,
unsigned x_px,
unsigned y_px )
Here is the caller graph for this function:

◆ kvz_cu_array_copy_from_lcu()

void kvz_cu_array_copy_from_lcu ( cu_array_t * dst,
int dst_x,
int dst_y,
const lcu_t * src )

All values are in luma pixels.

Parameters
dstdestination array
dst_xx-coordinate of the left edge of the copied area in dst
dst_yy-coordinate of the top edge of the copied area in dst
srcsource lcu
Here is the caller graph for this function:

◆ kvz_cu_array_copy_ref()

cu_array_t * kvz_cu_array_copy_ref ( cu_array_t * cua)

Increment reference count and return the cu array.

Here is the caller graph for this function:

◆ kvz_cu_array_free()

void kvz_cu_array_free ( cu_array_t ** cua_ptr)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ kvz_cu_subarray()

cu_array_t * kvz_cu_subarray ( cu_array_t * base,
const unsigned x_offset,
const unsigned y_offset,
const unsigned width,
const unsigned height )
Here is the call graph for this function:
Here is the caller graph for this function:

Variable Documentation

◆ kvz_part_mode_num_parts

const uint8_t kvz_part_mode_num_parts[]
Initial value:
= {
1,
2,
2,
4,
2,
2,
2,
2,
}

Indexed by part_mode_t values.

◆ kvz_part_mode_offsets

const uint8_t kvz_part_mode_offsets[][4][2]
Initial value:
= {
{ {0, 0} },
{ {0, 0}, {0, 2} },
{ {0, 0}, {2, 0} },
{ {0, 0}, {2, 0}, {0, 2}, {2, 2} },
{ {0, 0}, {0, 1} },
{ {0, 0}, {0, 3} },
{ {0, 0}, {1, 0} },
{ {0, 0}, {3, 0} },
}

Indexed by [part mode][PU number][axis].

Units are 1/4 of the width of the CU.

◆ kvz_part_mode_sizes

const uint8_t kvz_part_mode_sizes[][4][2]
Initial value:
= {
{ {4, 4} },
{ {4, 2}, {4, 2} },
{ {2, 4}, {2, 4} },
{ {2, 2}, {2, 2}, {2, 2}, {2, 2} },
{ {4, 1}, {4, 3} },
{ {4, 3}, {4, 1} },
{ {1, 4}, {3, 4} },
{ {3, 4}, {1, 4} },
}

Indexed by [part mode][PU number][axis].

Units are 1/4 of the width of the CU.