Details
-
Type: Bug
-
Status: Closed
-
Priority: Major
-
Resolution: Fixed
-
Affects Version/s: 5.0
-
Fix Version/s: 5.0.1
-
Component/s: Core/Parsing
-
Labels:None
-
Environment:any
-
Salesforce Case Reference:
Description
There is a regression in ImageStream where the system property org.icepdf.core.ccittfax.jai=true is not correctly being applied.
The basic issue is as follows:
try {
// corner case where a user may want to use JAI because of
// speed or compatibility requirements.
if (forceJaiccittfax) {
throw new Throwable("Forcing CCITTFAX decode via JAI");
}
data = ccittFaxDecode(data, width, height);
dataLength = data.length;
} catch (Throwable e) {
// on a failure then fall back to JAI for a try. likely
// will not happen.
if (Tagger.tagging) {
Tagger.tagImage("CCITTFaxDecode JAI");
}
decodedImage = CCITTFax.attemptDeriveBufferedImageFromBytes(
this, library, entries, fill);
}
If the system property is true then we throw an exception and make the CCITTFax.attemptDeriveBufferedImageFromBytes() call but we never return the decodedImage an hens the problem.
The basic issue is as follows:
try {
// corner case where a user may want to use JAI because of
// speed or compatibility requirements.
if (forceJaiccittfax) {
throw new Throwable("Forcing CCITTFAX decode via JAI");
}
data = ccittFaxDecode(data, width, height);
dataLength = data.length;
} catch (Throwable e) {
// on a failure then fall back to JAI for a try. likely
// will not happen.
if (Tagger.tagging) {
Tagger.tagImage("CCITTFaxDecode JAI");
}
decodedImage = CCITTFax.attemptDeriveBufferedImageFromBytes(
this, library, entries, fill);
}
If the system property is true then we throw an exception and make the CCITTFax.attemptDeriveBufferedImageFromBytes() call but we never return the decodedImage an hens the problem.
Activity
- All
- Comments
- History
- Activity
- Remote Attachments
- Subversion
Updated the ImageStream to correctly return the decoded jai image.