[vlc-devel] commit: This should work for all planar YUV formats ( in fact it should work for (Antoine Cellerier )
git version control
git at videolan.org
Sat May 31 17:18:04 CEST 2008
vlc | branch: master | Antoine Cellerier <dionoea at videolan.org> | Sat May 31 17:18:31 2008 +0200| [043f82024c6e216a8516fca775da1561ad427a8c]
This should work for all planar YUV formats (in fact it should work for
all formats where the pixel pitch is of 1 byte on every plane).
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=043f82024c6e216a8516fca775da1561ad427a8c
---
modules/video_filter/rotate.c | 21 +++++++++------------
1 files changed, 9 insertions(+), 12 deletions(-)
diff --git a/modules/video_filter/rotate.c b/modules/video_filter/rotate.c
index d3c1169..0d6ba5c 100644
--- a/modules/video_filter/rotate.c
+++ b/modules/video_filter/rotate.c
@@ -36,6 +36,7 @@
#include <vlc_vout.h>
#include "vlc_filter.h"
+#include "filter_picture.h"
/*****************************************************************************
* Local prototypes
@@ -104,19 +105,15 @@ static int Create( vlc_object_t *p_this )
filter_t *p_filter = (filter_t *)p_this;
filter_sys_t *p_sys;
- if( p_filter->fmt_in.video.i_chroma != VLC_FOURCC('I','4','2','0')
- && p_filter->fmt_in.video.i_chroma != VLC_FOURCC('I','Y','U','V')
- && p_filter->fmt_in.video.i_chroma != VLC_FOURCC('J','4','2','0')
- && p_filter->fmt_in.video.i_chroma != VLC_FOURCC('Y','V','1','2')
-
- && p_filter->fmt_in.video.i_chroma != VLC_FOURCC('I','4','2','2')
- && p_filter->fmt_in.video.i_chroma != VLC_FOURCC('J','4','2','2')
- )
+ switch( p_filter->fmt_in.video.i_chroma )
{
- /* We only want planar YUV 4:2:0 or 4:2:2 */
- msg_Err( p_filter, "Unsupported input chroma (%4s)",
- (char*)&(p_filter->fmt_in.video.i_chroma) );
- return VLC_EGENERIC;
+ CASE_PLANAR_YUV
+ break;
+
+ default:
+ msg_Err( p_filter, "Unsupported input chroma (%4s)",
+ (char*)&(p_filter->fmt_in.video.i_chroma) );
+ return VLC_EGENERIC;
}
if( p_filter->fmt_in.video.i_chroma != p_filter->fmt_out.video.i_chroma )
More information about the vlc-devel
mailing list