[vlc-devel] commit: set stream aspect-ratio to video aspect-ratio, as ffmpeg checks that (Ilkka Ollakka )

git version control git at videolan.org
Fri Dec 5 14:30:17 CET 2008


vlc | branch: master | Ilkka Ollakka <ileoo at videolan.org> | Fri Dec  5 15:28:47 2008 +0200| [0a778174db0192075a3194fb05b06a034ad940d2] | committer: Ilkka Ollakka 

set stream aspect-ratio to video aspect-ratio, as ffmpeg checks that
from r15367 onward and refuses to mux without them matching.

Should fix flv-muxing.

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

 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 4a402d7..a059c49 100644
--- a/modules/demux/avformat/mux.c
+++ b/modules/demux/avformat/mux.c
@@ -252,6 +252,8 @@ 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 );
+        stream->sample_aspect_ratio.num = codec->sample_aspect_ratio.num;
+        stream->sample_aspect_ratio.den = codec->sample_aspect_ratio.den;
         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