]> git.sesse.net Git - ffmpeg/log
ffmpeg
12 years agoMerge remote-tracking branch 'qatar/master'
Michael Niedermayer [Wed, 11 Apr 2012 20:50:22 +0000 (22:50 +0200)]
Merge remote-tracking branch 'qatar/master'

* qatar/master:
  avplay: Don't free video filters string until the end of decoding.
  movenc: small refactor mov_write_packet
  movenc: remove redundant check
  interplayvideo: fix av_dlog parameter type mismatch
  Drop some pointless #ifdefs.

Conflicts:
libavcodec/interplayvideo.c
libavcodec/libxvidff.c
libavcodec/snowenc.c
libavformat/movenc.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
12 years agolatmenc: error out when packet size is too large.
Reimar Döffinger [Tue, 10 Apr 2012 19:11:50 +0000 (21:11 +0200)]
latmenc: error out when packet size is too large.

Previously it would just silently write out incorrect data.
This also fixes a potential integer overflow in the allocation.

Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
12 years agolatmenc: Fix ALS in LATM.
Reimar Döffinger [Tue, 10 Apr 2012 18:59:05 +0000 (20:59 +0200)]
latmenc: Fix ALS in LATM.

"Fix" in so far as at least it will no longer overread and possibly
crash and makes somewhat sense, but no idea whether there is anything
that can play the resulting files (FFmpeg can't).

Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
12 years agolatmenc: remove unused return value.
Reimar Döffinger [Tue, 10 Apr 2012 19:46:56 +0000 (21:46 +0200)]
latmenc: remove unused return value.

Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
12 years agolatmenc: remove dead code.
Reimar Döffinger [Sun, 8 Apr 2012 19:32:20 +0000 (21:32 +0200)]
latmenc: remove dead code.

Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
12 years agoh261: move tables from header to .c file.
Reimar Döffinger [Tue, 10 Apr 2012 21:13:59 +0000 (23:13 +0200)]
h261: move tables from header to .c file.

Currently they end up twice in the binary, since both
encoder and decoder include the header and thus each gets
their own copy.
This is clearly nonsense for the const tables, but shouldn't
be necessary for the RLTable either.

Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
12 years agoff_samples_to_time_base: support AV_NOPTS_VALUE
Michael Niedermayer [Wed, 11 Apr 2012 18:23:27 +0000 (20:23 +0200)]
ff_samples_to_time_base: support AV_NOPTS_VALUE

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years agoavplay: Don't free video filters string until the end of decoding.
Alex Converse [Wed, 11 Apr 2012 01:18:53 +0000 (18:18 -0700)]
avplay: Don't free video filters string until the end of decoding.

av_freep()ing inside configure_video_filters() leaves a dangling
reference in the calling code, and the filter string is needed again when
reconfiguring video filters for a size change.

12 years agoFix memory leaks on failed ff_h264_decode_init()
Dale Curtis [Tue, 10 Apr 2012 18:31:03 +0000 (11:31 -0700)]
Fix memory leaks on failed ff_h264_decode_init()

During failure conditions ff_h264_decode_init() leaks memory
allocated for nal units.  Found via valgrind.

Valgrind traces: http://pastebin.com/GqTqxs8T

Signed-off-by: Dale Curtis <dalecurtis@chromium.org>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years agooggparsevorbis: Remove code messing with cur_dts.
Michael Niedermayer [Wed, 11 Apr 2012 12:56:02 +0000 (14:56 +0200)]
oggparsevorbis: Remove code messing with cur_dts.

This code caused first_dts to become corrupt and in value to be
around relative_ts.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years agoswr: add a swr_flags AVOption
Michael Niedermayer [Wed, 11 Apr 2012 12:07:58 +0000 (14:07 +0200)]
swr: add a swr_flags AVOption

Using swr_flags instead of plain flags will avoid conflicts that
arise with plain flags and multiple libs (which all have AVOption flags)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years agoffmpeg: support changing dither parameters for swr
Michael Niedermayer [Wed, 11 Apr 2012 11:46:31 +0000 (13:46 +0200)]
ffmpeg: support changing dither parameters for swr

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years agocmdutils: parse options for swr
Michael Niedermayer [Wed, 11 Apr 2012 11:46:02 +0000 (13:46 +0200)]
cmdutils: parse options for swr

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years agoswr: add a dither_scale parameter to tune the amplitude of the dither.
Michael Niedermayer [Wed, 11 Apr 2012 11:44:48 +0000 (13:44 +0200)]
swr: add a dither_scale parameter to tune the amplitude of the dither.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years agoswr: pass context to swri_get_dither()
Michael Niedermayer [Wed, 11 Apr 2012 11:44:15 +0000 (13:44 +0200)]
swr: pass context to swri_get_dither()

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years agomovenc: small refactor mov_write_packet
Luca Barbato [Wed, 11 Apr 2012 10:37:14 +0000 (03:37 -0700)]
movenc: small refactor mov_write_packet

Share the formerly internal write_packet with the hinter and move the
fragment flush logic to the user facing one since it is not concerned
about movtrack-only streams.

Fixes bug #263

Signed-off-by: Martin Storsjö <martin@martin.st>
12 years agomovenc: remove redundant check
Luca Barbato [Wed, 11 Apr 2012 10:37:13 +0000 (03:37 -0700)]
movenc: remove redundant check

The proper check is already in mov_write_header.

Signed-off-by: Martin Storsjö <martin@martin.st>
12 years agoswr: add triangular highpass dither
Michael Niedermayer [Wed, 11 Apr 2012 11:27:22 +0000 (13:27 +0200)]
swr: add triangular highpass dither

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years agoswr: generate more dither noise to improve quality.
Michael Niedermayer [Wed, 11 Apr 2012 11:26:32 +0000 (13:26 +0200)]
swr: generate more dither noise to improve quality.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years agoswr: add swr_get_class()
Michael Niedermayer [Wed, 11 Apr 2012 11:25:56 +0000 (13:25 +0200)]
swr: add swr_get_class()

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years agointerplayvideo: fix av_dlog parameter type mismatch
Diego Biurrun [Tue, 10 Apr 2012 16:18:40 +0000 (18:18 +0200)]
interplayvideo: fix av_dlog parameter type mismatch

libavcodec/interplayvideo.c:909:13: warning: format ‘%p’ expects argument of type ‘void *’, but argument 7 has type ‘GetByteContext’ [-Wformat]

12 years agoswr: simplify code by using av_get_bytes_per_sample()
Michael Niedermayer [Wed, 11 Apr 2012 07:57:38 +0000 (09:57 +0200)]
swr: simplify code by using av_get_bytes_per_sample()

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years agoswr: fix copy & pasted comment to match the code.
Michael Niedermayer [Tue, 10 Apr 2012 21:54:04 +0000 (23:54 +0200)]
swr: fix copy & pasted comment to match the code.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years agovda: try to fix compile
Michael Niedermayer [Tue, 10 Apr 2012 21:34:51 +0000 (23:34 +0200)]
vda: try to fix compile

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years agoMerge remote-tracking branch 'qatar/master'
Michael Niedermayer [Tue, 10 Apr 2012 20:06:53 +0000 (22:06 +0200)]
Merge remote-tracking branch 'qatar/master'

* qatar/master: (22 commits)
  rv40dsp x86: use only one register, for both increment and loop counter
  rv40dsp: implement prescaled versions for biweight.
  avconv: use default channel layouts when they are unknown
  avconv: parse channel layout string
  nutdec: K&R formatting cosmetics
  vda: Signal 4 byte NAL headers to the decoder regardless of what's in the extradata
  mem: Consistently return NULL for av_malloc(0)
  vf_overlay: implement poll_frame()
  vf_scale: support named constants for sws flags.
  lavc doxy: add all installed headers to doxy groups.
  lavc doxy: add avfft to the main lavc group.
  lavc doxy: add remaining avcodec.h functions to a misc doxygen group.
  lavc doxy: add AVPicture functions to a doxy group.
  lavc doxy: add resampling functions to a doxy group.
  lavc doxy: replace \ with /
  lavc doxy: add encoding functions to a doxy group.
  lavc doxy: add decoding functions to a doxy group.
  lavc doxy: fix formatting of AV_PKT_DATA_{PARAM_CHANGE,H263_MB_INFO}
  lavc doxy: add AVPacket-related stuff to a separate doxy group.
  lavc doxy: add core functions/definitions to a doxy group.
  ...

Conflicts:
ffmpeg.c
libavcodec/avcodec.h
libavcodec/vda.c
libavcodec/x86/rv40dsp.asm
libavfilter/vf_scale.c
libavformat/nutdec.c
libavutil/mem.c
tests/ref/acodec/pcm_s24daud

Merged-by: Michael Niedermayer <michaelni@gmx.at>
12 years agoswr: add triangular dither support
Michael Niedermayer [Tue, 10 Apr 2012 19:10:14 +0000 (21:10 +0200)]
swr: add triangular dither support

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years agoswr: remove unused variable
Michael Niedermayer [Tue, 10 Apr 2012 18:30:06 +0000 (20:30 +0200)]
swr: remove unused variable

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years agoswr: add SWR_DITHER_RECTANGULAR to AVOptions array
Michael Niedermayer [Tue, 10 Apr 2012 18:29:47 +0000 (20:29 +0200)]
swr: add SWR_DITHER_RECTANGULAR to AVOptions array

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years agoaacsbr: silence message for SBR extension "padding".
Reimar Döffinger [Mon, 9 Apr 2012 19:19:30 +0000 (21:19 +0200)]
aacsbr: silence message for SBR extension "padding".

Some files contain a few additional, all-0 bits.
Check for that case and don't print incorrect "not supported"
message.
Fixes trac issue #836.

Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
12 years agoswr-test: include opt.h, this is needed for changing options for testing.
Michael Niedermayer [Tue, 10 Apr 2012 17:53:43 +0000 (19:53 +0200)]
swr-test: include opt.h, this is needed for changing options for testing.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years agoswr: use assert in swri_sum2 to check that only supported formats are used.
Michael Niedermayer [Tue, 10 Apr 2012 17:53:11 +0000 (19:53 +0200)]
swr: use assert in swri_sum2 to check that only supported formats are used.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years agoswr: add dither support.
Michael Niedermayer [Tue, 10 Apr 2012 17:52:42 +0000 (19:52 +0200)]
swr: add dither support.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years agoswr: update copyright year for rematrix
Michael Niedermayer [Tue, 10 Apr 2012 16:56:17 +0000 (18:56 +0200)]
swr: update copyright year for rematrix

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years agoDrop some pointless #ifdefs.
Diego Biurrun [Tue, 10 Apr 2012 12:27:59 +0000 (14:27 +0200)]
Drop some pointless #ifdefs.

The files are only compiled if the #ifdef conditions are met.

12 years agorv40dsp x86: use only one register, for both increment and loop counter
Christophe GISQUET [Tue, 20 Mar 2012 15:13:55 +0000 (16:13 +0100)]
rv40dsp x86: use only one register, for both increment and loop counter

Around 10 cycles faster for luma.

Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
12 years agorv40dsp: implement prescaled versions for biweight.
Christophe GISQUET [Mon, 19 Mar 2012 21:46:28 +0000 (22:46 +0100)]
rv40dsp: implement prescaled versions for biweight.

Quite often, the original weights are multiple of 512. By prescaling them
by 1/512 when they are computed (once per frame), no intermediate shifting
is needed, and no prescaling on each call either.

The x86 code already used that trick.

Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
12 years agoavconv: use default channel layouts when they are unknown
Justin Ruggles [Thu, 5 Apr 2012 22:11:28 +0000 (18:11 -0400)]
avconv: use default channel layouts when they are unknown

If either input or output layout is known and the channel counts match,
use the known layout for both. Otherwise choose the default layout based on
av_get_default_channel_layout().

Changed some FATE references due to some WAVE files now having a non-zero
channel mask.

12 years agoavconv: parse channel layout string
Justin Ruggles [Thu, 5 Apr 2012 21:47:20 +0000 (17:47 -0400)]
avconv: parse channel layout string

This allows the user to use channel layout names instead of having to use the
channel mask values.

12 years agovf_drawtext: fontconfig support.
Nicolas George [Sat, 7 Apr 2012 13:09:16 +0000 (15:09 +0200)]
vf_drawtext: fontconfig support.

12 years agovf_drawtext: fix memory leak of draw expression.
Nicolas George [Tue, 10 Apr 2012 07:55:30 +0000 (09:55 +0200)]
vf_drawtext: fix memory leak of draw expression.

12 years agovf_drawtext: fix memory leak of glyph data.
Nicolas George [Tue, 10 Apr 2012 07:55:11 +0000 (09:55 +0200)]
vf_drawtext: fix memory leak of glyph data.

12 years agonutdec: K&R formatting cosmetics
Asen Lekov [Fri, 2 Dec 2011 16:14:05 +0000 (16:14 +0000)]
nutdec: K&R formatting cosmetics

Signed-off-by: Diego Biurrun <diego@biurrun.de>
12 years agovda: Signal 4 byte NAL headers to the decoder regardless of what's in the extradata
Sebastien Zwickert [Tue, 10 Apr 2012 11:48:08 +0000 (13:48 +0200)]
vda: Signal 4 byte NAL headers to the decoder regardless of what's in the extradata

Signed-off-by: Martin Storsjö <martin@martin.st>
12 years agoresample: support double precission resampling
Michael Niedermayer [Tue, 10 Apr 2012 11:38:10 +0000 (13:38 +0200)]
resample: support double precission resampling

This commit is dedicated to the audiophiles who can hear it when a
needle is dropped on the moon.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years agoswr: support int32 and float as internal sample formats
Michael Niedermayer [Tue, 10 Apr 2012 11:19:29 +0000 (13:19 +0200)]
swr: support int32 and float as internal sample formats

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years agoswr: support float & int32 in the resampler
Michael Niedermayer [Tue, 10 Apr 2012 11:18:49 +0000 (13:18 +0200)]
swr: support float & int32 in the resampler

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years agoswr-test: Add newline to test output
Michael Niedermayer [Tue, 10 Apr 2012 11:06:00 +0000 (13:06 +0200)]
swr-test: Add newline to test output

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years agoresample: update copyright years, they where incorrect.
Michael Niedermayer [Tue, 10 Apr 2012 10:35:37 +0000 (12:35 +0200)]
resample: update copyright years, they where incorrect.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years agomem: Consistently return NULL for av_malloc(0)
Martin Storsjö [Sun, 8 Apr 2012 14:38:45 +0000 (17:38 +0300)]
mem: Consistently return NULL for av_malloc(0)

Plain POSIX malloc(0) is allowed to return either NULL or a
non-NULL pointer. The calling code should be ready to handle
a NULL return as a correct return (instead of a failure) if the size
to allocate was 0 - this makes sure the condition is handled
in a consistent way across platforms.

This also avoids calling posix_memalign(&ptr, 32, 0) on OS X,
which returns an invalid pointer (a non-NULL pointer that causes
crashes when passed to av_free).

Abort in debug mode, to help track down issues related to
incorrect handling of this case.

Signed-off-by: Martin Storsjö <martin@martin.st>
12 years agoMerge remote-tracking branch 'qatar/master'
Michael Niedermayer [Mon, 9 Apr 2012 20:48:20 +0000 (22:48 +0200)]
Merge remote-tracking branch 'qatar/master'

* qatar/master:
  avconv: use default alignment for audio buffer
  avcodec: use align == 0 for default alignment in avcodec_fill_audio_frame()
  avutil: use align == 0 for default alignment in audio sample buffer functions
  avutil: allow NULL linesize in av_samples_fill_arrays() and av_samples_alloc()
  avconv: remove OutputStream.picref.
  avconv: only set SAR once on the decoded frame.
  avcodec: validate the channel layout vs. channel count for decoders
  audioconvert: make av_get_channel_layout accept composite names.
  avutil: add av_get_packed_sample_fmt() and av_get_planar_sample_fmt()

Conflicts:
doc/APIchanges
ffmpeg.c
libavcodec/utils.c
libavcodec/version.h
libavutil/audioconvert.c
libavutil/audioconvert.h
libavutil/avutil.h
libavutil/samplefmt.c
libavutil/samplefmt.h

Merged-by: Michael Niedermayer <michaelni@gmx.at>
12 years agoFix gif regression test on big-endian.
Reimar Döffinger [Mon, 9 Apr 2012 19:54:38 +0000 (21:54 +0200)]
Fix gif regression test on big-endian.

Decode output must be converted to rgb24 to avoid CRC difference
due to palette being stored in machine endianness.

Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
12 years agovf_overlay: implement poll_frame()
Anton Khirnov [Sun, 1 Apr 2012 16:51:27 +0000 (18:51 +0200)]
vf_overlay: implement poll_frame()

Signal that it can output a frame when there are frames on the main
input and EOF on the overlay input, but a frame is buffered -- e.g.
single picture overlay.

12 years agovf_scale: support named constants for sws flags.
Anton Khirnov [Mon, 9 Apr 2012 04:05:50 +0000 (06:05 +0200)]
vf_scale: support named constants for sws flags.

12 years agolavc doxy: add all installed headers to doxy groups.
Anton Khirnov [Sun, 8 Apr 2012 12:08:05 +0000 (14:08 +0200)]
lavc doxy: add all installed headers to doxy groups.

12 years agolavc doxy: add avfft to the main lavc group.
Anton Khirnov [Sun, 8 Apr 2012 11:49:15 +0000 (13:49 +0200)]
lavc doxy: add avfft to the main lavc group.

12 years agolavc doxy: add remaining avcodec.h functions to a misc doxygen group.
Anton Khirnov [Sun, 8 Apr 2012 11:35:50 +0000 (13:35 +0200)]
lavc doxy: add remaining avcodec.h functions to a misc doxygen group.

12 years agolavc doxy: add AVPicture functions to a doxy group.
Anton Khirnov [Sun, 8 Apr 2012 11:22:19 +0000 (13:22 +0200)]
lavc doxy: add AVPicture functions to a doxy group.

12 years agolavc doxy: add resampling functions to a doxy group.
Anton Khirnov [Sun, 8 Apr 2012 11:22:19 +0000 (13:22 +0200)]
lavc doxy: add resampling functions to a doxy group.

12 years agolavc doxy: replace \ with /
Anton Khirnov [Sun, 8 Apr 2012 11:05:53 +0000 (13:05 +0200)]
lavc doxy: replace \ with /

It's the more proper symbol to use and it prevents doxygen from thinking
it's a command.

12 years agolavc doxy: add encoding functions to a doxy group.
Anton Khirnov [Sun, 8 Apr 2012 10:45:58 +0000 (12:45 +0200)]
lavc doxy: add encoding functions to a doxy group.

12 years agolavc doxy: add decoding functions to a doxy group.
Anton Khirnov [Sun, 8 Apr 2012 10:45:58 +0000 (12:45 +0200)]
lavc doxy: add decoding functions to a doxy group.

12 years agolavc doxy: fix formatting of AV_PKT_DATA_{PARAM_CHANGE,H263_MB_INFO}
Anton Khirnov [Sun, 8 Apr 2012 10:31:56 +0000 (12:31 +0200)]
lavc doxy: fix formatting of AV_PKT_DATA_{PARAM_CHANGE,H263_MB_INFO}

12 years agolavc doxy: add AVPacket-related stuff to a separate doxy group.
Anton Khirnov [Sun, 8 Apr 2012 10:28:46 +0000 (12:28 +0200)]
lavc doxy: add AVPacket-related stuff to a separate doxy group.

Also move AV_PKT_DATA_PARAM_CHANGE/AV_PKT_DATA_H263_MB_INFO to the
proper place.

12 years agolavc doxy: add core functions/definitions to a doxy group.
Anton Khirnov [Sun, 8 Apr 2012 10:12:33 +0000 (12:12 +0200)]
lavc doxy: add core functions/definitions to a doxy group.

12 years agoexr: optimize exr_halflt2uint()
Michael Niedermayer [Mon, 9 Apr 2012 18:55:09 +0000 (20:55 +0200)]
exr: optimize exr_halflt2uint()

30% faster

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years agoppc: Add/remove a number of const qualifiers to fix related warnings.
Diego Biurrun [Mon, 2 Apr 2012 17:03:30 +0000 (19:03 +0200)]
ppc: Add/remove a number of const qualifiers to fix related warnings.

12 years agoavconv: allow '-async -1' to disable timestamp sync for audio encoding
Justin Ruggles [Sun, 8 Apr 2012 19:00:01 +0000 (15:00 -0400)]
avconv: allow '-async -1' to disable timestamp sync for audio encoding

This will allow a workaround for cases where input timestamps are invalid or
when decoder delay of 1 packet or more confuses avconv into using the wrong
timestamps as a sync reference.

12 years agoAdd gif and xbm regression tests.
Reimar Döffinger [Sun, 8 Apr 2012 14:23:18 +0000 (16:23 +0200)]
Add gif and xbm regression tests.

Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
12 years agovf_scale: ensure the palette is set for output.
Reimar Döffinger [Sun, 8 Apr 2012 13:11:13 +0000 (15:11 +0200)]
vf_scale: ensure the palette is set for output.

Since those are pseudo-palette formats, swscale does not write
into data[1], swscale must initialize the palette properly itself.
This lead to frames that actually decoded as all-gray before.

Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
12 years agoMark GRAY8 format as pseudo-paletted.
Reimar Döffinger [Sun, 8 Apr 2012 14:12:46 +0000 (16:12 +0200)]
Mark GRAY8 format as pseudo-paletted.

This fixes that the GIF encoder crashes with it because
it has no palette.
And the arguments for the pseudopalette apply to gray8 as
much as to RGB8 etc.
In addition the changes required in lavfi should be needed anyway
when adding support for RGB8 etc.

Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
12 years agoscale: fix slice rendering with conversion between pal/non-pal.
Reimar Döffinger [Sun, 8 Apr 2012 12:59:53 +0000 (14:59 +0200)]
scale: fix slice rendering with conversion between pal/non-pal.

We can't use whether the input format is paletted to decide that
the output format has a palette in data[1], too, that makes no sense.

Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
12 years agoRV20: try keeping aspect during resolution changes.
Reimar Döffinger [Mon, 9 Apr 2012 12:21:01 +0000 (14:21 +0200)]
RV20: try keeping aspect during resolution changes.

Resolution changes are usually only used to scale with
network bandwidth, the (full) resolution specified in the
RM header really is authoritative.
While I am not sure this is the best solution, it is a
conservative approach that still should fix the most
common cases.
In particular, it fixes aspect with the sample from trac
issue #785 (in MPlayer, ffplay seems to just ignore
sample aspect changes in mid-playback).

Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
12 years agoaacdec: update debug code to always print the processed data.
Reimar Döffinger [Sun, 8 Apr 2012 22:17:25 +0000 (00:17 +0200)]
aacdec: update debug code to always print the processed data.

