Commit Graph
100 Commits
Author SHA1 Message Date
Nicolas GeorgeandAnton Khirnov ecab1c7741 oggdec: add support for Opus in Ogg demuxing 2013-10-12 15:25:18 +02:00
Nicolas George 231e50157c lavfi/dualinput: reimplement on top of framesync. 2013-09-23 09:50:09 +02:00
Nicolas George 53319d5c93 lavfi: add an API to synchronize multiple video inputs.
Compared to dualinput, this API can handle more than two
inputs and can generate frames synchronized to any or all
input streams.
2013-09-23 09:49:37 +02:00
Nicolas George 04dcdc4640 lavc/avfft: init context to 0.
Prevent an invalid free in case of init failure.
2013-09-04 16:37:25 +02:00
Nicolas George 83635ac67b ffprobe: show bitmap subtitles size.
Fix trac ticket #2930.
2013-09-04 16:36:28 +02:00
Nicolas George d7ccfe58e3 lavc/libvorbisdec: do not return empty frames.
Some parts of the code have been known to react badly to
empty frames; they should not, but there is no need to
take risks.
2013-09-04 16:36:20 +02:00
Nicolas George d5b58f678d tools: add benchmark for crypto functions.
The benchmark tests the speed of the following algorithms:
MD5, SHA-1, SHA-256, SHA-512, RIPEMD-160, AES-128.

It can optionally be built to perform the same benchmark on
other crypto libraries, for comparison purposes.
The supported libraries are:
- crypto:   OpenSSL's libcrypto;
- gcrypt:   GnuTLS's libgcrypt;
- tomcrypt: LibTomCrypt
To enable them, use this syntax:
make VERSUS=crypto+gcrypt+tomcrypt tools/crypto_bench
They do not need to have been enabled in configure.
2013-09-04 16:36:11 +02:00
Nicolas GeorgeandMichael Niedermayer d5f38847f5 tests/fli: avoid rounding errors in -t option.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-08-10 20:17:10 +02:00
Nicolas George dd9555e94b ffmpeg: remove obsolete workaround in trim insertion.
The bug it was working seems to have been fixed.
This change causes ffmpeg to use the trim filter to implement
the -t option.
FATE tests are updated due to the more accurate handling of
the last packets.
2013-08-07 16:20:41 +02:00
Nicolas George 39bb26f91b lavu/log: do not skip overwritten lines.
If the line ends with \r, it will not flood the tty, and
the "Last message repeated" line would overwrite it.
Fix bug introduced by c25d1ba.
2013-08-07 16:01:45 +02:00
Nicolas George c25d1ba556 lavu/log: print prefix after \r.
Should fix trac ticket #2797 because of the progress line.
2013-07-20 11:06:19 +02:00
Nicolas George ebaf20e94b lavfi/scale: allocate interlaced scalers only if needed.
Fix "Value 0.000000 for parameter 'srch' out of range"
error message when source or destination height is 1.

Note: since the av_opt_set_int() calls are not checked for
failure and the interlaced scalers are not actually used,
this error has no consequence apart from a frightening message
in the log.
2013-07-18 12:08:25 +02:00
Nicolas GeorgeandStefano Sabatini a334b00cf6 ffprobe: fix exit code with stream specifiers
Without this fix, ffprobe would exit with a failure exit code if a stream
specifier is given that selects the last stream.

Signed-off-by: Nicolas George <nicolas.george@normalesup.org>
2013-06-27 00:20:20 +02:00
Nicolas George 50a4d076ce lavfi/trim: mark link closed on EOF.
Fix trac ticket #2620.
2013-06-02 23:19:42 +02:00
Nicolas George fc82f4a1f8 ffmpeg: ignore EOF when pushing frames to filters.
EOF is not a fatal condition, it is normally produced
by a few filters.

TODO: take it into account to avoid useless decoding.
2013-06-02 23:19:42 +02:00
Nicolas George ca2f6b6932 lavf/concat: reject empty scripts.
Fix trac ticket #2566.
2013-05-15 16:53:35 +02:00
Nicolas George 4582e4c086 lavfi: add comments to explain the negotiation loop. 2013-05-07 18:40:51 +02:00
Nicolas George 78d16b6a51 lavfi: fix filter format negotiation loop.
query_formats() returning EAGAIN is not considered a progress
in the format negotiation.

