Video scaler. More...
Typedefs | |
typedef struct gavl_video_scaler_s | gavl_video_scaler_t |
Opaque scaler structure. | |
Functions | |
GAVL_PUBLIC gavl_video_scaler_t * | gavl_video_scaler_create () |
Create a video scaler. | |
GAVL_PUBLIC void | gavl_video_scaler_destroy (gavl_video_scaler_t *scaler) |
Destroy a video scaler. | |
GAVL_PUBLIC gavl_video_options_t * | gavl_video_scaler_get_options (gavl_video_scaler_t *scaler) |
gets options of a scaler | |
GAVL_PUBLIC int | gavl_video_scaler_init (gavl_video_scaler_t *scaler, const gavl_video_format_t *src_format, const gavl_video_format_t *dst_format) |
Initialize a video scaler. | |
GAVL_PUBLIC int | gavl_video_scaler_init_convolve (gavl_video_scaler_t *scaler, const gavl_video_format_t *format, int h_radius, const float *h_coeffs, int v_radius, const float *v_coeffs) |
Initialize a video scaler as a generic convolver. | |
GAVL_PUBLIC void | gavl_video_scaler_scale (gavl_video_scaler_t *scaler, const gavl_video_frame_t *input_frame, gavl_video_frame_t *output_frame) |
Scale video. |
Video scaler.
The scaler does the elementary operation to take a rectangular area of the source image and scale it into a specified rectangular area of the destination image. The source rectangle has floating point coordinates, the destination rectangle must have integer coordinates, which are aligned to chroma subsampling factors.
The internal scale tables are created for each plane and field separately. This means that:
You can use the scaler directly (through gavl_video_scaler_t). The generic video converter (gavl_video_converter_t) will create an internal scaler if necessary.
typedef struct gavl_video_scaler_s gavl_video_scaler_t |
Opaque scaler structure.
You don't want to know what's inside.
GAVL_PUBLIC gavl_video_scaler_t* gavl_video_scaler_create | ( | ) |
Create a video scaler.
GAVL_PUBLIC void gavl_video_scaler_destroy | ( | gavl_video_scaler_t * | scaler | ) |
Destroy a video scaler.
scaler | A video scaler |
GAVL_PUBLIC gavl_video_options_t* gavl_video_scaler_get_options | ( | gavl_video_scaler_t * | scaler | ) |
gets options of a scaler
scaler | A video scaler |
GAVL_PUBLIC int gavl_video_scaler_init | ( | gavl_video_scaler_t * | scaler, | |
const gavl_video_format_t * | src_format, | |||
const gavl_video_format_t * | dst_format | |||
) |
Initialize a video scaler.
scaler | A video scaler
|
GAVL_PUBLIC int gavl_video_scaler_init_convolve | ( | gavl_video_scaler_t * | scaler, | |
const gavl_video_format_t * | format, | |||
int | h_radius, | |||
const float * | h_coeffs, | |||
int | v_radius, | |||
const float * | v_coeffs | |||
) |
Initialize a video scaler as a generic convolver.
scaler | A video scaler
|
GAVL_PUBLIC void gavl_video_scaler_scale | ( | gavl_video_scaler_t * | scaler, | |
const gavl_video_frame_t * | input_frame, | |||
gavl_video_frame_t * | output_frame | |||
) |
Scale video.
scaler | A video scaler
|