Commit Graph

47638 Commits

Author SHA1 Message Date
Mans Rullgard
f0fe245bc3 configure: arm: set fast_clz and fast_unaligned in cpuflags section
These are properties of the targeted core and do not depend on
specific assembly support in the toolchain which if missing will
render the controlling options here disabled.

Signed-off-by: Mans Rullgard <mans@mansr.com>
2012-12-07 16:54:03 +00:00
Mans Rullgard
1234c66a31 configure: arm: detect toolchain default arch version
Probe for the toolchain default architecture version if no --cpu flag
is present or an unknown cpu is specified.  Works with gcc, clang and
armcc.

This allows configuring based on the arch version even if it is not
explicitly specified to configure.  It also causes an explicit -march
flag to be added to CFLAGS and ASFLAGS, which in turn lets us do
proper instruction set tests with the assembler.

Signed-off-by: Mans Rullgard <mans@mansr.com>
2012-12-07 16:54:03 +00:00
Mans Rullgard
9ebd45c2d5 configure: do not bypass cpuflags section if --cpu not given
This will allow arch-specific ways of determining the target
variant when none is specified on the command line.

Signed-off-by: Mans Rullgard <mans@mansr.com>
2012-12-07 16:54:03 +00:00
Mans Rullgard
a7831d509f arm: use HAVE*_INLINE/EXTERNAL macros for conditional compilation
These macros reflect the actual capabilities required here.

Signed-off-by: Mans Rullgard <mans@mansr.com>
2012-12-07 16:54:03 +00:00
Mans Rullgard
7fd90119bb configure: clean up check_inline_asm and check_as functions
The check_inline_asm function should check the actual C compiler,
not the one used for assembly files.  Usually these are the same,
but they might be different, typically when using a compiler other
than gcc.

The check_as should, as its name suggests, test the type of input
the AS command is used with, i.e. a standalond assembly (.S) file.

Finally, check for gnu assembler using the modified check_as as
this reflects actual usage.

Signed-off-by: Mans Rullgard <mans@mansr.com>
2012-12-07 16:54:03 +00:00
Mans Rullgard
c29d49c1b3 dct-test: arm: indicate required cpu features for optimised funcs
Signed-off-by: Mans Rullgard <mans@mansr.com>
2012-12-07 16:54:03 +00:00
Anton Khirnov
380232fac3 snow: fix build after 594d4d5df3 2012-12-07 16:35:06 +01:00
Michael Niedermayer
857d7194ca Merge remote-tracking branch 'qatar/master'
* qatar/master:
  h264: add a pointer for weighted prediction temporary buffer

Conflicts:
	libavcodec/h264.c
	libavcodec/h264.h

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2012-12-07 16:29:07 +01:00
Paul B Mahol
6777aa6387 lavc/takdec: s/get_b/get_bits_esc4
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2012-12-07 15:19:49 +00:00
Martin Storsjö
4ed0c35c40 avcodec: Fix a typo in an option description
Signed-off-by: Martin Storsjö <martin@martin.st>
Signed-off-by: Clément Bœsch <ubitux@gmail.com>
2012-12-07 16:16:20 +01:00
Paul B Mahol
1c779854b5 lavc/takdec: simplify code
Merge get_scale/get_shift into set_sample_rate_params().
Rename tak_set_bps to set_bps_params and remove 2nd argument.

Signed-off-by: Paul B Mahol <onemda@gmail.com>
2012-12-07 15:01:02 +00:00
Michael Niedermayer
7c425e4f2d Merge commit 'd7d6efe42b0d2057e67999b96b9a391f533d2333'
* commit 'd7d6efe42b0d2057e67999b96b9a391f533d2333':
  h264: check sps.log2_max_frame_num for validity
  mov: validate number of DataReferenceBox entries against box size
  mov: compute avg_frame_rate only if duration is known
  flac: change minimum and default of lpc_passes option to 1

Conflicts:
	libavcodec/h264_ps.c
	libavformat/mov.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2012-12-07 15:52:43 +01:00
