1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2024-11-26 19:01:44 +02:00
Commit Graph

11029 Commits

Author SHA1 Message Date
Sven Dueking
f25117a428 libsrt: Pass the correct pointer for the passphrase
The passphrase field is a pointer already.

Bug-Id: https://github.com/Haivision/srt/issues/416
2018-07-13 18:36:11 +02:00
Sven Dueking
a507af97ee avformat/libsrt: add latency options and deprecate tspbdelay
Signed-off-by: Sven Dueking <sven.dueking@nablet.com>
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2018-06-04 18:47:48 +02:00
Sven Dueking
ea8ae27a5e avformat/libsrt: add payload size option
Signed-off-by: Sven Dueking <sven.dueking@nablet.com>
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2018-06-03 17:46:23 +02:00
Diego Biurrun
e368b0cbfa tls_mbedtls: Use non-deprecated header file
/usr/include/mbedtls/net.h:29:2: warning: #warning "Deprecated header file: Superseded by mbedtls/net_sockets.h" [-Wcpp]
2018-04-26 11:27:08 +02:00
Thomas Volkert
4130e05ff4 libavformat: add mbedTLS based TLS
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2018-04-25 10:34:12 +02:00
Diego Biurrun
23be4eebf8 build: Group external library protocols separately 2018-04-20 12:00:10 +02:00
Sven Dueking
a2fc8dbae8 Add Haivision SRT protocol
The protocol requires libsrt (https://github.com/Haivision/srt) to be
installed

Signed-off-by: Sven Dueking <sven.dueking@nablet.com>
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2018-03-28 16:16:41 +02:00
Luca Barbato
44a1731011 ivf: Support VP9 and AV1 as well 2018-03-12 08:12:43 +01:00
Luca Barbato
aeaa108baf hls: Add a discontinuity marker on recover
It seems to improve the compatibility with the js demuxers.

Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2018-03-06 20:59:40 +01:00
James Almer
dc40e64adb hvcc: zero initialize the nal buffers past the last written byte
Bug-Id: 1116
Cc: libav-stable@libav.org

Signed-off-by: James Almer <jamrial@gmail.com>
2018-02-23 00:17:17 -03:00
Diego Biurrun
4cf84e254a Drop some unnecessary config.h #includes 2018-02-06 10:03:15 +01:00
Josh Allmann
a2a9e4eea0 rtmp: Plug leak if sending bytes read report fails.
Signed-off-by: Martin Storsjö <martin@martin.st>
2018-01-24 07:16:06 +02:00
Tristan Matthews
f6161fccf8 rtsp: only break on parse_rtsp_message on error
Fix suggested by Luca Barbato.

This was causing spurious EOFs when using -rtsp_transport udp, as
reported in https://bugzilla.libav.org/show_bug.cgi?id=1103

Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2017-11-30 15:32:04 +01:00
Sean McGovern
fbca6e7d16 matroskadec: allow RealAudio/Cook/Sipro streams of flavor 0
Regression since 569d18aa9d.

Bug-Id: 1055
Cc: libav-stable@libav.org
2017-11-06 17:30:05 -05:00
James Almer
55fe72a841 matroskadec: don't warn about unknown spherical medata when none is present
track->video.projection.type is set to 0 (a Matroska specific "No spherical
metadata present" value, with no related AVSphericalMapping) by default on
files without the element.

This removes bogus warnings on every single matroska file without Spherical
metadata.

Signed-off-by: James Almer <jamrial@gmail.com>
2017-11-03 19:41:08 -03:00
Peter Große
91760a9340 dashenc: copy stream frame rate to output stream
Leads to setting of DefaultDuration in Matroska muxer based on frame rate instead of timebase.
Fixes playback in Chrome.

Signed-off-by: Peter Große <pegro@friiks.de>
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2017-10-27 19:52:48 +02:00
Anton Schubert
4723c6226a dashenc: fix bitrate estimation with correct scaling
Signed-off-by: Anton Schubert <ischluff@mailbox.org>
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2017-10-27 19:52:48 +02:00
Jacek Jendrzej
9b1c091114 http: Reset compressed header flag when starting to read a request
This fixes redirects, where the original redirect response indicated
support for compression, while the actual redirected content didn't.

Signed-off-by: Martin Storsjö <martin@martin.st>
2017-09-26 13:36:21 +03:00
Michael Niedermayer
ec683ed527 smacker: fix integer overflow with pts_inc
Bug-Id: 1073

Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Sean McGovern <gseanmcg@gmail.com>
2017-09-24 12:58:42 +02:00
Sean McGovern
9e36102278 smacker: return meaningful error codes on failure 2017-09-24 12:57:54 +02:00
James Almer
ac6691ab99 avio: update avio_alloc_context() doxy
It must be freed using avio_context_free() starting with commit
99684f3ae7.

Signed-off-by: James Almer <jamrial@gmail.com>
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2017-09-14 09:53:31 +02:00
Martin Storsjö
585dc1aece flvdec: Check the avio_seek return value after reading a metadata packet
If the metadata packet is corrupted, flv_read_metabody can accidentally
read past the start of the next packet. If the start of the next packet
had been flushed out of the IO buffer, we would be unable to seek to
the right position (on a nonseekable stream).

Prefer to clearly error out instead of silently trying to read from a
desynced stream which will only be interpreted as garbage.

Signed-off-by: Martin Storsjö <martin@martin.st>
2017-09-04 09:42:51 +03:00
Martin Storsjö
e41daa6246 Remove support for building for mingw32ce (Windows CE)
The toolchain for this target is unmaintained since many years.

While it has been continuously build tested on fate, it hasn't
actually been tested at runtime since many, many years (and back
then, only a few codecs in libavcodec were tested).

So far, keeping support for it has been mostly effortless, but
the compiler does seem to have issues with dllimported data symbols,
ending up as internal compiler errors in some cases. Instead of
jumping through further hoops to work around that, just remove the
target.

Signed-off-by: Martin Storsjö <martin@martin.st>
2017-08-31 14:21:08 +03:00
wm4
173b56218f lavf: make avio_read_partial() public
Main use-case is proxying avio through a foreign I/O layer and a custom
AVIO context, without losing latency and performance characteristics.

Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2017-08-30 14:29:14 +02:00
Mark Thompson
b88da98b34 hevc: Improve stream constraint values in common header
Add comments to describe the sources of the constraint values expressed here,
and add some more related values which will be used in following patches.

Fix the incorrect values for SPS and PPS count (they are not the same as those
used for H.264), and remove HEVC_MAX_CU_SIZE because it is not used anywhere.
2017-08-05 23:54:35 +01:00
Sean McGovern
defe307fb2 mov: move stsd finalization to an appropriate place
mov_finalize_stsd_codec() parses stream information from the ALAC extradata,
so run it after the extradata processing is completed in mov_read_stsd().

Fixes playback of 96kHz ALAC streams muxed by qaac or the reference alac encoder.

Adapted from an FFmpeg patch by Hendrik Leppkes <h.leppkes@gmail.com>

Bug-Id: 1072
2017-07-31 17:41:01 -04:00
Sean McGovern
3050dabaa9 mov: Do not set stsd_count if mov_read_stsd() fails
Based on an FFmpeg patch by Michael Niedermayer <michael@niedermayer.cc>
2017-07-31 17:41:01 -04:00
Sean McGovern
d7bdab1ad7 mov: log and return early on non-positive stsd entry counts
Based on an FFmpeg patch by Michael Niedermayer <michael@niedermayer.cc>
2017-07-30 10:51:12 -04:00
Sean McGovern
80e919b174 rmdec: add missing brackets to compound statement
Accidentally left out of 95ce02b35d.
2017-07-25 19:19:20 -04:00
wm4
2b1324bd16 lavf: allow avformat_close_input() with NULL
This is consistent with how other destructors behave.

Signed-off-by: Anton Khirnov <anton@khirnov.net>
2017-07-22 09:30:56 +02:00
Anton Khirnov
48a5c35346 caf: add an Opus tag
CC: libav-stable@libav.org
2017-07-22 09:30:56 +02:00
Sean McGovern
95ce02b35d rmdec: don't ignore the return value of av_get_packet() 2017-07-17 07:08:13 -04:00
Diego Biurrun
825e463a17 build: Add feature test macros for glibc 2.19+
glibc introduced _DEFAULT_SOURCE in version 2.19 to replace _BSD_SOURCE and
_SVID_SOURCE, which were deprecated in version 2.20. Add _DEFAULT_SOURCE
where the latter two are used to be forwards-compatible and avoid warnings
about the use of deprecated definitions.
2017-07-10 10:22:56 +02:00
Martin Storsjö
4d330da006 os_support: Use HAVE_UWP instead of manually checking WINAPI_FAMILY
Signed-off-by: Martin Storsjö <martin@martin.st>
2017-07-05 13:55:12 +03:00
Martin Storsjö
61f589e31e lavf: Remove codec_tag from dashenc and smoothstreamingenc
Currently, the tags enforced and set on the segmenter muxer level
mismatch what the mp4/ismv muxer uses (since 713efb2c0d).

Skip the codec_tag altogether here, to let the user (try to) set
whichever codec/tag is preferred; the individual chained muxer will
reject invalid codecs anyway.

Signed-off-by: Martin Storsjö <martin@martin.st>
2017-07-02 22:42:26 +03:00
Martin Storsjö
eb061ad6fd tls_gnutls: Readd support for nonblocking operation
The rtmp protocol uses nonblocking reads, to poll for incoming
messages from the server while publishing a stream.

Prior to 94599a6de3 and
d13b124eaf, the tls protocol
handled the nonblocking flag, mostly as a side effect from not
using custom IO callbacks for reading from the socket. When custom
IO callbacks were taken into use in
d15eec4d6b, the handling of a nonblocking
socket wasn't necessary for the default blocking mode any longer.

The code was simplified, since it was overlooked that other code
within libavformat actually used the tls protocol in nonblocking mode.

This fixes publishing over rtmps, with the gnutls backend.

Signed-off-by: Martin Storsjö <martin@martin.st>
2017-06-20 23:55:52 +03:00
Martin Storsjö
0671eb2346 tls_openssl: Readd support for nonblocking operation
The rtmp protocol uses nonblocking reads, to poll for incoming
messages from the server while publishing a stream.

Prior to 94599a6de3 and
d13b124eaf, the tls protocol
handled the nonblocking flag, mostly as a side effect from not
using custom IO callbacks for reading from the socket. When custom
IO callbacks were taken into use in
d15eec4d6b, the handling of a nonblocking
socket wasn't necessary for the default blocking mode any longer.

The code was simplified, since it was overlooked that other code
within libavformat actually used the tls protocol in nonblocking mode.

This fixes publishing over rtmps, with the openssl backend.

Signed-off-by: Martin Storsjö <martin@martin.st>
2017-06-20 23:55:52 +03:00
John Stebbins
84ab1cc437 movenc: allow alternative hvc1 h.265 codec tag
If AVCodecParameters.codec_tag is 'hvc1' use it instead of 'hev1' for
h.265 streams. QuickTime (and other Apple software) requires 'hvc1'.
2017-06-20 08:08:38 -07:00
John Stebbins
1ea9b7fdf9 movenc: write correct format hvcc when tag is hvc1 2017-06-20 08:08:38 -07:00
John Stebbins
1c64bae648 movenc: move tags definitions to where they are used 2017-06-20 08:08:38 -07:00
John Stebbins
f6f86f432f movenc: simplify codec_tag lookup
mux.c init_muxer() already sets codec_tag correctly in the cases
simplified here.

This also adds the capability to support alternative tags for the
same codec_id.
2017-06-20 08:08:38 -07:00
John Stebbins
713efb2c0d movenc: use correct tag list for AVOutputFormat.codec_tag
ff_mp4_obj_type contains the wrong type of tags for
AVOutputFormat.codec_tag. AVOutputFormat.codec_tag is used to
validate AVCodecParameters.codec_tag so needs to be the same
type of tag.

Creates new tag lists for mp4 and ismv.  New tag lists support
same list of codecs found in ff_mp4_obj_type. psp uses the same
tag list as mp4 since these both use mp4_get_codec_tag to look up tags.
2017-06-20 08:08:38 -07:00
Diego Biurrun
61cec5adaa tls: Hide backend implementation details from users
TLS is currently implemented over either OpenSSL or GnuTLS, with more
backends likely to appear in the future. Currently, those backend libraries
are part of the protocol names used during e.g. the configure stage of a
build. Hide those details behind a generically-named declaration for the
TLS protocol to avoid leaking those details into the configuration stage.
2017-06-02 10:41:52 +02:00
Martin Storsjö
2ca759657b os_support: Remove the dynamic loading of getaddrinfo from the fallback getaddrinfo
If we for some unexplicable reason didn't pick up getaddrinfo
at configure, the default, IPv4-only, fallback should be good enough.

This effectively reverts 6023d84a2b.

Signed-off-by: Martin Storsjö <martin@martin.st>
2017-06-01 13:29:55 +03:00
Luca Barbato
16cb06bb30 hlsenc: Support recovery from an already present playlist
Parse the playlist to recover the start sequence and previously
generated segments and continue muxing from there.

Mainly useful for near-seamless recovery in live scenarios.
2017-05-31 14:22:52 +02:00
Martin Storsjö
7c35bee025 movenc-test: Add tests for negative cts offsets
Signed-off-by: Martin Storsjö <martin@martin.st>
2017-05-15 14:08:53 +03:00
Martin Storsjö
c415c8104c movenc: Don't write any edit list if the start offset is zero
In these cases, the CTTS flag is set, but no edit list is necessary.

Signed-off-by: Martin Storsjö <martin@martin.st>
2017-05-15 14:08:48 +03:00
Martin Storsjö
c380a0d7f7 movenc: Add an option for enabling negative CTS offsets
This reduces the need for an edit list; streams that start with
e.g. dts=-1, pts=0 can be encoded as dts=0, pts=0 (which is valid
in mov/mp4) by shifting the dts values of all packets forward.
This avoids the need for edit lists for such streams (while they
still are needed for audio streams with encoder delay).

This eases conformance with the DASH-IF interoperability guidelines.

Signed-off-by: Martin Storsjö <martin@martin.st>
2017-05-15 14:08:36 +03:00
Martin Storsjö
6ccf76aec7 mpjpeg: Use proper CR/LF in multipart headers
This is more correct.

Signed-off-by: Martin Storsjö <martin@martin.st>
2017-05-11 11:05:42 +03:00
Diego Biurrun
b5f19f7478 aac: Split function to parse ADTS header data into public and private part
This makes the currently semi-public avpriv_aac_parse_header() function
private to libavcodec and adds a proper public API function to return
the parts of the ADTS header required in libavformat.
2017-05-02 18:50:34 +02:00