summaryrefslogtreecommitdiff
path: root/doc/examples/muxing.c
Commit message (Collapse)AuthorAge
* examples/muxing: add support to audio resamplingStefano Sabatini2013-07-06
| | | | | Allows to encode to output in case the destination sample format is different from AV_SAMPLE_FMT_S16.
* examples/muxing: make more compact audio/video_time computationStefano Sabatini2013-07-03
|
* examples/muxing: rename audio/video_pts to audio/video_timeStefano Sabatini2013-06-26
| | | | | The new name is less confusing, since the variables represent times rather than timestamps.
* examples/muxing: remove useless instructionStefano Sabatini2013-06-26
| | | | Simpler and less confusing.
* examples/muxing: vertically alignStefano Sabatini2013-06-25
|
* Merge commit '9d3009c6c4b9b6734f07df7c88f6a42ded6cdf38'Michael Niedermayer2013-03-12
| | | | | | | | | | | | | | * commit '9d3009c6c4b9b6734f07df7c88f6a42ded6cdf38': avconv: print an error on applying options of the wrong type. atomic: Check for __sync_val_compare_and_swap instead of __sync_synchronize output-example: Update to use encode_video2 instead of the now dropped encode_video Conflicts: doc/examples/muxing.c ffmpeg_opt.c libavutil/atomic.h Merged-by: Michael Niedermayer <michaelni@gmx.at>
* examples/muxing: fix memory leak.Nicolas George2013-03-05
| | | | | | | | | | | Do not re-call avcodec_get_context_defaults3(), it is already called by avformat_new_stream() and it leaks the codec priv_data that was already allocated. Use avformat_free_context() instead of freeing (not) everything manually. Fix trac ticket #2322.
* examples/muxing: improve error messages.Nicolas George2013-01-02
| | | | | Illustrate the use of return values, av_err2str and avcodec_get_name.
* examples: fix doxy so they appear on the example pageMichael Niedermayer2012-10-26
| | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* examples/muxing: merge add_audio_stream() and add_video_stream()Stefano Sabatini2012-10-17
| | | | Factorize.
* examples/muxing: check on frameStefano Sabatini2012-10-17
| | | | Fix crash in case frame is not defined (e.g. with muxing out.wav).
* examples/muxing: fix bogus setting of st->idStefano Sabatini2012-10-17
|
* examples/muxing: remove misleading comment about pending API changeStefano Sabatini2012-10-17
| | | | | The API was never changed since 2003. Replace with a comment about the performed operation.
* examples/muxing: remove video_outbuf unused and useless codeStefano Sabatini2012-10-17
|
* examples/muxing: fix video ptsMichael Niedermayer2012-10-17
| | | | | | Fixes Ticket1801 Based on suggestion from AztecC Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* examples/muxing: extend usage noticeStefano Sabatini2012-10-15
|
* examples/muxing: provide more information in case of avcodec_open2 failureStefano Sabatini2012-10-15
|
* examples/muxing: add missing error checksStefano Sabatini2012-10-15
|
* examples/muxing: fix case inconsistency in messageStefano Sabatini2012-10-15
|
* Merge commit '716d413c13981da15323c7a3821860536eefdbbb'Michael Niedermayer2012-10-08
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * commit '716d413c13981da15323c7a3821860536eefdbbb': Replace PIX_FMT_* -> AV_PIX_FMT_*, PixelFormat -> AVPixelFormat Conflicts: doc/examples/muxing.c ffmpeg.h ffmpeg_filter.c ffmpeg_opt.c ffplay.c ffprobe.c libavcodec/8bps.c libavcodec/aasc.c libavcodec/aura.c libavcodec/avcodec.h libavcodec/avs.c libavcodec/bfi.c libavcodec/bmp.c libavcodec/bmpenc.c libavcodec/c93.c libavcodec/cscd.c libavcodec/cyuv.c libavcodec/dpx.c libavcodec/dpxenc.c libavcodec/eatgv.c libavcodec/escape124.c libavcodec/ffv1.c libavcodec/flashsv.c libavcodec/fraps.c libavcodec/h264.c libavcodec/huffyuv.c libavcodec/iff.c libavcodec/imgconvert.c libavcodec/indeo3.c libavcodec/kmvc.c libavcodec/libopenjpegdec.c libavcodec/libopenjpegenc.c libavcodec/libx264.c libavcodec/ljpegenc.c libavcodec/mjpegdec.c libavcodec/mjpegenc.c libavcodec/motionpixels.c libavcodec/mpeg12.c libavcodec/mpeg12enc.c libavcodec/mpeg4videodec.c libavcodec/mpegvideo_enc.c libavcodec/pamenc.c libavcodec/pcxenc.c libavcodec/pgssubdec.c libavcodec/pngdec.c libavcodec/pngenc.c libavcodec/pnm.c libavcodec/pnmdec.c libavcodec/pnmenc.c libavcodec/ptx.c libavcodec/qdrw.c libavcodec/qpeg.c libavcodec/qtrleenc.c libavcodec/raw.c libavcodec/rawdec.c libavcodec/rl2.c libavcodec/sgidec.c libavcodec/sgienc.c libavcodec/snowdec.c libavcodec/snowenc.c libavcodec/sunrast.c libavcodec/targa.c libavcodec/targaenc.c libavcodec/tiff.c libavcodec/tiffenc.c libavcodec/tmv.c libavcodec/truemotion2.c libavcodec/utils.c libavcodec/vb.c libavcodec/vp3.c libavcodec/wnv1.c libavcodec/xl.c libavcodec/xwddec.c libavcodec/xwdenc.c libavcodec/yop.c libavdevice/v4l2.c libavdevice/x11grab.c libavfilter/avfilter.c libavfilter/avfilter.h libavfilter/buffersrc.c libavfilter/drawutils.c libavfilter/formats.c libavfilter/src_movie.c libavfilter/vf_ass.c libavfilter/vf_drawtext.c libavfilter/vf_fade.c libavfilter/vf_format.c libavfilter/vf_hflip.c libavfilter/vf_lut.c libavfilter/vf_overlay.c libavfilter/vf_pad.c libavfilter/vf_scale.c libavfilter/vf_transpose.c libavfilter/vf_yadif.c libavfilter/video.c libavfilter/vsrc_testsrc.c libavformat/movenc.c libavformat/mxf.h libavformat/utils.c libavformat/yuv4mpeg.c libavutil/imgutils.c libavutil/pixdesc.c libswscale/input.c libswscale/output.c libswscale/swscale_internal.h libswscale/swscale_unscaled.c libswscale/utils.c libswscale/x86/swscale_template.c libswscale/x86/yuv2rgb.c libswscale/x86/yuv2rgb_template.c libswscale/yuv2rgb.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
* Merge commit '7751e4693dd10ec98c20fbd9887233b575034272'Michael Niedermayer2012-09-25
| | | | | | | | | | | | | | | | | | | | | | | | | | * commit '7751e4693dd10ec98c20fbd9887233b575034272': ogg: check that the expected number of headers had been parsed libx264: change default to closed gop to match x264cli Use avcodec_free_frame() to free AVFrames. lavf: use a malloced AVFrame in try_decode_frame(). lavc: add avcodec_free_frame(). lavc: ensure extended_data is set properly on decoding lavc: initialize AVFrame.extended_data in avcodec_get_frame_defaults() lavc: use av_mallocz to allocate AVFrames. lavc: rename the argument of avcodec_alloc_frame/get_frame_defaults Conflicts: doc/APIchanges doc/examples/decoding_encoding.c libavcodec/utils.c libavcodec/version.h libavfilter/src_movie.c libavformat/oggdec.c libavformat/oggdec.h libavformat/oggparsetheora.c libavformat/utils.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
* examples/muxing: add check on avformat_write_header() resultStefano Sabatini2012-09-11
|
* examples/muxing: apply misc fixes to log messagesStefano Sabatini2012-09-11
|
* examples/muxing: rename img_convert_ctx to sws_ctxStefano Sabatini2012-09-11
| | | | | The new name is more consistent with the codebase, and more self-consistent with the libswscale API.
* examples/muxing: merge some declarations and definitionsStefano Sabatini2012-09-11
|
* examples/muxing: prefer AVPicture to AVFrame, when feasibleStefano Sabatini2012-09-11
| | | | | | | Favor the use of plain AVPicture over AVFrame, especially when the use of AVFrame is not required like in the case of tmp_picture. Also adopt more straightforward names, to avoid frame/picture confusion.
* examples/muxing: remove pointless #undef exitStefano Sabatini2012-08-30
|
* examples/muxing: update to the new avcodec_encode_video2() APIStefano Sabatini2012-08-24
|
* examples/muxing: cast sws_scale() argument to the expected oneStefano Sabatini2012-08-22
| | | | | | Fix warnings: muxing.c: In function ‘write_video_frame’: muxing.c:326:23: warning: passing argument 2 of ‘sws_scale’ from incompatible pointer type [enabled by default]
* Merge commit '36ef5369ee9b336febc2c270f8718cec4476cb85'Michael Niedermayer2012-08-07
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * commit '36ef5369ee9b336febc2c270f8718cec4476cb85': Replace all CODEC_ID_* with AV_CODEC_ID_* lavc: add AV prefix to codec ids. Conflicts: doc/APIchanges doc/examples/decoding_encoding.c doc/examples/muxing.c ffmpeg.c ffprobe.c ffserver.c libavcodec/8svx.c libavcodec/avcodec.h libavcodec/dnxhd_parser.c libavcodec/dvdsubdec.c libavcodec/error_resilience.c libavcodec/h263dec.c libavcodec/libvorbisenc.c libavcodec/mjpeg_parser.c libavcodec/mjpegenc.c libavcodec/mpeg12.c libavcodec/mpeg4videodec.c libavcodec/mpegvideo.c libavcodec/mpegvideo_enc.c libavcodec/pcm.c libavcodec/r210dec.c libavcodec/utils.c libavcodec/v210dec.c libavcodec/version.h libavdevice/alsa-audio-dec.c libavdevice/bktr.c libavdevice/v4l2.c libavformat/asfdec.c libavformat/asfenc.c libavformat/avformat.h libavformat/avidec.c libavformat/caf.c libavformat/electronicarts.c libavformat/flacdec.c libavformat/flvdec.c libavformat/flvenc.c libavformat/framecrcenc.c libavformat/img2.c libavformat/img2dec.c libavformat/img2enc.c libavformat/ipmovie.c libavformat/isom.c libavformat/matroska.c libavformat/matroskadec.c libavformat/matroskaenc.c libavformat/mov.c libavformat/movenc.c libavformat/mp3dec.c libavformat/mpeg.c libavformat/mpegts.c libavformat/mxf.c libavformat/mxfdec.c libavformat/mxfenc.c libavformat/nsvdec.c libavformat/nut.c libavformat/oggenc.c libavformat/pmpdec.c libavformat/rawdec.c libavformat/rawenc.c libavformat/riff.c libavformat/sdp.c libavformat/utils.c libavformat/vocenc.c libavformat/wtv.c libavformat/xmv.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
* examples/muxing: set codec in the codec contextStefano Sabatini2012-08-07
| | | | | | | | | | | | Make add_{audio,video}_stream return the found codec, and pass it to avcodec_open2() through open_{audio,video} functions. Fix failure: No codec provided to avcodec_open2(). could not open codec This is also consistent with the use of the avcodec_open2() API in the codebase.
* examples/muxing: drop duplicated code in add_video_stream()Stefano Sabatini2012-08-05
|
* examples/muxing: simplify alloc_picture()Stefano Sabatini2012-08-05
| | | | Use avpicture_alloc() high level function.
* doc/examples: use system headers in decoding_encoding and muxing.Clément Bœsch2012-05-19
| | | | All the other examples already use the system installed headers.
* Merge remote-tracking branch 'qatar/master'Michael Niedermayer2012-03-30
| | | | | | | | | | | | | | | | | | | | | * qatar/master: h264: drop ff_h264_ prefix from static function ff_h264_decode_rbsp_trailing() h264: Make ff_h264_decode_end() static, it is not used externally. output-example: K&R formatting cosmetics, comment spelling fixes avf: make the example output the proper message avf: fix audio writing in the output-example mov: don't overwrite existing indexes. lzw: fix potential integer overflow. truemotion: forbid invalid VLC bitsizes and token values. truemotion2: handle out-of-frame motion vectors through edge extension. configure: Check for a different SDL function Conflicts: configure doc/examples/muxing.c libavcodec/truemotion2.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
* Merge remote-tracking branch 'qatar/master'Michael Niedermayer2012-02-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * qatar/master: docs: use -bsf:[vas] instead of -[vas]bsf. mpegaudiodec: Prevent premature clipping of mp3 input buffer. lavf: move the packet keyframe setting code. oggenc: free comment header for all codecs lcl: error out if uncompressed input buffer is smaller than framesize. mjpeg: abort decoding if packet is too large. golomb: use HAVE_BITS_REMAINING() macro to prevent infloop on EOF. get_bits: add HAVE_BITS_REMAINING macro. lavf/output-example: use new audio encoding API correctly. lavf/output-example: more proper usage of the new API. tiff: Prevent overreads in the type_sizes array. tiff: Make the TIFF_LONG and TIFF_SHORT types unsigned. apetag: do not leak memory if avio_read() fails apetag: propagate errors. SBR DSP x86: implement SSE sbr_hf_g_filt SBR DSP x86: implement SSE sbr_sum_square_sse SBR DSP: use intptr_t for the ixh parameter. Conflicts: doc/bitstream_filters.texi doc/examples/muxing.c doc/ffmpeg.texi libavcodec/golomb.h libavcodec/x86/Makefile libavformat/oggenc.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
* Merge remote-tracking branch 'qatar/master'Michael Niedermayer2012-02-20
| | | | | | | | | | | | | | | | * qatar/master: doxy: remove reference to removed api examples: unbreak compilation ttadec: cosmetics: reindent sunrast: use RLE trigger macro inplace of the hard coded value. sunrastenc: set keyframe flag for the output packet. mpegvideo_enc: switch to encode2(). mpegvideo_enc: force encoding delay of at least 1 frame when low_delay=0 Conflicts: doc/examples/muxing.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
* example: update muxing example to purple APIMichael Niedermayer2012-01-28
| | | | | Reviewed-by: Paul B Mahol <onemda@gmail.com> Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* Merge remote-tracking branch 'qatar/master'Michael Niedermayer2011-12-09
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * qatar/master: cljr: K&R cosmetics cljr: return a more sensible value when encountering invalid headers cljr: drop unnecessary emms_c() calls without MMX code cljr: remove useless casts cljr: group encode/decode parts under single ifdefs cljr: remove stray semicolon cljr: add missing return statement in decode_end() doc: add pulseaudio to the input list avconv: remove unsubstantiated comment shorten: avoid abort() on unknown audio types cljr: add encoder build: merge lists of HTML documentation targets tests/examples: Mark some variables only used within their files as static. tests/tools/examples: Replace direct exit() calls by return. x86 cpuid: set vendor union members separately cljr: release picture at end of decoding rv40: NEON optimised rv40 qpel motion compensation Conflicts: doc/examples/muxing.c libavcodec/cljr.c libavcodec/version.h Merged-by: Michael Niedermayer <michaelni@gmx.at>
* doc/example/muxing: fix video timestampsMichael Niedermayer2011-12-02
| | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* muxing example: set encoder defaultsMichael Niedermayer2011-12-02
| | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* Replace remaining av_new_stream() with avformat_new_stream().Clément Bœsch2011-11-05
|
* Merge remote-tracking branch 'qatar/master'Michael Niedermayer2011-10-20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * qatar/master: presets: rename presets directory lavc: make avcodec_get_context_defaults3 "officially" public lavf: replace av_new_stream->avformat_new_stream part II. lavf,lavd: replace av_new_stream->avformat_new_stream part I. lavf: add avformat_new_stream as a replacement for av_new_stream. Use correct scaling table for bwd-pred MVs in second B-field Ut Video decoder Makefile: change presets extension to .avpreset lavfi: add rgbtestsrc source, ported from MPlayer libmpcodecs lavfi: add testsrc source AVOptions: add documentation. presets: update libx264 ffpresets Conflicts: Changelog doc/APIchanges doc/ffmpeg.texi ffpresets/libx264-ipod320.ffpreset ffpresets/libx264-ipod640.ffpreset ffserver.c libavcodec/avcodec.h libavcodec/options.c libavcodec/version.h libavdevice/libdc1394.c libavfilter/avfilter.h libavfilter/vsrc_testsrc.c libavformat/flvdec.c libavformat/riff.c libavformat/version.h libavformat/wtv.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
* Merge remote-tracking branch 'luzero/segment'Michael Niedermayer2011-10-17
| | | | | | | | | | | * luzero/segment: segment: extend options segment: basic pattern support and playlist output segment: introduce segmented chain muxer output-example: extend duration ratecontrol: estimate twice the qscale values Merged-by: Michael Niedermayer <michaelni@gmx.at>
* examples/muxing.c: apply misc style fixesStefano Sabatini2011-07-27
|
* examples/muxing.c: fix typo, futur -> futureStefano Sabatini2011-07-27
|
* examples/muxing.c: remove doxy reference to unexisting fileStefano Sabatini2011-07-10
|
* examples: rename "-example" suffix from examples filesStefano Sabatini2011-07-04
The suffix is redundant since the containing directory itself is called "examples". Simplify.