Class BitmapDeindexer
java.lang.Object
com.itextpdf.pdfoptimizer.handlers.imagequality.processors.BitmapDeindexer
- All Implemented Interfaces:
-
IImageProcessor
Class is used to replace Indexed colorspace with appropriate Device colorspace. It should not optimize pdf document but can be used as the first step of optimization process.
- See Also:
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptioncom.itextpdf.kernel.pdf.xobject.PdfImageXObject
processImage
(com.itextpdf.kernel.pdf.xobject.PdfImageXObject objectToProcess, OptimizationSession session) If bitmap image is in Indexed color space the Deindexer will create a representation of the same in based color space.
-
Constructor Details
-
BitmapDeindexer
public BitmapDeindexer()
-
-
Method Details
-
processImage
public com.itextpdf.kernel.pdf.xobject.PdfImageXObject processImage(com.itextpdf.kernel.pdf.xobject.PdfImageXObject objectToProcess, OptimizationSession session) If bitmap image is in Indexed color space the Deindexer will create a representation of the same in based color space. Otherwise will return the original image.- Specified by:
-
processImage
in interfaceIImageProcessor
- Parameters:
-
objectToProcess
- is aPdfImageXObject
representing the image -
session
- is an auxiliary object used to support share data between stages of optimization process - Returns:
- processed image if processing can be performed and the same instance otherwise
-