1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2024-11-21 10:55:51 +02:00
Commit Graph

20056 Commits

Author SHA1 Message Date
nu774
6ec688e1bc mp3: enable packed main_data decoding in MP4
14496-3 suggests packing main_data of MP3 that is usually scattered
into multiple frames due to bit reservoir.

However, after packing main_data into a access unit, bitrate index
in the MPEG audio frame header doesn't match with actual frame size.

In order to accept this, this patch removes unnecessary frame size
checking on mp3 decoder.

Also, mov demuxer was changed to use MP3 parser only on special cases
(QT MOV with specific sample description) to avoid re-packetizing.

Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2015-06-20 12:18:01 +03:00
James Almer
1e79d5c6e7 libwebpenc: use WebPMemoryWriterClear()
WebPMemoryWriterClear() must be used instead of free() when
libwebp ABI version is > 0x0203.

Signed-off-by: James Almer <jamrial@gmail.com>
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2015-06-17 14:13:43 +01:00
Vittorio Giovara
d8d124eebc aic: Improve error reporting 2015-06-17 14:06:35 +01:00
Andreas Cadhalpun
a4fbd55d6e h264: er: Copy from the previous reference only if compatible
Also use the frame pixel format instead of the one from the codec
context, which is more robust.

Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2015-06-15 13:39:07 +02:00
Luca Barbato
9af7e8045e lavc: Clarify the behaviour of dimension and format context fields
The AVCodecContext width, height, coded_width, coded_height and format
are used mainly as decoding hints and they get internally overwritten
during the data parsing stage.

Do not assume they match the last AVFrame provided by
avcodec_decode_video2 and assimilated functions since multi-threading
and other frame reordering might make those values to refer to frames
that will be outputted in the future.

CC: libav-stable@libav.org
2015-06-15 13:39:07 +02:00
Luca Barbato
03ca6d70df x264: Factor out the reconfiguration code 2015-06-15 13:39:07 +02:00
Vittorio Giovara
3b73d5c942 fft-test: Use the float fabs() version
Fixes clang warning "absolute value function 'fabsf' given an argument
of type 'double' but has parameter of type 'float' which may cause
truncation of value [-Wabsolute-value]".
2015-06-12 17:15:18 +01:00
Vittorio Giovara
2d5176fad1 on2avc: Use the integer abs() version
Fixes clang warning "floating point absolute value function 'fabsf'
when argument is of integer type [-Wabsolute-value]".
2015-06-12 17:02:49 +01:00
Vittorio Giovara
b7a4127a45 h264_qpel: Use the correct header 2015-06-12 17:02:48 +01:00
Michael Niedermayer
5e87080f2c h264_weight: Fix SSSE3 biweight code with weights of 128
CC: libav-stable@libav.org
Sample-Id: test_bref.mp4

Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2015-06-12 17:02:48 +01:00
Luca Barbato
64a2e84416 eamad: Use the correct headers
Untangle eamad from the mpeg12.h header and speed up rebuilding.
2015-06-12 12:29:46 +01:00
Luca Barbato
8606e881b0 mpeg12: Move the vlc bits to a stand alone file 2015-06-12 12:29:46 +01:00
Vittorio Giovara
f1fa1eed2a mpegvideo: Expand macro
Having this macro in an header only facilitates the use of such header.
The code increase is minimal and files have one less dependency
on mpegvideo.h.
2015-06-12 12:29:46 +01:00
Vittorio Giovara
e7af52a68d mpegvideo: rv10: Move function declaration to a separate header 2015-06-12 12:26:54 +01:00
Vittorio Giovara
e3d0f49abb mpegvideo: h263: Move all tables to a single file 2015-06-12 12:26:04 +01:00
Vittorio Giovara
8b5007a31b mpegvideo: Move ER functions to a separate file 2015-06-12 11:57:26 +01:00
Vittorio Giovara
c0e6b8cab8 mpegvideo: Mark one function as static 2015-06-10 14:06:44 +01:00
Vittorio Giovara
d1dd0d404c mpegvideo: Move block permutation function where is used
Mark it as static.
2015-06-10 14:06:23 +01:00
Vittorio Giovara
c6aa0554b0 mpegvideo: Drop release_unused_pictures() function
It is only used in one place, and it is small enough that it might be
called directly.
2015-06-10 14:05:53 +01:00
Vittorio Giovara
7061bf0925 mpegvideo: Move Picture-related functions to a separate file 2015-06-10 14:05:32 +01:00
Janne Grunau
210921722b imc: add required padding for GetBitContext buffer
Fixes stack buffer overflow errors detected by address sanitizer in
fate-imc.

CC: libav-stable@libav.org
2015-06-09 10:07:04 +02:00
Janne Grunau
09447f2b0f ac3_parser: add required padding for GetBitContext buffer
Fixes stack buffer overflow errors detected by address sanitizer in
various fate tests.

CC: libav-stable@libav.org
2015-06-09 10:06:59 +02:00
Janne Grunau
fb14730802 aac_parser: add required padding for GetBitContext buffer
Fixes stack buffer overflow errors detected by address sanitizer in
various fate tests.

CC: libav-stable@libav.org
2015-06-09 10:05:54 +02:00
Vittorio Giovara
925b80d640 mpegvideo: Move OutFormat enum to mpegutils.h
It is necessary to avoid circular header dependencies.
2015-06-08 12:39:42 +01:00
Vittorio Giovara
9bb11be0e5 mpegvideo: Split picture allocation for encoding and decoding
The main ff_alloc_picture() function is made more generic with all the
parameters necessary as arguments. This will allows to move most of the
related functions to a separate file later.

