Hendrik Leppkes
c2f861ca42
Replace remaining occurances of av_free_packet with av_packet_unref
2015-10-27 14:35:30 +01:00
Hendrik Leppkes
7f5af80ba4
Merge commit 'ce70f28a1732c74a9cd7fec2d56178750bd6e457'
...
* commit 'ce70f28a1732c74a9cd7fec2d56178750bd6e457':
avpacket: Replace av_free_packet with av_packet_unref
Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
2015-10-27 14:28:56 +01:00
Luca Barbato
ce70f28a17
avpacket: Replace av_free_packet with av_packet_unref
...
`av_packet_unref` matches the AVFrame ref-counted API and can be used as
a drop in replacement.
Deprecate `av_free_packet`.
2015-10-26 18:00:55 +01:00
Michael Niedermayer
83fc0b9d48
doc/examples/muxing: Fix mixed declaration and code
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-10-15 00:24:00 +02:00
Hendrik Leppkes
1899b25799
Merge commit '34ed5c2e4d9b7fe5c9b3aae2da5599fabb95c02e'
...
* commit '34ed5c2e4d9b7fe5c9b3aae2da5599fabb95c02e':
avformat: Do not use AVFMT_RAWPICTURE
Removal from ffmpeg.c not merged because some parts of avdevice
still use it
Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
2015-10-14 14:43:20 +02:00
Luca Barbato
34ed5c2e4d
avformat: Do not use AVFMT_RAWPICTURE
...
There are no formats supporting it anymore and it is deprecated.
Update the documentation accordingly.
2015-10-13 13:43:29 +02:00
Hendrik Leppkes
b1284a4b4a
Merge commit '539e5ac2ecfec2e2f441222a43fb0583643ea607'
...
* commit '539e5ac2ecfec2e2f441222a43fb0583643ea607':
examples/qsvdec: free the lavc decoder before closing MFX/VAAPI
Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
2015-09-29 14:17:29 +02:00
Hendrik Leppkes
d0a1605134
Merge commit '3ee462dca1038e63b8e8d5e751121736d5772a5d'
...
* commit '3ee462dca1038e63b8e8d5e751121736d5772a5d':
examples/qsvdec: do not free the surfaces in the frame_free() callback
Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
2015-09-29 14:17:23 +02:00
Anton Khirnov
539e5ac2ec
examples/qsvdec: free the lavc decoder before closing MFX/VAAPI
...
lavc expects MFX to still be in a usable state on close.
2015-09-28 15:46:10 +02:00
Anton Khirnov
3ee462dca1
examples/qsvdec: do not free the surfaces in the frame_free() callback
...
Even though libmfx might not need them anymore, avcodec might still
access the surfaces. So free them separately at the end.
2015-09-28 15:45:29 +02:00
Clément Bœsch
d9464e9c14
doc/examples/demuxing_decoding: simplify api_mode to refcount
...
This finalizes the quick cleanup of a753e6c9f5
.
2015-09-06 12:35:00 +02:00
Michael Niedermayer
a753e6c9f5
doc/examples/demuxing_decoding: Drop old api mode, because the code fails to build otherwise
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-09-05 18:25:24 +02:00
Hendrik Leppkes
144fb06806
Remove left-over FF_API_AVFILTERBUFFER cruft
2015-09-05 16:27:19 +02:00
Michael Niedermayer
e9c58033e8
doc/examples/http_multiclient: Fix occured typo
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-09-04 11:30:25 +02:00
Harshit Mittal
53bf32fa42
doc/examples/filtering_video: better demo ffmpeg filters; demos chaining the filters
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-08-28 12:53:35 +02:00
Mariusz Szczepańczyk
767d780ec0
doc/examples: rename avio_list_dir -> avio_dir_cmd
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-08-16 02:16:47 +02:00
Mariusz Szczepańczyk
c84d208c27
examples/avio_list_dir: add move and delete methods
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-08-15 03:32:38 +02:00
Stephan Holljes
25410c524d
doc/example: Add http multi-client example code
...
Signed-off-by: Stephan Holljes <klaxa1337@googlemail.com>
2015-08-01 00:58:32 +02:00
Michael Niedermayer
29d147c94d
Merge commit '059a934806d61f7af9ab3fd9f74994b838ea5eba'
...
* commit '059a934806d61f7af9ab3fd9f74994b838ea5eba':
lavc: Consistently prefix input buffer defines
Conflicts:
doc/examples/decoding_encoding.c
libavcodec/4xm.c
libavcodec/aac_adtstoasc_bsf.c
libavcodec/aacdec.c
libavcodec/aacenc.c
libavcodec/ac3dec.h
libavcodec/asvenc.c
libavcodec/avcodec.h
libavcodec/avpacket.c
libavcodec/dvdec.c
libavcodec/ffv1enc.c
libavcodec/g2meet.c
libavcodec/gif.c
libavcodec/h264.c
libavcodec/h264_mp4toannexb_bsf.c
libavcodec/huffyuvdec.c
libavcodec/huffyuvenc.c
libavcodec/jpeglsenc.c
libavcodec/libxvid.c
libavcodec/mdec.c
libavcodec/motionpixels.c
libavcodec/mpeg4videodec.c
libavcodec/mpegvideo.c
libavcodec/noise_bsf.c
libavcodec/nuv.c
libavcodec/nvenc.c
libavcodec/options.c
libavcodec/parser.c
libavcodec/pngenc.c
libavcodec/proresenc_kostya.c
libavcodec/qsvdec.c
libavcodec/svq1enc.c
libavcodec/tiffenc.c
libavcodec/truemotion2.c
libavcodec/utils.c
libavcodec/utvideoenc.c
libavcodec/vc1dec.c
libavcodec/wmalosslessdec.c
libavformat/adxdec.c
libavformat/aiffdec.c
libavformat/apc.c
libavformat/apetag.c
libavformat/avidec.c
libavformat/bink.c
libavformat/cafdec.c
libavformat/flvdec.c
libavformat/id3v2.c
libavformat/isom.c
libavformat/matroskadec.c
libavformat/mov.c
libavformat/mpc.c
libavformat/mpc8.c
libavformat/mpegts.c
libavformat/mvi.c
libavformat/mxfdec.c
libavformat/mxg.c
libavformat/nutdec.c
libavformat/oggdec.c
libavformat/oggparsecelt.c
libavformat/oggparseflac.c
libavformat/oggparseopus.c
libavformat/oggparsespeex.c
libavformat/omadec.c
libavformat/rawdec.c
libavformat/riffdec.c
libavformat/rl2.c
libavformat/rmdec.c
libavformat/rtpdec_latm.c
libavformat/rtpdec_mpeg4.c
libavformat/rtpdec_qdm2.c
libavformat/rtpdec_svq3.c
libavformat/sierravmd.c
libavformat/smacker.c
libavformat/smush.c
libavformat/spdifenc.c
libavformat/takdec.c
libavformat/tta.c
libavformat/utils.c
libavformat/vqf.c
libavformat/westwood_vqa.c
libavformat/xmv.c
libavformat/xwma.c
libavformat/yop.c
Merged-by: Michael Niedermayer <michael@niedermayer.cc>
2015-07-27 23:15:19 +02:00
Michael Niedermayer
444e9874a7
Merge commit 'def97856de6021965db86c25a732d78689bd6bb0'
...
* commit 'def97856de6021965db86c25a732d78689bd6bb0':
lavc: AV-prefix all codec capabilities
Conflicts:
cmdutils.c
ffmpeg.c
ffplay.c
libavcodec/8svx.c
libavcodec/aacenc.c
libavcodec/ac3dec.c
libavcodec/adpcm.c
libavcodec/alac.c
libavcodec/atrac3plusdec.c
libavcodec/bink.c
libavcodec/dnxhddec.c
libavcodec/dvdec.c
libavcodec/dvenc.c
libavcodec/ffv1dec.c
libavcodec/ffv1enc.c
libavcodec/fic.c
libavcodec/flacdec.c
libavcodec/flacenc.c
libavcodec/flvdec.c
libavcodec/fraps.c
libavcodec/frwu.c
libavcodec/gifdec.c
libavcodec/h261dec.c
libavcodec/hevc.c
libavcodec/iff.c
libavcodec/imc.c
libavcodec/libopenjpegdec.c
libavcodec/libvo-aacenc.c
libavcodec/libvorbisenc.c
libavcodec/libvpxdec.c
libavcodec/libvpxenc.c
libavcodec/libx264.c
libavcodec/mjpegbdec.c
libavcodec/mjpegdec.c
libavcodec/mpegaudiodec_float.c
libavcodec/msmpeg4dec.c
libavcodec/mxpegdec.c
libavcodec/nvenc_h264.c
libavcodec/nvenc_hevc.c
libavcodec/pngdec.c
libavcodec/qpeg.c
libavcodec/ra288.c
libavcodec/rv10.c
libavcodec/s302m.c
libavcodec/sp5xdec.c
libavcodec/takdec.c
libavcodec/tiff.c
libavcodec/tta.c
libavcodec/utils.c
libavcodec/v210dec.c
libavcodec/vp6.c
libavcodec/vp9.c
libavcodec/wavpack.c
libavcodec/yop.c
Merged-by: Michael Niedermayer <michael@niedermayer.cc>
2015-07-27 22:50:18 +02:00
Michael Niedermayer
94d68a41fa
Merge commit '7c6eb0a1b7bf1aac7f033a7ec6d8cacc3b5c2615'
...
* commit '7c6eb0a1b7bf1aac7f033a7ec6d8cacc3b5c2615':
lavc: AV-prefix all codec flags
Conflicts:
doc/examples/muxing.c
ffmpeg.c
ffmpeg_opt.c
ffplay.c
libavcodec/aacdec.c
libavcodec/aacenc.c
libavcodec/ac3dec.c
libavcodec/ac3enc_float.c
libavcodec/atrac1.c
libavcodec/atrac3.c
libavcodec/atrac3plusdec.c
libavcodec/dcadec.c
libavcodec/ffv1enc.c
libavcodec/h264.c
libavcodec/h264_loopfilter.c
libavcodec/h264_mb.c
libavcodec/imc.c
libavcodec/libmp3lame.c
libavcodec/libtheoraenc.c
libavcodec/libtwolame.c
libavcodec/libvpxenc.c
libavcodec/libxavs.c
libavcodec/libxvid.c
libavcodec/mpeg12dec.c
libavcodec/mpeg12enc.c
libavcodec/mpegaudiodec_template.c
libavcodec/mpegvideo.c
libavcodec/mpegvideo_enc.c
libavcodec/mpegvideo_motion.c
libavcodec/nellymoserdec.c
libavcodec/nellymoserenc.c
libavcodec/nvenc.c
libavcodec/on2avc.c
libavcodec/options_table.h
libavcodec/opus_celt.c
libavcodec/pngenc.c
libavcodec/ra288.c
libavcodec/ratecontrol.c
libavcodec/twinvq.c
libavcodec/vc1_block.c
libavcodec/vc1_loopfilter.c
libavcodec/vc1_mc.c
libavcodec/vc1dec.c
libavcodec/vorbisdec.c
libavcodec/vp3.c
libavcodec/wma.c
libavcodec/wmaprodec.c
libavcodec/x86/hpeldsp_init.c
libavcodec/x86/me_cmp_init.c
Merged-by: Michael Niedermayer <michael@niedermayer.cc>
2015-07-27 22:10:35 +02:00
Vittorio Giovara
059a934806
lavc: Consistently prefix input buffer defines
...
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2015-07-27 15:24:59 +01:00
Vittorio Giovara
def97856de
lavc: AV-prefix all codec capabilities
...
Express bitfields more simply.
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2015-07-27 15:24:58 +01:00
Vittorio Giovara
7c6eb0a1b7
lavc: AV-prefix all codec flags
...
Convert doxygen to multiline and express bitfields more simply.
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2015-07-27 15:24:58 +01:00
Andreas Cadhalpun
dd6c8575db
examples/demuxing_decoding: use properties from frame instead of video_dec_ctx
...
This is more robust.
And only check if there is actually a frame returned.
Reviewed-by: Michael Niedermayer <michaelni@gmx.at>
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
2015-06-15 18:32:18 +02:00
Andreas Cadhalpun
ed0b1db640
doc: fix spelling errors
...
Neccessary -> Necessary
formated -> formatted
thee -> the
eventhough -> even though
seperately -> separately
Reviewed-by: Michael Niedermayer <michaelni@gmx.at>
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
2015-06-14 15:09:33 +02:00
Michael Niedermayer
b8ba2d3915
examples/decoding_encoding: Use the AVFrame width/height for processing images after decoding
...
This is what FFmpeg / FFplay do and it is more robust
Reviewed-by: Stefano Sabatini <stefasab@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-13 02:14:26 +02:00
Lukasz Marek
f79cd98caf
examples/avio_list_dir: init/deinit network
...
Signed-off-by: Lukasz Marek <lukasz.m.luki2@gmail.com>
2015-04-06 15:50:26 +02:00
Mariusz Szczepańczyk
f10aa0e125
doc/examples: Handle new types in avio_list_dir
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-04-03 04:09:40 +02:00
Lukasz Marek
56b7aa2138
doc/examples: add directory listing example
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-28 03:13:44 +01:00
Michael Niedermayer
e73b3dba3e
Merge commit '990e4a6639d0714198583c2812b1074b5751898f'
...
* commit '990e4a6639d0714198583c2812b1074b5751898f':
Add a QSV decoding example.
Conflicts:
configure
doc/Makefile
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-01 00:30:20 +01:00
Anton Khirnov
990e4a6639
Add a QSV decoding example.
2015-02-28 21:51:24 +01:00
Andreas Cadhalpun
078be09dd7
examples/demuxing_decoding: abort decoding when width, height or pix_fmt change
...
This is necessary, because avcodec_decode_video2 can change
width, height and/or pixel format of the AVCodecContext. Since
video_dst_data and video_dst_linesize are not updated by calling
av_image_alloc again, av_image_copy[_plane] asserts, because the
destination buffer is too small.
In this case, creating a useable rawvideo is not possible anyway, since
it has fixed width/height/pix_fmt.
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-02-10 02:43:47 +01:00
Andreas Cadhalpun
2a3b7a55b5
examples/demuxing_decoding: set stream_idx in open_codec_context only if no error occured
...
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-01-31 21:54:36 +01:00
Stefano Sabatini
d43c1ec684
examples/filtering: extend comments about setting the filter graph endpoints
...
That part is a constant source of confusions for readers, this should
help clarify the apparently inverted logic.
2015-01-29 11:12:39 +01:00
Michael Niedermayer
e5c28d4f9a
Merge commit '3a70c0c95feacb3844d05eebd579fc8189a77eee'
...
* commit '3a70c0c95feacb3844d05eebd579fc8189a77eee':
examples/transcode_aac: generate proper PTS and set the muxer timebase
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-01-27 13:35:31 +01:00
Michael Niedermayer
d078d57fb7
Merge commit 'c9b19ac8928c6c9b7f25c3988177204f110d5e0e'
...
* commit 'c9b19ac8928c6c9b7f25c3988177204f110d5e0e':
examples/transcode_aac: fix a typo
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-01-27 13:29:46 +01:00
Michael Niedermayer
010311d673
Merge commit '749a89d1b8bb73b4d4f14c48f33259a1300c1761'
...
* commit '749a89d1b8bb73b4d4f14c48f33259a1300c1761':
examples/transcode_aac: properly select the output sample format
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-01-27 13:21:02 +01:00
Andreas Unterweger
3a70c0c95f
examples/transcode_aac: generate proper PTS and set the muxer timebase
...
Signed-off-by: Anton Khirnov <anton@khirnov.net>
2015-01-27 09:03:08 +01:00
Andreas Unterweger
c9b19ac892
examples/transcode_aac: fix a typo
...
Signed-off-by: Anton Khirnov <anton@khirnov.net>
2015-01-27 09:00:23 +01:00
Andreas Unterweger
749a89d1b8
examples/transcode_aac: properly select the output sample format
...
Makes the example work with all the supported AAC encoders.
Signed-off-by: Anton Khirnov <anton@khirnov.net>
2015-01-27 08:58:47 +01:00
Andreas Cadhalpun
f97f2a3527
doc/examples: fix lib math dep for decoding_encoding
...
It uses at least sin().
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-01-10 04:50:42 +01:00
Michael Niedermayer
a85f033149
doc/examples/transcoding: Use avio_closep() in examples as it avoids leaving stale pointers
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-01-08 05:29:10 +01:00
Michael Niedermayer
a63c17cec7
idoc/examples/remuxing: Use avio_closep() in examples as it avoids leaving stale pointers
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-01-08 05:28:59 +01:00
Michael Niedermayer
c61b84ccfd
doc/examples/transcode_aac: Use avio_closep() in examples as it avoids leaving stale pointers
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-01-08 05:28:51 +01:00
Michael Niedermayer
1d2410639d
doc/examples/muxing: Use avio_closep() in examples as it avoids leaving stale pointers
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-01-08 05:28:15 +01:00
Piotr Fusik
c99e5191ab
doc/examples/filtering_video: fix frame rate
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-05 16:52:19 +01:00
Michael Niedermayer
bde27e1e61
doc/examples/transcoding: check encoder before using it
...
Fixes null pointer exception
Found-by: stoupeace
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-04 18:58:38 +01:00
Michael Niedermayer
e6ea75c5e6
doc/examples/decoding_encoding: fix storing all channels
...
Fixes Ticket3355
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-11-24 22:01:33 +01:00
Michael Niedermayer
230aeee94c
doc: fix the the typos
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-11-22 02:09:09 +01:00
Stefano Sabatini
3a0c70f1e3
doc/examples/transcoding: use av_packet_rescale_ts()
...
Simplify.
2014-09-16 14:55:33 +02:00
Michael Niedermayer
68bca03951
doc/examples: remove unneeded NULL checks
...
dst_file cannot be NULL
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-09-14 16:45:50 +02:00
Clément Bœsch
b0352b1997
avcodec: export motion vectors in frame side data on demand
...
The reasoning behind this addition is that various third party
applications are interested in getting some motion information out of a
video "for free" when it is available.
It was considered to export other information as well (such as the intra
information about the block, or the quantization) but the structure
might have ended up into a half full-generic, half full of codec
specific cruft. If more information is necessary, it should either be
added in the "flags" field of the AVMotionVector structure, or in
another side-data.
This commit also includes an example exporting them in a CSV stream.
2014-08-18 14:13:57 +02:00
Timothy Gu
9f02a2b224
transcode_aac: fix const return value
...
Fixes Trac #3613 .
Signed-off-by: Timothy Gu <timothygu99@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-08-06 04:01:19 +02:00
Michael Niedermayer
f1d6fc7794
Merge commit '6a928293dd29c7f0dcf09107980a1d651c9957df'
...
* commit '6a928293dd29c7f0dcf09107980a1d651c9957df':
examples: filter_audio: Add missing mem.h header for av_freep()
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-08-03 19:18:25 +02:00
Diego Biurrun
6a928293dd
examples: filter_audio: Add missing mem.h header for av_freep()
2014-08-03 01:29:43 -07:00
Michael Niedermayer
f285056810
doc/examples/muxing: fix "-flags" option
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-07-27 19:58:47 +02:00
Michael Niedermayer
c437765be7
doc/examples/muxing: Exchange tmp_frame and frame
...
Reduces difference to 56f98e340f
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-07-27 12:03:51 +02:00
Michael Niedermayer
d1ce43a3e8
doc/examples/muxing: mark correct frame as writeable
...
Bug found from comparing 56f98e340f
to HEAD
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-07-27 01:55:17 +02:00
Michael Niedermayer
fbd46e2f1c
doc/examples/muxing: Always use swr, simplifies code slightly
...
Idea-from: 56f98e340f
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-07-27 01:32:19 +02:00
Anton Khirnov
22e9fe06eb
doc/examples/muxing: add alloc_audio_frame() and use it to simplify code.
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-07-27 01:15:39 +02:00
Michael Niedermayer
a98cadef7f
doc/examples/muxing: Move samples_count to OutputStream
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-07-27 01:05:05 +02:00
Michael Niedermayer
8b1d54ba40
doc/examples/muxing: free swr context at the end
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-07-27 00:50:58 +02:00
Michael Niedermayer
7cf0865551
doc/examples/muxing: Support setting flags, for example for setting bitexact
...
This would allow the example to be used in regression tests
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-07-26 22:49:02 +02:00
Michael Niedermayer
5d2cf1ae86
doc/examples/muxing: select a supported sample rate for the encoder, favor 44100
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-07-26 22:27:50 +02:00
Michael Niedermayer
ead22f42f4
doc/examples/muxing: pick a supported channel layout if stereo isnt supported by the encoder
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-07-26 22:01:08 +02:00
Michael Niedermayer
9ccb9c8df2
doc/examples/muxing: move swr context to OutputStream
...
Idea from: 56f98e340f
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-07-26 21:50:21 +02:00
Michael Niedermayer
1c0c19f8bd
Merge commit '884f7c975f0af25febe86660e87bf3b2165a0309'
...
* commit '884f7c975f0af25febe86660e87bf3b2165a0309':
output example: set the stream timebase
Conflicts:
doc/examples/muxing.c
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-07-26 21:04:31 +02:00
Anton Khirnov
56f98e340f
output example: convert audio to the format supported by the encoder
2014-07-26 14:57:59 +00:00
Anton Khirnov
884f7c975f
output example: set the stream timebase
...
This is required by the new API.
2014-07-26 14:57:45 +00:00
Diego Biurrun
6cc1409ba8
examples/output: Remove unused variable
...
doc/examples/output.c:460:9: warning: unused variable ‘i’
2014-07-11 07:23:50 -07:00
Timothy Gu
3be90723e7
transcoding: fix Doxygen file path
...
Signed-off-by: Timothy Gu <timothygu99@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-07-07 13:15:32 +02:00
Michael Niedermayer
cddbf95c5f
doc/examples/resampling_audio: use av_freep() for saftey
...
also its better in examples to use the safer functions.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-06-29 16:26:38 +02:00
Michael Niedermayer
4d3072ada3
doc/examples/muxing: remove unused variable
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-06-28 21:44:38 +02:00
Michael Niedermayer
8469c73576
Merge commit '182d3f8221c23716ea4eafa460bdb94968f71f26'
...
* commit '182d3f8221c23716ea4eafa460bdb94968f71f26':
output example: rewrite encoding logic
Conflicts:
doc/examples/muxing.c
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-06-27 00:57:04 +02:00
Michael Niedermayer
9a2850c26a
Merge commit 'a7fcd4122b19b0f934020f4e261d0c44c4c32e11'
...
* commit 'a7fcd4122b19b0f934020f4e261d0c44c4c32e11':
output example: store the scaling context in the stream context
Conflicts:
doc/examples/muxing.c
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-06-27 00:16:34 +02:00
Michael Niedermayer
877716a79c
Merge commit '6a927d7aaf5625e83a674072913b9e292a303fd1'
...
* commit '6a927d7aaf5625e83a674072913b9e292a303fd1':
output example: use a macro instead of a static variable
Conflicts:
doc/examples/muxing.c
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-06-26 23:58:00 +02:00
Michael Niedermayer
5a55d5e445
Merge commit '63fd0d866c8300a8f251a15b1535e9ce40a407fb'
...
* commit '63fd0d866c8300a8f251a15b1535e9ce40a407fb':
output example: allocate the audio frame only once
Conflicts:
doc/examples/muxing.c
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-06-26 23:22:08 +02:00
Michael Niedermayer
b9bfd888e5
Merge commit 'edd5f957646dcbf1bb55718bc7bf1e5481c25bcb'
...
* commit 'edd5f957646dcbf1bb55718bc7bf1e5481c25bcb':
output example: use OutputStream for audio streams as well
Conflicts:
doc/examples/muxing.c
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-06-26 23:01:52 +02:00
Michael Niedermayer
11991a7d90
Merge commit '5e7b125b6ae36893dfd9cb5661c99b67363cbb38'
...
* commit '5e7b125b6ae36893dfd9cb5661c99b67363cbb38':
output example: use the new AVFrame API to allocate audio frames
Conflicts:
doc/examples/muxing.c
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-06-26 22:46:11 +02:00
Michael Niedermayer
a1c4635558
Merge commit 'ac85f631c9a9cc59aaca1c8dd6894fb1f701c594'
...
* commit 'ac85f631c9a9cc59aaca1c8dd6894fb1f701c594':
output example: set output channel layout
Conflicts:
doc/examples/muxing.c
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-06-26 22:13:46 +02:00
Michael Niedermayer
8eb1174a9e
Merge commit '294daf71a7a1303b5ddd3cbefebed3b732d610f3'
...
* commit '294daf71a7a1303b5ddd3cbefebed3b732d610f3':
output example: use a struct to bundle the video stream variables together
Conflicts:
doc/examples/muxing.c
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-06-26 21:55:11 +02:00
Michael Niedermayer
c9083d85df
Merge commit '38d044429dabcd28928693240e955c6d4430cca9'
...
* commit '38d044429dabcd28928693240e955c6d4430cca9':
output example: use the new AVFrame API for allocating the video frame
Conflicts:
doc/examples/muxing.c
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-06-26 21:30:37 +02:00
Anton Khirnov
a5864e9a25
output example: free the muxing format context properly
2014-06-26 16:08:06 +02:00
Anton Khirnov
182d3f8221
output example: rewrite encoding logic
...
Properly generate pts for the frames sent to the encoder, avoid
using private and deprecated AVStream.pts.
2014-06-26 16:07:34 +02:00
Anton Khirnov
a7fcd4122b
output example: store the scaling context in the stream context
2014-06-26 16:07:29 +02:00
Anton Khirnov
6a927d7aaf
output example: use a macro instead of a static variable
2014-06-26 16:07:23 +02:00
Anton Khirnov
63fd0d866c
output example: allocate the audio frame only once
2014-06-26 16:07:08 +02:00
Anton Khirnov
edd5f95764
output example: use OutputStream for audio streams as well
2014-06-26 16:07:02 +02:00
Anton Khirnov
5e7b125b6a
output example: use the new AVFrame API to allocate audio frames
2014-06-26 16:06:54 +02:00
Anton Khirnov
ac85f631c9
output example: set output channel layout
2014-06-26 16:06:48 +02:00
Anton Khirnov
294daf71a7
output example: use a struct to bundle the video stream variables together
2014-06-26 16:05:24 +02:00
Anton Khirnov
38d044429d
output example: use the new AVFrame API for allocating the video frame
2014-06-26 16:05:19 +02:00
Michael Niedermayer
afa7ab557a
Merge commit '452860d7e056f9a894cac2fe52cdedeae4c38251'
...
* commit '452860d7e056f9a894cac2fe52cdedeae4c38251':
Use av_packet_rescale_ts() to simplify code.
Conflicts:
doc/examples/muxing.c
ffmpeg.c
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-06-20 17:03:58 +02:00
Anton Khirnov
452860d7e0
Use av_packet_rescale_ts() to simplify code.
2014-06-20 14:14:48 +02:00
Lou Logan
88f2586adb
fix various typos
...
Signed-off-by: Lou Logan <lou@lrcd.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-06-03 10:58:19 -08:00
Stefano Sabatini
bf411fffd4
examples: rename avcodec.c to decoding_encoding.c
...
Restore the old name, which was more meaningful and consistent with the
names of the other examples.
2014-04-23 10:32:42 +02:00
Michael Niedermayer
9b467d3cd5
examples/transcoding: use av_malloc_array()
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-08 15:35:14 +02:00
Michael Niedermayer
419800acc4
examples/avio_reading: fix null dereference on error
...
Fixed CID1197052
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-06 00:39:58 +02:00
Anshul Maheshwari
6d25e90262
doc/examples/avcodec: information regarding gop_size ignored if frame->pic-type is AV_PICTURE_TYPE_I
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-03-21 15:21:15 +01:00
Andrey Utkin
e10ab43614
doc/examples: Add example transcoding.c
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-03-17 20:56:33 +01:00
compn
84bccae8e9
doc: fix typo
2014-03-07 17:07:37 -05:00
Jason Hsu
8fb4dba89d
doc/examples/remuxing: dont use the input codec_tag, it may be invalid tor the output
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-03-05 16:10:06 +01:00
Michael Niedermayer
1f2bacc897
Merge commit 'e7dfaf16a403972eb6aed5ce8f84c0085bd2fb5a'
...
* commit 'e7dfaf16a403972eb6aed5ce8f84c0085bd2fb5a':
libavfilter: example audio filtering program
Conflicts:
.gitignore
configure
doc/Makefile
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-02-25 20:26:00 +01:00
Anton Khirnov
e7dfaf16a4
libavfilter: example audio filtering program
...
Based on a patch by Andrew Kelley <superjoe30@gmail.com>
Signed-off-by: Diego Biurrun <diego@biurrun.de>
2014-02-25 13:22:10 +01:00
Michael Niedermayer
341639fe80
doc/examples: remove pathes from doxy examples
...
This makes the examples page less cluttered
Reviewed-by: Clément Bœsch <u@pkh.me>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-02-17 13:50:53 +01:00
Michael Niedermayer
1fc74926a5
Merge commit 'b339182eba34f28de5f1a477cdd2c84f1ef35d90'
...
* commit 'b339182eba34f28de5f1a477cdd2c84f1ef35d90':
Move all example programs to doc/examples
Conflicts:
configure
doc/Makefile
doc/doxy-wrapper.sh
doc/examples/avcodec.c
doc/examples/decoding_encoding.c
doc/examples/metadata.c
doc/examples/muxing.c
doc/examples/transcode_aac.c
libavcodec/Makefile
libavcodec/api-example.c
libavformat/Makefile
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-02-17 02:22:01 +01:00
Diego Biurrun
b339182eba
Move all example programs to doc/examples
...
Also drop support for building examples in library directories.
2014-02-16 21:37:21 +01:00
Michael Niedermayer
fba1592f35
Merge remote-tracking branch 'qatar/master'
...
* qatar/master:
doc/examples: misc Doxygen markup improvements
Conflicts:
doc/examples/muxing.c
doc/examples/transcode_aac.c
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-02-14 15:31:14 +01:00
Diego Biurrun
0b9716c455
doc/examples: misc Doxygen markup improvements
...
Add properly formatted @example tag and fix Doxygen syntax.
2014-02-14 12:01:36 +01:00
Stefano Sabatini
60251c13e3
examples/avio_reading: remove stray empty line
2014-02-02 12:35:46 +01:00
Stefano Sabatini
5fc4dea39c
examples: add avio_reading.c example
2014-02-02 11:58:23 +01:00
Michael Niedermayer
a85a718f26
doc/examples/decoding_encoding: Check all av_samples_get_buffer_size() returns
...
Fixed CID1135755
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-01-31 03:27:37 +01:00
Stefano Sabatini
ca57659440
examples/filtering_audio,video: do not call avcodec_register_all()
...
It is implied by av_register_all(). Simplify.
2014-01-24 12:20:46 +01:00
Stefano Sabatini
35fe88bb51
examples/muxing: reindent after previous commit
2014-01-23 01:08:24 +01:00
Stefano Sabatini
c92d2f98db
examples/muxing: flush encoders at the end
2014-01-23 00:54:33 +01:00
Stefano Sabatini
b539a72bba
examples/filtering_audio,video: drop call to avcodec_get_frame_defaults()
...
The avcodec_get_frame_defaults() function is deprecated and its use
doesn't seem required.
2014-01-21 20:08:36 +01:00
Stefano Sabatini
e34ad128a3
examples/muxing: reduce duration, remove wrong and misleading comment
...
Set duration to 10 seconds, after it was increased from 5 to 200 seconds
in 8d80f3cb87
.
200 seconds will generate too much data which is annoying especially when
testing.
2014-01-21 11:52:14 +01:00
Stefano Sabatini
9ab8f3738a
examples/muxing: remove redundant {}
2014-01-20 13:10:10 +01:00
Stefano Sabatini
b933c72b5e
examples/muxing: change error checks, from "ret != 0" to "ret < 0"
...
More consistent and more future-proof.
2014-01-20 13:10:10 +01:00
Stefano Sabatini
d72c742d47
examples/muxing: factorize write_interleave code
...
Also log output packet information.
2014-01-20 13:10:10 +01:00
Stefano Sabatini
5e2b8e4934
examples: add remuxing example
...
Show how to perform streamcopy from one container to another.
2014-01-20 13:10:10 +01:00
Stefano Sabatini
d497141b85
examples/muxing: simplify video PTS setting
...
Rely on frame_count. Also more consistent with audio path.
2014-01-12 09:25:48 +01:00
Andre Anjos
23ffc4c70d
doc/examples/muxing: Fixes frame initialization.
...
Fixes use of the example with encoders which use tha AVFrame w/h/pix_fmt fields
FFV1 is one of these codecs
We cannot easily workaround the not set fields in common code because the API
has AVFrame constant for the encoders.
Alternatives would be to fix the API or to duplicate the struct and fill in
missing fields. Or as is to require all user apps to set this correctly and
maybe simplify for that case
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-01-09 18:12:24 +01:00
Stefano Sabatini
094c500caf
examples/muxing: set timestamps in output audio packet
...
In particular, fix trac ticket #3231 .
2014-01-09 10:54:38 +01:00
Stefano Sabatini
8d22d37e54
examples/muxing: use av_frame_free() in place of av_free()
2014-01-09 10:51:57 +01:00
Stefano Sabatini
9abe4a10fd
examples/muxing: reuse global audio frame
...
Simplify logic, avoid multiple unnecessary alloc/free operations.
2014-01-09 10:51:52 +01:00
Stefano Sabatini
80bca6eabe
examples/muxing: honour distinction between encoder PTS timebase and stream timebase
...
Fix PTS set on the frame when encoding, which must be specified in the
encoder timebase or this will confuse the encoder.
When muxing the packet, the PTS/DTS generated by the encoder is then
rescaled to the stream timebase.
2014-01-09 10:51:47 +01:00
Stefano Sabatini
eadc421259
examples/muxing: set sample formats from list of codec supported sample formats
...
Avoid the need of tweaking, also show how to get list of supported sample
formats.
2014-01-09 10:51:41 +01:00
Stefano Sabatini
2503928a2f
examples/decoding_encoding: fix style nits
2014-01-07 13:08:11 +01:00
Ilya Basin
d1b8e01ef1
examples/muxing: fix memleaks in resampler
...
- do not allocate resample dst buffer when resample is off
- free sample buffers in addition to freeing data pointer arrays
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-12-21 12:22:49 +01:00
Ilya Basin
7d1d0b3ecf
examples/muxing: use S16 sample_fmt for resample src regardless of codec sample_fmt
...
We generate S16 samples and we should allocate the right buffer
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-12-21 12:21:05 +01:00
Ilya Basin
b6714fa077
examples/muxing: fix av_frame_free() not called when got_packet is false
...
Hi list! Since my last patch (fix 2 memleaks in doc/examples/muxing.c)
I found more problems to fix.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-12-21 12:20:44 +01:00
Stefano Sabatini
b2a4316287
examples/decoding_encoding: check av_samples_get_buffer_size() for a negative value
...
Fix broken != 0 check.
2013-12-15 20:09:26 +01:00
Timothy Gu
c65fe9e982
examples/decoding_encoding: check av_samples_get_buffer_size() return code
...
Fixes CID1135756.
Signed-off-by: Timothy Gu <timothygu99@gmail.com>
2013-12-14 14:02:49 +01:00
Timothy Gu
b242c156e5
examples/resample_audio: check av_samples_get_buffer_size() return code
...
Fixes CID1135757.
Signed-off-by: Timothy Gu <timothygu99@gmail.com>
2013-12-14 14:02:33 +01:00
Clément Bœsch
b02d87936b
examples/demuxing_decoding: print the decoding error when it happens.
2013-12-13 10:37:20 +01:00
Even Wiik Thomassen
43f116d162
examples/demuxing_decoding: return error when no codec found
...
The open_codec_context function, when it fails to find a codec, now
return AVERROR(EINVAL) to signal an error.
Before it would return the stream index, which was always >= 0, and
continue as if a codec was found. This change make it fail faster,
instead of repeated failed tries to decode frames with no codec.
Signed-off-by: Even Wiik Thomassen <e.thomassen@sportradar.com>
Signed-off-by: Stefano Sabatini <stefasab@gmail.com>
2013-12-13 09:45:54 +01:00
Michael Niedermayer
525a7d9b78
Merge commit '48d17ee6dc2b2a552f645484f200c2946bf24607'
...
* commit '48d17ee6dc2b2a552f645484f200c2946bf24607':
api-example: remove an unneeded call to avcodec_get_frame_defaults().
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2013-12-12 00:19:53 +01:00
Michael Niedermayer
4cbf3eb9e6
Merge commit 'eb891b3114f499e96b9faddd0b0ae856345dfbd9'
...
* commit 'eb891b3114f499e96b9faddd0b0ae856345dfbd9':
Replace all uses of avcodec_free_frame with av_frame_free().
Conflicts:
doc/examples/decoding_encoding.c
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2013-12-11 23:18:51 +01:00
Anton Khirnov
eb891b3114
Replace all uses of avcodec_free_frame with av_frame_free().
2013-12-11 20:39:54 +01:00
Michael Niedermayer
210a78aeb5
doc/examples/filtering_audio: init packet0.data
...
Fixes use of uinitialized data and crash
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-12-03 00:01:07 +01:00
Stefano Sabatini
c490cd4c1a
doc/examples/filtering_audio: fix chunked audio decoding
...
Support the case when multiple frames are contained in a single packet.
In particular, fix fate-samples/lossless-audio/luckynight-partial.shn
sample decoding.
2013-12-02 15:21:52 +01:00
Stefano Sabatini
893f33e7f0
doc/examples/filtering_audio: fix style
2013-12-02 15:08:00 +01:00
Stefano Sabatini
c7a99d99bd
doc/examples/filtering_video: do not make use of AVBufferSinkParams
...
Set the value on the filter context instead. Simplify.
2013-12-02 14:35:40 +01:00
Stefano Sabatini
3aa6018010
doc/examples/filtering_video: add some error handling in init_filters()
2013-12-02 14:35:39 +01:00
Stefano Sabatini
a12bf9f50f
doc/examples/README: fix typo
2013-12-02 14:35:39 +01:00
Stefano Sabatini
55c57658d2
doc/examples/filtering_audio: add more error checks
2013-12-02 14:35:39 +01:00
Stefano Sabatini
82e74ee6e4
doc/examples/filtering: make use of av_err2str()
...
Simplify.
2013-12-02 14:35:31 +01:00
Clément Bœsch
0d2c832445
doc/examples: update README.
2013-11-28 14:08:06 +01:00