[vlc-commits] neon yuv->rgb : check RGBA order/endianess

Rafaël Carré git at videolan.org
Sun Jan 22 19:27:48 CET 2012


vlc | branch: master | Rafaël Carré <funman at videolan.org> | Sun Jan 22 13:27:02 2012 -0500| [99bf74390c5a44d0a9199881c7ddee752c613d5e] | committer: Rafaël Carré

neon yuv->rgb : check RGBA order/endianess

We only support ABGR

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=99bf74390c5a44d0a9199881c7ddee752c613d5e
---

 modules/arm_neon/yuv_rgb.c |    5 +++++
 1 files changed, 5 insertions(+), 0 deletions(-)

diff --git a/modules/arm_neon/yuv_rgb.c b/modules/arm_neon/yuv_rgb.c
index ede49c9..f6113f2 100644
--- a/modules/arm_neon/yuv_rgb.c
+++ b/modules/arm_neon/yuv_rgb.c
@@ -133,6 +133,11 @@ static int Open (vlc_object_t *obj)
     switch (filter->fmt_out.video.i_chroma)
     {
         case VLC_CODEC_RGB32:
+            if(        filter->fmt_out.video.i_rmask != 0x000000ff
+                    || filter->fmt_out.video.i_gmask != 0x0000ff00
+                    || filter->fmt_out.video.i_bmask != 0x00ff0000 )
+                return VLC_EGENERIC;
+
             switch (filter->fmt_in.video.i_chroma)
             {
                 case VLC_CODEC_I420:



More information about the vlc-commits mailing list