[vlc-devel] commit: Check for input/output size match here too. I hope that I didn' t forget other files. (Antoine Cellerier )

git version control git at videolan.org
Thu Aug 28 18:49:41 CEST 2008


vlc | branch: master | Antoine Cellerier <dionoea at videolan.org> | Thu Aug 28 18:50:11 2008 +0200| [89ec4e6268a775ec55544ad540d0143fad34b3f8] | committer: Antoine Cellerier 

Check for input/output size match here too. I hope that I didn't forget other files.

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

 modules/video_chroma/grey_yuv.c  |    4 ++++
 modules/video_chroma/i420_ymga.c |    4 ++++
 modules/video_chroma/i422_i420.c |    4 ++++
 modules/video_chroma/yuy2_i422.c |    4 ++++
 4 files changed, 16 insertions(+), 0 deletions(-)

diff --git a/modules/video_chroma/grey_yuv.c b/modules/video_chroma/grey_yuv.c
index 494cacd..d8a805c 100644
--- a/modules/video_chroma/grey_yuv.c
+++ b/modules/video_chroma/grey_yuv.c
@@ -72,6 +72,10 @@ static int Activate( vlc_object_t *p_this )
         return -1;
     }
 
+    if( p_filter->fmt_in.video.i_width != p_filter->fmt_out.video.i_width
+     || p_filter->fmt_in.video.i_height != p_filter->fmt_out.video.i_height )
+        return -1;
+
     switch( p_filter->fmt_in.video.i_chroma )
     {
         case VLC_FOURCC('Y','8','0','0'):
diff --git a/modules/video_chroma/i420_ymga.c b/modules/video_chroma/i420_ymga.c
index 4efc6a6..2859f92 100644
--- a/modules/video_chroma/i420_ymga.c
+++ b/modules/video_chroma/i420_ymga.c
@@ -76,6 +76,10 @@ static int Activate( vlc_object_t *p_this )
         return -1;
     }
 
+    if( p_filter->fmt_in.video.i_width != p_filter->fmt_out.video.i_width
+     || p_filter->fmt_in.video.i_height != p_filter->fmt_out.video.i_height )
+        return -1;
+
     switch( p_filter->fmt_in.video.i_chroma )
     {
         case VLC_FOURCC('Y','V','1','2'):
diff --git a/modules/video_chroma/i422_i420.c b/modules/video_chroma/i422_i420.c
index a318580..ed0c029 100644
--- a/modules/video_chroma/i422_i420.c
+++ b/modules/video_chroma/i422_i420.c
@@ -74,6 +74,10 @@ static int Activate( vlc_object_t *p_this )
         return -1;
     }
 
+    if( p_filter->fmt_in.video.i_width != p_filter->fmt_out.video.i_width
+     || p_filter->fmt_in.video.i_height != p_filter->fmt_out.video.i_height )
+        return -1;
+
     switch( p_filter->fmt_in.video.i_chroma )
     {
         case VLC_FOURCC('I','4','2','2'):
diff --git a/modules/video_chroma/yuy2_i422.c b/modules/video_chroma/yuy2_i422.c
index 131f09b..4faea42 100644
--- a/modules/video_chroma/yuy2_i422.c
+++ b/modules/video_chroma/yuy2_i422.c
@@ -75,6 +75,10 @@ static int Activate( vlc_object_t *p_this )
         return -1;
     }
 
+    if( p_filter->fmt_in.video.i_width != p_filter->fmt_out.video.i_width
+     || p_filter->fmt_in.video.i_height != p_filter->fmt_out.video.i_height )
+        return -1;
+
     switch( p_filter->fmt_out.video.i_chroma )
     {
         case VLC_FOURCC('I','4','2','2'):




More information about the vlc-devel mailing list