ffmpeg.git
9 years agoMerge branch 'master' of git://git.videolan.org/ffmpeg
Michael Bradshaw [Fri, 18 Nov 2011 15:28:03 +0000 (08:28 -0700)]
Merge branch 'master' of git://git.videolan.org/ffmpeg

9 years agomxfdec: Add hack that adjusts the n_delta calculation when system items are present
Tomas Härdin [Fri, 11 Nov 2011 14:01:34 +0000 (15:01 +0100)]
mxfdec: Add hack that adjusts the n_delta calculation when system items are present

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
9 years agomxfdec: Parse IndexTableSegments and convert them into AVIndexEntry arrays
Tomas Härdin [Wed, 9 Nov 2011 10:47:57 +0000 (11:47 +0100)]
mxfdec: Parse IndexTableSegments and convert them into AVIndexEntry arrays

Based on work by Georg Lippitsch <georg.lippitsch@gmx.at>

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
9 years agoffprobe: make writer_print_integer support long long int values
Stefano Sabatini [Mon, 7 Nov 2011 14:58:41 +0000 (15:58 +0100)]
ffprobe: make writer_print_integer support long long int values

This makes possible to use writer_print_integer for printing int64_t
values.

9 years agoMerge remote-tracking branch 'qatar/master'
Michael Niedermayer [Fri, 18 Nov 2011 01:55:19 +0000 (02:55 +0100)]
Merge remote-tracking branch 'qatar/master'

* qatar/master:
  vp5: Fix illegal read.
  vp6: Fix illegal read.
  tls: Use TLSv1_client_method for OpenSSL

Merged-by: Michael Niedermayer <michaelni@gmx.at>
9 years agoj2kdec: fix 10l typo in initializing sgnd.
Michael Niedermayer [Fri, 18 Nov 2011 01:35:49 +0000 (02:35 +0100)]
j2kdec: fix 10l typo in initializing sgnd.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
9 years agoAdded support for J2K encoding with libopenjpeg
Michael Bradshaw [Thu, 17 Nov 2011 23:57:09 +0000 (16:57 -0700)]
Added support for J2K encoding with libopenjpeg

Note: Some of the previous patches have had two bugs that have been fixed
in this patch.

Signed-off-by: Michael Bradshaw <mbradshaw@sorensonmedia.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
9 years agoAdded support for J2K encoding with libopenjpeg
Michael Bradshaw [Thu, 17 Nov 2011 23:57:09 +0000 (16:57 -0700)]
Added support for J2K encoding with libopenjpeg

Note: Some of the previous patches have had two bugs that have been fixed
in this patch.

9 years agovf_scale: Fix slice position assert to take vertical subsampling into account.
Michael Niedermayer [Thu, 17 Nov 2011 21:39:46 +0000 (22:39 +0100)]
vf_scale: Fix slice position assert to take vertical subsampling into account.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
9 years agosws: handle jpeg pixel formats in sws_init_context()
Michael Niedermayer [Thu, 17 Nov 2011 20:51:25 +0000 (21:51 +0100)]
sws: handle jpeg pixel formats in sws_init_context()
Fixes Ticket576

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
9 years agolibutvideo: use K&R style.
Clément Bœsch [Mon, 14 Nov 2011 23:06:02 +0000 (00:06 +0100)]
libutvideo: use K&R style.

9 years agovp5: Fix illegal read.
Alex Converse [Thu, 17 Nov 2011 18:06:14 +0000 (10:06 -0800)]
vp5: Fix illegal read.

Found with Address Sanitizer

9 years agovp6: Fix illegal read.
Thierry Foucu [Thu, 17 Nov 2011 17:39:52 +0000 (09:39 -0800)]
vp6: Fix illegal read.

Found with Address Sanitizer

Signed-off-by: Alex Converse <alex.converse@gmail.com>
9 years agoac3probe: Detect Sonic Foundry Soft Encode AC3 as raw AC3.
Michael Niedermayer [Thu, 17 Nov 2011 18:38:47 +0000 (19:38 +0100)]
ac3probe: Detect Sonic Foundry Soft Encode AC3 as raw AC3.
Our ac3 code chain can handle it fine.
More ideal would be to write a demuxer that actually extracts what can be from the additional
headers and uses it for whatever it can be used for.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
9 years agoswr: doxument matrix fields.
Michael Niedermayer [Thu, 17 Nov 2011 17:29:25 +0000 (18:29 +0100)]
swr: doxument matrix fields.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
9 years agoswr: move code to avoid resample forward declaration.
Clément Bœsch [Thu, 17 Nov 2011 14:09:52 +0000 (15:09 +0100)]
swr: move code to avoid resample forward declaration.