When decoding LATM, this function will not process extradata
but a different buffer.
It seems this was forgotten to update when LATM support
was added.

Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
12 years agoavconv: use default alignment for audio buffer
Justin Ruggles [Thu, 5 Apr 2012 23:09:51 +0000 (19:09 -0400)]
avconv: use default alignment for audio buffer

12 years agoavcodec: use align == 0 for default alignment in avcodec_fill_audio_frame()
Justin Ruggles [Thu, 5 Apr 2012 23:01:21 +0000 (19:01 -0400)]
avcodec: use align == 0 for default alignment in avcodec_fill_audio_frame()

Use default alignment in audio_get_buffer()

12 years agoavutil: use align == 0 for default alignment in audio sample buffer functions
Justin Ruggles [Wed, 28 Mar 2012 01:31:14 +0000 (21:31 -0400)]
avutil: use align == 0 for default alignment in audio sample buffer functions

12 years agoavutil: allow NULL linesize in av_samples_fill_arrays() and av_samples_alloc()
Justin Ruggles [Wed, 28 Mar 2012 01:34:47 +0000 (21:34 -0400)]
avutil: allow NULL linesize in av_samples_fill_arrays() and av_samples_alloc()

12 years agoavconv: remove OutputStream.picref.
Anton Khirnov [Thu, 29 Mar 2012 07:02:01 +0000 (09:02 +0200)]
avconv: remove OutputStream.picref.