Michael Niedermayer
af164d7d9f Merge commit 'c25fc5c2bb6ae8c93541c9427df3e47206d95152'
* commit 'c25fc5c2bb6ae8c93541c9427df3e47206d95152':
  fate: dpcm: Add dependencies
  SBR DSP x86: implement SSE sbr_hf_gen
  AAC SBR: use AVFloatDSPContext's vector_fmul
  fate: image: Add dependencies
  Changelog: add an entry for deprecating the avconv -vol option
  x86: float_dsp: fix compilation of ff_vector_dmul_scalar_avx() on x86-32

Conflicts:
	Changelog
	libavutil/x86/float_dsp.asm
	tests/fate/image.mak

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2012-12-07 15:21:41 +01:00
Mans Rullgard
92dad6687f arm: fix use of uninitialised value in ff_fft_fixed_init_arm()
When initialising an FFTContext for a plain FFT, mdct_bits is not set
and can contain a garbage value.  Since nbits is always valid and for
MDCT operation is mdct_bits - 2 checking this instead avoids using an
uninitialised value while having the same effect.

Signed-off-by: Mans Rullgard <mans@mansr.com>
2012-12-07 13:11:57 +00:00
Paul B Mahol
8ca8b43d71 lavf/pcm: check size, do not produce invalid packets
Inspired by 92b8c9d89e.

Signed-off-by: Paul B Mahol <onemda@gmail.com>
2012-12-07 13:05:43 +00:00
Michael Niedermayer
ea6da80cb4 diracdec: check dimensions against chroma format.
Fixes out of array reads

Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-12-07 13:43:40 +01:00
Martin Storsjö
2c96392277 avpicture: Don't assume a valid pix fmt in avpicture_get_size
When called from the v4l2 input device, pix_fmt can be
AV_PIX_FMT_NONE (for jpeg formats). Before 50ba57e0, this wasn't
an issue for avpicture_get_size, but after that commit, this
lead to crashes.

Signed-off-by: Martin Storsjö <martin@martin.st>
2012-12-07 14:28:47 +02:00
Janne Grunau
a394959bbe h264: add a pointer for weighted prediction temporary buffer
Reusing MpegEncContext's obmc_scratchpad for this becomes a mess with
adaptive frame-mt.
2012-12-07 11:43:28 +01:00
Janne Grunau
d7d6efe42b h264: check sps.log2_max_frame_num for validity
Fixes infinite or long taking loop in frame num gap code in
the fuzzed sample bipbop234.ts_s223302.

CC: libav-stable@libav.org
2012-12-07 11:43:28 +01:00
Janne Grunau
8cc2fa1e5d mov: validate number of DataReferenceBox entries against box size
Avoids a 2G memory allocation and parsing of random data in
mov_read_dref(). The fuzzed sample sample.mp4_s224424 triggers this.
2012-12-07 11:43:28 +01:00
Janne Grunau
80b6b31417 mov: compute avg_frame_rate only if duration is known
Fixes an assert in fuzzed sample sample.mp4_s265930.
2012-12-07 11:43:28 +01:00
Janne Grunau
480be07a96 flac: change minimum and default of lpc_passes option to 1
Avoid use of uninitialized and uncomputed linear least square models
during ff_lpc_calc_coefs() for FF_LPC_TYPE_CHOLESKY. Fixes running
make fate-flac-16-lpc-cholesk with valgrind --undef-value-errors=yes.
2012-12-07 11:43:28 +01:00
Diego Biurrun
c25fc5c2bb fate: dpcm: Add dependencies 2012-12-07 11:34:16 +01:00
Christophe Gisquet
2aef3d66c9 SBR DSP x86: implement SSE sbr_hf_gen
Start and end index are multiple of 2, therefore guaranteeing aligned access.
Also, this allows to generate 4 floats per loop, keeping the alignment all
along.

Timing:
- 32 bits: 326c -> 172c
- 64 bits: 323c -> 156c

Signed-off-by: Diego Biurrun <diego@biurrun.de>
2012-12-07 11:04:26 +01:00
Christophe Gisquet
9a16359c38 AAC SBR: use AVFloatDSPContext's vector_fmul
Around 5% speedup on the code block using 'vector_fmul_add's.

