Commit Graph

59662 Commits

Author SHA1 Message Date
Anton Khirnov
bfd26b7ce6 h264: reject mismatching luma/chroma bit depths during sps parsing
There is no point in delaying the check and it avoids bugs with a
half-initialized context.

Fixes invalid reads.

Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
CC:libav-stable@libav.org
2014-01-06 08:23:45 +01:00
Anton Khirnov
9a026c7298 h264: rebuild the default ref list if the reference count changes
Fixes possible access to freed memory.

Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
CC:libav-stable@libav.org
2014-01-06 08:23:17 +01:00
Anton Khirnov
4736d003fa cavsdec: check ff_get_buffer() return value
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
CC:libav-stable@libav.org
2014-01-06 08:22:48 +01:00
Anton Khirnov
50079a6aa9 lavc: do not leak the internal frame if opening the codec fails 2014-01-06 08:21:58 +01:00
Anton Khirnov
3867f3718b lavf: remove a pointless check
AVStream.codec is always non-NULL
2014-01-06 08:21:53 +01:00
Anton Khirnov
75647dea6f oggparseogm: check timing variables
Fixes a potential divide by zero.

Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
CC:libav-stable@libav.org
2014-01-06 08:21:38 +01:00
Anton Khirnov
8058284ce0 lavc: add 422/444 YUV with alpha to align_dimensions()
Aligns frame dimensions to 16, which fixes potential invalid writes.
2014-01-06 08:20:56 +01:00
Kostya Shishkov
2f97094608 lagarith: do not call simd functions on unaligned lines
They end up overwriting past the line end.

Partially based on a patch by Michael Niedermayer <michaelni@gmx.at>

Bug-Id: vlc/9700
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
Signed-off-by: Anton Khirnov <anton@khirnov.net>
2014-01-06 08:19:29 +01:00
Anton Khirnov
f4a8a00805 sgidec: fix buffer size check in expand_rle_row()
Right now it will spuriously fail if the linesize is exactly equal to
the data width.

CC:libav-stable@libav.org
2014-01-06 08:18:45 +01:00
Anton Khirnov
adb199d1bc kgv1dec: replace forcing EMU_EDGE by a copy
The decoder currently sets CODEC_FLAG_EMU_EDGE and relies on
get_buffer2() to always provide buffers with linesize == 2 * width.
This is wrong, since we place no such restriction on get_buffer2()
implementations.

Fix this by decoding into internal buffers and copying them to output
frames. Since this is a very obscure decoder, the performance hit should
not be an issue.
2014-01-06 08:15:36 +01:00
Anton Khirnov
fe80fa53bc 4xm: replace forcing EMU_EDGE by a copy
The decoder currently sets CODEC_FLAG_EMU_EDGE and relies on
get_buffer2() to always provide buffers with linesize == 2 * width.
This is wrong, since we place no such restriction on get_buffer2()
implementations.

Fix this by decoding into internal buffers and copying them to output
frames. Since this is a very obscure decoder, the performance hit should
not be an issue.
2014-01-06 08:14:14 +01:00
Anton Khirnov
fffca3d278 4xm: return a proper error code. 2014-01-06 08:13:50 +01:00
Guillaume Martres
060667195e hevc: rename some HEVC conformance streams
Some HEVC conformance streams zip on
http://wftp3.itu.int/av-arch/jctvc-site/bitstream_exchange/draft_conformance/
were updated without changing the actual stream. Rename them in FATE
accordingly to make it easier to track future stream updates.

Signed-off-by: Anton Khirnov <anton@khirnov.net>
2014-01-06 08:05:17 +01:00
Guillaume Martres
98c0cd0b99 hevc: add new conformance streams
Also remove superseded conformance streams. The conformance streams all
come from http://wftp3.itu.int/av-arch/jctvc-site/bitstream_exchange/draft_conformance/

Signed-off-by: Anton Khirnov <anton@khirnov.net>
2014-01-06 08:03:35 +01:00
Michael Niedermayer
4ced5d7780 avcodec/hevc: Fix modulo operations
Fixes qp fields becoming out of range
Fixes: asan_static-oob_e393a3_6998_WPP_A_ericsson_MAIN10_2.bit
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-01-06 04:32:37 +01:00
Michael Niedermayer
d66bab0a69 avcodec/hevc_ps: check that VPS referenced from SPS exists
This matches how its done for SPS/PPS.
An alternative to this is to check it when its used.

