GstVideo.VideoScaler¶
Fields¶
None
Methods¶
|
|
|
|
|
|
|
|
|
Details¶
- class GstVideo.VideoScaler¶
GstVideo.VideoScaler
is a utility object for rescaling and resampling video frames using various interpolation / sampling methods.- free()[source]¶
Free a previously allocated
GstVideo.VideoScaler
self.
- get_coeff(out_offset)[source]¶
- Parameters:
out_offset (
int
) – an output offset- Returns:
an array of n_tap
float
values with filter coefficients.- in_offset:
result input offset
- n_taps:
result n_taps
- Return type:
For a given pixel at out_offset, get the first required input pixel at in_offset and the n_taps filter coefficients.
Note that for interlaced content, in_offset needs to be incremented with 2 to get the next input line.
- get_max_taps()[source]¶
- Returns:
the maximum number of taps
- Return type:
Get the maximum number of taps for self.
- horizontal(format, src, dest, dest_offset, width)[source]¶
- Parameters:
format (
GstVideo.VideoFormat
) – aGstVideo.VideoFormat
for src and destdest_offset (
int
) – the horizontal destination offsetwidth (
int
) – the number of pixels to scale
Horizontally scale the pixels in src to dest, starting from dest_offset for width samples.
- vertical(format, src_lines, dest, dest_offset, width)[source]¶
- Parameters:
format (
GstVideo.VideoFormat
) – aGstVideo.VideoFormat
for srcs and destdest_offset (
int
) – the vertical destination offsetwidth (
int
) – the number of pixels to scale
Vertically combine width pixels in the lines in src_lines to dest. dest is the location of the target line at dest_offset and srcs are the input lines for dest_offset.