Package com.itextpdf.io.codec
Class Jbig2SegmentReader
java.lang.Object
com.itextpdf.io.codec.Jbig2SegmentReader
Class to read a JBIG2 file at a basic level: understand all the segments, understand what segments belong to which pages, how many pages there are, what the width and height of each page is, and global segments if there are any. Or: the minimum required to be able to take a normal sequential or random-access organized file, and be able to embed JBIG2 pages as images in a PDF.
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic class
Inner class that holds information about a JBIG2 page.static class
Inner class that holds information about a JBIG2 segment. -
Field Summary
Modifier and TypeFieldDescriptionstatic final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic byte[]
copyByteArray
(byte[] b) byte[]
getGlobal
(boolean for_embedding) getPage
(int page) int
getPageHeight
(int i) int
getPageWidth
(int i) int
void
read()
toString()
-
Field Details
-
SYMBOL_DICTIONARY
public static final int SYMBOL_DICTIONARY- See Also:
-
INTERMEDIATE_TEXT_REGION
public static final int INTERMEDIATE_TEXT_REGION- See Also:
-
IMMEDIATE_TEXT_REGION
public static final int IMMEDIATE_TEXT_REGION- See Also:
-
IMMEDIATE_LOSSLESS_TEXT_REGION
public static final int IMMEDIATE_LOSSLESS_TEXT_REGION- See Also:
-
PATTERN_DICTIONARY
public static final int PATTERN_DICTIONARY- See Also:
-
INTERMEDIATE_HALFTONE_REGION
public static final int INTERMEDIATE_HALFTONE_REGION- See Also:
-
IMMEDIATE_HALFTONE_REGION
public static final int IMMEDIATE_HALFTONE_REGION- See Also:
-
IMMEDIATE_LOSSLESS_HALFTONE_REGION
public static final int IMMEDIATE_LOSSLESS_HALFTONE_REGION- See Also:
-
INTERMEDIATE_GENERIC_REGION
public static final int INTERMEDIATE_GENERIC_REGION- See Also:
-
IMMEDIATE_GENERIC_REGION
public static final int IMMEDIATE_GENERIC_REGION- See Also:
-
IMMEDIATE_LOSSLESS_GENERIC_REGION
public static final int IMMEDIATE_LOSSLESS_GENERIC_REGION- See Also:
-
INTERMEDIATE_GENERIC_REFINEMENT_REGION
public static final int INTERMEDIATE_GENERIC_REFINEMENT_REGION- See Also:
-
IMMEDIATE_GENERIC_REFINEMENT_REGION
public static final int IMMEDIATE_GENERIC_REFINEMENT_REGION- See Also:
-
IMMEDIATE_LOSSLESS_GENERIC_REFINEMENT_REGION
public static final int IMMEDIATE_LOSSLESS_GENERIC_REFINEMENT_REGION- See Also:
-
PAGE_INFORMATION
public static final int PAGE_INFORMATION- See Also:
-
END_OF_PAGE
public static final int END_OF_PAGE- See Also:
-
END_OF_STRIPE
public static final int END_OF_STRIPE- See Also:
-
END_OF_FILE
public static final int END_OF_FILE- See Also:
-
PROFILES
public static final int PROFILES- See Also:
-
TABLES
public static final int TABLES- See Also:
-
EXTENSION
public static final int EXTENSION- See Also:
-
-
Constructor Details
-
Jbig2SegmentReader
-
-
Method Details
-
copyByteArray
public static byte[] copyByteArray(byte[] b) -
read
- Throws:
-
IOException
-
numberOfPages
public int numberOfPages() -
getPageHeight
public int getPageHeight(int i) -
getPageWidth
public int getPageWidth(int i) -
getPage
-
getGlobal
public byte[] getGlobal(boolean for_embedding) -
toString
-