This makes the addition of arch optimized functions easier.
Reviewed-by: Michael Niedermayer <michaelni@gmx.at>
Signed-off-by: James Almer <jamrial@gmail.com>
* commit 'fe4d5fe9361162f9033ff1bd84bfc1b2091ba785':
jpeg2000: Mark static data init functions as av_cold
Conflicts:
libavcodec/jpeg2000.c
libavcodec/jpeg2000dec.c
Merged-by: Michael Niedermayer <michaelni@gmx.at>
Fixes: msan_uninit-mem_7f50b84aac30_6823_mjp2.mov
Fixes use of uninitialized memory
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Fixes out of array reads
Fixes: asan_heap-oob_f0de57_6823_mjp2.mov
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This prevents future frames from using half initialized/inconsistent
structures
Fixes assertion failure
Fixes Ticket2897
Reviewed-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* commit '18a245a2aea31b92bc435f2962a71e060d83b5f7':
jpeg2000dec: Add more checks when parsing headers
The check cannot be true in FFmpeg, but does no harm.
I will move it in a subsequent commit so it can detect missing SIZ
Merged-by: Michael Niedermayer <michaelni@gmx.at>
Some invalid values where not handled correctly in the later pixel
format matching code.
Fixes out of array accesses
Fixes Ticket2848
Found-by: Piotr Bandurski <ami_stuff@o2.pl>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Conflicts:
libavcodec/jpeg2000dec.c
Reviewed-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* commit '22e18ea39e371030cc78973d1b46aae45a7ea215':
jpeg2000: Optimize output sample conversion
jpeg2000: Reset s->numX/Ytiles on tile deallocation
jpeg2000: Optimize dequantization
jpeg2000: Do not assume a single tile
jpeg2000: Speed up jpeg2000_decode_tile()
jpeg2000: Use EBCOT's CAUSAL and BYPASS mode in decode_cblk()
Conflicts:
libavcodec/jpeg2000dec.c
Merged-by: Michael Niedermayer <michaelni@gmx.at>
* commit 'd57c737ac30cf079a342fa649fd4888c2d059dd9':
jpeg2000: Simplify jpeg2000_decode_packets()
jpeg2000: Do not crash on NULL node in tag_tree_decode
jpeg2000: Refactor SOT marker parsing
Conflicts:
libavcodec/jpeg2000dec.c
Merged-by: Michael Niedermayer <michaelni@gmx.at>
* commit '589e5b52f634f6b2d307a167a19eef7e7328cb08':
jpeg2000: Use the correct sizeof in memset for T1 data
jpeg2000: Simplify init_tile()
jpeg2000: Update pixel format support
Conflicts:
libavcodec/jpeg2000dec.c
Merged-by: Michael Niedermayer <michaelni@gmx.at>
* commit '4cbd5ed11b0161a6a192174934b241e0cc0599a9':
jpeg2000: Fix compute precedence error in lut_gain index
jpeg2000: Initialize code blocks structures in precincts to 0
jpeg2000: Check that we have enough components for MCT
Conflicts:
libavcodec/jpeg2000.c
libavcodec/jpeg2000dec.c
Merged-by: Michael Niedermayer <michaelni@gmx.at>
* commit 'fd54dd028bc9f7bfb80ebf823a533dc84b73f936':
jpeg2000: check len before parsing header
jpeg2000: Check component number in get_coc() and get_qcc()
Conflicts:
libavcodec/jpeg2000dec.c
Merged-by: Michael Niedermayer <michaelni@gmx.at>
* commit '278a923c51187d37445d88a6b21082036ec9568d':
jpeg2000: Validate SIZ parsing
Conflicts:
libavcodec/jpeg2000dec.c
This commit is not exactly merged due to bugs in it
Merged-by: Michael Niedermayer <michaelni@gmx.at>