It's only used inside transcode_video() and there's no point in
preserving it between subsequent calls. So use a local variable instead.

12 years agoavconv: only set SAR once on the decoded frame.
Anton Khirnov [Thu, 22 Mar 2012 08:37:33 +0000 (09:37 +0100)]
avconv: only set SAR once on the decoded frame.

No point in repeating the assignment for each output stream.

12 years agoAdd v408 codec regression test.
Reimar Döffinger [Sun, 8 Apr 2012 14:19:06 +0000 (16:19 +0200)]
Add v408 codec regression test.

Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
12 years agoavcodec: validate the channel layout vs. channel count for decoders
Justin Ruggles [Wed, 4 Apr 2012 14:47:45 +0000 (10:47 -0400)]
avcodec: validate the channel layout vs. channel count for decoders

Set avctx->channel_layout to 0 if the channel count does not match
avctx->channels.

12 years agoaudioconvert: make av_get_channel_layout accept composite names.
Nicolas George [Tue, 8 Nov 2011 15:32:50 +0000 (16:32 +0100)]
audioconvert: make av_get_channel_layout accept composite names.

Signed-off-by: Nicolas George <nicolas.george@normalesup.org>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Signed-off-by: Justin Ruggles <justin.ruggles@gmail.com>
12 years agoAdd roqaudio regression test.
Reimar Döffinger [Sun, 8 Apr 2012 19:10:44 +0000 (21:10 +0200)]
Add roqaudio regression test.

Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
12 years agoavutil: add av_get_packed_sample_fmt() and av_get_planar_sample_fmt()
Justin Ruggles [Thu, 5 Apr 2012 21:00:53 +0000 (17:00 -0400)]
avutil: add av_get_packed_sample_fmt() and av_get_planar_sample_fmt()

