Andreas Rheinhardt
e68247d5cf
avcodec/hqx: Don't check for errors for complete VLCs
...
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
4 years ago
Andreas Rheinhardt
a03caa384f
avcodec/hqx: Inline constants
...
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
4 years ago
Anton Khirnov
1f4cf92cfb
pthread_frame: merge the functionality for normal decoder init and init_thread_copy
...
The current design, where
- proper init is called for the first per-thread context
- first thread's private data is copied into private data for all the
other threads
- a "fixup" function is called for all the other threads to e.g.
allocate dynamically allocated data
is very fragile and hard to follow, so it is abandoned. Instead, the
same init function is used to init each per-thread context. Where
necessary, AVCodecInternal.is_copy can be used to differentiate between
the first thread and the other ones (e.g. for decoding the extradata
just once).
5 years ago
Michael Niedermayer
07519f363b
avcodec/hqx: Check the input data against the image size
...
Fixes: Timeout (22 -> 100 ms)
Fixes: 15173/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_HQX_fuzzer-5662556846292992
Fixes: 17896/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_HQX_fuzzer-5679312077848576
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
5 years ago
Paul B Mahol
20f7872d99
avcodec/hqx: add support for frame threads
...
Signed-off-by: Paul B Mahol <onemda@gmail.com>
8 years ago
Clément Bœsch
549045254c
Fix all -Wformat warnings raised by DJGPP
8 years ago
Diego Biurrun
0b77a59336
Use correct printf conversion specifiers for POSIX integer types
8 years ago
Alexandra Hájková
1df549bfa2
hqx: Convert to the new bitstream header
...
Signed-off-by: Anton Khirnov <anton@khirnov.net>
8 years ago
Andreas Cadhalpun
1ed7fcd42a
hqx: correct type and size check of info_offset
...
It is used as size argument of ff_canopus_parse_info_tag, which uses it
as size argument to bytestream2_init, which only supports sizes up to
INT_MAX.
Changing it's type to unsigned simplifies the check.
Reviewed-by: Vittorio Giovara <vittorio.giovara@gmail.com>
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
9 years ago
Andreas Cadhalpun
9fd2bf09db
hqx: correct type and size check of info_offset
...
It is used as size argument of ff_canopus_parse_info_tag, which uses it
as size argument to bytestream2_init, which only supports sizes up to
INT_MAX.
Changing it's type to unsigned simplifies the check.
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
9 years ago
Vittorio Giovara
def97856de
lavc: AV-prefix all codec capabilities
...
Express bitfields more simply.
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
10 years ago
Vittorio Giovara
bb428e00ac
hqx: Mark codec as init-thread-safe and init-cleanup
10 years ago
Vittorio Giovara
e6fb844f7b
Implement shared parsing of INFO tag in Canopus family
...
Add some bounds checking to CLLC; reduce HQX variable scoping,
add an error message.
10 years ago
Vittorio Giovara
5b5338f6d1
hqx: Implement slice-threaded decoding
...
Inspired by a patch from Ferdinand Oeinck <ferdo@demon.nl>.
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
10 years ago
Vittorio Giovara
453642f8af
hqx: Store shareable data in main decoder context
...
In preparation for multithreaded decoding.
10 years ago
Vittorio Giovara
ea031b75fb
hqx: Move DSP related code to a separate file
10 years ago
Vittorio Giovara
17aa81d947
hqx: Merge invalid format check within switch block
10 years ago
Michael Niedermayer
599dc8fee1
avcodec/hqx: Use av_clip_uintp2()
...
Suggested-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
10 years ago
Ferdinand Oeinck
eff72a6c73
libavcodec/hqx: multi threading support
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
10 years ago
Ferdinand Oeinck
0266988ccd
hqx: Fix clipping error in idct put function
...
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
10 years ago
ferdo@bigroses.nl
92f94fd5dd
libavcodec/hqx: correct clipping error
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
10 years ago
Paul B Mahol
aa7a2fa58f
avcodec/hqx: use init_get_bits8()
...
Signed-off-by: Paul B Mahol <onemda@gmail.com>
10 years ago
Paul B Mahol
5440076303
avcodec/hqx: fix typo
...
Signed-off-by: Paul B Mahol <onemda@gmail.com>
10 years ago
Paul B Mahol
665916ffa2
avcodec/hqx: remove superfluous log message
...
Signed-off-by: Paul B Mahol <onemda@gmail.com>
10 years ago
Vittorio Giovara
35c6ce76b1
Canopus HQX decoder
...
Based on work by Kostya Shishkov <kostya.shishkov@gmail.com>.
10 years ago