Replace "((a << shift) + b) >> shift" by "a + (b >> shift)". This avoids
a left shift which also happens to trigger undefined behaviour in case "a"
is negative. This affected the FATE-tests acodec-adpcm-adx and
acodec-adpcm-adx-trellis; it also fixes ticket #8008.
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
This parameter can be used to inform the allocation code about how much
downsizing might occur, and can be used to optimize how to allocate the
packet
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* commit '0f24a3ca999a702f83af9307f9f47b6fdeb546a5':
lavc: remove disabled FF_API_OLD_ENCODE_VIDEO cruft
lavc: remove disabled FF_API_OLD_ENCODE_AUDIO cruft
lavc: remove disabled FF_API_OLD_DECODE_AUDIO cruft
Conflicts:
libavcodec/flacenc.c
libavcodec/libgsm.c
libavcodec/utils.c
libavcodec/version.h
The compatibility wrapers are left as they likely sre still
in wide use. They will be removed when they break or otherwise
cause work without an volunteer being available.
Merged-by: Michael Niedermayer <michaelni@gmx.at>
* commit 'e3db34291f4401a16f6ac92721617a9f33cd4c31':
amrnb: decode directly to the user-provided AVFrame
als: decode directly to the user-provided AVFrame
alac: decode directly to the user-provided AVFrame
adxenc: alloc/free coded_frame instead of keeping it in the ADXContext
adx: decode directly to the user-provided AVFrame
Conflicts:
libavcodec/alsdec.c
libavcodec/amrnbdec.c
Merged-by: Michael Niedermayer <michaelni@gmx.at>
* qatar/master: (26 commits)
adxenc: use AVCodec.encode2()
adxenc: Use the AVFrame in ADXContext for coded_frame
indeo4: fix out-of-bounds function call.
configure: Restructure help output.
configure: Internal-only components should not be command-line selectable.
vorbisenc: use AVCodec.encode2()
libvorbis: use AVCodec.encode2()
libopencore-amrnbenc: use AVCodec.encode2()
ra144enc: use AVCodec.encode2()
nellymoserenc: use AVCodec.encode2()
roqaudioenc: use AVCodec.encode2()
libspeex: use AVCodec.encode2()
libvo_amrwbenc: use AVCodec.encode2()
libvo_aacenc: use AVCodec.encode2()
wmaenc: use AVCodec.encode2()
mpegaudioenc: use AVCodec.encode2()
libmp3lame: use AVCodec.encode2()
libgsmenc: use AVCodec.encode2()
libfaac: use AVCodec.encode2()
g726enc: use AVCodec.encode2()
...
Conflicts:
configure
libavcodec/Makefile
libavcodec/ac3enc.c
libavcodec/adxenc.c
libavcodec/libgsm.c
libavcodec/libvorbis.c
libavcodec/vorbisenc.c
libavcodec/wmaenc.c
tests/ref/acodec/g722
tests/ref/lavf/asf
tests/ref/lavf/ffm
tests/ref/lavf/mkv
tests/ref/lavf/mpg
tests/ref/lavf/rm
tests/ref/lavf/ts
tests/ref/seek/lavf_asf
tests/ref/seek/lavf_ffm
tests/ref/seek/lavf_mkv
tests/ref/seek/lavf_mpg
tests/ref/seek/lavf_rm
tests/ref/seek/lavf_ts
Merged-by: Michael Niedermayer <michaelni@gmx.at>
* qatar/master: (46 commits)
mtv: Make sure audio_subsegments is not 0
v4l2: use V4L2_FMT_FLAG_EMULATED only if it is defined
avconv: add symbolic names for -vsync parameters
flvdec: Fix compiler warning for uninitialized variables
rtsp: Fix compiler warning for uninitialized variable
ulti: convert to new bytestream API.
swscale: Use standard multiple inclusion guards in ppc/ header files.
Place some START_TIMER invocations in separate blocks.
v4l2: list available formats
v4l2: set the proper codec_tag
v4l2: refactor device_open
v4l2: simplify away io_method
v4l2: cosmetics
v4l2: uniform and format options
v4l2: do not force interlaced mode
avio: exit early in fill_buffer without read_packet
vc1dec: fix invalid memory access for small video dimensions
rv34: fix invalid memory access for small video dimensions
rv34: joint coefficient decoding and dequantization
avplay: Don't call avio_set_interrupt_cb(NULL)
...
Conflicts:
Changelog
avconv.c
doc/APIchanges
doc/indevs.texi
libavcodec/adxenc.c
libavcodec/dnxhdenc.c
libavcodec/h264.c
libavdevice/v4l2.c
libavformat/flvdec.c
libavformat/mtv.c
libswscale/utils.c
Merged-by: Michael Niedermayer <michaelni@gmx.at>
* qatar/master: (42 commits)
swscale: fix signed overflow in yuv2mono_X_c_template
snow: fix integer overflows
svq1enc: remove stale altivec-related hack
snow: fix signed overflow in byte to 32-bit replication
adx: rename ff_adx_decode_header() to avpriv_adx_decode_header()
avformat: add CRI ADX format demuxer
adx: add an ADX parser.
adx: move header decoding to ADX common code
adx: calculate the number of blocks in a packet
adx: define and use 2 new macro constants BLOCK_SIZE and BLOCK_SAMPLES
adx: check for unsupported ADX formats
adx: simplify encoding by using put_sbits()
adx: calculate correct LPC coeffs
adx: use 12-bit coefficients instead of 14-bit to avoid integer overflow
adx: simplify adx_decode() by using get_sbits() to read residual samples
adx: fix the data offset parsing in adx_decode_header()
adx: remove unneeded post-decode channel interleaving
adx: validate header values
adx: cosmetics: general pretty-printing and comment clean-up
adx: remove useless comments
...
Conflicts:
Changelog
libavcodec/cook.c
libavcodec/fraps.c
libavcodec/nuv.c
libavcodec/pthread.c
libavcodec/version.h
libavformat/Makefile
libavformat/version.h
Merged-by: Michael Niedermayer <michaelni@gmx.at>
Instead of using fixed coefficients, the correct way is to calculate the
coefficients using the highpass cutoff frequency from the ADX stream header
and the sample rate.
* qatar/master:
mxfdec: Include FF_INPUT_BUFFER_PADDING_SIZE when allocating extradata.
H.264: tweak some other x86 asm for Atom
probe: Fix insane flow control.
mpegts: remove invalid error check
s302m: use nondeprecated audio sample format API
lavc: use designated initialisers for all codecs.
x86: cabac: add operand size suffixes missing from 6c32576
Conflicts:
libavcodec/ac3enc_float.c
libavcodec/flacenc.c
libavcodec/frwu.c
libavcodec/pictordec.c
libavcodec/qtrleenc.c
libavcodec/v210enc.c
libavcodec/wmv2dec.c
Merged-by: Michael Niedermayer <michaelni@gmx.at>
None of these symbols should be accessed directly, so declare them as
hidden.
Signed-off-by: Mans Rullgard <mans@mansr.com>
(cherry picked from commit d36beb3f69)
Passing an explicit filename to this command is only necessary if the
documentation in the @file block refers to a file different from the
one the block resides in.
Originally committed as revision 22921 to svn://svn.ffmpeg.org/ffmpeg/trunk