Bug 696825

Summary: Luratech jbig2 image decoding fails where jbig2dec succeeds
Product: Ghostscript Reporter: Sebastian Rasmussen <sebastian.rasmussen>
Component: JPX/JBIG2 encode/decodeAssignee: Shailesh Mistry <shailesh.mistry>
Status: RESOLVED WONTFIX    
Severity: enhancement CC: henry.stiles
Priority: P4    
Version: master   
Hardware: PC   
OS: Linux   
Customer: Word Size: ---

Description Sebastian Rasmussen 2016-06-06 07:51:25 UTC
I have confirmed this by building gs using both luratech and jbig2dec. When image decoding fails a blank white page is shown.

The PDF-files with the Jbig2 images in question are:
Jbig2_042_21.pdf
Jbig2_042_22.pdf
Jbig2_042_23.pdf
Jbig2_042_24.pdf
jbig2dec_memory_leak.pdf
Comment 1 Henry Stiles 2016-07-05 06:40:01 UTC
Here is a response from Luratech, we can just leave the problem open as a P4 enhancement.  I changed the status of the bug.


All the files do contain segments of types we do not yet support, namely Intermediate Text Regions and Generic Refinement Regions. If a JBIG2 stream contains unsupported regions can be checked in advance by calling JB2_Document_Get_Property() for cJB2_Prop_All_Regions_Supported. If you try to render the page anyway you will get a return code from JB2_Document_Decompress_Page() which is cJB2_Error_Not_Yet_Supported. You could set the property cJB2_Prop_Decoder_Tolerance to force the SDK do decode whatever it can but this will only result in a blank page in these cases, because the actual content is contained in the not supported segments.
 
We plan to add support for such seldom used segment types but there is no definitive schedule yet.
Comment 2 Henry Stiles 2021-01-11 16:34:03 UTC
Luratech support discontinued.