| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The patch will make audio and subtitle packets be marked as AV_PKT_FLAG_KEY.
For audio, it'll caused the audio sample to be sync sample.
To verify ref/fate/movenc results:
1. Get the movenc test data
[lmwang@vpn ffmpeg]$ libavformat/tests/movenc -w && mkdir -p audio_old && mv *.mp4 audio_old_
After applied the patch:
[lmwang@vpn ffmpeg]$ make fate-movenc SAMPLES=../fate-suite
[lmwang@vpn ffmpeg]$ libavformat/tests/movenc -w && mkdir -p audio_key && mv *.mp4 audio_key
2. Get l-smash and build boxdumper
https://github.com/l-smash/l-smash.git
3. dump the box of crc change mp4 and diff -u
[lmwang@vpn ffmpeg]$ ../l-smash/cli/boxdumper --box audio_key/non-empty-moov-no-elst.mp4 > audio_key/non-empty-moov-no-elst.log
[lmwang@vpn ffmpeg]$ ../l-smash/cli/boxdumper --box audio_old/non-empty-moov-no-elst.mp4 > audio_old/non-empty-moov-no-elst.log
[lmwang@vpn ffmpeg]$ diff -u audio_key/non-empty-moov-no-elst.log audio_old/non-empty-moov-no-elst.log
- default_sample_flags = 0x02000000
- independent
- sync sample
+ default_sample_flags = 0x01010000
+ dependent
+ non-sync sample
4. have checked the change of crc are caused by default_sample_flags
non-empty-moov.mp4, non-empty-moov-elst.mp4,
non-empty-moov-no-elst.mp4, empty-moov.mp4, delay-moov-content.mp4,
empty-moov-second-frag.mp4, empty-moov-second-frag-discont.mp4,
delay-moov-second-frag-discont.mp4, delay-moov-elst-second-frag.mp4
etc
5 For subtitle, it'll effect for tests/ref/fate/binsub-movtextenc and
tests/ref/fate/sub2video, that's expecting result for the subtitle is
marked as keyframe. Below is the checking result of binsub-movtextenc:
[lmwang@vpn ffmpeg]$ ./ffmpeg -i ../fate-suite/sub/MovText_capability_tester.mp4 -map 0 -scodec mov_text -f mp4 -flags +bitexact -fflags +bitexact -movflags frag_keyframe+empty_moov audio_key/binsub-movtextenc.mp4
[lmwang@vpn ffmpeg]$ ./ffmpeg -i ../fate-suite/sub/MovText_capability_tester.mp4 -map 0 -scodec mov_text -f mp4 -flags +bitexact -fflags +bitexact -movflags frag_keyframe+empty_moov audio_old/binsub-movtextenc.mp4
[lmwang@vpn ffmpeg]$../l-smash/cli/boxdumper audio_key/binsub-movtextenc.mp4 > audio_key/binsub-movtextenc.log
[lmwang@vpn ffmpeg]$../l-smash/cli/boxdumper audio_old/binsub-movtextenc.mp4 > audio_old/binsub-movtextenc.log
[lmwang@vpn ffmpeg]$ diff -u audio_key/binsub-movtextenc.log audio_old/binsub-movtextenc.log
.... // the key difference is the flag for sync sample
- flags = 0x000701
+ flags = 0x000301
data-offset-present
sample-duration-present
sample-size-present
- sample-flags-present
sample_count = 6
- data_offset = 188
+ data_offset = 164
sample[0]
sample_duration = 1570000
sample_size = 21
- sample_flags = 0x02000000
- independent
- sync sample
- degradation_priority = 0
sample[1]
sample_duration = 510000
sample_size = 2
- sample_flags = 0x01010000
- dependent
- non-sync sample
- degradation_priority = 0
sample[2]
sample_duration = 1690000
sample_size = 9
- sample_flags = 0x02000000
- independent
- sync sample
- degradation_priority = 0
Suggested-by: Andreas Rheinhardt <[email protected]>
Suggested-by: Nicolas George <[email protected]>
Signed-off-by: Limin Wang <[email protected]>
|
|
|
|
| |
Signed-off-by: Limin Wang <[email protected]>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
and make it static again.
These functions have been moved from nutenc to aviobuf and internal.h
in f8280ff4c00eeaa245085fa9691035203abd168c in order to use them in a
forthcoming patch in utils.c. Said patch never happened, so this commit
moves them back and makes them static, effectively reverting said
commit as well as f8280ff4c00eeaa245085fa9691035203abd168c (which added
the ff-prefix to these functions).
Reviewed-by: Michael Niedermayer <[email protected]>
Signed-off-by: Andreas Rheinhardt <[email protected]>
|
|
|
|
|
|
|
|
|
|
|
|
| |
Current muxers only use a single bitstream filter, so there is no need to
maintain code which operates on a list of bitstream filters. When multiple
bitstream filters are needed muxers can simply use a list bitstream filter.
If there is a use case in the future when different bitstream filters should be
added at subsequent packets then a new API possibly involving reconfiguring the
list bitstream filter can be added knowing the exact requirements.
Signed-off-by: Marton Balint <[email protected]>
|
|
|
|
|
|
|
|
|
|
|
| |
When no packet could be output, the interleavement functions
nevertheless initialized the packet destined for output (with the
exception of the data and size fields, making the initialization
pointless), although it will not be used at all. So remove the
initializations.
Reviewed-by: Marton Balint <[email protected]>
Signed-off-by: Andreas Rheinhardt <[email protected]>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Now that ff_interleave_add_packet() always returns blank packets, the
input packet to ff_interleave_packet_per_dts() will always be blank on
return as well (if supplied) and the same goes for interleave_packet()
in mux.c. Document these facts and remove the redundant resetting that
happened in av_interleaved_write_frame().
The last reference to the (long removed) destruct field that AVPackets
once had has been removed as well when updating the documentation of
ff_interleave_packet_per_dts().
Signed-off-by: Andreas Rheinhardt <[email protected]>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When an error happened in ff_interleave_add_packet() when adding
a packet to the packet queue, said packet would not be unreferenced
in ff_interleave_add_packet(), but would be zeroed in
av_interleaved_write_frame(), which results in a memleak.
This has been fixed: ff_interleave_add_packet() now always unreferences
the input packet on error; as a result, it always returns blank packets
which has been documented. Relying on this a call to av_packet_unref()
in ff_audio_rechunk_interleave() can be removed.
Signed-off-by: Andreas Rheinhardt <[email protected]>
|
|
|
|
|
|
|
|
|
|
|
| |
Also simplify it and make it always log the error.
This fixes for example the image2 muxer when used with an URL which also
contains the protocol:
ffmpeg -f lavfi -i testsrc -vframes 10 -atomic_writing 1 file:out%d.png
Signed-off-by: Marton Balint <[email protected]>
|
|
|
|
| |
Signed-off-by: Marton Balint <[email protected]>
|
|
|
|
| |
Signed-off-by: James Almer <[email protected]>
|
|
|
|
|
|
| |
Will be needed by the next patch.
Signed-off-by: James Almer <[email protected]>
|
|
|
|
|
|
|
| |
Allows user to set maximum number of buffered packets when
probing a codec. It was a hard-coded parameter before this commit.
Signed-off-by: Michael Niedermayer <[email protected]>
|
|
|
|
|
|
|
| |
This is done so that its data is really owned by the packet.
This was already true for the current callers.
Signed-off-by: James Almer <[email protected]>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The documentation of ff_packet_list_get currently didn't match the
actual usage:
1. It said that the destination packet is supposed to be initialized.
But this makes no sense given that it will be overwritten completely and
flacenc, mp3enc and ttaenc ignored this.
2. ff_packet_list_get returns an int, although it can't fail in case the
packet list is not empty (for which there is an assert). Again, several
callers didn't check for any return value.
In both cases, the documentation has been adapted to match actual usage.
Signed-off-by: Andreas Rheinhardt <[email protected]>
Signed-off-by: Michael Niedermayer <[email protected]>
|
|
|
|
|
|
|
|
|
| |
There is no reason for these functions to modify the given packets at
all.
Signed-off-by: Andreas Rheinhardt <[email protected]>
Reviewed-by: Paul B Mahol <[email protected]>
Signed-off-by: Michael Niedermayer <[email protected]>
|
|
|
|
|
|
| |
Remove the function ffio_open2_wrapper, it's not being used anymore.
Signed-off-by: Jun Zhao <[email protected]>
|
|
|
|
|
|
|
| |
Because it will be used by avformat/segment.c or other module which
need to automatically create sub-directories operation.
Signed-off-by: Steven Liu <[email protected]>
|
|
|
|
|
|
|
| |
This utility function creates 64-bit NTP time format as per the RFC
5905.
A simple explaination of 64-bit NTP time format is here
http://www.beaglesoft.com/Manual/page53.htm
|
|
|
|
|
|
|
| |
Same as ff_get_line but strip the white-space characters in the
string tail.
Signed-off-by: Jun Zhao <[email protected]>
|
|
|
|
|
|
| |
Based on a patch by Luca Barbato.
Signed-off-by: James Almer <[email protected]>
|
|
|
|
| |
Signed-off-by: Josh de Kock <[email protected]>
|
|
|
|
|
|
|
|
|
|
| |
This reverts commit 0fd475704e871ef3a535947596a012894bae3cbd.
Revert "lavd: fix iterating of input and output devices"
This reverts commit ce1d77a5e7cebce11074bf6f9e38ad6da37338ff.
Signed-off-by: Josh de Kock <[email protected]>
|
|
|
|
| |
Signed-off-by: Michael Niedermayer <[email protected]>
|
|
|
|
|
|
|
|
| |
ff_read_line_to_bprint_overwrite functions
To be able to read lines longer than a static buffer size.
Signed-off-by: Marton Balint <[email protected]>
|
|
|
|
|
| |
This also adds an avpriv function to register devices in
libavformat
|
|
|
|
|
|
|
|
|
| |
This will replace the 1024 character limited filename field. Compatiblity for
output contexts are provided by copying filename field to URL if URL is unset
and by providing an internal function for muxers to set both url and filename
at once.
Signed-off-by: Marton Balint <[email protected]>
|
|
|
|
|
| |
Reviewed-by: Aman Gupta <[email protected]>
Reviewed-by: Steven Liu <[email protected]>
|
|
|
|
|
|
|
|
| |
It's completely absurd that libavcodec would care about libavformat
locking, but it was there because the lock manager was in libavcodec.
This is more stright forward. Changes ABI, but we don't require ABI
compatibility currently.
|
|
|
|
|
|
| |
Fixes #6926
Signed-off-by: Aman Gupta <[email protected]>
|
|
|
|
|
| |
Signed-off-by: Aman Gupta <[email protected]>
Signed-off-by: wm4 <[email protected]>
|
|
|
|
|
|
|
| |
Every bitstream filter behaves as intended now, so there's no need to
wait for the first packet of every stream.
Signed-off-by: James Almer <[email protected]>
|
|
|
|
|
|
|
| |
It has no reason to be in a public header, even if defined as private.
Reviewed-by: Michael Niedermayer <[email protected]>
Signed-off-by: James Almer <[email protected]>
|
|
|
|
|
|
|
| |
Fixes detection of some TV sample as 24.5 FPS. With the patch applied,
it's detected as 25 FPS.
This is enabled for mpegts only.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This merges commits 8e2ea691351c5079cdab245ff7bfa5c0f3e3bfe4 and
096a8effa3f8f3455292c958c3ed07e798def7bd by Anton Khirnov, with the
following change:
- extract_extradata_check() is added to know if the codec is supported
by the bsf before trying to initialize it. This behaviour is similar to
the old AVCodecParser.split checks.
The FATE reference changes are due to the filtered out NAL units that
the old AVCodecParser.split implementation left alone.
Decoding is unchanged as the functions that parse extradata simply
ignored said unnecessary NAL units.
Signed-off-by: James Almer <[email protected]>
|
|
|
|
|
|
|
|
| |
This reverts commit 1c193ac1f9cfe703d6a1c36795f309ba5d14bf6e, reversing
changes made to 7ebc9f8df4035ecaa84ad4429480986e3e7597ae.
Several FATE tests started failing after this merge, so it's reverted
until it can be properly fixed.
|
|\
| |
| |
| |
| |
| |
| | |
* commit '8e2ea691351c5079cdab245ff7bfa5c0f3e3bfe4':
lavf: use the new bitstream filter for extracting extradata
Merged-by: James Almer <[email protected]>
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This also fixes a minor bug introduced in the codecpar conversion, where
the termination condition for extracting the extradata does not match
the actual extradata setting code. As a result, the packet durations
made up by lavf go back to their values before the codecpar conversion.
That is of little consequence since that code should eventually be
dropped completely.
|
| |
| |
| |
| |
| | |
Reviewed-by: wm4 <[email protected]>
Signed-off-by: Michael Niedermayer <[email protected]>
|
|\|
| |
| |
| |
| |
| |
| | |
* commit '785c25443b56adb6dbbb78d68cccbd9bd4a42e05':
movenc: Apply offsets on timestamps when peeking into interleaving queues
Merged-by: Hendrik Leppkes <[email protected]>
|
| |
| |
| |
| | |
Signed-off-by: Martin Storsjö <[email protected]>
|
| |
| |
| |
| |
| |
| | |
This allows a consumer to run the muxer's init function without actually
writing the header, which is useful in chained muxers that support
automatic bitstream filtering.
|
| |
| |
| |
| |
| |
| |
| |
| | |
Thanks to Mathieu Malaterre <[email protected]> for reporting the
Que/Queue typo. (https://bugs.debian.org/839542)
Reviewed-by: Lou Logan <[email protected]>
Signed-off-by: Andreas Cadhalpun <[email protected]>
|
| |
| |
| |
| |
| |
| | |
This will allow fixing several bugs with the -shortest option
Signed-off-by: Michael Niedermayer <[email protected]>
|
| | |
|
| |
| |
| |
| |
| |
| |
| |
| | |
Add ff_format_output_open utility function to wrap
io_open callback of AVFormatContext structure.
Signed-off-by: Jan Sebechlebsky <[email protected]>
Signed-off-by: Marton Balint <[email protected]>
|
| |
| |
| |
| |
| | |
Signed-off-by: Jan Sebechlebsky <[email protected]>
Signed-off-by: Marton Balint <[email protected]>
|
| | |
|
| |
| |
| |
| |
| |
| | |
Fixes assertion failures in movenc
Signed-off-by: Michael Niedermayer <[email protected]>
|
|\|
| |
| |
| |
| |
| |
| | |
* commit 'e1eb0fc960163402bbb4e630185790488f7d28ed':
movenc: Use packets in interleaving queues for the duration at the end of fragments
Merged-by: Matthieu Bouron <[email protected]>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
fragments
As long as caller only writes packets using av_interleaved_write_frame
with no manual flushing, this should allow us to always have accurate
durations at the end of fragments, since there should be at least
one queued packet in each stream (except for the stream where the
current packet is being written, but if the muxer itself does the
cutting of fragments, it also has info about the next packet for that
stream).
Signed-off-by: Martin Storsjö <[email protected]>
|