Commit Graph

21216 Commits

Author SHA1 Message Date
kjeyapal@akamai.com f848d384dd avformat/dashenc: Support HTTP Persistent for master.m3u8 as well 2018-10-21 16:26:32 +05:30
Carl Eugen Hoyos 6871c17173 lavf/matroskadec: Simplify string length calculation.
FFmpeg relies on sizeof(char) == 1.
2018-10-19 20:36:55 +02:00
Carl Eugen Hoyos feb05ffa99 lavf/dump: Fix a typo: comentary -> commentary.
Fixes ticket #7499.
2018-10-19 20:19:25 +02:00
Karthick Jeyapal 444cdb422d avformat/dashenc: Dont ignore the codec tag from codec parameters 2018-10-18 10:56:05 +05:30
Michael Niedermayer 079d1a7175 avformat/utils: Never store negative values in last_IP_duration
Fixes: integer overflow compute_pkt_fields()
Fixes: compute_pkt_usan

Reported-by: Thomas Guilbert <tguilbert@chromium.org>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2018-10-18 02:28:54 +02:00
Michael Niedermayer 4e19cfcfa3 avformat/utils: Fix integer overflow in discontinuity check
Fixes: signed integer overflow: 7738135736989908991 - -7954308516317364223 cannot be represented in type 'long'
Fixes: find_stream_info_usan

Reported-by: Thomas Guilbert <tguilbert@google.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2018-10-18 02:28:54 +02:00
Carl Eugen Hoyos b9136c1b90 lavf/mxfenc: Remove a write-only variable.
Fixes the following warning:
libavformat/mxfenc.c:2125:22: warning: variable 'frame_size' set but not used
2018-10-17 20:47:14 +02:00
bnnm 02ea060b29 avformat/xwma: fix WMAv2 with incorrect bit rate
Fixes trac issue #7215

Output for files created by xWMAEncode and various videogames is correct now.

1ch 32000hz files are still broken, would need fixes in WMA decoder.

Signed-off-by: bnnm <bananaman255@gmail.com>
2018-10-17 20:35:06 +02:00
Paul B Mahol 0709b0561f avformat: add SER demuxer 2018-10-13 15:40:08 +02:00
Carl Eugen Hoyos b4e29e6225 lavf/mxfenc: Remove two unused variables.
Fixes the following warnings:
libavformat/mxfenc.c:2036:9: warning: unused variable 'i'
libavformat/mxfenc.c:2125:9: warning: unused variable 'i'
2018-10-13 13:08:32 +02:00
Baptiste Coudurier ef23ed6fe9 lavf/mxfdec: demux s436m as eia608 subtitle track 2018-10-12 12:28:28 -07:00
Baptiste Coudurier 9b7ab57953 lavf/mxfenc: support creating s436m data tracks 2018-10-12 12:28:22 -07:00
Baptiste Coudurier bb89109a0a avformat/mxfenc: correctly set content package rate in system element 2018-10-12 12:27:58 -07:00
Baptiste Coudurier 84e8a87ca0 avformat/mxfenc: update body partition with footer offset 2018-10-12 12:27:43 -07:00
Baptiste Coudurier ea55a11ced avformat/mxfenc: add mpeg-2 specific metadata, fix compatibility with sony content browser 2018-10-12 12:26:01 -07:00
Baptiste Coudurier 3d38e45eb8 avformat/mxfenc: write index delta entry array needed by sony vegas pro 11 2018-10-12 12:15:38 -07:00
Jian Yang f7affc6f70 avformat/dashenc: only write video streams into HLS master playlist
Tool mediastreamvalidator reports error "Variant media_[N].m3u8 is
missing audio group" for audio streams in HLS master playlist. As audio
streams are already listed in audio group, skip them as variant media
streams in master playlist.
2018-10-11 12:46:31 +05:30
Carl Eugen Hoyos f85fa100db lavf/ftp: Remove an unneeded forward declaration. 2018-10-09 22:49:57 +02:00
Marton Balint 3bfd409e59 avformat/segment: fix segment_time_delta option min/max value
Signed-off-by: Marton Balint <cus@passwd.hu>
2018-10-07 20:26:29 +02:00
Michael Niedermayer 0a41a8bf29 avformat/utils: Fix potential integer overflow in extract_extradata()
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2018-10-07 03:03:09 +02:00
Michael Niedermayer b4a1ccfc41 avformat/utils: Do not use "i" as a context pointer, "i" is normally the integer counter in loops
This avoids surprising developers. Its bad to surprise developers with
such unexpected things.

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2018-10-07 03:03:09 +02:00
Michael Niedermayer beb3aea48e avformat/utils: Do not ignore failure in extract_extradata_init()
We check for the documented explanation of the "Ignore code" in extract_extradata_check() already

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2018-10-07 03:03:09 +02:00
Michael Niedermayer 52e62b0585 avformat/movenc: Remove unneeded variable from mov_find_codec_tag()
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2018-10-07 03:03:09 +02:00
Michael Niedermayer 8c49340b18 libavformat/ty: use decimal constant for shift
This was the only case in the source that uses a hexadecimal shift value.
The change removed a special case in respect to greping

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2018-10-07 03:03:09 +02:00
Marton Balint ab0812c1a8 avformat/udp: always use IP_ADD_SOURCE_MEMBERSHIP for subscribing to an UDP multicast source group in IPv4
That alone supports specifying the interface based on its address. Getting the
interface index from the local address seems quite a bit of work in a platform
independent way...