Based on a patch by Clément Bœsch <ubitux@gmail.com>

12 years agoMerge remote-tracking branch 'qatar/master'
Michael Niedermayer [Sun, 8 Apr 2012 18:55:02 +0000 (20:55 +0200)]
Merge remote-tracking branch 'qatar/master'

* qatar/master:
  rtsp: Don't use av_malloc(0) if there are no streams
  rtsp: Don't use uninitialized data if there are no streams
  vaapi: mpeg2: fix slice_vertical_position calculation.
  hwaccel: mpeg2: decode first field, if requested.
  cosmetics: Fix indentation
  rtsp: Don't expose the MS-RTSP RTX data stream to the caller

Merged-by: Michael Niedermayer <michaelni@gmx.at>
12 years agoAllow running fate-wmv8-x8intra manually.
Reimar Döffinger [Sun, 8 Apr 2012 17:59:59 +0000 (19:59 +0200)]
Allow running fate-wmv8-x8intra manually.

Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
12 years agoAllow manually running disabled FATE tests.
Reimar Döffinger [Sun, 8 Apr 2012 17:55:49 +0000 (19:55 +0200)]
Allow manually running disabled FATE tests.

This makes it easy to allow people to run tests that are disabled
(e.g. because they are broken) without having to hack Makefiles
by adding the test name to FATE_TESTS-no.

Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
12 years agoFix nellymoser encoder crash with hardcoded tables.
Reimar Döffinger [Sun, 8 Apr 2012 18:25:08 +0000 (20:25 +0200)]
Fix nellymoser encoder crash with hardcoded tables.

