[FFmpeg-devel] muxing-example.c - libx264

Michael Niedermayer michaelni at gmx.at
Fri Dec 2 22:50:04 CET 2011


On Fri, Dec 02, 2011 at 09:48:30AM -0200, Germán Milano wrote:
> Hi everyone,
> 
> I'm using muxing-example.c to create an mp4 file using libx264. Since
> muxing-example.c is made for MPEG, I made following changes on it:
> http://libav-users.943685.n4.nabble.com/output-example-h264-and-mp4-td944149.html
> 
> but still doesn't work. Is there an updated version adapted for h264???
> 
> 
> 
> One of the problems I'm having is that everytime function
> write_video_frame(AVFormatContext *oc, AVStream *st) is called, the
> following line always returns a value of zero:
> 
> out_size = avcodec_encode_video(c, video_outbuf, video_outbuf_size,
> picture);
> 
> Since this value is always zero, compressed video data is never stored.

> Can't find what causes this issue. Any help will be appreciated.

here the muxing example with test.mp4 produces a clear error message


[...]
-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

When the tyrant has disposed of foreign enemies by conquest or treaty, and
there is nothing more to fear from them, then he is always stirring up
some war or other, in order that the people may require a leader. -- Plato
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20111202/e8dbbbd6/attachment.asc>


More information about the ffmpeg-devel mailing list