9 years agoswr: introduce a public function to customize the channel mapping.
Clément Bœsch [Thu, 17 Nov 2011 14:06:35 +0000 (15:06 +0100)]
swr: introduce a public function to customize the channel mapping.

9 years agodoc: reword and clarify default stream selection.
Tim Nicholson [Thu, 17 Nov 2011 17:08:10 +0000 (18:08 +0100)]
doc: reword and clarify default stream selection.

9 years agoaacdec: Avoid unneeded reinit due to ADTS headers
Michael Niedermayer [Thu, 17 Nov 2011 16:42:47 +0000 (17:42 +0100)]
aacdec: Avoid unneeded reinit due to ADTS headers
Fixes Ticket 662

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
9 years agoswr: use av_opt_set_int() instead of manual assignments in swr_alloc_set_opts().
Clément Bœsch [Thu, 17 Nov 2011 10:36:14 +0000 (11:36 +0100)]
swr: use av_opt_set_int() instead of manual assignments in swr_alloc_set_opts().

9 years agoswr: surround mixing is obviously used, fix comment.
Clément Bœsch [Thu, 17 Nov 2011 10:40:23 +0000 (11:40 +0100)]
swr: surround mixing is obviously used, fix comment.

9 years agoswr: doxycomment public API.
Clément Bœsch [Thu, 17 Nov 2011 10:20:29 +0000 (11:20 +0100)]
swr: doxycomment public API.

9 years agoswr: correctly raise rematrix AVERROR.
Clément Bœsch [Thu, 17 Nov 2011 10:20:50 +0000 (11:20 +0100)]
swr: correctly raise rematrix AVERROR.

9 years agolibopenjpeg: rename decoder source file.
Michael Bradshaw [Thu, 17 Nov 2011 14:39:16 +0000 (15:39 +0100)]
libopenjpeg: rename decoder source file.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
9 years agoDo not try to read total disc or track number if data atom is too short.
Carl Eugen Hoyos [Thu, 17 Nov 2011 13:12:34 +0000 (14:12 +0100)]
Do not try to read total disc or track number if data atom is too short.

Fixes ticket #659.

9 years agotls: Use TLSv1_client_method for OpenSSL
Martin Storsjö [Thu, 17 Nov 2011 09:15:27 +0000 (11:15 +0200)]
tls: Use TLSv1_client_method for OpenSSL

