Commit Graph

11103 Commits

Author SHA1 Message Date
Michael Niedermayer
a8e3815db5 lavf: factorize timestamp shift in update_initial_timestamps()
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-26 22:58:02 +02:00
Michael Niedermayer
5c4e2e8755 nutenc: avoid negative timestamps
Fixes Ticket1468

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-26 15:56:06 +02:00
Michael Niedermayer
3ba0dab76a lavf: Add support offset timestamps on muxing.
This allows avoiding negative timestamps.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-26 15:55:16 +02:00
Michael Niedermayer
e9350c44ad nutenc: remove outdated fixme
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-26 15:53:17 +02:00
Michael Niedermayer
299c0b30a6 lavf: fix bug that caused has_decode_delay_been_guessed() to never return !=0
Possibly fixes Ticket1724

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-26 04:53:03 +02:00
Duncan Salerno
4b80a619b7 Handle the following type of relative URL correctly:
http://a/b + //c/d = http://c/d
http://a/b?c + ?d = http://a/b?d
http://a/b?c/d + /e = http://a/e

Updated with feedback from Clément Bœsch

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-26 03:43:06 +02:00
Michael Niedermayer
d9d56712e9 oggparsetheora: print error when failing on unknown header
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-25 17:32:11 +02:00
Michael Niedermayer
abcaacf1ac Merge remote-tracking branch 'qatar/master'
* qatar/master:
  pthread: make sure AVFrame.extended_data is set properly.
  libfdk-aac: reindent after last commit
  libfdk-aac: Limit to supported sample rates.
  cbrt_tablegen: Include libm.h
  oggparsetheora: make it more robust
  ogg: prevent NULL pointer deference in theora gptopts

Conflicts:
	libavformat/oggparsetheora.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-25 16:11:34 +02:00
Michael Niedermayer
d3ef2da59d oggdec: add missing () for OGG_NOGRANULE_VALUE
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-25 16:03:55 +02:00
Michael Niedermayer
0842e32f99 Merge commit 'd1f05dd18375f2f8e68372edee11436927e43ba8'
* commit 'd1f05dd18375f2f8e68372edee11436927e43ba8':
  ogg: calculate the start position once all the headers are parsed

Conflicts:
	libavformat/oggdec.c
	libavformat/oggparseskeleton.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-25 16:00:09 +02:00
Michael Niedermayer
4c273eb64c oggdec: print a warning if the number of headers mismatch expectations.
This is based on:
	commit 7751e4693d
	Author: Luca Barbato <lu_zero@gentoo.org>

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-25 15:34:58 +02:00
Michael Niedermayer
cc4deafed1 oggdec: print error when headers couldnt be parses successfully
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-25 15:22:05 +02:00
Michael Niedermayer
46a35959d8 Merge commit '7751e4693dd10ec98c20fbd9887233b575034272'
* commit '7751e4693dd10ec98c20fbd9887233b575034272':
  ogg: check that the expected number of headers had been parsed
  libx264: change default to closed gop to match x264cli
  Use avcodec_free_frame() to free AVFrames.
  lavf: use a malloced AVFrame in try_decode_frame().
  lavc: add avcodec_free_frame().
  lavc: ensure extended_data is set properly on decoding
  lavc: initialize AVFrame.extended_data in avcodec_get_frame_defaults()
  lavc: use av_mallocz to allocate AVFrames.
  lavc: rename the argument of avcodec_alloc_frame/get_frame_defaults

Conflicts:
	doc/APIchanges
	doc/examples/decoding_encoding.c
	libavcodec/utils.c
	libavcodec/version.h
	libavfilter/src_movie.c
	libavformat/oggdec.c
	libavformat/oggdec.h
	libavformat/oggparsetheora.c
	libavformat/utils.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-25 15:15:16 +02:00
