summaryrefslogtreecommitdiff
path: root/libavformat/mov.c
Commit message (Collapse)AuthorAge
* mov: Export geotag metadata fieldsMartin Storsjö2014-06-06
| | | | | | | | | | | | The '?xyz' form is used by android devices (and according to apple mailing list archives, also by older iOS devices). The 'loci' field (defined in 3GPP 26.244) is used by recent iOS devices. Even though the loci field can contain an altitude, it was plain 0 in my sample. Just export longitude and latitude, in a string format matching the one used by the '?xyz' metadata field. Signed-off-by: Martin Storsjö <martin@martin.st>
* mov: store display matrix in a stream side dataVittorio Giovara2014-05-19
| | | | Signed-off-by: Anton Khirnov <anton@khirnov.net>
* mov: export stsd Compressorname in metadataAnton Khirnov2014-05-01
| | | | | Stop using the undocumented to-be-deprecated AVCodecContext.codec_name field.
* mov: read hydrogenaudio replaygain informationAnton Khirnov2014-04-10
|
* lavf: add supported extension to avi and mov demuxersMarc-Antoine Arnaud2014-04-02
|
* More correct printf format specifiersDiego Biurrun2014-04-02
| | | | This avoids compiler warnings about argument and specifier type mismatch.
* mov: call mov_rewrite_dvd_sub_extradata() after parsing dimensions from tkhdMichael Niedermayer2014-03-31
| | | | | | This also moves mov_rewrite_dvd_sub_extradata() to mov.c. Sample-Id: NeroRecodeSample.mp4
* mov: fill in subtitle dimensions after parsing tkhdMichael Niedermayer2014-03-31
| | | | Sample-Id: NeroRecodeSample.mp4
* lavf: more correct printf format specifiersDiego Biurrun2014-03-11
|
* movdec: handle 0x7fff langcode as macintosh per the specsBaptiste Coudurier2014-03-09
| | | | | | The correct point that seperates ISO and MAC language codes is 0x400 according to the current QT spec. Old QT specs did not list where this seperation is but apparently only defined the meaning of the first 137.
* mov: do not set avg_frame_rate in the demuxerJustin Ruggles2014-01-20
| | | | | | | | | | | The track duration is often not reliable or is not the duration represented by the number of frames. In those cases, avg_frame_rate was reported incorrectly. Removing this code falls back to the default calculation in avformat_find_stream_info(). This is a partial revert of commit c3aeaa540. Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
* mov: Free an earlier allocated array if allocating a new oneMartin Storsjö2014-01-15
| | | | | | | | | | | It could probably also be considered an error if the pointer isn't null at this point, but then we might risk rejecting some slightly broken files that we might have handled so far. Sample-Id: 00000496-google Reported-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind CC: libav-stable@libav.org Signed-off-by: Martin Storsjö <martin@martin.st>
* mov: Free intermediate arrays in the normal cleanup functionMartin Storsjö2014-01-15
| | | | | | | | | | | | | These arrays are normally freed at the end of mov_read_trak, but make sure they're freed in case mov_read_trak returned early (due to errors) or in case the atoms that allocate arrays are encountered at some other point than within a trak (which we don't have checks against). Sample-Id: 00000496-google Reported-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind CC: libav-stable@libav.org Signed-off-by: Martin Storsjö <martin@martin.st>
* Add missing #includes for *INT64_MAX and *INT64_CDiego Biurrun2013-11-23
|
* lavf: improve support for AVC-Intra files.Reimar Döffinger2013-11-14
| | | | | | | | Generate extradata with SPS/PPS based on container dimensions. Authors of this commit are: Reimar and Thomas Mundt Signed-off-by: Anton Khirnov <anton@khirnov.net>
* mov: Support HEVC demuxingYusuke Nakamura2013-10-31
| | | | Signed-off-by: Anton Khirnov <anton@khirnov.net>
* mov: Don't allocate arrays with av_malloc that will be reallocedMartin Storsjö2013-10-05
| | | | | CC: libav-stable@libav.org Signed-off-by: Martin Storsjö <martin@martin.st>
* mov: Make sure the read sample count is nonnegativeMartin Storsjö2013-09-29
| | | | | | | | | This avoids setting a negative number of frames, ending up with a negative average frame rate. Reported-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind CC: libav-stable@libav.org Signed-off-by: Martin Storsjö <martin@martin.st>
* lavf: Reset the entry count and allocation size variables on av_reallocp ↵Martin Storsjö2013-09-26
| | | | | | | | | | | | | | failures When av_reallocp fails, the associated variables that keep track of the number of elements in the array (and in some cases, the separate number of allocated elements) need to be reset. Not all of these might technically be needed, but it's better to reset them if in doubt, to make sure variables don't end up conflicting. Signed-off-by: Martin Storsjö <martin@martin.st>
* avformat: Use av_reallocp() where suitableAlexandra Khirnova2013-09-18
| | | | Signed-off-by: Diego Biurrun <diego@biurrun.de>
* mov: Don't use a negative duration for setting other fieldsMartin Storsjö2013-09-17
| | | | | | | | | | Some files have the duration set to -1 in the mdhd atom, more or less legitimately. (We produce such files ourselves, for the initial duration in fragmented mp4 files.) Reported-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind CC: libav-stable@libav.org Signed-off-by: Martin Storsjö <martin@martin.st>
* avformat: Use av_reallocp_array() where suitableAlexandra Khirnova2013-09-10
| | | | Signed-off-by: Diego Biurrun <diego@biurrun.de>
* mov: Parse tmcd extradataLuca Barbato2013-08-25
|
* mov: Refactor multiple stsd skipping in mov_mov_skip_multiple_stsdLuca Barbato2013-08-24
|
* mov: Refactor codec specific final steps in mov_finalize_stsd_codecLuca Barbato2013-08-24
|
* mov: Refactor subtitle specific parsing in mov_parse_stsd_subtitleLuca Barbato2013-08-24
|
* mov: Refactor audio specific parsing in mov_parse_stsd_audioLuca Barbato2013-08-24
|
* mov: Refactor video specific parsing in mov_parse_stsd_videoLuca Barbato2013-08-24
|
* mov: Refactor codec id selection in mov_codec_idLuca Barbato2013-08-24
|
* mov: use tkhd enabled flag to set the default trackJohn Stebbins2013-08-23
| | | | Signed-off-by: Anton Khirnov <anton@khirnov.net>
* mov: Do not allow updating the time scale after it has been setMartin Storsjö2013-07-15
| | | | | | | | | | | | The time scale is set in mdhd, and later validated in the enclosing trak atom once all of its children have been parsed. A loose mdhd atom outside of a trak atom could update the time scale of the last stream without any validation. Reported-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Cc: libav-stable@libav.org Signed-off-by: Martin Storsjö <martin@martin.st>
* mov: Seek back if overreading an individual atomMartin Storsjö2013-07-15
| | | | | | Reported-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Cc: libav-stable@libav.org Signed-off-by: Martin Storsjö <martin@martin.st>
* Remove commented-out debug #define cruftDiego Biurrun2013-05-16
|
* avformat: Add AVPROBE_SCORE_EXTENSION define and use where appropriateDiego Biurrun2013-05-04
|
* Move misplaced file author information where it belongsDiego Biurrun2013-04-11
|
* avformat: av_log_ask_for_sample() ---> avpriv_request_sample()Diego Biurrun2013-03-13
|
* lavf: remove disabled FF_API_R_FRAME_RATE cruftAnton Khirnov2013-03-11
|
* mov: use the format context for logging.Anton Khirnov2013-02-23
| | | | CC:libav-stable@libav.org
* mov: handle h263 and flv1 for codec_tag 'H','2','6','3'Janne Grunau2012-12-19
| | | | | | | | | | The sample in https://bugzilla.libav.org/show_bug.cgi?id=393 and samples/F4V/H263_NM_f.mp4 both have codec_tag H263 for different codecs. H263 is apparently used by Flash Media Server for Sorensen Spark videos. Patch based on commit 5442083b1c541dd166b3adf39131259fc846a62b by Carl Eugen Hoyos. Fixes bug 393.
* mov: validate number of DataReferenceBox entries against box sizeJanne Grunau2012-12-07
| | | | | Avoids a 2G memory allocation and parsing of random data in mov_read_dref(). The fuzzed sample sample.mp4_s224424 triggers this.
* mov: compute avg_frame_rate only if duration is knownJanne Grunau2012-12-07
| | | | Fixes an assert in fuzzed sample sample.mp4_s265930.
* lavf: add a common function for selecting a pcm codec from parametersJustin Ruggles2012-11-28
|
* Include libavutil/channel_layout.h instead of libavutil/audioconvert.hJustin Ruggles2012-11-11
| | | | Also reorder some other #include when applicable.
* mov: support random access point groupingYusuke Nakamura2012-09-19
| | | | | | | | | Frames described by this grouping are the starter of a closed or an open GOP. This is useful for open GOP of H.264 stream which is not described by sync sample atom. Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
* mov: check for EOF in long lasting loopsLuca Barbato2012-09-18
| | | | | | | A quite widespread pattern in the demuxer is read a 32bit unsigned integer and then loop till this value is reached. Checking for EOF prevents pathological situations.
* mov: stsd entries must be at least 16 byteMichael Niedermayer2012-09-16
| | | | | | | | | | Fix near infinite loop in stsd parsing. Bug found by: Diana Elena Muscalu The size is unsigned according the specification. Signed-off-by: Michael Niedermayer <michaelni@gmx.at> Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
* mov: detect EOF in mov_read_dref()Michael Niedermayer2012-09-16
| | | | | | | | Avoid a near infinite loop. Issue discovered by cosminamironesei. Signed-off-by: Michael Niedermayer <michaelni@gmx.at> Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
* mov_chan: Pass a separate AVIOContext for readingSamuel Pitoiset2012-09-07
| | | | | | | This fixes crashes when called from rtpdec_qt, where AVFormatContext->pb is null, a crash present since 3bab7cd128. Signed-off-by: Martin Storsjö <martin@martin.st>
* Replace all CODEC_ID_* with AV_CODEC_ID_*Anton Khirnov2012-08-07
|
* Improve descriptiveness of a number of codec and container long namesDiego Biurrun2012-07-30
|