[vlc-devel] [PATCH 8/8] codec/schroedinger: inform vlc of clean area

davidf+nntp at woaf.net davidf+nntp at woaf.net
Fri Mar 27 21:37:57 CET 2009


From: David Flynn <davidf at rd.bbc.co.uk>

For SD, this should allow removal of black bars form the edge of frames.
i_aspect is set to the aspect ratio of the whole frame which may be
greater than that of the clean area.  VLC should then calculate the SAR,
and eventually display a clean area sized picture that is of the correct
aspect ratio.

NB, we do actually know the SAR, but it isn't known if vlc cares at this
point.

Signed-off-by: David Flynn <davidf at rd.bbc.co.uk>
---
 modules/codec/schroedinger.c |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/modules/codec/schroedinger.c b/modules/codec/schroedinger.c
index 83409ed..cf81333 100644
--- a/modules/codec/schroedinger.c
+++ b/modules/codec/schroedinger.c
@@ -153,10 +153,12 @@ static void SetVideoFormat( decoder_t *p_dec )
         break;
     }
 
-    p_dec->fmt_out.video.i_visible_width =
+    p_dec->fmt_out.video.i_visible_width = p_sys->p_format->clean_width;
+    p_dec->fmt_out.video.i_x_offset = p_sys->p_format->left_offset;
     p_dec->fmt_out.video.i_width = p_sys->p_format->width;
 
-    p_dec->fmt_out.video.i_visible_height =
+    p_dec->fmt_out.video.i_visible_height = p_sys->p_format->clean_height;
+    p_dec->fmt_out.video.i_y_offset = p_sys->p_format->top_offset;
     p_dec->fmt_out.video.i_height = p_sys->p_format->height;
 
     /* aspect_ratio_[numerator|denominator] describes the pixel aspect ratio */
-- 
1.5.6.5




More information about the vlc-devel mailing list