Hendrik Leppkes
c2f861ca42
Replace remaining occurances of av_free_packet with av_packet_unref
9 years ago
Michael Niedermayer
bd70303ead
avformat/swfdec: Check return value of init_get_bits8()
...
Fixes: CID1322320
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
9 years ago
Ronald S. Bultje
229843aa35
Replace av_dlog with ff_dlog.
...
ff_dlog checks compilability, and is non-public. av_dlog is deprecated
and no longer exists if FF_API_DLOG=0.
9 years ago
Carl Eugen Hoyos
128e722bc1
lavf/swf: Fix auto-detection of compressed files.
...
Fixes auto-detection of compressed swf files as in
http://samples.ffmpeg.org/SWF/compressed-swf/
Reported by forum user Zard1096.
9 years ago
Michael Niedermayer
656e9a68c4
avformat/swfdec: Fix "}else" style
...
Found-by: durandal_170
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
10 years ago
Michael Niedermayer
6a1204a1a4
avformat/swfdec: Do not error out on pixel format changes
...
Instead print an error and continue
Fixes Ticket4702
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
10 years ago
Michael Niedermayer
b7e506b3b9
avformat/swfdec: Check frame size rectangle in probe()
...
fixes probetest failure
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
10 years ago
Michael Niedermayer
c2430304df
avformat/swfdec: Do not change the pixel format
...
This is currently not supported
Fixes part of Ticket 3539
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
10 years ago
Michael Niedermayer
1c55d0ff32
avformat/swfdec: Use side data to communicate w/h changes to the decoder
...
Fixes reading from freed data
Fixes part of Ticket3539
Reviewed-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
10 years ago
James Almer
d34ec64a22
replace calls to url_feof() with avio_feof()
...
Signed-off-by: James Almer <jamrial@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
10 years ago
Michael Niedermayer
f5d039840a
avformat/swfdec: clear 4 bytes at the end of a packet if they are not initialized
...
Fixes use of uninitialized memory
Fixes part of msan_uninit-mem_7f055dd0ab1b_9558_videopop_guitar_300k.swf
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
11 years ago
Michael Niedermayer
e72f5abbc6
avformat/swfdec: check avio_read() return code
...
Fixes use of uninitialized memory
Fixes part of msan_uninit-mem_7f055dd0ab1b_9558_videopop_guitar_300k.swf
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
11 years ago
Michael Niedermayer
fde74d1b9d
avformat/swfdec: check avio_read() return code
...
Fixes use of uninitialized memory
Fixes msan_uninit-mem_7f90d9cce964_9558_videopop_guitar_300k.swf
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
11 years ago
Michael Niedermayer
9225ebd50d
avformat/swfdec: return AVPROBE_SCORE_MAX / 4 for unexpected versions
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
11 years ago
Michael Niedermayer
ff1d81b08c
avformat/swfdec: check version and size during probing
...
Fixes probetest failure
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
11 years ago
Clément Bœsch
580e228557
lavf/swfdec: remove 8-bit audio FIXME.
...
Implemented since 624fb5f9
.
12 years ago
Clément Bœsch
624fb5f965
lavf/swfdec: support 8-bits PCM audio.
12 years ago
Clément Bœsch
9a0076f50c
lavf/swfdec: factorize the creation of a new stream.
...
This also makes the changes of a3949fe11
applicable in both cases.
12 years ago
Michael Niedermayer
d276f28b7d
swfdec: print warning when len is cliped
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Justin Ruggles
d04c17c913
swfdec: cosmetics: fix indentation
12 years ago
Justin Ruggles
e70c5b034c
swfdec: do better validation of tag length
...
Avoids trying to read a packet with 0 or negative size.
Avoids a potential infinite loop due to seeking backwards.
Partially based on a patch by Michael Niedermayer.
12 years ago
Michael Niedermayer
c73685398d
swfdec: check lens validity
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Carl Eugen Hoyos
0877f64fea
Add debug output when skipping unknown swf tags.
...
Reviewed-by: Clément Bœsch
12 years ago
Michael Niedermayer
abe68364a3
swfdec: check space before copy
...
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Justin Ruggles
a3949fe11f
swfdec: set channel layout
12 years ago
Clément Bœsch
711ffb84df
lavf/swfdec: support DefineBitsLossless{,2} tag.
12 years ago
Clément Bœsch
cd78192d09
lavf/swfdec: return more meaningful error codes.
12 years ago
Clément Bœsch
0c40220b9d
lavf/swfdec: fix flushing with compressed swf.
...
We now only return in the middle of the refill in case of read error, so
inflate can be re-called if zlib needs an empty (z.avail_in=0) inflate
call for flushing.
12 years ago
Michael Bradshaw
a41c824c53
Parse DEFINESOUND tags in swf (fix ticket 1638)
...
Signed-off-by: Michael Bradshaw <mbradshaw@sorensonmedia.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Diego Biurrun
11d4e92ed9
avformat: Remove non-compiling and/or silly commented-out printf/av_log statements
12 years ago
Anton Khirnov
15c71dfd03
swf(dec): replace CODEC_ID with AV_CODEC_ID
12 years ago
Diego Biurrun
90f7e61769
swf: Move shared table out of the header file
12 years ago
Diego Biurrun
2804ba6a3b
swf: Move swf_audio_codec_tags table to the only place it is used
12 years ago
Anton Khirnov
36ef5369ee
Replace all CODEC_ID_* with AV_CODEC_ID_*
12 years ago
Diego Biurrun
0177b7d23a
Improve descriptiveness of a number of codec and container long names
12 years ago
Clément Bœsch
588eaa106d
swfdec: support compressed swf.
13 years ago
Anton Khirnov
eaea76d72c
swfdec: do not set codec timebase.
...
It is not supposed to be set outside of lavc.
Fixes a divide by zero when the stored framerate is 0.
13 years ago
Ronald S. Bultje
31632e73f4
swf: check return values for av_get/new_packet().
...
Prevents crashers when using the packet if allocation failed.
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
CC: libav-stable@libav.org
13 years ago
Alex Converse
c0bc7bd1e7
swfdec: Simplify sample rate calculation.
13 years ago
Anton Khirnov
6e9651d106
lavf: remove AVFormatParameters from AVFormatContext.read_header signature
13 years ago
Anton Khirnov
c3f9ebf743
lavf: make av_set_pts_info private.
...
It's supposed to be called only from (de)muxers.
13 years ago
Anton Khirnov
84ad31ff18
lavf: replace av_new_stream->avformat_new_stream part II.
...
Manual replacements are done in this commit.
In many cases, the id is some constant made up number (e.g. 0 for video
and 1 for audio), which is then not used in the demuxer for anything.
Those ids are removed.
13 years ago
Tanami, Ohad
99d7d1510e
swfdec: return correct error code at EOF
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Alex Converse
05fc9e40a4
swfdec: Add support for sample_rate_code 0 (5512 Hz)
13 years ago
Anton Khirnov
dfc2c4d900
lavf: use designated initialisers for all (de)muxers.
...
It's more readable and less prone to breakage.
14 years ago
Mans Rullgard
add41decd9
Remove return statements following infinite loops without break
...
These statements cannot be reached and are thus not needed.
This removes a number of compiler warnings.
Signed-off-by: Mans Rullgard <mans@mansr.com>
14 years ago
Mans Rullgard
2912e87a6c
Replace FFmpeg with Libav in licence headers
...
Signed-off-by: Mans Rullgard <mans@mansr.com>
14 years ago
Anton Khirnov
45a8a02a41
lavf: replace avio_seek(SEEK_CUR) with avio_skip where it makes sense
...
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
14 years ago
Anton Khirnov
66e5b1df36
avio: deprecate url_feof
...
AVIOContext.eof_reached should be used directly instead.
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
14 years ago
Anton Khirnov
384c9c2fa7
avio: add avio_tell macro as a replacement for url_ftell
...
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
(cherry picked from commit a2704c9712
)
14 years ago