Clément Bœsch
fb10b43fc4
doc/examples: rename demuxing to demuxing_decoding.
...
That example shows how the decoding process works, not only the
demuxing.
2013-11-04 12:53:06 +01:00
Clément Bœsch
d10b1a200d
doc/examples/demuxing: show how to use the reference counting system.
2013-11-04 12:53:06 +01:00
Clément Bœsch
0c6bb53bb2
doc/examples/demuxing: reset got_frame.
...
Fix infinite loop at flushing.
2013-10-30 14:37:58 +01:00
Clément Bœsch
dc8f732292
doc/examples: fix lib math dep for resampling_audio.
...
It uses at least sin()
2013-09-04 15:49:18 +02:00
Clément Bœsch
98b9bbb787
doc/examples: remove extra "the".
...
"into the doc/examples directory" vs "into doc/examples".
2013-09-04 15:46:31 +02:00
Michael Niedermayer
f187390907
doc/examples/filtering_audio: make const arrays also static
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-08-03 22:22:03 +02:00
wm4
72f5a6d067
examples: demuxing: print ffplay command even if sample format is planar
...
Adjust the code so that a working ffplay command is printed in the
planar audio case.
2013-07-19 12:14:54 +02:00
wm4
9f31c1608c
examples: demuxing: simplify audio output
...
There is no reason why this should copy the audio data in a very
complicated way. Also, strictly write the first plane, instead of
writing the whole buffer. This is more helpful in context of the
example. This way a user can clearly confirm that it works by playing
the written data as raw audio.
2013-07-19 12:14:46 +02:00
wm4
06b269dacb
examples: demuxing: do partial audio packet decoding
...
This assumes one audio packet is decoded one time. This is not true:
packets can be partially decoded. Then you have to "adjust" the packet
and pass the undecoded part of the packet to the decode function again.
2013-07-19 12:14:23 +02:00
Stefano Sabatini
2aa2b4ac65
examples/muxing: add support to audio resampling
...
Allows to encode to output in case the destination sample format is
different from AV_SAMPLE_FMT_S16.
2013-07-06 12:31:16 +02:00
Stefano Sabatini
838bd73139
lavfi: create Libav-API compatibility layer for avfilter_graph_parse() at the next bump
...
Add function avfilter_graph_parse_ptr() and favor it in place of
avfilter_graph_parse(), which will be restored with the old/Libav
signature at the next bump.
If HAVE_INCOMPATIBLE_LIBAV_API is enabled it will use the
Libav-compatible signature for avfilter_graph_parse().
At the next major bump the current implementation of
avfilter_graph_parse() should be dropped in favor of the Libav/old
implementation.
Should address trac ticket #2672 .
2013-07-03 13:21:42 +02:00
Stefano Sabatini
759dfd5684
examples/muxing: make more compact audio/video_time computation
2013-07-03 11:31:34 +02:00
Stefano Sabatini
80b56a7bdd
examples/muxing: rename audio/video_pts to audio/video_time
...
The new name is less confusing, since the variables represent times
rather than timestamps.
2013-06-26 23:38:42 +02:00
Stefano Sabatini
c58d535b2f
examples/Makefile: disable -O2 optimizations
...
There is no much point in optimizing example code, and the -O2 flag is
annoying when debugging.
2013-06-26 23:21:39 +02:00
Stefano Sabatini
3aa57e1582
examples/muxing: remove useless instruction
...
Simpler and less confusing.
2013-06-26 23:21:06 +02:00
Stefano Sabatini
4b6cf1ce0e
examples/muxing: vertically align
2013-06-25 21:36:53 +02:00
Nicolas George
300ca0763b
examples/filtering_audio: fix frame leak.
...
The frame is not used after being added to the filter
graph, there is no need to keep the reference.
2013-04-18 17:03:01 +02:00
Pavel Koshevoy
e5644313c5
examples/filtering_audio: get rid of AVABufferSinkParams
...
AVABufferSinkParams are ignored by avfilter_graph_create_filter,
therefore the example is misleading. Use av_opt_set_int_list to
configure abuffersink directly.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-04-17 11:11:57 +02:00
Michael Niedermayer
f2619cbd61
examples/filtering_audio: enable ref counted frames
...
Fixes accessing freed memory
Signe-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-04-17 11:11:57 +02:00
Clément Bœsch
9ab221f8d8
lavfi: deprecate aconvert.
...
This filter is not required anymore with aformat. Drop it at next bump.
2013-04-11 22:13:45 +02:00
Michael Niedermayer
e7389ed5d0
Merge commit 'bcc94328980e6c56546792ab08b0756abdce310b'
...
* commit 'bcc94328980e6c56546792ab08b0756abdce310b':
opt: check the return values of av_get_token for ENOMEM.
doc: Fix best_nb_channells typo
matroska: pass the lace size to the matroska_parse_rm_audio
Conflicts:
libavformat/matroskadec.c
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2013-04-04 13:00:59 +02:00
Stefano Sabatini
66c92a1575
examples/resampling_audio: make use of av_samples_alloc_array_and_samples()
...
Simplify.
2013-03-31 18:00:45 +02:00
Stefano Sabatini
9bb25dbd13
examples/filtering_*: constify AVFrame * for print_frame() and display_frame() functions
2013-03-14 21:39:15 +01:00
Stefano Sabatini
9076a6a943
examples/filtering_audio: update to new API
...
In particular, fix crash.
2013-03-14 21:39:09 +01:00
Stefano Sabatini
f0da370a52
examples/filtering_video: update to new API
...
In particular, fix crash.
2013-03-14 21:39:01 +01:00
Nicolas George
ceac5c54dd
Remove references to the "ff" variant of buffersink.
2013-03-12 23:31:07 +01:00
Michael Niedermayer
5743095ca9
Merge commit '9d3009c6c4b9b6734f07df7c88f6a42ded6cdf38'
...
* 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>
2013-03-12 18:10:35 +01:00
Clément Bœsch
5e4bc96415
doc: fix examples.
2013-03-10 01:41:53 +01:00
Nicolas George
9b211c43dc
examples/muxing: fix memory leak.
...
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 .
2013-03-05 15:43:32 +01:00
Michael Niedermayer
5ade6bfb03
doc/examples/demuxing: use AVFrame accessor functions
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-03-01 22:40:50 +01:00
Nicolas George
dcc73aaaa9
doc/examples: do not allocate AVFrame directly.
...
The size of the AVFrame structure is not part of the ABI;
it can grow with later versions. Therefore, applications
are not supposed to allocate AVFrame directly, they are
supposed to use avcodec_alloc_frame() instead.
2013-02-17 15:51:50 +01:00
Stefano Sabatini
772b949d8e
examples/scaling_video: fix typo
2013-02-15 00:28:53 +01:00
Angelo Haller
e7a39e163d
examples/demuxing: free AVPacket after usage
...
Fix leak.
2013-01-15 23:37:30 +01:00
Michael Niedermayer
48a7981e6f
doc/examples: fix assignments in if()
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-01-14 05:05:20 +01:00
Nicolas George
e4f14c32b9
examples/muxing: improve error messages.
...
Illustrate the use of return values, av_err2str and
avcodec_get_name.
2013-01-02 17:42:00 +01:00
Michael Niedermayer
55b243cade
doc/examples/resampling_audio.c: fix path
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-12-16 21:37:23 +01:00
Stefano Sabatini
89920387da
examples: add resampling_audio.c file
2012-12-06 10:09:37 +01:00
Michael Niedermayer
03b078721c
Merge commit '97bf7c03b1338a867da52c159a2afecbdedcfa88'
...
* commit '97bf7c03b1338a867da52c159a2afecbdedcfa88':
doc: git-howto: Leave reviewers time to react before pushing patches
Include libavutil/channel_layout.h instead of libavutil/audioconvert.h
lavu: rename audioconvert.* to channel_layout.* and deprecate audioconvert.h
Conflicts:
doc/APIchanges
doc/examples/decoding_encoding.c
doc/git-howto.texi
ffmpeg_filter.c
libavcodec/flacdec.c
libavcodec/imc.c
libavcodec/mpegaudiodec.c
libavcodec/utils.c
libavfilter/asrc_anullsrc.c
libavfilter/audio.c
libavfilter/avfilter.c
libavfilter/avfilter.h
libavfilter/avfiltergraph.c
libavfilter/buffer.c
libavutil/Makefile
libavutil/audioconvert.h
libavutil/channel_layout.c
libavutil/version.h
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2012-11-12 11:32:11 +01:00
Stefano Sabatini
e8c0b6710c
examples/muxing: fix typo: allocated -> allocate
2012-11-06 11:28:28 +01:00
Stefano Sabatini
7f6f8f642c
examples/demuxing: fix braino
...
s/video/audio/ in a log message.
2012-11-06 01:10:12 +01:00
Stefano Sabatini
794cea588c
examples/demuxing: dump input information *after* trying to open audio stream
...
Implement more logical code flow.
2012-11-06 01:10:12 +01:00
Michael Niedermayer
ca28cb5f83
examples: fix doxy so they appear on the example page
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-10-26 16:32:32 +02:00
Stefano Sabatini
33c4535db7
examples/decoding_encoding: add and use the decode_write_frame function
...
Allow to factorize code in video_decode_example(), simplify.
2012-10-24 00:29:37 +02:00
Stefano Sabatini
d3b8d56e06
examples/decoding_encoding: prefer 'frame' over 'picture' for an AVFrame
...
Decrease confusion.
2012-10-20 19:42:55 +02:00
Stefano Sabatini
935ecfb002
examples/scaling_video: remove unnecessary intermediary variable in fill_yuv_frame()
2012-10-20 12:06:45 +02:00
Stefano Sabatini
7b116a94af
examples/decoding_encoding: fix misc typos in the usage text
2012-10-20 11:30:13 +02:00
Stefano Sabatini
8c4753f7f5
examples/decoding_encoding: remove misplaced and confusing comment
2012-10-20 11:30:13 +02:00
Stefano Sabatini
6d6ccbae4c
examples/decoding_encoding: add missing checks on avcodec_alloc_context3()
2012-10-20 11:30:13 +02:00
Stefano Sabatini
eebde404bc
examples/muxing: merge add_audio_stream() and add_video_stream()
...
Factorize.
2012-10-17 21:39:13 +02:00
Stefano Sabatini
eda0a52bf1
examples/muxing: check on frame
...
Fix crash in case frame is not defined (e.g. with muxing out.wav).
2012-10-17 21:39:13 +02:00