Obviously for IPv6 we still always use MCAST_JOIN_SOURCE_GROUP.

As a side effect this also fixes ticket #7459.

Signed-off-by: Marton Balint <cus@passwd.hu>
2018-10-03 22:03:29 +02:00
Marton Balint d3bda871f0 avformat/udp: specify the local address for some source filtered multicast joins
We already use localaddr for the multicast joins without source filters, so we
should use them for source filters as well. This patch only fixes the
IP_ADD_SOURCE_MEMBERSHIP and the IP_BLOCK_SOURCE case.

Unless we do this, the kernel automatically selects an interface based on the
source address, and that interface might be different from the one set in
localaddr. For blocked sources this even casues EINVAL because we joined the
multicast group on a different interface.

Signed-off-by: Marton Balint <cus@passwd.hu>
2018-10-03 22:03:29 +02:00
Marton Balint 91a1363452 avformat/udp: add support for generic source filtering
This allows getting data only from a specific source IP. This is useful not
only for unicast but for multicast as well because multicast source
subscriptions do not act as source filters for the incoming packets.

Signed-off-by: Marton Balint <cus@passwd.hu>
2018-10-03 22:03:29 +02:00
Marton Balint 9d4829f3c9 avformat/rtpproto: use factorized ip functions
Signed-off-by: Marton Balint <cus@passwd.hu>
2018-10-03 22:03:29 +02:00
Marton Balint 826972c9d8 avformat/udp: use factorized ip functions
Signed-off-by: Marton Balint <cus@passwd.hu>
2018-10-03 22:03:29 +02:00
Marton Balint 45fa756fa4 avformat/ip: factorize some IP filtering and resolving functions to a new file
These are based on the very similar UDP and RTP protocol functions.

Signed-off-by: Marton Balint <cus@passwd.hu>
2018-10-03 22:03:29 +02:00
Sigga Regina dcbd89e000 avformat/matroskaenc: reserve free space for metadata on request
Signed-off-by: James Almer <jamrial@gmail.com>
2018-10-01 14:52:35 -03:00
Carl Eugen Hoyos 303439bc5f lavf/mpeg: Support demuxing HEVC in mpeg-ps. 2018-09-27 23:53:21 +02:00
James Almer 819e4e7979 avformat/matroskaenc: reindent after the previous commit
Signed-off-by: James Almer <jamrial@gmail.com>
2018-09-26 15:17:14 -03:00
James Almer 8439656503 avformat/matroskaenc: refactor checks for allowed codecs in WebM
Use the new ff_webm_codec_tags[] array for this purpose.

Signed-off-by: James Almer <jamrial@gmail.com>
2018-09-26 15:17:14 -03:00
James Almer 794079e815 avformat/matroskaenc: implement AVOutputFormat.query_codec for webm
Signed-off-by: James Almer <jamrial@gmail.com>
2018-09-26 15:17:13 -03:00
James Almer 14ac62f9af avformat/matroskaenc: remove unnecessary additional codec tags
They are listed in riff.c already.

