java.lang.Object
org.sejda.sambox.filter.Filter
org.sejda.sambox.filter.JBIG2Filter
Decompresses data encoded using the JBIG2 standard, reproducing the original
monochrome (1 bit per pixel) image data (or an approximation of that data).
Requires a JBIG2 plugin for Java Image I/O to be installed. A known working
plug-in is the Apache PDFBox JBIG2 plugin.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static booleanprivate static final org.slf4j.LoggerFields inherited from class org.sejda.sambox.filter.Filter
SYSPROP_DEFLATELEVEL -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiondecode(InputStream encoded, OutputStream decoded, COSDictionary parameters, int index) Decodes data, producing the original non-encoded data.voidencode(InputStream input, OutputStream encoded, COSDictionary parameters) Encodes data.private static voidMethods inherited from class org.sejda.sambox.filter.Filter
findImageReader, getCompressionLevel, getDecodeParams
-
Field Details
-
LOG
private static final org.slf4j.Logger LOG -
levigoLogged
private static boolean levigoLogged
-
-
Constructor Details
-
JBIG2Filter
JBIG2Filter()
-
-
Method Details
-
logLevigoDonated
private static void logLevigoDonated() -
decode
public DecodeResult decode(InputStream encoded, OutputStream decoded, COSDictionary parameters, int index) throws IOException Description copied from class:FilterDecodes data, producing the original non-encoded data.- Specified by:
decodein classFilter- Parameters:
encoded- the encoded byte streamdecoded- the stream where decoded data will be writtenparameters- the parameters used for decodingindex- the index to the filter being decoded- Returns:
- repaired parameters dictionary, or the original parameters dictionary
- Throws:
IOException- if the stream cannot be decoded
-
encode
Description copied from class:FilterEncodes data.
-