[gst-devel] ffmux_mp4 (gst-ffmpeg- CVS version) not correctly muxing AAC file to MP4

Deeptendu Bikash dbikash at gmail.com
Sat Nov 4 04:20:03 CET 2006


I am using the latest CVS version of gst-ffmpeg to mux raw AAC files into
MP4 format, but there seems to be some problem with the duration.

gst-launch filesrc location=... ! audio/mpeg, rate=\(int\)8000,
channels=\(int\)2, mpegversion=\(int\)4 ! ffmux_mp4 ! filesink location=...

The resulting file has the MP4 file format but has a huge duration (8000
hours etc) and a zero bitrate. And of course, no player, including VLC,
could play it. Any suggestions on how to fix this?

Looking at the code (gstffmpegmux.c), the portion that sets the framerate
for audio, looks to incomplete/incorrect. There is a comment saying that
this might not work for any kind of audio.

    buffer=gst_collect_pads_peek(ffmpegmux->collect, (GstCollectData
        st->codec->frame_size = st->codec->sample_rate *

When I print the values of st->codec->frame_size, st->codec->sample_rate and
GST_BUFFER_DURATION(buffer)/GST_SECOND, I get the values 1266874889, 8000
and 1266874889. Evidently, the buffer duration is wrong. How can I correct

Can anybody help with this much of info?

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/gstreamer-devel/attachments/20061103/f8529dca/attachment.htm>

More information about the gstreamer-devel mailing list