summaryrefslogtreecommitdiffstats
path: root/libavformat
Commit message (Collapse)AuthorAgeFilesLines
* avformat/mxfdec: add support for clip wrapped essencesMarton Balint2018-07-041-151/+131
| | | | | | | | | | Also use common code with opAtom. Fixes ticket #2776. Partially fixes ticket #5671. Fixes ticket #5866. Signed-off-by: Marton Balint <cus@passwd.hu>
* avformat/mov: Expose encryption info to the app.Jacob Trimble2018-07-041-1/+119
| | | | | | | | | | This exposes encryption info from the container to the app. This includes key ID, IV, and subsample byte ranges. The info is passed using the new side-data AV_PKT_DATA_ENCRYPTION_DATA and AV_PKT_DATA_ENCRYPTION_INIT_DATA. Signed-off-by: Jacob Trimble <modmaker@google.com> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* riff: add ATRAC9 guidRostislav Pehlivanov2018-07-031-0/+1
| | | | | | Enables demuxing of ATRAC9 files. Signed-off-by: Rostislav Pehlivanov <atomnuker@gmail.com>
* avformat/apngdec: set pts to AV_NOPTS_VALUEMarton Balint2018-07-021-3/+1
| | | | | | | | | And let the generic code figure out the proper PTS. This is needed because apng does not provide seek functions, but after a generic seek (e.g. to file start) timestamps are not reset which causes broken timestamps when looping apngs, like in ticket #6121. Signed-off-by: Marton Balint <cus@passwd.hu>
* libavformat/yuv4mpeg: Add color range support for Y4M Add color_range ↵Wang Cao2018-06-302-2/+43
| | | | | | | | | | support in Y4M. Set pixel format and color_range for YUVJ pixel formats. Also set color_range based on AVFormatContext. Signed-off-by: Wang Cao <wangcao@google.com> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avformat/movenc: Use mov->fc consistently for av_log()Michael Niedermayer2018-06-281-1/+1
| | | | Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avformat/movenc: Do not pass AVCodecParameters in avpriv_request_sampleMichael Niedermayer2018-06-281-1/+1
| | | | | | | | Fixes: out of array read Fixes: ffmpeg_crash_8.avi Found-by: Thuan Pham, Marcel Böhme, Andrew Santosa and Alexandru Razvan Caciulescu with AFLSmart Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avformat/movenc: Check that frame_types other than ↵Michael Niedermayer2018-06-281-0/+6
| | | | | | | | | | EAC3_FRAME_TYPE_INDEPENDENT have a supported substream id Fixes: out of array access Fixes: ffmpeg_bof_1.avi Found-by: Thuan Pham, Marcel Böhme, Andrew Santosa and Alexandru Razvan Caciulescu with AFLSmart Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* lavf/amr: Fix heuristic to avoid detection of repeated bytes.Carl Eugen Hoyos2018-06-261-4/+2
|
* lavf/mpjpegdec: Mark local variable staticMark Thompson2018-06-251-1/+1
|
* avformat/mxfdec: avoid index_table->nb_ptses overflow in ↵Marton Balint2018-06-241-0/+6
| | | | | | mxf_compute_ptses_fake_index Signed-off-by: Marton Balint <cus@passwd.hu>
* avformat/mxfdec: compute sample_count for all streams on seekMarton Balint2018-06-241-22/+17
| | | | | | sample_count will be used for per-stream current_edit_unit. Signed-off-by: Marton Balint <cus@passwd.hu>
* avformat/mxfdec: add support for returning the partition for ↵Marton Balint2018-06-241-8/+10
| | | | | | mxf_edit_unit_absolute_offset and mxf_absolute_bodysid_offset Signed-off-by: Marton Balint <cus@passwd.hu>
* avformat/mxfdec: make current_edit_unit a parameter of mxf_compute_samplesMarton Balint2018-06-241-5/+5
| | | | | | No change in functionality. Signed-off-by: Marton Balint <cus@passwd.hu>
* avformat/mxfdec: make edit_units_per_packet a track propertyMarton Balint2018-06-241-25/+26
| | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* avformat/mxfdec: simply use the first essence element for non frame-wrapped ↵Marton Balint2018-06-241-21/+4
| | | | | | | | | partition essence offset Also add the canopus essence element to the list of the recognized essence element keys. Signed-off-by: Marton Balint <cus@passwd.hu>
* avformat/mxfdec: compute both essence_offset and essence_length in ↵Marton Balint2018-06-241-51/+57
| | | | | | | | | mxf_compute_essence_containers Also compute the correct essence_offset and essence_length for all clip wrapped essences. Signed-off-by: Marton Balint <cus@passwd.hu>
* avformat/mxfdec: extend mxf_handle_missing_index_segment for all clip ↵Marton Balint2018-06-241-16/+23
| | | | | | | | | wrapped essences Also make sure we set a valid track index sid and a valid track edit rate in order for the index to be useful. Signed-off-by: Marton Balint <cus@passwd.hu>
* avformat/mxfdec: add some essence container uls from SMPTE draftMarton Balint2018-06-241-0/+2
| | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* avformat/mxfdec: add support for determining essence wrapping schemeMarton Balint2018-06-242-20/+68
| | | | | | Some code is based on bmxlib-libmxf/mxf/mxf_utils.c. Signed-off-by: Marton Balint <cus@passwd.hu>
* avformat/mxfdec: store next_klv in KLVPacketMarton Balint2018-06-242-5/+9
| | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* lavf/amr: Make the heuristic for auto-detection even stricter.Carl Eugen Hoyos2018-06-221-3/+3
| | | | Fixes ticket #7270.
* avformat/movenc: allow hdlr name field to be emptyGyan Doshi2018-06-213-1/+7
| | | | | | Both QTFF and the ISOBMFF standards allow it. Fixes #7262
* lavf/mov: Do not fail hard for truncated stsz atoms.Carl Eugen Hoyos2018-06-191-1/+2
| | | | Fixes ticket #6433.
* avformat/movenc: read track title from correct keyGyan Doshi2018-06-191-1/+1
| | | | | | | | | | da9cc22d5bd allowed the MOV muxer to relay a custom stream handler name, whether populated from the input stream or user-set. However, the entry key didn't match the key set by the MOV demuxer, so it wasn't effective. Fixed. Due to the change, four FATE refs have to be updated. Verified that the target payload of the tests hasn't changed in terms of CRC.
* avformat/mpegts: parse large PMTs with multiple tablesAman Gupta2018-06-181-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In 9152c1e4955, the mpegts parser was taught how to parse PMT sections which contained multiple tables. That commit fixed parsing of PMT packets from some cable providers, which included a special SCTE table (0xc0) before the standard program map table (0x2). Sometimes, however, the combined 0xc0 and 0x2 tables are larger than a single TS packet (188 bytes). The mpegts parser already attempts to parse sections which span multiple packets, but still assumed that the split section only contained one table. This patch fixes parsing of such a sample[1]. Before: Input #0, mpegts, from 'combined-pmt-tids-split.ts': Duration: 00:00:01.26, start: 39188.931756, bitrate: 597 kb/s Program 1 No Program Stream #0:0[0xeff]: Audio: ac3, 48000 Hz, mono, fltp, 64 kb/s Stream #0:1[0xefd]: Audio: mp3, 0 channels, fltp Stream #0:2[0xefe]: Unknown: none After: Input #0, mpegts, from 'combined-pmt-tids-split.ts': Duration: 00:00:01.27, start: 39188.931756, bitrate: 589 kb/s Program 1 Stream #0:0[0xefd]: Video: h264 ([27][0][0][0] / 0x001B), none, 59.94 fps, 59.94 tbr, 90k tbn, 180k tbc Stream #0:1[0xefe](eng): Audio: ac3 ([129][0][0][0] / 0x0081), 48000 Hz, stereo, fltp, 384 kb/s Stream #0:2[0xeff](spa): Audio: ac3 ([129][0][0][0] / 0x0081), 48000 Hz, mono, fltp, 64 kb/s Stream #0:3[0xf00]: Data: scte_35 Stream #0:4[0xf01]: Unknown: none (ETV1 / 0x31565445) Stream #0:5[0xf02]: Unknown: none (ETV1 / 0x31565445) Stream #0:6[0xf03]: Unknown: none ([192][0][0][0] / 0x00C0) With the patch, the PMT is parsed correctly so the streams are created in the correct order, are associated with "Program 1", and their codecs are set correctly. [1] https://s3.amazonaws.com/tmm1/combined-pmt-tids-split.ts Signed-off-by: Aman Gupta <aman@tmm1.net> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* lavf/tedcaptionsdec: Replace the number by macro for bprint initJun Zhao2018-06-171-1/+1
| | | | | | Replace the number by macro for bprint init. Signed-off-by: Jun Zhao <mypopydev@gmail.com>
* lavf/icecast: Replace the number by macro for bprint initJun Zhao2018-06-171-1/+1
| | | | | | Replace the number by macro for bprint init. Signed-off-by: Jun Zhao <mypopydev@gmail.com>
* lavf/aviobuf: Increase Statistics verbosity to AV_LOG_VERBOSE.Carl Eugen Hoyos2018-06-161-2/+2
|
* avformat/mov: Only set pkt->duration to non negative valuesMichael Niedermayer2018-06-141-1/+3
| | | | | Reviewed-by: Sasi Inguva <isasi@google.com> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avformat/movenc: fix recognization of cover image streamsTimo Teräs2018-06-131-18/+18
| | | | | | | | | | For chapter images, the mov demux produces streams with disposition set to attached_pic+timed_thumbnails. This patch fixes to properly recognize streams that should be encoded as cover image (ones with only and only attached_pic disposition set). Signed-off-by: Timo Teräs <timo.teras@iki.fi> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avformat/movenc: properly handle cover image codecsTimo Teräs2018-06-131-18/+12
| | | | | | | | | | | Find codec tag for attached images using appropriate list of supported image formats. This fixes writing the cover image to m4v/m4a and other container formats that do not allow these codecs as a track. Signed-off-by: Timo Teräs <timo.teras@iki.fi> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avformat/mov: Add check for per-sample IV size.Jacob Trimble2018-06-131-2/+7
| | | | | | | Found by Chrome's ClusterFuzz: http://crbug.com/849062. Signed-off-by: Jacob Trimble <modmaker@google.com> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avformat: deprecate unused MP4A_LATM flagGyan Doshi2018-06-134-3/+10
| | | | | | | A generic lavf flag for AAC LATM packetization for the RTP muxer was added in ef409645f0 and then made inert 20 days later in 0832122880 when a private muxer option was added and the generic flag no longer read.
* avformat/mov: Fix reading saio/saiz for clear content.Jacob Trimble2018-06-091-16/+55
| | | | | | | | | | | This validates that the common encryption saio/saiz atoms only appear when the data is actually encrypted. This also ignores those atoms in clear content. Found by Chrome's ClusterFuzz: http://crbug.com/850389 Signed-off-by: Jacob Trimble <modmaker@google.com> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avformat/mxfdec: add support for recognizing timed text streamsMarton Balint2018-06-081-0/+8
| | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* avformat/mxfdec: remove check for NULL MXFTrack in mxf_set_ptsMarton Balint2018-06-081-1/+1
| | | | | | It cannot happen for video streams. Signed-off-by: Marton Balint <cus@passwd.hu>
* avformat/mxfdec: only disallow seek on metadata streamsMarton Balint2018-06-081-1/+1
| | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* avformat/mxfdec: recognize SMPTE 436 VBI dataMarton Balint2018-06-081-0/+2
| | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* avformat/mxfdec: use MXFCodecUL struct to store essence description for ↵Marton Balint2018-06-082-12/+5
| | | | | | data_essence_container_uls Signed-off-by: Marton Balint <cus@passwd.hu>
* lavf/mov.c: Set st->start_time for video streams explicitly.Sasi Inguva2018-06-061-4/+16
| | | | | | | If start_time is not set, ffmpeg takes the duration from the global movie instead of the per stream duration. Signed-off-by: Sasi Inguva <isasi@google.com> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* lavf/mov.c: Fix timestamps to be strictly monotonic for video also.Sasi Inguva2018-06-051-4/+5
| | | | | | | | | | | We already do this for audio, but it should be done for video too. If we don't, seeking back to the start of the file, for example, can become quite broken, since the first N packets will have repeating and nonmonotonic PTS, yet they need to be decoded even if they are to be discarded. Signed-off-by: Sasi Inguva <isasi@isasi.mtv.corp.google.com> Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
* libavformat/mov: Fix heap buffer overflow.Jacob Trimble2018-06-021-3/+3
| | | | | | | Found by Chrome's ClusterFuzz: https://crbug.com/847060 Signed-off-by: Jacob Trimble <modmaker@google.com> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avformat/mxfdec: add some missing picture_essence_container_ulsMarton Balint2018-05-301-0/+3
| | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* avformat/mxfdec: use int math for sample count calculationMarton Balint2018-05-301-2/+1
| | | | | | This also changes the rounding to nearest. Signed-off-by: Marton Balint <cus@passwd.hu>
* avformat/mxfdec: fix klv_decode_ber_length return value usageMarton Balint2018-05-301-3/+12
| | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* flvenc: Fix sequence header update timestampsAlex Converse2018-05-291-4/+4
|
* flvenc: Factorize timestamp writingAlex Converse2018-05-291-6/+9
| | | | | The code is trivial but the semantics in the spec are ambiguous. This should help keep parts of the muxer interpreting them consistently.
* avformat/movenc: creating producer reference time (PRFT) boxVishwanath Dixit2018-05-292-0/+59
| | | | | | | | | The producer reference time box supplies relative wall-clock times at which movie fragments, or files containing movie fragments (such as segments) were produced. The box is mainly useful in live streaming use cases. A media player can parse the box and utilize the time fields to measure and improve the latency during real time playout.
* avformat/utils: function to get the formatted ntp timeVishwanath Dixit2018-05-292-0/+30
| | | | | | | 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
OpenPOWER on IntegriCloud