[vlc-devel] commit: Fix compile on machine with older avformat. (Jean-Baptiste Kempf )

git version control git at videolan.org
Sun Feb 22 22:29:42 CET 2009


vlc | branch: 0.9-bugfix | Jean-Baptiste Kempf <jb at videolan.org> | Sun Feb 22 22:24:02 2009 +0100| [e7fdb2d30666699c544223fe1e48712f267db850] | committer: Jean-Baptiste Kempf 

Fix compile on machine with older avformat.

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

 modules/demux/avformat/mux.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/modules/demux/avformat/mux.c b/modules/demux/avformat/mux.c
index 9f8cde1..90d72ef 100644
--- a/modules/demux/avformat/mux.c
+++ b/modules/demux/avformat/mux.c
@@ -252,8 +252,10 @@ static int AddStream( sout_mux_t *p_mux, sout_input_t *p_input )
                    &codec->sample_aspect_ratio.den,
                    i_aspect_num * (int64_t)codec->height,
                    i_aspect_den * (int64_t)codec->width, 1 << 30 );
+#if LIBAVFORMAT_VERSION_INT >= ((52<<16)+(21<<8)+0)
         stream->sample_aspect_ratio.num = codec->sample_aspect_ratio.num;
         stream->sample_aspect_ratio.den = codec->sample_aspect_ratio.den;
+#endif
         codec->time_base.den = p_input->p_fmt->video.i_frame_rate;
         codec->time_base.num = p_input->p_fmt->video.i_frame_rate_base;
         break;




More information about the vlc-devel mailing list