Commit Graph

428 Commits

Author SHA1 Message Date
Michael Niedermayer 76424b2da8 Merge commit 'e01fba5562133ac56a4f44c6f214a80ee33cb388'
* commit 'e01fba5562133ac56a4f44c6f214a80ee33cb388':
  movenc: Add an F4V muxer

Conflicts:
	Changelog
	libavformat/allformats.c
	libavformat/movenc.c
	libavformat/version.h

See: 7bc70930dd
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2013-10-23 12:05:48 +02:00
Clément Bœsch e01fba5562 movenc: Add an F4V muxer
F4V is Adobe's mp4/iso media variant, with the most significant
addition/change being supporting other flash codecs than just
aac/h264.

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-10-23 11:17:03 +03:00
Michael Niedermayer d5ec8ba7f2 Do not leave positive values undefined when negative are defined as error
Define positive return values as non errors and leave further meaning undefined
This allows future extensions to use these values

Reviewed-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-10-19 16:42:57 +02:00
Michael Niedermayer 6b1b63df85 Merge commit '71549a857b13edf4c4f95037de6ed5bb4c4bd4af'
* commit '71549a857b13edf4c4f95037de6ed5bb4c4bd4af':
  http: Support auth method detection for POST

Conflicts:
	libavformat/version.h

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2013-10-14 00:37:01 +02:00
Michael Niedermayer 5dee3e8bb4 Merge commit 'eb8b05a3824a9fa85e20d603595ac8a3b83505d4'
* commit 'eb8b05a3824a9fa85e20d603595ac8a3b83505d4':
  http: Add an option for forcing basic authentication

Conflicts:
	libavformat/http.c
	libavformat/version.h

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2013-10-14 00:17:49 +02:00
Martin Storsjö 71549a857b http: Support auth method detection for POST
Inspired by a patch by Jakob van Bethlehem. But instead of doing
an empty POST first to trigger the WWW-Authenticate header (which
would succeed if no auth actually was required), add an Expect:
100-continue header, which is meant to be used exactly for
cases like this.

The header is added if doing a post, and the user has specified
authentication but we don't know the auth method yet.