Right now wrappers are provided to try and minimize the number of
changes in the code.
2015-06-08 12:39:42 +01:00
Vittorio Giovara
f8716a1408 mpegvideo: Rework frame_size_alloc function
Use more generic arguments and remove its static attribute since it will
be moved to a separate file.
2015-06-08 12:39:42 +01:00
Vittorio Giovara
da0c8664b4 mpegvideo: Move various temporary buffers to a separate context 2015-06-08 12:39:42 +01:00
Luca Barbato
bc76c46943 aac: Wait to know the channels before allocating frame
The channel configuration can be delivered only by the PCE,
try to parse it first and not try to decode until a channel
configuration is set.

CC: libav-stable@libav.org
2015-06-07 10:14:46 +02:00
Sebastian Dröge
a188108ebf aac: Support channel configurations 11 and 12
These are defined in ISO/IEC 14496-3:2009/PDAM 4 for 6.1 and 7.1.
It also defines another 7.1 layout with configuration 14, that one
is not added here for now.

11: 3/3.1    FC FL+FR BL+BR BC LFE
12: 3/2/2.1  FC FL+FR SiL+SiR BL+BR LFE

Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2015-06-07 10:14:46 +02:00
nu774
677c804aa3 aac: correctly map 7.1ch-wide AAC from FDK AAC encoder
FDK AAC encoder outputs SCE(front)+CPE(front)+CPE(back)+CPE(back) on
MODE_7_1_REAR_SURROUND configuration.
Since decoder couldn't properly map 4 back channels, decoding failed
unless -request_channel_layout 0x8000000000000000 has been specified.
Now we treat first CPE(back) as CPE(side) on channel mapping.

Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2015-06-07 10:14:45 +02:00
nu774
0289f81241 aac: Correctly map multichannel ADTS AAC with non-zero channel_config + PCE
The decoder assigns channels using default channel configuration
for 5.1ch when it parses an ADTS frame header using consecutive
channel ids.

When a PCE comes, it reassigns channels using PCE configuration
using directly the ids provided. They can be arbitrary.

Always use consecutive channel ids to avoid decoding glitches due
spurious reconfigurations due the channel ids mismatch between the
two otherwise-identical channel maps.

Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2015-06-03 14:40:10 +02:00
Luca Barbato
7f596368a4 bink: Factorize bink put_pixel
And make sure to check INTER_BLOCK as had been fixed by Michael
Niedermayer.

Reported-By: Andreas Cadhalpun
CC: libav-stable@libav.org
2015-06-03 14:39:03 +02:00
Martin Storsjö
172b2cee17 dxva2: Add ifdefs around structs that might not be available
Signed-off-by: Martin Storsjö <martin@martin.st>
2015-06-01 23:04:46 +03:00
Steve Lhomme
28fa58cf5d dxva2: Fix build when only D3D11 or DXVA2 is used
Signed-off-by: Martin Storsjö <martin@martin.st>
2015-06-01 12:04:57 +03:00
Michael Niedermayer
08d006f5a8 h264: Fix HWACCEL_MAX for D3D11
Signed-off-by: Martin Storsjö <martin@martin.st>
2015-06-01 11:36:30 +03:00
Michael Niedermayer
674b79148f hevc: Fix HWACCEL_MAX for D3D11
Signed-off-by: Martin Storsjö <martin@martin.st>
2015-06-01 11:36:22 +03:00
Luca Barbato
b08caa87c3 nvenc: H264 and HEVC encoders
Partially based on the work of Timo Rothenpieler <timo@rothenpieler.org>

Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2015-05-31 15:17:22 +02:00
Vittorio Giovara
522d971c7f xsub: Check memory allocation 2015-05-31 15:03:31 +02:00
Vittorio Giovara
83797da6e3 wma: Check memory allocation 2015-05-31 15:03:31 +02:00
Vittorio Giovara
e1ea365f7e truemotion2: Check memory allocation 2015-05-31 15:03:31 +02:00
Vittorio Giovara
28fb80dcbf svq1: Check memory allocation 2015-05-31 15:03:31 +02:00
Vittorio Giovara
42df71d9bb ratecontrol: Check memory allocation 2015-05-31 15:03:31 +02:00
Vittorio Giovara
0994e14213 pthread: Check memory allocation 2015-05-31 15:03:31 +02:00
Vittorio Giovara
03927cb733 psymodel: Check memory allocation 2015-05-31 15:03:31 +02:00
Vittorio Giovara
fef2f4722b xvid: Check memory allocation 2015-05-31 15:03:31 +02:00
Vittorio Giovara
9fb483fede x264: Check memory allocation 2015-05-31 15:03:31 +02:00
Vittorio Giovara
41658bc885 libtheora: Check memory allocation 2015-05-31 15:03:31 +02:00
Vittorio Giovara
8df5fbf0b0 lcl: Check memory allocation 2015-05-31 15:03:31 +02:00
Vittorio Giovara
7ca603f96f jpegls: Check memory allocation 2015-05-31 15:03:31 +02:00
Vittorio Giovara
7d2a682691 huffyuv: Check memory allocation 2015-05-31 15:03:31 +02:00