summaryrefslogtreecommitdiff
path: root/src/bin/jp2/opj_decompress.c
AgeCommit message (Collapse)Author
2023-03-09CMake: error out on warnings for strict/missing prototypes.Sebastian Rasmussen
And fix strict-prototypes/missing-prototypes warnings.
2022-02-10Add support for partial bitstream decoding (#1407) (fixes #715)Robert Gabriel Jakabosky
Add a -allow-partial option to opj_decompress utility and a opj_decoder_set_strict_mode() option to the API Co-authored-by: Chris Hafey <chafey@gmail.com>
2022-01-16Fix unsigned vs OPJ_INT32 mismatches (#1398)Eric Harvey
2022-01-15Added check for integer overflow in get_num_images (#1397)Eharve14
As discussed in pull request 1396, added a check for integer overflow. Change list: Defined num_images as unsigned int Moved the if statement to check for an empty directory to the beginning of the read directory section Added a check to see if num images would roll back to zero when incrementing.
2022-01-13Avoid overflow in multiplications in utilities related to big number of ↵Eharve14
files in a directory (CVE-2021-29338) (#1396)
2022-01-12opj_compress/opj_uncompress: fix integer overflow in num_images (#1395)Brad Parham
Includes the fix for CVE-2021-29338 Credit to @kaniini based on #1346 Fixes #1338
2021-12-05Fix some typos (found by codespell)Stefan Weil
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-10-21API: deprecate 'bpp' member in favor of 'prec'Even Rouault
in opj_image_comp and opj_image_comptparm structures. bpp was redundant with prec, and almost never set by the library, except by opj_image_create(). This change should hopefully not impact existing, working, users of the API, which should already have used prec to get things working. Fixes #1379
2021-09-25opj_decompress / opj_dump: accept .jph and .jhc extensions for HTJ2K filesEven Rouault
2021-07-14Fix segfault in src/bin/jp2/opj_decompress.c due to uninitialized pointer ↵xiaoxiaoafeifei
(fixes #1368) (#1369)
2021-06-07Fix various compiler warningsEven Rouault
2021-05-06Import files tiff and yuv(raw) (#1316)Jamaika1
2020-06-30opj_decompress: fix double-free on input directory with mix of valid and ↵Even Rouault
invalid images (CVE-2020-15389) Fixes #1261 Credits to @Ruia-ruia for reporting and analysis.
2019-02-21openjp2/j2k: Report error if all wanted components are not decoded.Sebastian Rasmussen
Previously the caller had to check whether each component data had been decoded. This means duplicating the checking in every user of openjpeg which is unnecessary. If the caller wantes to decode all or a set of, or a specific component then openjpeg ought to error out if it was unable to do so. Fixes #1158.
2018-10-31Fix some potential overflow issues (#1161)Stefan Weil
* Fix some potential overflow issues Put sizeof to the beginning of the multiplication to enforce that size_t instead of smaller integer types is used for the calculation. This fixes warnings from LGTM: Multiplication result may overflow 'unsigned int' before it is converted to 'unsigned long'. It also allows removing some type casts. Signed-off-by: Stefan Weil <sw@weilnetz.de> * Fix code indentation Signed-off-by: Stefan Weil <sw@weilnetz.de>
2018-09-05Fix some typos in code comments and documentationStefan Weil
All typos were found by Codespell. Signed-off-by: Stefan Weil <sw@weilnetz.de>
2017-10-06opj_decompress -h: document -threads ALL_CPUSEven Rouault
2017-09-26Merge pull request #1022 from rouault/partial_component_decodingAntonin Descampe
Add capability to decode only a subset of all components of an image.
2017-09-20opj_decompress: add a warning when -d and -t are used together (#693)Even Rouault
2017-09-19opj_set_decoded_components(): add a provision for a apply_color_transforms ↵Even Rouault
parameter in case we support it in the future
2017-09-19Add capability to decode only a subset of all components of an image.Even Rouault
This adds a opj_set_decoded_components(opj_codec_t *p_codec, OPJ_UINT32 numcomps, const OPJ_UINT32* comps_indices) function, and equivalent "opj_decompress -c compno[,compno]*" option. When specified, neither the MCT transform nor JP2 channel transformations will be applied. Tests added for various combinations of whole image vs tiled-based decoding, full or reduced resolution, use of decode area or not.
2017-08-28Make opj_set_decode_area() and opj_decode() take into account ↵Even Rouault
opj_set_decoded_resolution_factor() (#1006, affect API use) * Better document usage of opj_set_decode_area(), ie expecting coordinates in full resolution/reference grid even if requesting at a lower resolution factor * Make sure that image->comps[].factor is set by opj_set_decode_area() and opj_decode() from the value specified in opj_set_decoded_resolution_factor() * opj_decompress: add 2 environmenet variables to test alternate ways of using the API, namely USE_OPJ_SET_DECODED_RESOLUTION_FACTOR=YES to use opj_set_decoded_resolution_factor() instead of parameters.cp_reduce, and SKIP_OPJ_SET_DECODE_AREA=YES to not call opj_set_decode_area() if -d is not specified.
2017-08-09opj_decompress: document -quiet option, and remove spurious newline outputEven Rouault
2017-07-31Catch images broken by AFLszukw000
2017-07-26opj_decompress: fix null pointer dereference on comps[].data on ↵Even Rouault
id_000167,sig_11,src_006079,op_havoc,rep_4 (#939)
2017-06-21Style fixEven Rouault
2017-06-21Fix mingw related warningsEven Rouault
2017-06-17Fix warning about unused argumentsEven Rouault
2017-05-16Fixed formatting issues ASTYLERussell McOrmond
2017-05-15Quiet mode for opj_decompress via -quiet long parameter.Russell McOrmond
2017-05-09Reformat whole codebase with astyle.options (#128)Even Rouault
2016-09-14Fix some warnings (#838)Matthieu Darbois
Fix warnings introduced by uclouvain/openjpeg#786
2016-05-25opj_decompress: use clock_gettime() instead of getrusage() so as to get the ↵Even Rouault
time spent, and not to the total CPU time
2016-05-25opj_decompress: add a -threads <num_threads> optionEven Rouault
2016-04-29cppcheck fix for openjp2 (#740)julienmalik
2015-11-01opj_decompress: Update error messageStefan Weil
The png format is also supported, so add it to the message. Remove also the unneeded blank character before \n. Signed-off-by: Stefan Weil <sw@weilnetz.de>
2015-10-07Fix warnings for C++Stefan Weil
g++ complains about invalid conversions like these ones: error: invalid conversion from ‘const char*’ to ‘char*’ [-fpermissive] error: invalid conversion from ‘void*’ to ‘opj_precision* {aka opj_prec*}’ [-fpermissive] Signed-off-by: Stefan Weil <sw@weilnetz.de>
2015-09-29Fix typos in comments and stringStefan Weil
Most typos were found by codespell. Signed-off-by: Stefan Weil <sw@weilnetz.de>
2015-09-25Provide safer string copy than strncpymayeut
As per @boxerab suggestion in commit b9ca882749597e4943e609daba1d3c27694fe2ff
2015-09-25Fix resource leakmayeut
2015-09-25Fix resource leaks & unchecked resource allocationsmayeut
2015-09-13Correct leak in color_cielab_to_rgbmayeut
2015-08-21TIFF can output CMYKmayeut
2015-07-30Defines three new functionsszukw000
Declares three new functions Calls the three new functions Collects data for CIELab, sets the color_space for EYCC and CMYK
2015-07-26Remove some warnings when buildingmayeut
Update #442
2015-07-25Remove some warnings when buildingmayeut
Update #442
2015-07-24Remove some warnings when buildingmayeut
Update #442
2015-07-11Add option to force component splitting in imagetopnmmayeut
Update uclouvain/openjpeg#289
2015-07-03fixed a few bugsAaron Boxer
2015-07-03add timing to compress and decompressAaron Boxer