Not all common HTTP servers support the Expect: 100-continue header,
though, so we only try to use it when it really is needed. The user
can request it to be added for other POST requests as well via
an option - which would allow the caller to know immediately that
the POST has failed (e.g. if no auth was provided but the server
required it, or if the target URL simply doesn't exist).

This is only done for write mode posts (e.g. posts without pre-set
post_data) - for posts with pre-set data, we can just redo the post
if it failed due to 401.

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-10-13 12:59:03 +03:00
Martin Storsjö eb8b05a382 http: Add an option for forcing basic authentication
The default is to autodetect the auth method. This does require one
extra request (and also closing and reopening the http connection).
For some cases such as HTTP POST, the autodetection is not handled
properly (yet).

No option is added for digest, since this method requires getting
nonce parameters from the server first and can't be used straight
away like Basic.

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-10-13 12:59:03 +03:00
Nicolas George ecab1c7741 oggdec: add support for Opus in Ogg demuxing 2013-10-12 15:25:18 +02:00
Michael Niedermayer 5082fcc0e2 avformat: add support to force specific AVCodecs
previously only codec_ids could be forced, which did not allow
forcing a specific implementation like libopenjpeg vs jpeg2000.

Reviewed-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-10-02 22:56:03 +02:00
Michael Niedermayer f31c36e552 Merge commit '705b748e8d8612385c96428ae36ed0d42a170d93'
* commit '705b748e8d8612385c96428ae36ed0d42a170d93':
  tls: Add support for listen mode

Conflicts:
	doc/protocols.texi
	libavformat/tls.c
	libavformat/version.h

See: 4f4eb380f0
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2013-09-27 11:33:19 +02:00
Michael Niedermayer e6e71fd7b5 Merge commit '8b09d917e7dc7d7f2ace31419f802d4ff518236c'
* commit '8b09d917e7dc7d7f2ace31419f802d4ff518236c':
  tls: Add options for verifying the peer certificate

Conflicts:
	doc/protocols.texi
	libavformat/tls.c
	libavformat/version.h

See: b2460858f6
See: 973a758f52
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2013-09-27 09:33:28 +02:00
Martin Storsjö 705b748e8d tls: Add support for listen mode
Also add options for specifying a certificate and key, which can
be used both when operating as client and as server.

Partially based on a patch by Peter Ross.

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-09-26 23:13:35 +03:00
Martin Storsjö 8b09d917e7 tls: Add options for verifying the peer certificate
A file containing the trusted CA certificates needs to be
supplied via the ca_file AVOption, unless the TLS library
has got a system default file/database set up.

This doesn't check the hostname of the peer certificate with
openssl, which requires a non-trivial piece of code for
manually matching the desired hostname to the string provided
by the certificate, not provided as a library function.

That is, with openssl, this only validates that the received
certificate is signed with the right CA, but not that it is
the actual server we think we're talking to.

Verification is still disabled by default since we can't count
on a proper CA database existing at all times.

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-09-26 23:13:06 +03:00
James Almer 39442b1a1b matroskaenc: Add CuePoints for subtitle tracks
Signed-off-by: James Almer <jamrial@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-09-20 22:40:16 +02:00
Michael Niedermayer 04ee57ce0a Merge commit 'bb461370e34b1fa1637f34ce7d37b934ddb472d5'
* commit 'bb461370e34b1fa1637f34ce7d37b934ddb472d5':
  asfenc: mux chapters in ASF files using an ASF "marker" section

Conflicts:
	Changelog
	libavformat/version.h

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2013-09-20 12:06:15 +02:00
Vladimir Pantelic bb461370e3 asfenc: mux chapters in ASF files using an ASF "marker" section
ASF markers only have a start time, so we lose the chapter end times,
but that is ASF for you

Signed-off-by: Vladimir Pantelic <vladoman@gmail.com>
Signed-off-by: Anton Khirnov <anton@khirnov.net>
2013-09-19 19:51:49 +02:00
Michael Niedermayer b7e7d8cdaf Merge remote-tracking branch 'qatar/master'
* qatar/master:
  movenc: Add an option for omitting the tfhd base offset

Conflicts:
	libavformat/version.h

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2013-09-18 13:32:55 +02:00
Martin Storsjö e7bf085b78 movenc: Add an option for omitting the tfhd base offset
This makes the output fragments independent of their position in
the output stream, making the output work better when streamed.

QuickTime Player doesn't support fragmented mp4 without the base
data offset, though.

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-09-17 23:30:31 +03:00
Michael Niedermayer 96e6447d62 Merge commit '596e5d4783ca951258a7c580951fd161f1785ec1'
* commit '596e5d4783ca951258a7c580951fd161f1785ec1':
  lavf: Add a flag to enable/disable per-packet flushing

Conflicts:
	libavformat/avformat.h
	libavformat/mux.c
	libavformat/version.h

This adds a 2nd API to set per packet flushing
If the user application indicates through either a non default then this non default takes
precedence over the other still default value

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2013-09-17 12:01:35 +02:00
Luca Barbato 596e5d4783 lavf: Add a flag to enable/disable per-packet flushing
This is enabled by default and can be disabled with
"-fflags -flush_packets".

Inspired by a patch from Nicolas George <nicolas.george@normalesup.org>.

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-09-16 22:11:08 +03:00
Paul B Mahol 42b8f5fba1 avformat/segafilm: remove deplanarization hack
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2013-09-16 13:30:20 +00:00
Vignesh Venkatasubramanian d92b1b1bab lavf/matroska: Adding support for Opus CodecDelay
In order to represent the codec delay accurately in Matroska, a
new element CodecDelay has been introduced. It contains the
overall delay added by the codec in nanoseconds. This patch adds
support for muxing CodecDelay value in the container.
Matroska spec for CodecDelay element can be found here:
http://matroska.org/technical/specs/index.html#CodecDelay

Signed-off-by: Vignesh Venkatasubramanian <vigneshv@google.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-09-10 01:45:38 +02:00
Clément Bœsch 36cd017acd avformat: make avformat_close_input() more tolerant.
The purpose of this commit is to make error management simpler and less
error prone, just like av_free() which is safe with NULL.
2013-09-04 22:06:38 +02:00
Dirk Farin 902a5fa722 avformat: H265 demuxer
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-09-03 19:34:04 +02:00
Michael Niedermayer e31db621bf avformat: export probe score
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-08-28 22:18:57 +02:00
Stefano Sabatini 7af7b45c38 lavf/image2: extend start_number range to accept zero
Address trac ticket #2884.
2013-08-22 14:26:23 +02:00
Stefano Sabatini 5ae3563359 lavf/tee: add special select option 2013-08-21 17:44:35 +02:00
Michael Niedermayer e1acfd3cb0 Merge commit 'b886f5c2f1e71b3e60e4265c500158d392b4b9a4'
* commit 'b886f5c2f1e71b3e60e4265c500158d392b4b9a4':
  mkv: Allow flushing the current cluster in progress

Conflicts:
	libavformat/matroskaenc.c
	libavformat/version.h

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2013-08-20 11:44:25 +02:00
Martin Storsjö b886f5c2f1 mkv: Allow flushing the current cluster in progress
Allow emitting the current cluster that is being written before
starting a new one, simplifying how to figure out where clusters
are positioned in the output stream (for live streaming).

Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2013-08-19 22:47:07 +02:00
Stefano Sabatini faf7c35655 lavf/tee: add support for bitstream filtering
This allows to apply different bitstream filters to different outputs,
with no need to transcode.
2013-08-16 17:58:58 +02:00
Alexis Ballier 7a48b1c492 Remove FF_API_PKT_DUMP cruft. Not compiled since libavformat 54.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-08-13 04:18:32 +02:00
Alexis Ballier ca2378ad04 libavformat/version.h: Drop FF_API_OLD_AVIO (unused and undefined since libavformat 55)
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-08-13 03:26:25 +02:00
Marton Balint a7bb12a307 mpegts: add fix_teletext_pts mpegts demuxer option
Changes since v1 of the patch:
- enable option by default
- add documentation
- move up PTS override code after PES header parsing, to ensure we use the
  last PCR before the first packet of the teletext PES packet.

The option overrides teletext packet PTS and DTS values with the timestamps
calculated from the PCR of the first program which the teletext stream is part
of and is not discarded.

Using the same teletext PID for multiple programs is possible, therefore we
need some kind of heuristics to know which program PCR we should synchronize
to. Using the first non-discarded PCR pid among the programs of the teletext
stream seemed like a good choice.

The patch does not do PCR interpolation to estimate the PCR of the teltetext
packet, it just uses the last PCR of the program, which may cause a slight
error (0.1 sec) in the teletext packet pts-es.

Based on a patch by Reimar Döffinger.
http://lists.ffmpeg.org/pipermail/ffmpeg-devel/2012-September/131610.html

Signed-off-by: Marton Balint <cus@passwd.hu>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-08-06 02:47:38 +02:00
Andrey Utkin b7ed18b9bd mpegtsenc: add option tables_version
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-08-03 12:44:53 +02:00
Michael Niedermayer 8e970a5861 Merge commit '0d6fa3977b016f1b72b0b24b8834ff9222498548'
* commit '0d6fa3977b016f1b72b0b24b8834ff9222498548':
  rtmp: Add seek support

Conflicts:
	Changelog
	libavformat/version.h

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2013-08-03 09:01:48 +02:00
Gavriloaie Eugen-Andrei 0d6fa3977b rtmp: Add seek support
Signed-off-by: Martin Storsjö <martin@martin.st>
2013-08-02 20:11:54 +03:00
Carl Eugen Hoyos 0fff7f039c Supply a User-Agent header when opening rtsp streams.
Some rtsp servers like the IP Cam IcyBox IB-CAM2002 need it.
Fixes ticket #2761.
Reported, analyzed and tested by trac user imavra.
2013-07-11 23:05:53 +02:00
Stefano Sabatini 19ea08a11a lavf/segment: add initial_offset option
Should address trac ticket #2224.
2013-07-11 00:36:24 +02:00
Michael Niedermayer f9d7431272 avformat/AVFormatContext: Move fields down to match the fork
avconv uses private and internal fields from libavformat, we thus must
match the layout even of the fields marked non public.
Otherwise ffmpegs libavformat could not be used as a dropin replacement
on debian/ubuntu

The current soname of libavformat was not part of any release nor are any
fields marked public moved thus in theory
no installed shared lib ABI breakage should occur. Still the need for this
change is unfortunate and chilling.
If you installed shared libs from a recent development version of libavformat
that is more recent than the last release. You probably want to check or rebuild
applications that linked to it.

minor versions of avformat & avdevice are bumped to allow detecting this
as both use the updated struct

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-07-09 19:06:32 +02:00
Michael Niedermayer 0844630e6b avformat/mp3dec: Add usetoc option to allow dlsabling the use of the xing TOC
The toc is inexact and not using it can thus make sense.
Using it is faster though, thus the opposite can similarly makes sense

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-07-06 05:43:48 +02:00
wm4 c3316ddb83 lavf: add support for libgme
Reviewed-by: Stefano Sabatini <stefasab@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-07-02 18:52:45 +02:00
wm4 a92fbe16f2 lavf/http: add support for reading streamcast metadata
Allow applications to request reading streamcast metadata. This uses
AVOptions as API, and requires the application to explicitly request
and read metadata. Metadata can be updated mid-stream; if an
application is interested in that, it has to poll for the data by
reading the "icy_metadata_packet" option in regular intervals.

There doesn't seem to be a nice way to transfer the metadata in a nicer
way. Converting the metadata to ID3v2 tags might be a nice idea, but
the libavformat mp3 demuxer doesn't seem to read these tags mid-stream,
and even then we couldn't guarantee that tags are not inserted in the
middle of mp3 packet data.

This commit provides the minimum to enable applications to retrieve
this information at all.

Signed-off-by: Stefano Sabatini <stefasab@gmail.com>
2013-07-02 02:00:56 +02:00
Matthew Heaney bc35df29c1 lavf: add AV_DISPOSITION flags for WebVTT text track kinds
There are 4 separate WebVTT text track kinds: subtitles (the default
if not otherwise specified), captions, descriptions, and metadata.
The WebM muxer needs to know which WebVTT text track kind this is, in
order to synthesize the correct track type and codec id.

To allow a demuxer to indicate the text track kind of the input, a new
set of AV_DISPOSITION flag values has been added, corresponding to
each of the non-default text track kind values.
2013-06-25 00:13:47 +02:00
Matthew Heaney b24f15c45e lavf: add WebVTT muxer.
This revision creates a WebVTT muxer, that outputs files having the
format described in the following specification:

http://dev.w3.org/html5/webvtt/
2013-06-17 22:28:19 +02:00
James Almer 1bb005ce54 lavf/md5enc: Use AV_HASH_MAX_SIZE
Also increase the buffer size in write_trailer(), since 128
is not enough anymore

Signed-off-by: James Almer <jamrial@gmail.com>
2013-06-15 18:50:11 -03:00
Matthieu Bouron f468325d34 lavf/id3v2enc: fix cover art display on some software
Adding an arbitrary amount of padding bytes at the end of the
ID3 metadata fixes cover art display for some software (iTunes,
Traktor, Serato, Torq).

For reference (ID3 metadata):

[ Apic frames ]                      -> cover doesn't show up
[ Apic frames, Padding ]             -> ok
[ Apic frames, ID3 frames ]          -> ok
[ ID3 frames, Apic frames ]          -> cover doesn't show up
[ ID3 frames, Apic frames, Padding ] -> ok
2013-05-30 21:16:57 +00:00
Paul B Mahol c4e0e31424 tta: remove pointless code
Checking seek table crc in decoder is pointless, as seek table is not used in
decoder anyway, so also stop storing seek table into extradata.
2013-05-30 20:17:27 +00:00
Michael Niedermayer d9cde3976c Merge commit '2d2d6a4883479403798f4ed46941d5b365823570'
* commit '2d2d6a4883479403798f4ed46941d5b365823570':
  lavf: add a raw WavPack muxer.
  apetag: add support for writing APE tags
  matroskaenc: support muxing WavPack

Conflicts:
	libavformat/Makefile
	libavformat/allformats.c
	libavformat/apetag.h
	libavformat/version.h
	libavformat/wvenc.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2013-05-29 10:40:42 +02:00
Anton Khirnov 2d2d6a4883 lavf: add a raw WavPack muxer. 2013-05-28 18:19:19 +02:00
James Almer e5e86db178 RedSpark demuxer
Signed-off-by: James Almer <jamrial@gmail.com>
2013-05-10 16:53:02 -03:00