Fixes null pointer dereference
Fixes: signal_sigsegv_e30a43_1437_CIP_A_Panasonic_3.bit
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-01-06 04:30:04 +01:00
Michael Niedermayer
4816d63fb7 avcodec/huffyuvdec: optimize decode_plane_bitstream(), use joint tables for new yuv formats
Reviewed-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-01-06 01:38:14 +01:00
Michael Niedermayer
1bef9bfc77 fate: test version 3 of ffvhuff
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-01-06 01:37:22 +01:00
Michael Niedermayer
27b1e63f32 avcodec/huffyuv: Support more 8bit YUV formats
Reviewed-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-01-06 01:02:26 +01:00
Michael Niedermayer
67999d3d12 Merge remote-tracking branch 'qatar/master'
* qatar/master:
  cmdutils: update copyright year to 2014.

Conflicts:
	cmdutils.c

See: 0b1cfc4f28
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-01-05 23:23:53 +01:00
Michael Niedermayer
d18234f319 Merge commit '7840c40445c9f52aeccba96de3d27613398bfbf2'
* commit '7840c40445c9f52aeccba96de3d27613398bfbf2':
  (e)ac3dec: set AV_FRAME_DATA_MATRIXENCODING side data.

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-01-05 23:14:26 +01:00
Michael Niedermayer
7b3c78b5e6 Merge commit '13345fc1f86fc3615789e196d5a339c1c27c9068'
* commit '13345fc1f86fc3615789e196d5a339c1c27c9068':
  (e)ac3: parse and store the Dolby Surround, Surround EX and Headphone mode flags.

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-01-05 23:06:53 +01:00
Michael Niedermayer
85b424a45e Merge commit 'e92123093dfdca0ef6608998240e2f9345d63bff'
* commit 'e92123093dfdca0ef6608998240e2f9345d63bff':
  mlpdec: set AV_FRAME_DATA_MATRIXENCODING side data.

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-01-05 23:00:22 +01:00
Michael Niedermayer
b4107f7805 Merge commit '4b7f1a7ced0e98f2cc698d896f7ebab8d30eaa09'
* commit '4b7f1a7ced0e98f2cc698d896f7ebab8d30eaa09':
  mlp: Parse TrueHD decoder channel modifiers and set the AVMatrixEncoding for each substream.

Conflicts:
	libavcodec/mlp_parser.h
	libavcodec/mlpdec.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-01-05 22:53:13 +01:00
Michael Niedermayer
ae01af2475 Merge commit '30d70e79a6b4ac7f4eb66446a9da275161ef6ea7'
* commit '30d70e79a6b4ac7f4eb66446a9da275161ef6ea7':
  dcadec: set AV_FRAME_DATA_MATRIXENCODING side data.

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-01-05 22:34:21 +01:00
Michael Niedermayer
bc7f76377c Merge commit '6bfdb2de881372048be7fbda643417e1fd3ce93c'
* commit '6bfdb2de881372048be7fbda643417e1fd3ce93c':
  dcadec: set the output channel mode more accurately.

Conflicts:
	libavcodec/dcadec.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-01-05 22:27:34 +01:00
Michael Niedermayer
4cf4da9dc5 Merge commit '5b4797a21db900b7d509660b7a4d49829089b004'
* commit '5b4797a21db900b7d509660b7a4d49829089b004':
  avframe: add AV_FRAME_DATA_MATRIXENCODING side data type.

Conflicts:
	libavutil/version.h

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-01-05 22:12:41 +01:00
Michael Niedermayer
751385fe3f Merge commit '5c437fb'
* commit '5c437fb':
  lavu: Add values for various Dolby flags to the AVMatrixEncoding enum.

Conflicts:
	doc/APIchanges
	libavutil/version.h

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-01-05 21:55:58 +01:00
Ronald S. Bultje
847072873c vp9_parse: don't use AVCodecParserContext as av_log context.
Fixes trac ticket 3273.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-01-05 21:45:24 +01:00
Johan Andersson
7ce88e5ec4 cmdutils: update copyright year to 2014.
Signed-off-by: Martin Storsjö <martin@martin.st>
2014-01-05 22:39:35 +02:00
Michael Niedermayer
ee16e0cacc avfilter/vf_format: check that the format list is not empty
Fixes Ticket3210

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-01-05 20:14:03 +01:00
Federico Simoncelli
b53d6ce3fd pulse: get latency only when needed
Signed-off-by: Federico Simoncelli <fsimonce@redhat.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-01-05 18:44:18 +01:00
Federico Simoncelli
b13d6c837f pulse: set time_base as multiple of sample_rate
The stream time_base has been changed to be a multiple of the
device sample_rate. Now the frame_duration computation is simpler
and a message will warn about problematic frame_size values.