Clément Bœsch
4390f8c28d Fix two "skiping" typo. 2012-09-25 07:42:32 +02:00
Michael Niedermayer
6bcbe768bb lavf: dont add apic streams for demuxers that dont support it.
Fixes crash
Fixes ticket1730

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-25 02:47:09 +02:00
Luca Barbato
d1f05dd183 ogg: calculate the start position once all the headers are parsed
The fisbone packets can be muxed in any order as long the last one
comes before the first data packet.
2012-09-24 22:35:29 +02:00
Luca Barbato
7751e4693d ogg: check that the expected number of headers had been parsed
Not having the header for a codec is a tell-tale of a broken file.
2012-09-24 22:35:29 +02:00
Luca Barbato
0336dea2ef oggparsetheora: make it more robust 2012-09-24 22:35:29 +02:00
Michael Niedermayer
bb146bb57b ogg: prevent NULL pointer deference in theora gptopts
Additional safety in case a special ogg stream is crafted
with the proper number of

Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-24 22:35:29 +02:00
Stefano Sabatini
bbe9fe469a lavf/utils: remove loop on AVERROR(EAGAIN) in av_read_frame()
The loop was introduced in 64d340c62a, and
was likely breaking non blocking reads as it busy loops.
2012-09-24 21:16:48 +02:00
Michael Niedermayer
ff584803b7 Merge remote-tracking branch 'qatar/master'
* qatar/master:
  rtp: Packetization of JPEG (RFC 2435)
  smoothstreamingenc: Copy the SAR on the AVStreams as well

Conflicts:
	Changelog
	libavformat/rtpenc.c
	libavformat/version.h

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-24 13:54:24 +02:00
Anton Khirnov
11d1ca4b2c Use avcodec_free_frame() to free AVFrames. 2012-09-24 12:31:25 +02:00
Anton Khirnov
9eb296572e lavf: use a malloced AVFrame in try_decode_frame().
This allows using avcodec_free_frame() to free it properly.
2012-09-24 12:31:24 +02:00
Stefano Sabatini
64d340c62a lavf/utils: add error check in av_read_frame()
In particular, fix crash when the input file contains no packets (e.g. an
ffmeta input).
2012-09-24 00:41:13 +02:00
Samuel Pitoiset
cee1950bbb rtp: Packetization of JPEG (RFC 2435) 2012-09-23 21:58:41 +03:00
Martin Storsjö
71908f0838 smoothstreamingenc: Copy the SAR on the AVStreams as well
This is required in chained muxers, if the SAR happens to be set.

Signed-off-by: Martin Storsjö <martin@martin.st>
2012-09-23 21:28:58 +03:00
Reimar Döffinger
033f53fb8f Document why we always send a Range HTTP header.
Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
2012-09-23 15:40:17 +02:00
Clément Bœsch
2599541b3d WebVTT demuxer and decoder. 2012-09-23 15:24:08 +02:00
Dmitry Samonenko
697ea4fccf Introducing speex RTP demuxing (RFC 5574)
RTPDynamicProtocolHandler for speex is added. Initial support for
speex depacketization from RTP stream comes with it.
Currently, only codec audio rate can be applied based on sdp:
* Narrowband    ( 8K)
* Wideband      (16K)
* Ultrawideband (32K)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-23 14:20:13 +02:00
Dmitry Samonenko
b024c41e1e Add initial support for speex RTP packetization (RFC 5574)
* libspeex audio codec is no longer considered unsupported
  when using rtp as output format.
