[vlc-commits] encoder: dirac: match source geometry

Francois Cartegnie git at videolan.org
Thu Jan 16 19:35:41 CET 2014


vlc | branch: master | Francois Cartegnie <fcvlcdev at free.fr> | Wed Jan 15 19:53:51 2014 +0100| [c21305385d6f8a1eeb7931a4e7c42de6017ede26] | committer: Francois Cartegnie

encoder: dirac: match source geometry

refs #10386
Still junk on bottom due to invalid plane->i_visible_lines

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

 modules/codec/dirac.c |    5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/modules/codec/dirac.c b/modules/codec/dirac.c
index 94319a3..5627406 100644
--- a/modules/codec/dirac.c
+++ b/modules/codec/dirac.c
@@ -500,8 +500,6 @@ static int OpenEncoder( vlc_object_t *p_this )
     dirac_encoder_context_init( &p_sys->ctx, guessed_video_fmt );
 
     /* constants set from the input video format */
-    p_sys->ctx.src_params.width = p_enc->fmt_in.video.i_visible_width;
-    p_sys->ctx.src_params.height = p_enc->fmt_in.video.i_visible_height;
     p_sys->ctx.src_params.frame_rate.numerator = p_enc->fmt_in.video.i_frame_rate;
     p_sys->ctx.src_params.frame_rate.denominator = p_enc->fmt_in.video.i_frame_rate_base;
     unsigned u_asr_num, u_asr_den;
@@ -558,6 +556,9 @@ static int OpenEncoder( vlc_object_t *p_this )
         break;
     }
 
+    p_sys->ctx.src_params.width = picture.format.i_visible_width;
+    p_sys->ctx.src_params.height = picture.format.i_visible_height;
+
     p_sys->ctx.enc_params.qf = var_GetFloat( p_enc, ENC_CFG_PREFIX ENC_QUALITY_FACTOR );
 
     /* use bitrate from sout-transcode-vb in kbps */



More information about the vlc-commits mailing list