743f07062a
lavfi: better channel layout negotiation
...
Allow substitution of channel pairs in the input for nearby channel pairs in
the output in order to get a closer match. Also weigh LFE channel mismatch
differently to favor matching the same layout without LFE over one less
channel with LFE.
2012-07-27 14:15:33 -04:00
b5c8aa745e
vf_yadif: unset cur_buf on the input link.
...
The buffer is stored internally, so this prevents it from being unreffed
automatically.
Signed-off-by: Luca Barbato <lu_zero@gentoo.org >
2012-07-26 00:01:04 +02:00
f431315a86
vf_overlay: ensure the overlay frame does not get leaked.
...
Signed-off-by: Luca Barbato <lu_zero@gentoo.org >
2012-07-26 00:01:04 +02:00
08fc1ad151
vf_overlay: prevent premature freeing of cur_buf
...
Signed-off-by: Anton Khirnov <anton@khirnov.net >
Signed-off-by: Luca Barbato <lu_zero@gentoo.org >
2012-07-26 00:01:04 +02:00
49c45a2624
avfilter: Fix printf format string conversion specifier
...
libavfilter/avfilter.c:224:9: warning: format ‘%ld’ expects argument of type ‘long int’, but argument 5 has type ‘int’ [-Wformat]
2012-07-25 09:24:25 +02:00
3124886554
lavfi: place x86 inline assembly under HAVE_INLINE_ASM.
...
This allows compiling this code using compilers that do not understand
gcc-style inline assembly.
2012-07-22 19:44:06 -07:00
a8a2271fe0
buffersrc: check ff_get_audio_buffer() for errors.
2012-07-22 09:14:05 +02:00
8f3a3ce730
lavfi: check all ff_get_video_buffer() calls for errors.
2012-07-22 09:14:05 +02:00
1dc4205018
lavfi: check all avfilter_ref_buffer() calls for errors.
2012-07-22 09:14:05 +02:00
80e4ed279b
vf_select: avoid an unnecessary avfilter_ref_buffer().
2012-07-22 09:14:05 +02:00
785fa50f0b
buffersrc: avoid creating unnecessary buffer reference
2012-07-22 09:14:05 +02:00
02ac7311c8
lavfi: use avfilter_unref_bufferp() where appropriate.
2012-07-22 09:14:05 +02:00
043800a968
vf_fps: add more error checks.
2012-07-22 09:14:05 +02:00
d515e9c225
vf_fps: fix a memleak on malloc failure.
2012-07-22 09:14:05 +02:00
3825b52688
lavfi: check all ff_start_frame/draw_slice/end_frame calls for errors
2012-07-22 09:14:05 +02:00
d4f89906e3
lavfi: add error handling to end_frame().
2012-07-22 09:14:05 +02:00
e9b992d035
lavfi: add error handling to draw_slice().
2012-07-22 09:14:05 +02:00
ebc8d97481
lavfi: add error handling to start_frame().
2012-07-22 09:14:04 +02:00
731fa116b4
yadif: use emms_c() instead of inline assembly for emms invocations.
2012-07-21 17:16:49 -07:00
3db407038e
lavfi: use const for AVFilterPad declarations in all filters.
2012-07-21 16:31:15 -07:00
4c9080a7ef
lavfi: unref AVFilterLink.out_buf in ff_end_frame().
...
This reduces code duplication and prevents stale pointers from remaining
on the link.
2012-07-20 21:12:49 +02:00
07bad27810
lavfi: unref AVFilterLink.cur_buf in ff_end_frame().
...
This reduces code duplication and prevents stale pointers from remaining
on the link.
2012-07-20 21:10:42 +02:00
533fd5b5b4
vsrc_testsrc: avoid an unnecessary avfilter_ref_buffer().
2012-07-20 21:09:57 +02:00
5b50ae94e6
vf_slicify: clear AVFilterLink.cur_buf in start_frame().
...
The buffer is passed on to the next filter, so we shouldn't keep any
pointers to it.
2012-07-20 21:09:48 +02:00
0393af4f0b
vf_settb: simplify start_frame().
...
Avoid pointless filter ref/unref. Just use the reference passed to
start_frame().
2012-07-20 21:08:50 +02:00
9203fa0b32
vf_fieldorder: don't give up its own reference to the output buffer.
2012-07-20 21:08:26 +02:00
f493c644cd
vf_pad: don't give up its own reference to the output buffer.
2012-07-20 21:08:13 +02:00
ad8b6326aa
vf_overlay: don't access a buffer reference that's been given away.
2012-07-20 21:07:51 +02:00
7155763b78
vf_drawtext: don't give up its own reference to the input buffer.
...
Directly forwarding the input buffer to the next filter means that
drawtext no longer owns any references to it and thus shouldn't refer to
it in any way.
2012-07-20 21:07:32 +02:00
d19499c796
vf_gradfun: don't store two pointers to one AVFilterBufferRef.
2012-07-20 21:07:11 +02:00
0fe010a36f
vf_delogo: don't store two pointers to one AVFilterBufferRef.
2012-07-20 21:06:49 +02:00
51a8049be8
vf_aspect: clear AVFilterLink.cur_buf in start_frame().
...
The buffer is passed on to the next filter, so we shouldn't keep any
pointers to it.
2012-07-20 21:06:40 +02:00
b70d89a033
lavfi: add avfilter_unref_bufferp()
...
Signed-off-by: Anton Khirnov <anton@khirnov.net >
2012-07-20 21:06:18 +02:00
cd99146253
lavfi: add error handling to filter_samples().
2012-07-09 08:25:19 +02:00
083d0f6be8
asplit: don't leak the input buffer.
2012-07-09 08:22:11 +02:00
1ffb645662
af_resample: fix request_frame() behavior.
...
Make sure that an output frame has really been produced before returning
0.
2012-07-09 08:21:37 +02:00
6f834293d3
af_asyncts: fix request_frame() behavior.
...
Make sure that an output frame has really been produced before returning
0.
2012-07-09 08:21:15 +02:00
8ca08066fc
lavr: Use AV_SAMPLE_FMT_NONE to auto-select the internal sample format
...
Also make this the default value.
2012-07-08 15:22:11 -04:00
b7558ac293
af_amix: avoid spurious EAGAIN.
...
Input on/off state can change in request_samples(), which can result in
a state where only the first input is active. get_available_samples()
will then return 0, and request_frame() will fail with EAGAIN even
though there is data on the single active input.
Take this into account and check the number of active inputs again after
calling request_samples().
2012-07-06 13:51:58 +02:00
54bf88e65f
af_amix: return AVERROR(EAGAIN) when request_frame didn't produce output.
...
0 should only be returned when there was at least one output frame.
2012-07-06 13:51:58 +02:00
428b369804
af_amix: only consider negative return codes as errors.
2012-07-06 13:51:58 +02:00
7c29377b70
lavfi: reclassify showfiltfmts as a TESTPROG
...
This tool uses lavfi internal symbols not accessible in shared
libraries. TESTPROGS are linked statically to allow them use of
library internals not normally exported.
Signed-off-by: Mans Rullgard <mans@mansr.com >
2012-07-04 17:48:25 +01:00
2047e40e6e
Clarify Doxygen comment for FF_API_* #defines.
2012-07-04 15:10:10 +02:00
1a068bfefd
cosmetics: Consistently use C-style comments with multiple inclusion guards
2012-07-03 17:35:12 +02:00
09f211987c
misc typo and wording fixes
2012-07-03 17:35:11 +02:00
fb93e61e2b
x86: lavfi: fix gradfun/yadif build with mmx/sse disabled
...
These functions are defined conditionally so any uses need to have
preprocessor guards.
Signed-off-by: Mans Rullgard <mans@mansr.com >
2012-07-03 14:14:13 +01:00
a87b17f328
vf_yadif: move x86 init code to x86/yadif.c
...
Signed-off-by: Mans Rullgard <mans@mansr.com >
2012-07-02 01:16:37 +01:00
2f0accf103
vf_gradfun: move x86 init code to x86/gradfun.c
...
Signed-off-by: Mans Rullgard <mans@mansr.com >
2012-07-02 01:16:37 +01:00
61d158c321
avfiltergraph: shut up uninitialized variable warning.
...
The warning silenced was:
libavfilter/avfiltergraph.c: In function ‘avfilter_graph_config’:
libavfilter/avfiltergraph.c:500:13: warning: ‘best_idx’ may be used uninitialized in this function [-Wuninitialized]
2012-06-26 19:10:17 +02:00
fd2784c3b5
af_join: initialize a variable to shut up gcc warning.
...
The warning silenced was:
libavfilter/af_join.c: In function ‘join_request_frame’:
libavfilter/af_join.c:451:9: warning: ‘nb_samples’ may be used uninitialized in this function [-Wuninitialized]
2012-06-26 19:09:15 +02:00