Use the correct init function to avoid crashes due to writing
to a rodata location.

Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
12 years agoUpdate reference for disabled fate-wmv8-x8intra test to new format.
Reimar Döffinger [Sun, 8 Apr 2012 17:59:20 +0000 (19:59 +0200)]
Update reference for disabled fate-wmv8-x8intra test to new format.

Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
12 years agoffv1: set slice geometry based on user specified slices.
Michael Niedermayer [Sun, 8 Apr 2012 15:03:38 +0000 (17:03 +0200)]
ffv1: set slice geometry based on user specified slices.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years agoffv1: allow enabling of version 2 by using some of its features.
Michael Niedermayer [Sun, 8 Apr 2012 14:46:36 +0000 (16:46 +0200)]
ffv1: allow enabling of version 2 by using some of its features.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years agoffv1: fix version=2 chroma handling
Michael Niedermayer [Sun, 8 Apr 2012 13:03:40 +0000 (15:03 +0200)]
ffv1: fix version=2 chroma handling

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years agoffv1: add a minor version field beginning with ffv1.3
Michael Niedermayer [Sun, 8 Apr 2012 12:20:17 +0000 (14:20 +0200)]
ffv1: add a minor version field beginning with ffv1.3

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years agortsp: Don't use av_malloc(0) if there are no streams
Martin Storsjö [Fri, 6 Apr 2012 19:36:16 +0000 (22:36 +0300)]
rtsp: Don't use av_malloc(0) if there are no streams