If the filter returns EAGAIN but did set some of its formats
lists, it could be considered a partial success and counted
as progress in the negotiation. Not counting it is not a
problem because it currently only happens in the first round,
where there will always be some progress on the other filters.
2013-05-07 18:40:51 +02:00
Nicolas George 449704b475 ffmpeg: move a local variable definition later.
Fix a segfault when using the -map option without input files.
2013-05-07 18:39:45 +02:00
Nicolas George fa245e432b lavf/matroskaenc: return an error for unsupported types. 2013-05-04 14:12:57 +02:00
Nicolas George d608a27d9e lavf/concatdec: remove invalid check for AVSEEK_FLAG_BACKWARD. 2013-05-04 14:11:53 +02:00
Nicolas George 3fc66dfef2 lavf: filter out AVSEEK_FLAG_BACKWARD in new API.
Also document that it has no effect.
2013-05-04 14:11:53 +02:00
Nicolas George cc24afb45c lavf: call the new seek API from the old.
If the demuxer implements read_seek2() and not read_seek(),
call avformat_seek_file() from av_seek_frame().
Allow to properly seek in formats that only implement the
new API from applications that use the old one.
Tested with mplayer and a concat script.
2013-05-04 14:11:53 +02:00
Nicolas George ceb33f3aee lavc: copy subtitle_header when copying context.
Fix trac ticket #2489.
2013-05-01 11:56:34 +02:00
Nicolas George 276fcbde6c lavf: data muxer and demuxer.
Allow to use tools designed to work with demuxers, muxers
and packets (for example ffmpeg itself) to process raw byte
streams (like aviocat).
2013-05-01 11:56:34 +02:00
Nicolas George 70feca926b lavc: check decoded subtitles encoding.
Address trac ticket #2431.
2013-04-24 19:41:27 +02:00
Nicolas George 29ebb7ba8d lavu: fix GET_UTF8 macro.
Prevent 0xFE and 0xFF from being considered the start of
non-standard 7-bytes sequences. No noticeable effect on speed.
2013-04-24 19:41:27 +02:00
Nicolas George fd7a7e11b9 lavfi/buffersink: fix possible leaks after allocation failures.
Should fix Coverity CID 1005313, 1005314, 1005315.
2013-04-21 16:11:36 +02:00
Nicolas George b57c23f8c8 lavfi: add asetrate filter. 2013-04-21 15:20:50 +02:00
Nicolas George b1cc12d0e3 ffmpeg: make -aspect work with -vcodec copy. 2013-04-18 22:59:54 +02:00
Nicolas George b42827ffd9 lavfi/vf_aspect: improve compatibility of parsing.
Try to accept both the old "num:den" and the new "num/den"
syntax. Fix "aspect=2" being ignored due to a missing den.

Also remove a duplicated #include.
2013-04-18 20:51:55 +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
Nicolas George e3e6aa7afb lavfi/buffersrc: fix failed requests count.
The line was lost during the AVFrame transition.
It causes programs relying on the failed requests count,
especially ffmpeg, to add frames to the wrong input.

Fix trac ticket #2467.
2013-04-17 11:32:03 +02:00
Nicolas George 9e8e03de38 lavu/opt: check int lists length for overflow.
Also add parens on macro arguments.
2013-04-13 20:19:24 +02:00
Nicolas George 2a1d7ea5f8 lavu: add parens to macro argument. 2013-04-13 20:19:24 +02:00
Nicolas George 76c8060654 lavu: add av_pure to av_int_list_length_for_size. 2013-04-13 20:19:24 +02:00
Nicolas George 6fbb21d685 lavfi/buffersink: factor checks for lists sizes. 2013-04-13 20:19:24 +02:00
Nicolas GeorgeandMichael Niedermayer 62d888ef0e ffmpeg: use options for abuffersink.
Also remove unused buffersink_params.

Signed-off-by: Nicolas George <nicolas.george@normalesup.org>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-04-12 12:11:10 +02:00
Nicolas GeorgeandMichael Niedermayer e48ded8551 lavfi/buffersink: accept parameters as options.
Move validation from init to query_formats().
Accept the formats lists as binary options.

Signed-off-by: Nicolas George <nicolas.george@normalesup.org>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-04-12 12:12:51 +02:00
Nicolas GeorgeandMichael Niedermayer af0d270aac lavu: add helper functions for integer lists.
Add av_int_list_length() to compute a list length.
Add av_opt_set_int_list() to set a binary option.

Signed-off-by: Nicolas George <nicolas.george@normalesup.org>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-04-12 12:09:51 +02:00
Nicolas George 08dd2c9df1 fate: add tests for unknown channel layouts. 2013-04-11 13:09:33 +02:00
Nicolas George 0d58bbb28d lavfi/buffersrc: update for compatibility with the fork.
Merge and adapt commit d28cb84 by Anton Khirnov.
2013-04-11 13:09:10 +02:00
Nicolas George de38e7c8c3 ffmpeg: use a rational for -aspect option. 2013-04-09 20:16:20 +02:00
Nicolas George 0884d04dc3 lavc: fix recoded subtitles end.
Text subtitles packets are not 0-terminated (and if they are,
it is handled by the recoding process since 0 is a valid
Unicode code point). The terminating 0 would overwrite the
last payload octet.

