From 431117dcb55c9bd47febf9ee3379e14a5d6595c8 Mon Sep 17 00:00:00 2001 From: "Ronald S. Bultje" Date: Tue, 3 May 2016 13:53:17 -0400 Subject: vf_colorspace: add floyd-steinberg dithering option to full conversion. --- libavfilter/colorspacedsp.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'libavfilter/colorspacedsp.h') diff --git a/libavfilter/colorspacedsp.h b/libavfilter/colorspacedsp.h index 4e70c6c938..2ca7b19898 100644 --- a/libavfilter/colorspacedsp.h +++ b/libavfilter/colorspacedsp.h @@ -32,6 +32,11 @@ typedef void (*rgb2yuv_fn)(uint8_t *yuv[3], ptrdiff_t yuv_stride[3], int16_t *rgb[3], ptrdiff_t rgb_stride, int w, int h, const int16_t rgb2yuv_coeffs[3][3][8], const int16_t yuv_offset[8]); +typedef void (*rgb2yuv_fsb_fn)(uint8_t *yuv[3], ptrdiff_t yuv_stride[3], + int16_t *rgb[3], ptrdiff_t rgb_stride, + int w, int h, const int16_t rgb2yuv_coeffs[3][3][8], + const int16_t yuv_offset[8], + int *rnd[3][2]); typedef void (*yuv2yuv_fn)(uint8_t *yuv_out[3], ptrdiff_t yuv_out_stride[3], uint8_t *yuv_in[3], ptrdiff_t yuv_in_stride[3], int w, int h, const int16_t yuv2yuv_coeffs[3][3][8], @@ -40,6 +45,7 @@ typedef void (*yuv2yuv_fn)(uint8_t *yuv_out[3], ptrdiff_t yuv_out_stride[3], typedef struct ColorSpaceDSPContext { yuv2rgb_fn yuv2rgb[3 /* 0: 8bit, 1: 10bit, 2: 12bit */][3 /* 0: 444, 1: 422, 2: 420 */]; rgb2yuv_fn rgb2yuv[3 /* 0: 8bit, 1: 10bit, 2: 12bit */][3 /* 0: 444, 1: 422, 2: 420 */]; + rgb2yuv_fsb_fn rgb2yuv_fsb[3 /* 0: 8bit, 1: 10bit, 2: 12bit */][3 /* 0: 444, 1: 422, 2: 420 */]; yuv2yuv_fn yuv2yuv[3 /* in_depth */][3 /* out_depth */][3 /* 0: 444, 1: 422, 2: 420 */]; void (*multiply3x3)(int16_t *data[3], ptrdiff_t stride, -- cgit v1.2.3