yuv2gray16_2_c_template(SwsContext *c, const uint16_t *buf0,

                        const uint16_t *buf1, const uint16_t *ubuf0,

                        const uint16_t *ubuf1, const uint16_t *vbuf0,

                        const uint16_t *vbuf1, const uint16_t *abuf0,

                        const uint16_t *abuf1, uint8_t *dest, int dstW,

                        int yalpha, int uvalpha, int y,

                        enum PixelFormat target)

{

    int  yalpha1 = 4095 - yalpha; \

    int i;



    for (i = 0; i < (dstW >> 1); i++) {

        const int i2 = 2 * i;

        int Y1 = (buf0[i2  ] * yalpha1 + buf1[i2  ] * yalpha) >> 11;

        int Y2 = (buf0[i2+1] * yalpha1 + buf1[i2+1] * yalpha) >> 11;



        output_pixel(&dest[2 * i2 + 0], Y1);

        output_pixel(&dest[2 * i2 + 2], Y2);

    }

}

yuv2gray16_2_c_template(SwsContext *c, const uint16_t *buf0,

                        const uint16_t *buf1, const uint16_t *ubuf0,

                        const uint16_t *ubuf1, const uint16_t *vbuf0,

                        const uint16_t *vbuf1, const uint16_t *abuf0,

                        const uint16_t *abuf1, uint8_t *dest, int dstW,

                        int yalpha, int uvalpha, int y,

                        enum PixelFormat target)

{

    int  yalpha1 = 4095 - yalpha; \

    int i;



    for (i = 0; i < (dstW >> 1); i++) {

        const int i2 = 2 * i;

        int Y1 = (buf0[i2  ] * yalpha1 + buf1[i2  ] * yalpha) >> 11;

        int Y2 = (buf0[i2+1] * yalpha1 + buf1[i2+1] * yalpha) >> 11;



        output_pixel(&dest[2 * i2 + 0], Y1);

        output_pixel(&dest[2 * i2 + 2], Y2);

    }

}

FUNC_0(SwsContext *VAR_0, const uint16_t *VAR_1,

                        const uint16_t *VAR_2, const uint16_t *VAR_3,

                        const uint16_t *VAR_4, const uint16_t *VAR_5,

                        const uint16_t *VAR_6, const uint16_t *VAR_7,

                        const uint16_t *VAR_8, uint8_t *VAR_9, int VAR_10,

                        int VAR_11, int VAR_12, int VAR_13,

                        enum PixelFormat VAR_14)

{

    int  VAR_15 = 4095 - VAR_11; \

    int VAR_16;



    for (VAR_16 = 0; VAR_16 < (VAR_10 >> 1); VAR_16++) {

        const int VAR_17 = 2 * VAR_16;

        int VAR_18 = (VAR_1[VAR_17  ] * VAR_15 + VAR_2[VAR_17  ] * VAR_11) >> 11;

        int VAR_19 = (VAR_1[VAR_17+1] * VAR_15 + VAR_2[VAR_17+1] * VAR_11) >> 11;



        output_pixel(&VAR_9[2 * VAR_17 + 0], VAR_18);

        output_pixel(&VAR_9[2 * VAR_17 + 2], VAR_19);

    }

}

FUNC_0(SwsContext *VAR_0, const uint16_t *VAR_1,
const uint16_t *VAR_2, const uint16_t *VAR_3,
const uint16_t *VAR_4, const uint16_t *VAR_5,
const uint16_t *VAR_6, const uint16_t *VAR_7,
const uint16_t *VAR_8, uint8_t *VAR_9, int VAR_10,
int VAR_11, int VAR_12, int VAR_13,
enum PixelFormat VAR_14)
{ int  VAR_15 = 4095 - VAR_11; \ int VAR_16; for (VAR_16 = 0; VAR_16 < (VAR_10 >> 1); VAR_16++) { const int VAR_17 = 2 * VAR_16; int VAR_18 = (VAR_1[VAR_17  ] * VAR_15 + VAR_2[VAR_17  ] * VAR_11) >> 11; int VAR_19 = (VAR_1[VAR_17+1] * VAR_15 + VAR_2[VAR_17+1] * VAR_11) >> 11; output_pixel(&VAR_9[2 * VAR_17 + 0], VAR_18); output_pixel(&VAR_9[2 * VAR_17 + 2], VAR_19); } }