[MPlayer-cvslog] r22484 - trunk/libmpcodecs/vd_ffmpeg.c

gpoirier subversion at mplayerhq.hu
Wed Mar 7 10:19:36 CET 2007


Author: gpoirier
Date: Wed Mar  7 10:19:36 2007
New Revision: 22484

Modified:
   trunk/libmpcodecs/vd_ffmpeg.c

Log:
Fix ratio aspect on Matroska files, broken with recent 'spect change in DVB' patch
patch by Carl Eugen Hoyos % cehoyos A ag P or P at %
Original thread:
Subj: [MPlayer-dev-eng] [PATCH] Fix aspect in mkv
Date: 03/05/2007 02:01 PM
Bug report report:
http://lists.mplayerhq.hu/pipermail/mplayer-users/2007-March/065823.html


Modified: trunk/libmpcodecs/vd_ffmpeg.c
==============================================================================
--- trunk/libmpcodecs/vd_ffmpeg.c	(original)
+++ trunk/libmpcodecs/vd_ffmpeg.c	Wed Mar  7 10:19:36 2007
@@ -504,8 +504,11 @@ static int init_vo(sh_video_t *sh, enum 
 	!ctx->vo_inited)
     {
 	mp_msg(MSGT_DECVIDEO, MSGL_V, "[ffmpeg] aspect_ratio: %f\n", aspect);
+	if (sh->aspect == 0 ||
+	    av_cmp_q(avctx->sample_aspect_ratio, 
+	             ctx->last_sample_aspect_ratio))
+	    sh->aspect = aspect;
 	ctx->last_sample_aspect_ratio = avctx->sample_aspect_ratio;
-	sh->aspect = aspect;
 	sh->disp_w = width;
 	sh->disp_h = height;
 	ctx->pix_fmt = pix_fmt;



More information about the MPlayer-cvslog mailing list