Signed-off-by: James Almer <jamrial@gmail.com>
2018-09-26 15:17:13 -03:00
Steven Liu bb660800a5 avformat/utils: move mkdir_p to utils
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 <lq@chinaffmpeg.org>
2018-09-25 21:57:49 +08:00
Baptiste Coudurier dc58e33dd3 avformat/utils: set AV_PKT_FLAG_KEY for data packets 2018-09-24 13:51:13 -07:00
James Almer e50cb8b2f4 avformat/ivfenc: fix writing codec tag
The value in AVCodecParameters->codec_tag may not be correct for IVF,
as it's the case when remuxing AV1 streams from mp4, so ignore it and
write the correct value based on codec ID instead.

Reviewed-by: Jan Ekström <jeebjp@gmail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
2018-09-24 16:15:30 -03:00
James Almer a068594248 Revert "avformat/matroskaenc: write CodecPrivate in WebM"
This reverts commit 4755b6e6d1.

This change was not necessary. CodecPrivate was being written to WebM
for codecs like AV1 already.
2018-09-21 18:22:37 -03:00
James Almer 4755b6e6d1 avformat/matroskaenc: write CodecPrivate in WebM
This is now needed for AV1.

Signed-off-by: James Almer <jamrial@gmail.com>
2018-09-21 16:57:32 -03:00
Kagami Hiiragi cbe5c7ef38 lavf/matroska: Allow AV1 in WebM
Nothing prevents it to work except this check. AV1 is already supported
by Matroska muxer and aomenc produces WebM/AV1 files as well.

Signed-off-by: Kagami Hiiragi <kagami@genshiken.org>
Signed-off-by: James Almer <jamrial@gmail.com>
2018-09-21 12:20:48 -03:00
Karthick Jeyapal 49c67e79ca avformat/dashenc: Reduce Muxing overhead for chunked CMAF format
SIDX atom being inserted for every MOOF atom increases the muxing overhead.
This behaviour can be disabled for chunked CMAF format by enabling Global SIDX option of mov muxer.
2018-09-19 17:31:56 +05:30
Carl Eugen Hoyos 26902f2ef0 lavf/webvttenc: Always write hours in the timestamp with two characters.
Fixes ticket #7442.

Reviewed-by: Reto Kromer
2018-09-19 18:07:32 +02:00
James Almer e3981c5a21 avformat/dashenc: Format VP9 profile as decimal instead of Hexadecimal
Signed-off-by: James Almer <jamrial@gmail.com>
2018-09-17 14:29:46 -03:00
Karthick Jeyapal 422be081a3 avformat/dashenc: Format VP9 bitdepth as decimal instead of Hexadecimal
For example bitdepth should be printed as 10 instead of 0A. Thanks to Hendrik Leppkes for pointing this out

Signed-off-by: James Almer <jamrial@gmail.com>
2018-09-17 14:29:40 -03:00
Karthick Jeyapal 7ff3d2594f avformat/dashenc: Format VP9 level as decimal instead of hexadecimal
Commit ID 63c69d51c7 fixed the bug in vpcc, get_vp9_level() function, causing this change.

Signed-off-by: James Almer <jamrial@gmail.com>
2018-09-17 14:29:40 -03:00
James Almer 63c69d51c7 avformat/vpcc: fix values in VP9 level detection heuristics
The levels are stored as decimal values, not hexadecimal.

Reviewed-by: James Zern <jzern@google.com>
Signed-off-by: James Almer <jamrial@gmail.com>
2018-09-15 18:06:58 -03:00
Jason Stevens 384dcd66a2 libavformat/mxfenc: fix dnxhr ul typo
byte 8 of dnxhr codec ul should be 0x0D

Signed-off-by: Jason Stevens <jay@wizardofthenet.com>
Reviewed-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2018-09-15 20:00:45 +02:00
Carl Eugen Hoyos 0a12af2185 lavf/davs2: Do not mix declarations and code.
Fixes the following warning:
libavformat/davs2.c:39:5: warning: ISO C90 forbids mixed declarations and code
2018-09-14 20:55:51 +02:00