[FFmpeg-devel] [PATCH] ffmpeg: prefer "dec" over "ist->st->codec" in do_video_out() snippet

Stefano Sabatini stefano.sabatini-lala at poste.it
Sun Apr 17 01:43:14 CEST 2011


Simplify, ease readability.

Signed-off-by: Stefano Sabatini <stefano.sabatini-lala at poste.it>
---
 ffmpeg.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/ffmpeg.c b/ffmpeg.c
index 7452141..820b1f8 100644
--- a/ffmpeg.c
+++ b/ffmpeg.c
@@ -1185,8 +1185,8 @@ static void do_video_out(AVFormatContext *s,
         av_log(NULL, AV_LOG_INFO,
                "Input stream #%d.%d frame size changed from s:%dx%d fmt:%s to s:%dx%d fmt:%s\n",
                ist->file_index, ist->index,
-               ost->resample_width  , ost->resample_height  , avcodec_get_pix_fmt_name(ost->resample_pix_fmt),
-               ist->st->codec->width, ist->st->codec->height, avcodec_get_pix_fmt_name(ist->st->codec->pix_fmt));
+               ost->resample_width, ost->resample_height, avcodec_get_pix_fmt_name(ost->resample_pix_fmt),
+               dec->width         , dec->height         , avcodec_get_pix_fmt_name(dec->pix_fmt));
         if(!ost->video_resample)
             ffmpeg_exit(1);
     }
-- 
1.7.2.3



More information about the ffmpeg-devel mailing list