Signed-off-by: Martin Storsjö <martin@martin.st>
12 years agortsp: Don't use uninitialized data if there are no streams
Martin Storsjö [Fri, 6 Apr 2012 19:35:48 +0000 (22:35 +0300)]
rtsp: Don't use uninitialized data if there are no streams

Signed-off-by: Martin Storsjö <martin@martin.st>
12 years agoFix side-data memleak also for audio.
Reimar Döffinger [Sun, 8 Apr 2012 10:09:55 +0000 (12:09 +0200)]
Fix side-data memleak also for audio.

This uses the same code as in decode_video also in decode_audio.
Should fix valgrind FATE failures for nellymoser encode test.

Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
12 years agovaapi: mpeg2: fix slice_vertical_position calculation.
Gwenole Beauchesne [Sun, 18 Mar 2012 08:30:05 +0000 (09:30 +0100)]
vaapi: mpeg2: fix slice_vertical_position calculation.

VASliceParameterBufferMPEG2.slice_vertical_position shall express
the slice vertical position from the original bitstream. The HW
decoder will correctly decode to the right line computed from the
appropriate top_field_first and is_first_field flags.

This patch aligns with DXVA's definition, which is what most HW and
drivers expect. In particular, Intel PowerVR (Cedarview et al.) and
NVIDIA (through VA-to-VDPAU layer). Since it looks more complex to fix
binary drivers, I aligned the Intel Gen driver (Sandy Bridge et al.)
to this behaviour, while maintaining compatibility with codec layers
not providing this patch yet.

