swscale/input: Fix alpha of YA16 input
authorMichael Niedermayer <michaelni@gmx.at>
Wed, 21 Jan 2015 19:14:34 +0000 (20:14 +0100)
committerMichael Niedermayer <michaelni@gmx.at>
Wed, 21 Jan 2015 20:21:00 +0000 (21:21 +0100)
Fixes Ticket4278

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
libswscale/input.c

index 6716f0d..1928223 100644 (file)
@@ -1249,11 +1249,9 @@ av_cold void ff_sws_init_input_funcs(SwsContext *c)
 #endif
     case AV_PIX_FMT_YA16LE:
         c->lumToYV12 = read_ya16le_gray_c;
-        c->alpToYV12 = read_ya16le_alpha_c;
         break;
     case AV_PIX_FMT_YA16BE:
         c->lumToYV12 = read_ya16be_gray_c;
-        c->alpToYV12 = read_ya16be_alpha_c;
         break;
     case AV_PIX_FMT_YUYV422:
     case AV_PIX_FMT_YVYU422:
@@ -1375,6 +1373,12 @@ av_cold void ff_sws_init_input_funcs(SwsContext *c)
         case AV_PIX_FMT_YA8:
             c->alpToYV12 = uyvyToY_c;
             break;
+        case AV_PIX_FMT_YA16LE:
+            c->alpToYV12 = read_ya16le_alpha_c;
+            break;
+        case AV_PIX_FMT_YA16BE:
+            c->alpToYV12 = read_ya16be_alpha_c;
+            break;
         case AV_PIX_FMT_PAL8 :
             c->alpToYV12 = palToA_c;
             break;