OTOH, packets must be 0-padded.

Fix a problem reported in trac ticket #2431.
2013-04-07 13:25:24 +02:00
Nicolas George 83affcde51 lavc: use packet duration for subtitles if necessary.
Fix trac ticket #2397.
2013-04-04 14:04:51 +02:00
Nicolas George 464f94b206 lavc: do not init frame with guessed layout.
It is breaking support from files with unknown layout.
2013-04-03 17:44:10 +02:00
Nicolas George d38c173dfb lavfi/af_atempo: simplify request_frame loop. 2013-04-03 17:44:10 +02:00
Nicolas George b570f24d76 lavfi/af_asetnsamples: simplify request_frame loop. 2013-04-03 17:44:10 +02:00
Nicolas George 9566ba91ab lavfi/f_ebur128: remove request_frame hack. 2013-04-03 17:44:10 +02:00
Nicolas George 77fa554b6e lavfi/vf_tile: simplify request_frame loop. 2013-04-03 17:44:10 +02:00
Nicolas George 69d67fb622 lavfi: reindent after last commit. 2013-04-03 17:44:10 +02:00
Nicolas George 79d8cfacf0 lavfi: loop on request_frame if necessary.
Some filters need several input frames before producing output.
For these filter, it becomes simpler to return 0 in
request_frame() and let the framework call it again until
output has been produced.
2013-04-03 17:33:27 +02:00
Nicolas George 52853077ee lavfi/af_asetnsamples: fix EOF handling.
Only filter one buffered frame.
Correctly return EOF if there is none.
2013-04-01 10:38:52 +02:00
Nicolas George 983d04dd40 lavu/opt: make sure av_opt_set_bin() handles NULL/0. 2013-04-01 10:38:38 +02:00
Nicolas George 9dd54d7422 lavd/v4l2: fully init an ioctl argument.
Silence a valgrind warning about uninitialized memory.
2013-04-01 10:38:14 +02:00
Nicolas George f810ca63f8 lavfi: detect merge failure for unknown layouts.
Detect when filtering known layouts from an explicit list
results in an empty list.

Fix erratic behavior.
2013-04-01 10:37:48 +02:00
Nicolas George 4f112a8e34 lavf/mux: add the flush_packets option.
Note: a lot of muxers already do the flushing explicitly.
2013-03-24 23:19:07 +01:00
Nicolas George 125acd2152 lavfi: support multiple rounds of format negotiation.
Remove the temporary hack for amerge and replace it with a
generic solution.
2013-03-24 23:17:47 +01:00
Nicolas George 00da527b44 lavfi/af_amerge: return EAGAIN if the input layouts are not known.
Also downgrade the error to a warning.
2013-03-24 23:17:47 +01:00
Nicolas George 57cb4fb075 lavfi: add test for concat. 2013-03-24 23:16:40 +01:00
Nicolas George 2753d4ebf0 lavfi/vf_yadif: use standard options parsing. 2013-03-20 21:13:56 +01:00
Nicolas George 8d4d11cd89 lavfi/vf_unsharp: use standard options parsing. 2013-03-20 21:13:56 +01:00
Nicolas George 769cc30072 lavfi/vf_transpose: use standard options parsing. 2013-03-20 21:13:56 +01:00
Nicolas George 392ec7ec1c lavfi/vf_pad: use standard options parsing. 2013-03-20 21:13:56 +01:00
Nicolas George b201c167d0 lavfi/vf_fps: use standard options parsing. 2013-03-20 21:13:56 +01:00
Nicolas George 4e2bcec95f lavfi/vf_fade: use standard options parsing. 2013-03-20 21:13:56 +01:00
Nicolas George 80580b405a lavi/vf_drawbox: use standard options parsing. 2013-03-20 21:13:56 +01:00
Nicolas George 37438d0a72 lavfi/vf_delogo: use standard options parsing. 2013-03-20 21:13:56 +01:00
Nicolas George 40ecd44f00 lavfi/vf_decimate: use standard options parsing. 2013-03-20 21:13:56 +01:00
Nicolas George 6202cf5dd8 lavfi/vf_crop: use standard options parsing. 2013-03-20 21:13:56 +01:00
Nicolas George e9ca55aedd lavfi/af_volume: use standard options parsing. 2013-03-20 21:13:56 +01:00
Nicolas George e9f45a833d lavfi/vf_tile: use standard options parsing. 2013-03-20 21:13:56 +01:00
Nicolas George 8c6c811b21 lavfi/avf_concat: use standard options parsing. 2013-03-20 21:13:56 +01:00
Nicolas George befbcc374d lavfi: add common code to handle options parsing. 2013-03-20 21:13:56 +01:00
Nicolas George cdd78a65f4 lavf/vobsub: free index pseudo-packet. 2013-03-20 21:13:55 +01:00
Nicolas George 6a90f6d789 ffmpeg: fix freeing of sub2video frame. 2013-03-20 21:13:55 +01:00
Nicolas George 21b092de7c lavfi: add sine audio source. 2013-03-20 21:04:28 +01:00
Nicolas George 8d928a9d99 lavu/opt: add AV_OPT_TYPE_DURATION. 2013-03-20 21:04:28 +01:00
Nicolas George 68fb7e260b lavfi/concat: fix silence duration computation.
Inside send_silence(), delta_ts was used inconsistently:
sometimes as the new value, sometimes as the old value.