Signed-off-by: Gwenole Beauchesne <gwenole.beauchesne@intel.com>
Signed-off-by: Martin Storsjö <martin@martin.st>
12 years agohwaccel: mpeg2: decode first field, if requested.
Gwenole Beauchesne [Sun, 18 Mar 2012 08:46:58 +0000 (09:46 +0100)]
hwaccel: mpeg2: decode first field, if requested.

If user opted to present fields as they come, then the first field
picture needs to be submitted to the HW for decoding. In particular,
this fixes MPEG-2 decoding of interlaced streams.

Tested on Intel Cedar Trail, Sandy Bridge and Ivy Bridge platforms.
Someone reported on the ffmpeg-devel@ list this also works on DXVA
(Windows) and other Linux platforms (NVIDIA, through the VA wrapper).

This also means a similar patch to non-hwaccel VDPAU may be necessary.

Note: I believe the SLICE_FLAG_ALLOW_FIELD is useless since the first
field shall always be submitted to the HW anyway. Nobody uses HW accels
(dxva, vaapi, vdpau, etc.) without that flag though.

Signed-off-by: Gwenole Beauchesne <gwenole.beauchesne@intel.com>
Signed-off-by: Martin Storsjö <martin@martin.st>
12 years agocosmetics: Fix indentation
Martin Storsjö [Sat, 7 Apr 2012 20:40:37 +0000 (23:40 +0300)]
cosmetics: Fix indentation

Signed-off-by: Martin Storsjö <martin@martin.st>
12 years agortsp: Don't expose the MS-RTSP RTX data stream to the caller
Martin Storsjö [Fri, 6 Apr 2012 20:07:12 +0000 (23:07 +0300)]
rtsp: Don't expose the MS-RTSP RTX data stream to the caller

This avoids exposing a dummy AVStream which won't get any data
and which will make avformat_find_stream_info wait for info about
this stream.

Signed-off-by: Martin Storsjö <martin@martin.st>