* SDP rtpmap is added for speex payload, formatted according to RFC

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-23 14:08:48 +02:00
Michael Niedermayer
f0bb88e2bc Revert "http: only send range header when necessary"
This reverts commit 48cf0f1c18.
This can cause problems with seekability detection
2012-09-23 13:21:35 +02:00
Michael Niedermayer
21c4393f1c lavf/find_stream_info: make sure we decode at least one frame for DTS
The channel layout at the demuxer layer is commonly wrong and would
otherwise be used.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-23 04:56:51 +02:00
Michael Niedermayer
61a84755a9 lavf: dont open a decoder at the top of find_stream_info before probing has finished
It could open the wrong decoder.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-23 04:56:21 +02:00
Duncan Salerno
48cf0f1c18 http: only send range header when necessary
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-23 02:36:08 +02:00
Duncan Salerno
0a8cc1179a http: larger buffer for long URIs
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-23 02:35:42 +02:00
rogerdpack
641c0eea0b bitmap header lookup: add code comment
Signed-off-by: rogerdpack <rogerpack2005@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-23 02:12:34 +02:00
Michael Niedermayer
697b476c07 wav: Fix DTS detection
Fixes Ticket1474

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-23 01:22:16 +02:00
Michael Niedermayer
a9f522d1b7 lavf: document request_probe properly
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-23 01:22:16 +02:00
Michael Niedermayer
a380f82c53 lavf: allow using request_probe as a score threshold to accept a codec
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-23 01:22:16 +02:00
Michael Niedermayer
28e88a24f6 rtsp: fix "warning: ret may be used uninitialized in this function"
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-22 04:49:04 +02:00
Michael Niedermayer
0079232299 rtsp: kill a pointer type warning (void **) vs. (AVFormatContext **)
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-22 04:45:12 +02:00
Clément Bœsch
ea5bd7ea6f lavf/oggdec: check for begin-of-stream flag in case of chained streams.
Fix Ticket #1617, revealing a regression I introduced in 8f3eebd.

We need to make sure no stream is added in between Ogg context save and
restore operations (because it would likely lead to a mismatch between
ogg->nstreams and AVFormatContext->nb_streams after the restore op).
This is the reason the ogg->state check is added in ogg_new_stream().
Before this patch, checking for ogg->headers was preventing this:
ogg->headers is always set before any ogg save/restore (though, it was
also preventing from creating the stream when necessary).
2012-09-22 00:40:51 +02:00
Matthieu Bouron
41f7e0649f mxf: export ff_mxf_get_samples_per_frame to lavf
Reviewed-by: Tomas Härdin <tomas.hardin@codemill.se>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-21 16:20:38 +02:00
Clément Bœsch
7bc70930dd lavf/movenc: add F4V flavor. 2012-09-21 15:14:11 +02:00
Michael Niedermayer
406cdddbdd Merge remote-tracking branch 'qatar/master'
* qatar/master:
  libx264: add forgotten ;
  matroskadec: fix a sanity check.
  matroskadec: only return corrupt packets that actually contain data
  lavf: zero data/size of the packet passed to read_packet().
  ARM: use 2-operand syntax for ADD Rd, PC in Apple PIC code
  ARM: align PIC offset pools to 4 bytes
  ARM: swap source operands in some add instructions
  configure: update tms470 detection for latest version
  lavf probe: prevent codec probe with no data at all seen
  motion_est: fix use of inline on extern functions

Conflicts:
	libavcodec/motion_est_template.c
	libavformat/matroskadec.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-21 14:44:32 +02:00
Anton Khirnov
87b017a298 matroskadec: fix a sanity check. 2012-09-21 09:15:07 +02:00
Anton Khirnov
bdb939ad73 matroskadec: only return corrupt packets that actually contain data
Fixes bug 372.
2012-09-21 09:15:01 +02:00
Anton Khirnov
1cc569ddda lavf: zero data/size of the packet passed to read_packet(). 2012-09-21 09:14:37 +02:00
Michael Niedermayer
fb96ac469a nutdec: fix mixup of nb_streams and timebase_count
Fixes out of array read, should fix ffprove fate failure

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-21 06:29:24 +02:00
Michael Niedermayer
6ab1166c77 nutdec: fix type of intermediate variable for ts calculation.
Prior to this it could theoretically become negative and read
out of array.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-21 06:27:38 +02:00