Commit Graph

21314 Commits

Author SHA1 Message Date
Paul B Mahol
297e65c676 avformat/vividas: check if value from ffio_read_varlen() is too big 2018-12-22 11:14:21 +01:00
Jacob Trimble
555f332e7a libavformat/mov: Fix NULL-dereference read for some encrypted content.
When reading frames, we need to use the fragment for the correct
stream.  Sometimes the "current" fragment is not the same as the one
the frame is for.

Found by Chromium's ClusterFuzz:
https://crbug.com/906392 and https://crbug.com/915524

Signed-off-by: Jacob Trimble <modmaker@google.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2018-12-20 23:32:36 +01:00
Paul B Mahol
d06aae732c avformat: add vividas demuxer 2018-12-20 19:32:27 +01:00
Michael Niedermayer
21f4b456f1 avformat/mov: Simplify get_stream_info_time()
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2018-12-19 20:09:03 +01:00
Michael Niedermayer
ab1319d82f avformat/mpegts: Fix side data type for stream id
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2018-12-19 20:09:03 +01:00
Paul B Mahol
c0fb6f963f avformat/vorbiscomment: add support for writing chapters
Fixes #7532.
2018-12-18 19:45:59 +01:00
Jan Ekström
a1f0dd24f6 lavf/mov: document the dvh1 codec switch based on hvcC availability 2018-12-17 23:25:43 +02:00
Rodger Combs
6ebe88f3a4 lavf/isom: add Dolby Vision sample entry codes for HEVC and H.264
These are registered identifiers at the MPEG-4 RA, which are
defined as to be utilized for Dolby Vision AVC/HEVC streams that
are not correctly presentable by standards-compliant AVC/HEVC players.

According to the Dolby Vision specification for ISOBMFF, these sample
entry codes are specified to have the standard AVC or HEVC decoder
configuration box in addition to the Dolby custom DOVIConfigurationBox.
This is what enables us to decode the streams without custom parsing.

For correct presentation information from the DOVIConfigurationBox
is required (YCbCr or modified ICtCP, SDR or HDR, base or enhancement
layer).
2018-12-17 23:25:43 +02:00
Paul B Mahol
7b2a9aaa0b avformat/mxfenc: fix typo 2018-12-17 21:06:36 +01:00
chcunningham
ee1e39a576 lavf/id3v2: fail read_apic on EOF reading mimetype
avio_read may return EOF, leaving the mimetype array unitialized. fail
early when this occurs to avoid using the array in an unitialized state.

Reviewed-by: Tomas Härdin <tjoppen@acc.umu.se>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2018-12-17 18:30:10 +01:00
kjeyapal@akamai.com
f22fcd4483 avformat/dashenc: Added support for Low-latency HLS(Experimental)
Apple doesn't have an official spec for LHLS. Meanwhile hls.js player folks are
trying to standardize a open LHLS spec. The draft spec is available in https://github.com/video-dev/hlsjs-rfcs/blob/lhls-spec/proposals/0001-lhls.md
This option will also try to comply with the above open spec, till Apple's spec officially supports it.
Applicable only when @var{streaming} and @var{hls_playlist} options are enabled.
2018-12-17 12:11:55 +05:30
kjeyapal@akamai.com
d209a3d50f avformat/dashenc : Refactored HLS media playlist related code
Made it as a separate function, so that it could be reused (in future)
2018-12-17 12:11:18 +05:30
Michael Niedermayer
3a95b73abc avformat/nutenc: Document trailer index assert better
Reviewed-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2018-12-16 09:49:07 +01:00
chcunningham
c9f7b6f7a9 lavf/mov: ensure only one tkhd per trak
Chromium fuzzing produced a whacky file with extra tkhds. This caused
an AVStream that was already in use to be corrupted by assigning it a
new id, which blows up later in mov_read_trun because the
MOVFragmentStreamInfo.index_entry now points OOB.

Reviewed-by: Baptiste Coudurier <baptiste.coudurier@gmail.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2018-12-16 09:49:07 +01:00
Paul B Mahol
6bfc935232 avformat/nutdec: fix pts overflow
Probably fixes #6913.
2018-12-14 21:53:41 +01:00
Paul B Mahol
78e7b70395 avformat/ffmetadec: do no limit size of tags to 1024
Use bprint API instead.

Fixes #4833.
2018-12-14 17:33:52 +01:00
Paul B Mahol
d9a91d58a1 avformat/movenc: treat ALAC same as FLAC and write correct info
Fixes #7291.
2018-12-14 12:11:57 +01:00
Paul B Mahol
5e6b93bb4d avformat/id3v2: use png header to get PNG signature 2018-12-14 11:34:46 +01:00
Paul B Mahol
e9817636a7 avformat/flac_picture: try to guess PNG by actual picture data
Fixes #5028.
2018-12-14 11:32:27 +01:00
Paul B Mahol
6f058b5cef avformat/nut: add support for yuva444/422p12 pixel format 2018-12-14 11:26:30 +01:00
Paul B Mahol
f2179afb01 avformat/nutdec: fix obvious typo
Fixes #6742.
2018-12-14 10:45:32 +01:00
Paul B Mahol
e5a0013c4a avformat/mxfdec: fix error check in macro
Fixes #6750.
2018-12-13 23:51:53 +01:00
Paul B Mahol
0ed678a97a bump micro after recent gif changes 2018-12-13 19:30:39 +01:00
Paul B Mahol
0aa5a7b2e9 avformat/gifdec: export duration, nb_frames and comment 2018-12-13 18:58:48 +01:00
Paul B Mahol
280b432464 avformat/gif: extend description 2018-12-13 18:58:48 +01:00
Paul B Mahol
80f0f8660c avformat/gifdec: export sample aspect ratio 2018-12-13 18:58:48 +01:00
Paul B Mahol
faca28c264 avcodec: rewrite gif muxing and encoding
Now "-c copy" works.
Update FATE files.