TLSv1 is compatible with SSLv3, so this doesn't change much
in terms of compatibility. By explicitly using TLSv1, OpenSSL
sends the server name indication (SNI) header, which we
already set using SSL_set_tlsext_host_name (earlier, this
didn't have any effect).

SNI allows servers to serve SSL content for different host
names with separate certificates on one single port (vhosts).

Signed-off-by: Martin Storsjö <martin@martin.st>
9 years agoswr: fix "control reaches end of non-void function" compiler warning.
Clément Bœsch [Wed, 16 Nov 2011 19:39:16 +0000 (20:39 +0100)]
swr: fix "control reaches end of non-void function" compiler warning.

9 years agoswr: bump minor version.
Clément Bœsch [Wed, 16 Nov 2011 19:31:49 +0000 (20:31 +0100)]
swr: bump minor version.

9 years agoswr: use int16_t instead of short for resampling.
Clément Bœsch [Wed, 16 Nov 2011 20:31:44 +0000 (21:31 +0100)]
swr: use int16_t instead of short for resampling.

9 years agoswr: start doxycommenting the API.
Clément Bœsch [Wed, 16 Nov 2011 19:28:10 +0000 (20:28 +0100)]
swr: start doxycommenting the API.

9 years agoswr: make swr_* functions match the prototypes.
Clément Bœsch [Wed, 16 Nov 2011 18:50:33 +0000 (19:50 +0100)]
swr: make swr_* functions match the prototypes.

9 years agoswr: rename swr_alloc2() to swr_alloc_set_opts().
Clément Bœsch [Wed, 16 Nov 2011 18:43:58 +0000 (19:43 +0100)]
swr: rename swr_alloc2() to swr_alloc_set_opts().

9 years agoswr: use "swri_" prefix instead of "swr_" for the private API.
Clément Bœsch [Wed, 16 Nov 2011 07:12:48 +0000 (08:12 +0100)]
swr: use "swri_" prefix instead of "swr_" for the private API.

9 years agoswr: drop 'AV' prefix from ResampleContext.
Clément Bœsch [Wed, 16 Nov 2011 07:06:42 +0000 (08:06 +0100)]
swr: drop 'AV' prefix from ResampleContext.

This type/struct is not part of the public API.

9 years agoswr: make audio convert code explicitely private.
Clément Bœsch [Wed, 16 Nov 2011 07:00:31 +0000 (08:00 +0100)]
swr: make audio convert code explicitely private.

Only what's declared in libswresample/swresample.h is public.

9 years agoswr: fix #endif comment ref.
Clément Bœsch [Wed, 16 Nov 2011 06:58:39 +0000 (07:58 +0100)]
swr: fix #endif comment ref.

9 years agoh264: fix cur_chroma_format_idc with slice multithreading.
Michael Niedermayer [Thu, 17 Nov 2011 04:42:18 +0000 (05:42 +0100)]
h264: fix cur_chroma_format_idc with slice multithreading.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
9 years agomjpeg: support mpo
Michael Niedermayer [Thu, 17 Nov 2011 02:13:50 +0000 (03:13 +0100)]
mjpeg: support mpo
Fixes stereoscopic_photo.mpo

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
9 years agoMerge remote-tracking branch 'qatar/master'
Michael Niedermayer [Thu, 17 Nov 2011 01:44:33 +0000 (02:44 +0100)]
Merge remote-tracking branch 'qatar/master'

* qatar/master:
  mpegaudiodec: Don't use a nonexistent log context for av_dlog
  avformat: Accept the ISO8601 separate format as input, too
  avformat: Interpret times in ff_iso8601_to_unix_time as UTC
  avutil: Add av_timegm as a public function
  cinepak: Add another special case so that it can handle the following file:
  lagarith: add some RGBA decoding support
  lagarith: Add correct line prediction for RGB

Conflicts:
doc/APIchanges
libavcodec/cinepak.c
libavutil/avutil.h

Merged-by: Michael Niedermayer <michaelni@gmx.at>
9 years agoh264: migrate poc gap based has_b_frames calculation into new has_b_frame calculation...
Michael Niedermayer [Thu, 17 Nov 2011 00:08:17 +0000 (01:08 +0100)]
h264: migrate poc gap based has_b_frames calculation into new has_b_frame calculation code.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
9 years agoh264: minor simplification
Michael Niedermayer [Wed, 16 Nov 2011 23:36:38 +0000 (00:36 +0100)]
h264: minor simplification

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
9 years agoh264: rewrite has_b_frame calculation code,
Michael Niedermayer [Wed, 16 Nov 2011 22:58:06 +0000 (23:58 +0100)]
h264: rewrite has_b_frame calculation code,
the previous implementation was too buggy.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
9 years agoh264: reset last_pocs on IDRs
Michael Niedermayer [Wed, 16 Nov 2011 22:57:17 +0000 (23:57 +0100)]
h264: reset last_pocs on IDRs

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
9 years agocinepak: remove redundant coordinate checks
Michael Niedermayer [Wed, 16 Nov 2011 16:25:39 +0000 (17:25 +0100)]
cinepak: remove redundant coordinate checks

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
9 years agocinepak: check strip_size
Michael Niedermayer [Wed, 16 Nov 2011 16:21:42 +0000 (17:21 +0100)]
cinepak: check strip_size

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
9 years agocinepak, simplify, use AV_RB24()
Michael Niedermayer [Wed, 16 Nov 2011 16:16:38 +0000 (17:16 +0100)]
cinepak, simplify, use AV_RB24()

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
9 years agocinepak: simplify, use FFMIN()
Michael Niedermayer [Wed, 16 Nov 2011 16:15:15 +0000 (17:15 +0100)]
cinepak: simplify, use FFMIN()

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
9 years agoffprobe: small align cosmetic in json writer struct init.
Clément Bœsch [Wed, 16 Nov 2011 18:37:11 +0000 (19:37 +0100)]
ffprobe: small align cosmetic in json writer struct init.

9 years agoffprobe: make Writers constant.
Clément Bœsch [Wed, 16 Nov 2011 18:35:23 +0000 (19:35 +0100)]
ffprobe: make Writers constant.

9 years agoffprobe: apply misc cosmetics to compact writer definition
Stefano Sabatini [Wed, 16 Nov 2011 17:39:27 +0000 (18:39 +0100)]
ffprobe: apply misc cosmetics to compact writer definition

9 years agoffprobe: add csv writer
Stefano Sabatini [Tue, 15 Nov 2011 23:41:55 +0000 (00:41 +0100)]
ffprobe: add csv writer

9 years agocinepak: Fix division by zero, ask for sample if encoded_buf_size is 0
Michael Niedermayer [Wed, 16 Nov 2011 14:10:26 +0000 (15:10 +0100)]
cinepak: Fix division by zero, ask for sample if encoded_buf_size is 0

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
9 years agoAdd another special case to the Cinepak video decoder so that it can handle the follo...
Mike Melanson [Wed, 16 Nov 2011 07:06:48 +0000 (23:06 -0800)]
Add another special case to the Cinepak video decoder so that it can handle the following file:

http://samples.mplayerhq.hu/V-codecs/CVID/bad_cinepak_frame_size.mov

This fix works around another work around which handles a different type
of odd Cinepak data.

Thanks to Matthew Hoops (clone2727 - gmail.com) for the sample and fix.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
9 years agomandelbrot: make mincol description and code match.
Michael Niedermayer [Wed, 16 Nov 2011 03:22:36 +0000 (04:22 +0100)]
mandelbrot: make mincol description and code match.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
9 years agompegaudiodec: Don't use a nonexistent log context for av_dlog
Martin Storsjö [Wed, 16 Nov 2011 09:33:53 +0000 (11:33 +0200)]
mpegaudiodec: Don't use a nonexistent log context for av_dlog

This fixes builds with DEBUG defined, broken since
1158745a2d12966c58e83b66243a42f20190812e.

Signed-off-by: Martin Storsjö <martin@martin.st>
9 years agoavformat: Accept the ISO8601 separate format as input, too
Martin Storsjö [Mon, 7 Nov 2011 22:12:09 +0000 (00:12 +0200)]
avformat: Accept the ISO8601 separate format as input, too

This makes the function accept the format of creation_time
as output by demuxers (e.g. the mov demuxer), making the
creation timestamp stay intact if transcoding.

Signed-off-by: Martin Storsjö <martin@martin.st>
9 years agoavformat: Interpret times in ff_iso8601_to_unix_time as UTC
Martin Storsjö [Mon, 7 Nov 2011 21:32:21 +0000 (23:32 +0200)]
avformat: Interpret times in ff_iso8601_to_unix_time as UTC

This function is used in muxers for parsing the 'creation_time'
metadata key, for converting it to a time value.

This makes it match the behaviour of the exported 'creation_time'
metadata from demuxers, where it is in UTC, too.

Signed-off-by: Martin Storsjö <martin@martin.st>
9 years agoavutil: Add av_timegm as a public function
Martin Storsjö [Mon, 7 Nov 2011 21:20:31 +0000 (23:20 +0200)]
avutil: Add av_timegm as a public function

This is useful, since the normal timegm function isn't a standard
function (requiring _BSD_SOURCE or _SVID_SOURCE on glibc to
be visible, and not available on e.g. windows). The widely available
function mktime uses the local time zone, which requires ugly
workarounds to handle UTC time.

Signed-off-by: Martin Storsjö <martin@martin.st>
9 years agolavfi: fix misc typo in avfilter.h header.
Clément Bœsch [Tue, 15 Nov 2011 16:56:01 +0000 (17:56 +0100)]
lavfi: fix misc typo in avfilter.h header.

9 years agocinepak: Add another special case so that it can handle the following file:
Mike Melanson [Wed, 16 Nov 2011 07:06:48 +0000 (23:06 -0800)]
cinepak: Add another special case so that it can handle the following file:

http://samples.mplayerhq.hu/V-codecs/CVID/bad_cinepak_frame_size.mov

This fix works around another work around which handles a different type
of odd Cinepak data.

Thanks to Matthew Hoops (clone2727 - gmail.com) for the sample and fix.

Signed-off-by: Martin Storsjö <martin@martin.st>
9 years agolagarith: add some RGBA decoding support
Kostya Shishkov [Sat, 12 Nov 2011 19:54:27 +0000 (20:54 +0100)]
lagarith: add some RGBA decoding support

Signed-off-by: Martin Storsjö <martin@martin.st>
9 years agolagarith: Add correct line prediction for RGB
Nathan Caldwell [Wed, 16 Nov 2011 07:45:00 +0000 (00:45 -0700)]
lagarith: Add correct line prediction for RGB

Signed-off-by: Martin Storsjö <martin@martin.st>
9 years agocleanup: remove various double end ';' all over the code.
Clément Bœsch [Wed, 16 Nov 2011 06:48:23 +0000 (07:48 +0100)]
cleanup: remove various double end ';' all over the code.

9 years agoswr: replace deprecated av_set_int() with av_opt_set_int().
Clément Bœsch [Tue, 15 Nov 2011 23:33:19 +0000 (00:33 +0100)]
swr: replace deprecated av_set_int() with av_opt_set_int().

9 years agoswr: replace deprecated av_opt_set_defaults2() with av_opt_set_defaults().
Clément Bœsch [Tue, 15 Nov 2011 23:30:52 +0000 (00:30 +0100)]
swr: replace deprecated av_opt_set_defaults2() with av_opt_set_defaults().

9 years agoswr: replace deprecated av_get_bits_per_sample_fmt() with av_get_bytes_per_sample().
Clément Bœsch [Tue, 15 Nov 2011 23:23:22 +0000 (00:23 +0100)]
swr: replace deprecated av_get_bits_per_sample_fmt() with av_get_bytes_per_sample().

9 years agoswr: use designated initializers for the class.
Clément Bœsch [Tue, 15 Nov 2011 23:20:13 +0000 (00:20 +0100)]
swr: use designated initializers for the class.

9 years agoswr: rename resample2 to resample.
Clément Bœsch [Tue, 15 Nov 2011 21:17:58 +0000 (22:17 +0100)]
swr: rename resample2 to resample.

9 years agoswr: move format convert code to dedicated functions.
Clément Bœsch [Tue, 15 Nov 2011 10:06:25 +0000 (11:06 +0100)]
swr: move format convert code to dedicated functions.

This should easier common case optimizations.

9 years agowma: Check channel number before init.
Michael Niedermayer [Wed, 16 Nov 2011 02:31:25 +0000 (03:31 +0100)]
wma: Check channel number before init.
Fixes Ticket240

Based on patch by ami_stuff
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
9 years agoMerge remote-tracking branch 'qatar/master'
Michael Niedermayer [Wed, 16 Nov 2011 01:23:10 +0000 (02:23 +0100)]
Merge remote-tracking branch 'qatar/master'

* qatar/master:
  lavf: fix multiplication overflow in avformat_find_stream_info()
  cosmetics: indentation
  mpegaudiodec: init static tables in AVCodec.init_static_data()

Conflicts:
libavcodec/mpegaudiodec.c
libavformat/utils.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
9 years agolavf: if timestamps are invalid (pts=dts) only drop dts.
Michael Niedermayer [Wed, 16 Nov 2011 00:19:35 +0000 (01:19 +0100)]
lavf: if timestamps are invalid (pts=dts) only drop dts.
Because if we drop both we have no timestamps at all for some files.
Fixes Ticket344

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
9 years agolavf: fix multiplication overflow in avformat_find_stream_info()
Mans Rullgard [Tue, 15 Nov 2011 22:33:49 +0000 (22:33 +0000)]
lavf: fix multiplication overflow in avformat_find_stream_info()

Converting to double before the multiplication rather than after
avoids an integer overflow in some cases.

Signed-off-by: Mans Rullgard <mans@mansr.com>
9 years agoffprobe: add compact writer
Stefano Sabatini [Sun, 2 Oct 2011 09:25:44 +0000 (11:25 +0200)]
ffprobe: add compact writer

9 years agoffprobe: force display of missing fields, depending on writer.flags
Stefano Sabatini [Sun, 23 Oct 2011 23:23:22 +0000 (01:23 +0200)]
ffprobe: force display of missing fields, depending on writer.flags

Add flags field to Writer, and define the
WRITER_FLAG_DISPLAY_OPTIONAL_FIELDS flag which forces the display of
optional fields, for example non-available or invalid fields.

Also set the flag in the default writer.

This change is required as for some writers it is preferable to show all
fields (for example for avoiding a variable number of fields in CSV
output), while for other formats (e.g. JSON, XML) it is better to leave
invalid/unavailable fields unspecified and thus simplify the parsing
stage on the deserializer side.

9 years agodiracdec: obmc accesses arent aligned for all files.
Michael Niedermayer [Tue, 15 Nov 2011 22:37:40 +0000 (23:37 +0100)]
diracdec: obmc accesses arent aligned for all files.
Thus use unaligned accesses.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
9 years agoopt: Fix *av_opt_find2(NULL)
Michael Niedermayer [Tue, 15 Nov 2011 21:43:21 +0000 (22:43 +0100)]
opt: Fix *av_opt_find2(NULL)
Fixes Ticket650

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
9 years agomandelbrot: add dither to convergence & mincol colorings.
Michael Niedermayer [Tue, 15 Nov 2011 20:33:11 +0000 (21:33 +0100)]
mandelbrot: add dither to convergence & mincol colorings.
This avoids banding artifacts.
Note, low end TFTs still show some banding.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
9 years agomandelbrot: make mincol the default.
Michael Niedermayer [Tue, 15 Nov 2011 18:59:29 +0000 (19:59 +0100)]
mandelbrot: make mincol the default.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
9 years agomandelbrot: add mincol inner coloring method.
Michael Niedermayer [Tue, 15 Nov 2011 18:58:58 +0000 (19:58 +0100)]
mandelbrot: add mincol inner coloring method.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
9 years agoFix seeking when using Apple HTTP Live Streaming
Panagiotis H.M. Issaris [Tue, 15 Nov 2011 17:35:03 +0000 (18:35 +0100)]
Fix seeking when using Apple HTTP Live Streaming

The Apple HTTP Live Streaming demuxer's implementation of seeking searches for
the MPEG TS segment which contains the requested timestamp.  In its current
implementation it assumes that the first segment will start from 0.

But, MPEG TS streams do not necessarily start with timestamp (near) 0, causing
seeking to fail for those streams.

This also occurs when using live streaming of HTTP Live Streams. In this case
sliding playlists may be used, which means that in that case only the last x
encoded segments are stored, the earlier segments get deleted from disk and
removed from the playlist. Because of this, when starting playback of a stream
in the middle of such a broadcast, the initial segment fetched after parsing
the m3u8 playlist will not start from timestamp (near) 0, causing (the
admittedly limited live) seeking to fail.

This patch changes this demuxers seeking implementation to use the initial DTS
as an offset for searching the segments containing the requested timestamp.

9 years agocosmetics: indentation
Justin Ruggles [Thu, 3 Nov 2011 19:53:43 +0000 (15:53 -0400)]
cosmetics: indentation

9 years agompegaudiodec: init static tables in AVCodec.init_static_data()
Justin Ruggles [Thu, 3 Nov 2011 18:59:37 +0000 (14:59 -0400)]
mpegaudiodec: init static tables in AVCodec.init_static_data()

9 years agoUpdate my GnuPG fingerprint.
Panagiotis H.M. Issaris [Tue, 15 Nov 2011 16:57:10 +0000 (17:57 +0100)]
Update my GnuPG fingerprint.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
9 years agomandelbrot: add inner drawing method to show converence time
Michael Niedermayer [Tue, 15 Nov 2011 16:25:16 +0000 (17:25 +0100)]
mandelbrot: add inner drawing method to show converence time

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
9 years agomandelbrot: add "fractal" to the description
Michael Niedermayer [Tue, 15 Nov 2011 16:14:15 +0000 (17:14 +0100)]
mandelbrot: add "fractal" to the description

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
9 years agomandelbrot: Fix "warning: passing argument 2 of ‘draw_mandelbrot’ from incompatible...
Michael Niedermayer [Tue, 15 Nov 2011 16:12:52 +0000 (17:12 +0100)]
mandelbrot: Fix "warning: passing argument 2 of ‘draw_mandelbrot’ from incompatible pointer type"

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
9 years agoasfdec: mark only ts1 as av_unused
Michael Niedermayer [Tue, 15 Nov 2011 12:06:36 +0000 (13:06 +0100)]
asfdec: mark only ts1 as av_unused

Idea-by: ubitux
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
9 years agompegts: Completely ignore H222 spec and consider reserved adaption
Michael Niedermayer [Tue, 15 Nov 2011 03:15:34 +0000 (04:15 +0100)]
mpegts: Completely ignore H222 spec and consider reserved adaption
 fields to be perfectly fine mpeg TS.
Fixes Ticket580

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
9 years agoMerge remote-tracking branch 'qatar/master'
Michael Niedermayer [Tue, 15 Nov 2011 02:13:42 +0000 (03:13 +0100)]
Merge remote-tracking branch 'qatar/master'

* qatar/master:
  binkvideo: simplify and remove invalid shifts
  pulse: compute frame_duration once and fix it
  lavf: simplify format_child_class_next()
  hwaccel: OS X Video Decoder Acceleration (VDA) support.
  doc: add support for an optional navigation bar in texi2html pages

Conflicts:
configure
libavcodec/Makefile
libavcodec/allcodecs.c
libavcodec/vda.c
libavcodec/vda.h
libavcodec/vda_h264.c
libavcodec/vda_internal.h
libavcodec/version.h
libavformat/options.c
libavutil/avutil.h
libavutil/pixfmt.h

Merged-by: Michael Niedermayer <michaelni@gmx.at>
9 years agompeg4videodec: dont treat empty frames as errors for QMP4, it seems thats normal.
Michael Niedermayer [Tue, 15 Nov 2011 01:22:23 +0000 (02:22 +0100)]
mpeg4videodec: dont treat empty frames as errors for QMP4, it seems thats normal.
Fixes remaining complaints in Ticket560 possibly.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
9 years agompegaudio: prettify avpriv_mpa_bitrate_tab
Michael Niedermayer [Tue, 15 Nov 2011 00:59:59 +0000 (01:59 +0100)]
mpegaudio: prettify avpriv_mpa_bitrate_tab

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
9 years agoasfdec: avoid unused variable warning.
Michael Niedermayer [Tue, 15 Nov 2011 00:58:13 +0000 (01:58 +0100)]
asfdec: avoid unused variable warning.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
9 years agoasfdec: use dts for seeking.
Michael Niedermayer [Tue, 15 Nov 2011 00:08:04 +0000 (01:08 +0100)]
asfdec: use dts for seeking.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
9 years agoasfdec: restore timestamp reading code
Michael Niedermayer [Mon, 14 Nov 2011 23:57:08 +0000 (00:57 +0100)]
asfdec: restore timestamp reading code
This reverts part of:
commit e65ab9d94f1c8d8893e32d90467d9525625d306a
Author: Mans Rullgard <mans@mansr.com>
Date:   Wed Jun 1 17:26:27 2011 +0100

    Remove unused variables

9 years agovda: use K&R style.
Clément Bœsch [Mon, 14 Nov 2011 23:17:31 +0000 (00:17 +0100)]
vda: use K&R style.

9 years agoamovie: avoid crash in amovie_request_frame() if no samplesref is available
Stefano Sabatini [Sun, 13 Nov 2011 22:51:06 +0000 (23:51 +0100)]
amovie: avoid crash in amovie_request_frame() if no samplesref is available

The crash occurrs when a frame is successfully decoded, but no decoded
data is immediately available (typically happens with ogg/vorbis).

9 years agovda: get correctly the frame from h264 context.
Sebastien Zwickert [Mon, 14 Nov 2011 21:03:38 +0000 (22:03 +0100)]
vda: get correctly the frame from h264 context.

9 years agovda: check allocation result.
Sebastien Zwickert [Mon, 14 Nov 2011 20:56:16 +0000 (21:56 +0100)]
vda: check allocation result.

9 years agovda: removes useless casts.
Sebastien Zwickert [Mon, 14 Nov 2011 20:35:18 +0000 (21:35 +0100)]
vda: removes useless casts.