[vlc-devel] [PATCH 6/6] chroma:i420_nv12: only allow pixel copy, no resizing
Steve Lhomme
robux4 at videolabs.io
Thu May 12 12:17:19 CEST 2016
---
modules/video_chroma/i420_nv12.c | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/modules/video_chroma/i420_nv12.c b/modules/video_chroma/i420_nv12.c
index f15798e..da16349 100644
--- a/modules/video_chroma/i420_nv12.c
+++ b/modules/video_chroma/i420_nv12.c
@@ -69,8 +69,11 @@ static int Create( 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
+ /* resizing not supported */
+ if( p_filter->fmt_in.video.i_x_offset + p_filter->fmt_in.video.i_visible_width !=
+ p_filter->fmt_out.video.i_x_offset + p_filter->fmt_out.video.i_visible_width
+ || p_filter->fmt_in.video.i_y_offset + p_filter->fmt_in.video.i_visible_height !=
+ p_filter->fmt_out.video.i_y_offset + p_filter->fmt_out.video.i_visible_height
|| p_filter->fmt_in.video.orientation != p_filter->fmt_out.video.orientation )
return -1;
--
2.8.1
More information about the vlc-devel
mailing list