Michael Niedermayer
53cb0de25b
asfdec: mark only ts1 as av_unused
...
Idea-by: ubitux
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Michael Niedermayer
6760bd0a19
asfdec: avoid unused variable warning.
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Michael Niedermayer
ba7f18876c
asfdec: use dts for seeking.
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Michael Niedermayer
bb4eabacea
asfdec: restore timestamp reading code
...
This reverts part of:
commit e65ab9d94f
Author: Mans Rullgard <mans@mansr.com>
Date: Wed Jun 1 17:26:27 2011 +0100
Remove unused variables
13 years ago
Clément Bœsch
53d70a334a
Rename remaining get_buffer to avio_read.
13 years ago
Diego Biurrun
2f5df0b12c
Replace ffmpeg references with more accurate libav* references.
13 years ago
Michael Niedermayer
60fcc19bff
asfdec: Check packet_replic_size earlier
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Anton Khirnov
a2faa95151
lavf: make some seeking functions private
...
Specifically av_update_cur_dts(), av_seek_frame_binary() and
av_gen_search().
They are not supposed to be called outside lavf.
13 years ago
Anton Khirnov
1fa395e471
lavf: use avpriv_ prefix for ff_new_chapter().
...
It's used in libavdevice.
13 years ago
Anton Khirnov
3b3bbdd3e6
lavf,lavd: replace av_new_stream->avformat_new_stream part I.
...
Trivial replacements with sed are done in this commit:
sed 's/av_new_stream(\([^)]*\), 0)/avformat_new_stream(\1, NULL)/'
13 years ago
Michael Niedermayer
2eaa55375b
asf: export all the DRM stuff, some of it are human readable strings.
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Michael Niedermayer
6322a31df3
asf: dont warn the user about digital sigantures, they should on their own not cause failure.
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Michael Niedermayer
410c06d2f3
asf: export encryption information from asf.
...
This way user apps can choose to skip such content.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Joakim Plate
6c9a24636b
asf: only try to read asf index once
...
This avoid retrying to read ASF index in files for every
attempt to seek. This makes a big difference to protocols
with slow seeking (for example http)
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Joakim Plate
ac1d489320
asf: Check return value of more avio_seek calls
...
This reduces problems when underlying protocol is not
seekable even if marked as such or if the file has been
cut short.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
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
0ebcdf5cda
Do not include mathematics.h in avutil.h
...
Signed-off-by: Mans Rullgard <mans@mansr.com>
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
Diego Biurrun
91c9aa0941
Move some conditionally used code below the appropriate #ifdef.
14 years ago
Anton Khirnov
d2d67e424f
Remove all uses of now deprecated metadata functions.
14 years ago
Mans Rullgard
e65ab9d94f
Remove unused variables
14 years ago
Clément Bœsch
adba9c6352
Fix various unused variable warnings
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
14 years ago
Mans Rullgard
b122c65107
asfdec: add missing #include for av_bswap32()
...
Signed-off-by: Mans Rullgard <mans@mansr.com>
14 years ago
Uoti Urpala
29fa570d0c
asfdec: fix possible overread on broken files.
14 years ago
Vladimir Pantelic
69fa23961e
asfdec: do not fall back to binary/generic search
...
asf_read_seek() inside the asf demuxer already does the
right thing, it tries the index and if that fails it uses
binary search. If binary search is called from outside of asfdec.c
it will fail because the asf code cannot clean up after itself.
Therefore introduce AVFMT_NOBINSEARCH that prevents the seek
code to fallback to binary search and AVFMT_NOGENSEARCH that
prevents the seek code to fallback to generic search.
14 years ago
Vladimir Pantelic
b58bc17cf7
asfdec: reindent after previous commit c7bd5ed
14 years ago
Vladimir Pantelic
c7bd5edae4
asfdec: fallback to binary search internally
...
lavf will do that anyway in case seek by index fails
14 years ago
Uoti Urpala
bcedf2e519
asfdec: fix assert failure on invalid files
...
Add an extra size validity check in asf_read_frame_header(). Without
this asf->packet_size_left may become negative, which triggers an
assertion failure later.
14 years ago
Michael Niedermayer
10291562f3
Revert "asfdec: fix assert failure on invalid files"
...
Reverting this pulled change as author considers this change buggy compared to his
original version.
This reverts commit 0bd433a916
.
14 years ago
Uoti Urpala
0bd433a916
asfdec: fix assert failure on invalid files
...
Add an extra size validity check in asf_read_frame_header(). Without
this asf->packet_size_left may become negative, which triggers an
assertion failure later.
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
14 years ago
Ronald S. Bultje
f8b1245922
asfdec: fix parsing of packets that overrun into padding.
...
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
14 years ago
Vladimir Pantelic
8408e1d7d6
asf: remove commented out code in asf_read_seek
...
Signed-off-by: Mans Rullgard <mans@mansr.com>
14 years ago
Diego Biurrun
0b5ae1fdd3
asfdec: Remove dead code from asf_read_close().
14 years ago
Kostya Shishkov
2d8591c27e
make containers pass palette change in AVPacket
...
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
14 years ago
Max Horn
ca402f32e3
handle malloc failures in ff_get_wav_header
...
ff_get_wav_header is reading data from a WAVE file and then uses it
(without validation) to malloc a buffer. It then proceeded to read
data into the buffer, without verifying that the allocation succeeded.
To address this, change ff_get_wav_header to return an error if
allocation failed, and adapted all calling code to handle that error.
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
14 years ago
Anton Khirnov
ff1ec0c3f8
avio: undeprecate av_url_read_fseek/fpause under nicer names
...
It seems their replacements won't be ready anytime soon.
14 years ago
Anton Khirnov
acaceca2f1
asfdec: remove a forgotten declaration of nonexistent function
14 years ago
Peter Ross
c1309b27d2
move ff_asf_guid, ff_guidcmp and ff_get_guid into riff.h
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
14 years ago
Michael Niedermayer
5b56ad03fa
Reimplement stream probe try #2
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
14 years ago
Vladimir Pantelic
4377fafda1
asfdec: also subtract preroll when reading simple index object
...
This was missed when ASF was changed to return timestamps
without preroll.
Signed-off-by: Mans Rullgard <mans@mansr.com>
14 years ago
Anton Khirnov
933e90a69a
avio: make av_url_read_fseek/fpause internal.
...
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.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
Michael Niedermayer
133055c5e4
reverts parts of commit de11ee906e
. The author of this patch has a poor understanding of the code
14 years ago
Vladimir Pantelic
de11ee906e
asfdec: subtract the preroll value and thus output 0 based timestamps
...
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
3e68b3ba7b
avio: deprecate url_ferror
...
AVIOContext.error should be used directly instead.
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
Anton Khirnov
a2704c9712
avio: add avio_tell macro as a replacement for url_ftell
...
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
14 years ago
Anton Khirnov
74b3f67c9c
lavf: replace all uses of url_fskip with avio_seek
...
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
(cherry picked from commit e356fc57a2
)
14 years ago