Demuxer only split file into packets, no data is trimmed.
Encoder & muxer currently expect completely another format
where muxer writes stuff like disposal method which should
be really encoder job.
With this patch muxer only modifies delay between two packets.
Codec copy need to have same behavior between demuxer and
muxer to work correctly.

Fixes #6640.
2018-12-13 18:58:48 +01:00
Paul B Mahol
102c11745e avformat/utils: add support for reading ID3 tags at start of wav
Fixes #4140.
2018-12-13 10:01:15 +01:00
Paul B Mahol
f5aad350d3 avformat/wavdec: add support for 'id3 ' chunk
Fixes #5700.
2018-12-13 10:01:15 +01:00
Peter Ross
b41f378fc4 os_support: define socket shutdown SHUT_xxx macros if they are not defined
this section has been moved into the CONFIG_NETWORK block, since it only
affects network enabled builds.

sys/socket.h (with WIN32 guard) is needed to check if the SHUT_xxx macro exists.
2018-12-11 22:08:18 +11:00
kjeyapal@akamai.com
876ed08b0d avformat/dashenc: Used the movenc option skip_sidx instead of global_sidx
Anyways the intended behaviour was to disable SIDX atom.
2018-12-11 10:53:18 +05:30
kjeyapal@akamai.com
1d01ab399f avformat/movenc: Added an option to disable SIDX atom 2018-12-11 10:52:16 +05:30
Carl Eugen Hoyos
73abde61bb lavf/matroskadec: Do not use strncat() to limit copying a one-char constant.
Instead add the character to the snprintf above as suggested by Mark.

Silences a warning:
libavformat/matroskadec.c: In function 'webm_dash_manifest_cues':
libavformat/matroskadec.c:3947:13: warning: 'strncat' specified bound 1 equals source length [-Wstringop-overflow=]
             strncat(buf, ",", 1);
             ^~~~~~~~~~~~~~~~~~~~
2018-12-11 00:40:26 +01:00
Paul B Mahol
6a20876b62 avformat/gif: simplify signature writing 2018-12-10 21:13:15 +01:00
Paul B Mahol
14156e607d avformat/mxfenc: calculate and store DAR from user SAR 2018-12-10 17:35:38 +01:00
Paul B Mahol
5e0d54a031 avformat/mxfenc: allow muxing prores 2018-12-10 17:25:49 +01:00
Paul B Mahol
eade85bbbd avformat: add gif pipe demuxer 2018-12-10 11:20:41 +01:00
Karthick J
2349260330 avformat/hlsenc : Added an option to ignore IO errors
Useful for long duration runs with network output

Reviewed-by: Steven Liu <lq@chinaffmpeg.org>
2018-12-10 14:19:23 +08:00
Karthick J
56503a6925 avformat/hlsenc: Handled error from ff_http_do_new_request() function
This patch fixes the segmentation fault issues due to
unhandled errors from ff_http_do_new_request function.

Reviewed-by: Steven Liu <lq@chinaffmpeg.org>
2018-12-10 14:17:55 +08:00
Paul B Mahol
3981f262ac avformat/mxfdec: fix indentation 2018-12-09 20:12:23 +01:00
Paul B Mahol
c782e7aa9e avformat/dhav: export average frame rate too 2018-12-09 10:49:00 +01:00
Artyom Lebedev
6b1c4ce8cf Fix bug in mpegts muxer which affects KLV async stream generation.
Fixes ticket #7597.

Signed-off-by: Peter Ross <pross@xvid.org>
2018-12-08 11:06:10 +11:00
Paul B Mahol
cc6208cde2 avformat/mxfdec: set codec_tag for prores codec 2018-12-07 20:08:37 +01:00
Andrey Semashev
f176d6587b lavf/dashenc: Write media trailers when DASH trailer is written.
This commit ensures that all (potentially, long) filesystem activity is
performed when the user calls av_write_trailer on the DASH libavformat
context, not when freeing the context. Also, this defers media segment
deletion until after the media trailers are written.
2018-12-04 10:34:29 +05:30
Karthick J
4bbb6d1ae9 Revert "lavf/dashenc: Write media trailers when DASH trailer is written."
This reverts commit e444b3b184.
Causing build error due to rebasing. Sorry for about it.
2018-12-03 11:28:18 +05:30
Andrey Semashev
a68a975584 lavf/dashenc: Use avpriv_io_delete to delete files.
This fixes incorrect handling of file pseudo-URIs (i.e. when the filename
starts with "file:").
2018-12-03 10:54:47 +05:30
Andrey Semashev
e444b3b184 lavf/dashenc: Write media trailers when DASH trailer is written.
This commit ensures that all (potentially, long) filesystem activity is
performed when the user calls av_write_trailer on the DASH libavformat
context, not when freeing the context. Also, this defers media segment
deletion until after the media trailers are written.
2018-12-03 10:54:47 +05:30
Karthick J
0a80b39780 avformat/dashenc: Added proper logging when io_open fails for write 2018-12-03 10:54:47 +05:30
kjeyapal@akamai.com
c32aad1961 avformat/dashenc: Added an option to ignore io errors
When dashenc has to run for long duration(say 24x7 live stream), one can enable this option to ignore the io failure of few segment's upload due to an intermittent network issues.
When the network connection recovers dashenc will continue with the upload of the current segments, leading to the recovery of the stream.
2018-12-02 19:14:37 +05:30
kjeyapal@akamai.com
6c1e124201 avformat/dashenc: Handled the error from dashenc_io_open() 2018-12-02 19:14:03 +05:30