Signed-off-by: Diego Biurrun <diego@biurrun.de>
2012-12-07 10:33:39 +01:00
Diego Biurrun
33086f9265 fate: image: Add dependencies 2012-12-07 10:14:31 +01:00
Michael Niedermayer
f5d6b0c9c2 diracdec: fix typo in mctmp allocation
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-12-07 02:24:14 +01:00
Michael Niedermayer
2f6ec9fdd7 diracdec: Test mctmp and mcscratch for malloc failure.
Fixes null pointer dereference

Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-12-07 02:24:14 +01:00
Michael Niedermayer
b84d1bf193 diracdec: fix emulated_edge condition, fix out of array reads
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-12-07 02:24:14 +01:00
Paul B Mahol
f8d68822c0 takdec: use samplefmt.h from libavutil
Instead of having own code for calculating decoded buffer size
just use already provided functions from libavutil.

Signed-off-by: Paul B Mahol <onemda@gmail.com>
2012-12-07 01:11:55 +00:00
Paul B Mahol
6a7fed193c add missing dependency for tak demuxer 2012-12-07 00:15:47 +00:00
Paul B Mahol
4e4a95b18e takdec: remove get_code() and use get_sbits() directly
As found by Justin, this is probably bug in reference decoder.

Signed-off-by: Paul B Mahol <onemda@gmail.com>
2012-12-07 00:03:47 +00:00
Carl Eugen Hoyos
24b20087bd Fix compilation with yasm 0.6.2. 2012-12-07 00:26:45 +01:00
Michael Niedermayer
892750b07b fix tipo
Found-by: ubitux
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-12-06 22:59:21 +01:00
Stefano Sabatini
da9a45b681 lavfi/tinterlace: drop redundant NULL checks in uninit() 2012-12-06 22:32:03 +01:00
Stefano Sabatini
c6a216771f lavfi/tinterlace: add support to option parsing
Simplify code, and provide introspection through the AVOption system.
2012-12-06 22:31:42 +01:00
Stefano Sabatini
fef7b2e0be lavfi/tinterlace: switch to filter_frame API
Also add missing NULL checks.
2012-12-06 22:30:59 +01:00
Michael Niedermayer
656500c503 lavf: improve help text for avoid_negative_ts
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-12-06 22:06:40 +01:00
Michael Niedermayer
4b6869d6e0 bitstream: make vlc init of static tables thread safe.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-12-06 21:46:42 +01:00
Clément Bœsch
bbd44f6ca4 lavfi/mp: switch to ff_filter_frame. 2012-12-06 21:11:28 +01:00
Paul B Mahol
586c2528a0 dxa: port to bytestream2 API
Protects against overreads in input buffer.

Signed-off-by: Paul B Mahol <onemda@gmail.com>
2012-12-06 19:09:48 +00:00
Paul B Mahol
547b8aeed4 smacker: use meaningful error codes
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2012-12-06 18:06:52 +00:00
Paul B Mahol
29c3ebf56e siff: return meaningful error codes
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2012-12-06 18:00:37 +00:00
Paul B Mahol
7510a9a466 lavf/apedec: return meaningful error codes
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2012-12-06 17:17:49 +00:00
Paul B Mahol
4d1912ff4d huffyuv: return meaningful error codes
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2012-12-06 16:56:40 +00:00
Paul B Mahol
4a722a5cab huffyuv: check for malloc failures
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2012-12-06 16:44:43 +00:00
Justin Ruggles
b64ba37c4c Changelog: add an entry for deprecating the avconv -vol option 2012-12-06 11:33:38 -05:00
Paul B Mahol
7f261ac850 huffyuv: make use of av_fast_padded_malloc()
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2012-12-06 16:31:54 +00:00
Clément Bœsch
eaa47e7454 lavfi/deshake: small align prettifying. 2012-12-06 16:20:31 +01:00
Clément Bœsch
03778575b9 lavfi/deshake: switch inverted comments. 2012-12-06 16:20:31 +01:00