Signed-off-by: Federico Simoncelli <fsimonce@redhat.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-01-05 18:44:06 +01:00
Michael Niedermayer
d04aceb7d0 avformat/nutdec: remove unused variable
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-01-05 17:27:23 +01:00
Tim Walker
7840c40445 (e)ac3dec: set AV_FRAME_DATA_MATRIXENCODING side data. 2014-01-05 16:41:56 +01:00
Tim Walker
13345fc1f8 (e)ac3: parse and store the Dolby Surround, Surround EX and Headphone mode flags. 2014-01-05 16:41:56 +01:00
Tim Walker
e92123093d mlpdec: set AV_FRAME_DATA_MATRIXENCODING side data. 2014-01-05 16:41:56 +01:00
Tim Walker
4b7f1a7ced mlp: Parse TrueHD decoder channel modifiers and set the AVMatrixEncoding for each substream. 2014-01-05 16:41:56 +01:00
Tim Walker
30d70e79a6 dcadec: set AV_FRAME_DATA_MATRIXENCODING side data. 2014-01-05 16:41:56 +01:00
Tim Walker
6bfdb2de88 dcadec: set the output channel mode more accurately.
When downmixing 2.1 to 2-channel, if the 2.0 portion is Lt/Rt, sum-difference or dual mono, the actual output will be the same (with the LFE either mixed-in or discarded).

Also, when downmixing an arbitrary layout to 2-channel, if the bitstream contains custom downmix coefficients targeting Lt/Rt, then the output will be Lt/Rt rather than regular Stereo.
2014-01-05 16:41:56 +01:00
Tim Walker
5b4797a21d avframe: add AV_FRAME_DATA_MATRIXENCODING side data type.
Includes a libavcodec utility function to update a frame's side data.
2014-01-05 16:41:56 +01:00
Tim Walker
5c437fb672 lavu: Add values for various Dolby flags to the AVMatrixEncoding enum. 2014-01-05 16:41:56 +01:00
Federico Simoncelli
b1ad931233 v4l2: setting device parameters early
Setting the v4l2 device parameters may influence video properties
such as width, height and pixel format.
This patch moves v4l2_set_parameters to be executed before fetching
the video properties, avoiding errors such as (pal vs ntsc):

 The v4l2 frame is 829440 bytes, but 691200 bytes are expected

Signed-off-by: Federico Simoncelli <fsimonce@redhat.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-01-05 14:02:06 +01:00
Michael Niedermayer
05286b6a9c Merge remote-tracking branch 'qatar/master'
* qatar/master:
  configure: Support preprocessor macros as header names

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-01-05 13:29:44 +01:00
Diego Biurrun
52ccc4a0ec configure: Support preprocessor macros as header names
New versions of FreeType have moved the location of their API
header(s) and hide the location behind a macro.

Since the location changes between versions and no other way
to know the location exists, this workaround becomes necessary.

Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2014-01-05 11:48:13 +01:00
Peter Ross
f5f6e59495 avformat/matroskaenc: warn when muxing video codec not supported by format
This occurs for video codecs that have codec_tag set, but are are not listed
in ff_codec_bmp_tags (e.g. AV_CODEC_ID_BINKAUDIO, AV_CODEC_ID_IFF_ILBM).

Fixes ticket #3269.

Signed-off-by: Peter Ross <pross@xvid.org>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-01-05 04:33:24 +01:00
Michael Niedermayer
70937d9708 Merge remote-tracking branch 'qatar/master'
* qatar/master:
  sdp: Check that fmt->oformat is non-null before accessing it

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-01-05 02:38:57 +01:00
Michael Niedermayer
a57da850c0 Merge commit '9d18a7d3ec09d6d933d648570643fde924aa391a'
* commit '9d18a7d3ec09d6d933d648570643fde924aa391a':
  fate: Update AAC ELD 5.1 ref for recent bugfixes.

also reenable fate-aac-er_ad6000np_44_ep0, as this commit updates the pcm
reference, so that the test works again

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-01-05 02:37:22 +01:00
Michael Niedermayer
fd53f9d985 Merge commit '7f29644108c5fbd80f160930b31b78b8704c1a49'
* commit '7f29644108c5fbd80f160930b31b78b8704c1a49':
  aac: Fix low delay windowing.

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-01-05 02:18:57 +01:00
Michael Niedermayer
f200ec20b8 Merge commit '42d1b41983971da63302ac3d12091cad1f3d6324'
* commit '42d1b41983971da63302ac3d12091cad1f3d6324':
  fate: Add a test vector for AAC ELD with TNS.

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-01-05 02:09:55 +01:00