Consistently use it as the new value, and add an argument
to know the last segment duration.
2013-03-20 20:59:45 +01:00
Nicolas George de1a71595d lavf/concatdec: support seeking. 2013-03-20 20:59:24 +01:00
Nicolas George a964d6a8a2 lavu/frame: use channels rather than channel_layout. 2013-03-20 13:35:24 +01:00
Nicolas George 0d09aa9d8e lavf: avformat_seek_file(): validate stream_index. 2013-03-20 13:35:24 +01:00
Nicolas George de1568a452 lavf/concatdec: fix possible leak in case of malloc failure.
Fix CID 747737.
2013-03-20 13:35:24 +01:00
Nicolas George 5eb273b2e7 lavfi/buffersink: check av_frame_ref() failure. 2013-03-20 13:35:24 +01:00
Nicolas George ec7fc7b7d1 fate: add a test for -filter_complex / -lavfi without input. 2013-03-17 16:24:43 +01:00
Nicolas George 40ea006b76 ffmpeg: make -lavfi an alias for -filter_complex. 2013-03-17 16:24:43 +01:00
Nicolas George 7e6c67dd24 lavfi/buffersink: fix header.
Move non-obsolete functions, structures and constants outside
the scope of "#if FF_API_AVFILTERBUFFER".

Add attribute_deprecated to av_buffersink_get_buffer_ref()
and av_buffersink_poll_frame().

Add doxygen for av_buffersink_get_frame_flags().
2013-03-17 12:31:25 +01:00
Nicolas George a5149607df lavfi/buffersrc: disable deprecated warnings. 2013-03-17 12:31:24 +01:00
Nicolas George f29c28a884 lavfi/buffersrc: check channel count changes. 2013-03-17 12:31:24 +01:00
Nicolas George 3cd342636f lavfi/buffersrc: set channel layout if it is known.
Introduced in 01649c7, lost in the API change.
2013-03-17 11:59:51 +01:00
Nicolas George 639a9e21a6 ffmpeg_opt: add OPT_INPUT to -fix_sub_duration and -canvas_size. 2013-03-16 17:20:19 +01:00
Nicolas George b90912be68 lavd/lavfi: upgrade to AVFrame.
Fix a memory leak because the compat implementation of
AV_BUFFERSINK_FLAG_PEEK is not identical to the previous one.
2013-03-15 20:46:27 +01:00
Nicolas George 7a71544f9d lavfi/graphdump: fix output for unknown layouts. 2013-03-14 20:52:50 +01:00
Nicolas George 0eb56a085d ffmpeg: add OPT_INPUT to -guess_layout_max. 2013-03-14 19:32:22 +01:00
Nicolas George da397173df ffmpeg: add OPT_OUTPUT to -to option.
Fix trac ticket #2355.
2013-03-14 19:32:22 +01:00
Nicolas GeorgeandAnton Khirnov be40d6cc2b rawdec: fix a typo -- || instead of |
Signed-off-by: Anton Khirnov <anton@khirnov.net>
2013-03-13 09:13:54 +01:00
Nicolas George 684a264638 configure: remove selection of ff(a)buffersink.
buffersink is enabled unconditionally.
2013-03-12 23:31:07 +01:00
Nicolas George c14a8c834c lavfi/buffersink: schedule removing the "ff" variants.
They are no longer needed since there is no incompatible
ABI version.
2013-03-12 23:31:07 +01:00
Nicolas George ceac5c54dd Remove references to the "ff" variant of buffersink. 2013-03-12 23:31:07 +01:00
Nicolas George 9a2688826d lavfi/buffersink: rename filter structures.
Reduce the diff with the fork.
2013-03-12 23:31:07 +01:00