image_ffmpeg_scale_rgba function
- @Native<Int32 Function(Pointer<
Uint8> , Uint32, Uint32, Uint32, Uint32, Uint32, Uint32, Uint32, Uint32, Uint32, Uint32, Uint32, Pointer<image_ffmpeg_image> )>(ffi.Pointer<ffi.Uint8>, ffi.Uint32, ffi.Uint32, ffi.Uint32, ffi.Uint32, ffi.Uint32, ffi.Uint32, ffi.Uint32, ffi.Uint32, ffi.Uint32, ffi.Uint32, ffi.Uint32, ffi.Pointer<image_ffmpeg_image>)>()
Crops RGBA8888 pixels, then scales the crop to exactly output_width x output_height with the filter, an image_ffmpeg_scale_filter. A zero crop width and height use the whole image. The output may be larger or smaller than the crop, and its aspect ratio may differ. Alpha is not premultiplied: the colors of transparent pixels can bleed into their neighbors.
Implementation
@ffi.Native<
ffi.Int32 Function(
ffi.Pointer<ffi.Uint8>,
ffi.Uint32,
ffi.Uint32,
ffi.Uint32,
ffi.Uint32,
ffi.Uint32,
ffi.Uint32,
ffi.Uint32,
ffi.Uint32,
ffi.Uint32,
ffi.Uint32,
ffi.Uint32,
ffi.Pointer<image_ffmpeg_image>,
)
>()
external int image_ffmpeg_scale_rgba(
ffi.Pointer<ffi.Uint8> rgba,
int rgba_length,
int width,
int height,
int stride,
int crop_x,
int crop_y,
int crop_width,
int crop_height,
int output_width,
int output_height,
int filter,
ffi.Pointer<image_ffmpeg_image> output,
);