Package com.datalogics.PDFL
Class PageImageParams
java.lang.Object
com.datalogics.PDFL.PageImageParams
Used to manage converting a PDF page to an image. The Page Image Parameters are a set of parameters used to control converting a PDF page to an image, such as a PNG, JPG, or BMP. The parameters include pixel height invalid input: '&' width, color space, resolution, so on.
-
Constructor Summary
ConstructorsConstructorDescriptionPageImageParams(ColorSpace ColorSpace, EnumSet<SmoothFlags> Smoothing, int PixelWidth, int PixelHeight, double HorizontalResolution, double VerticalResolution, EnumSet<DrawFlags> PageDrawFlags) Set up the parameters for rendering a PDF page to an image. -
Method Summary
Modifier and TypeMethodDescriptionvoiddelete()booleanThe BlackPointCompensation desired (default is true if not explicitly set)booleanThe BypassCopyPerm allows to bypass copy permitions.booleanSets if Device spaces should be treated as calibrated to the associated working profile (when true), otherwise it treats them as uncalibrated (when false) when printing.doubleThe desired horizontal resolution in pixels/inch of the output image.Gets the ICC Profile of the colorspace to be used for rendering from a known value.Gets the ICC Profile of the colorspace to be used for rendering from a custom file path.The ColorSpace used in exporting a PDF page to an imagethe DrawFlags used or rendering a PDF page to an image.intThe height in pixels of the image to be created from a PDF page.intThe width in pixels of the image to be created from a PDF page.The RenderIntent used to specify color translation for colors outside gamut of the color profile used.The SmoothFlags used in exporting a PDF page to an imagebooleanThe ThinLineHeuristics used to determine whether thin lines will be fattened non-linearly or the stroke adjust will be applied to thin rectangles.booleanGets the UseDeviceNForImageSeparations setting, which indicates when the GetImageSeparations() method is called if a DeviceN colorspace will be used for rasterization. When false, if only Process colorants are provided to GetImageSeparations() then it's rendered using DeviceCMYK. When true, then it's rendered using DeviceN.doubleThe desired vertical resolution in pixels/inch of the output image.voidsetBlackPointCompensation(boolean arg0) voidsetBypassCopyPerm(boolean value) voidsetCalibrateDeviceSpacesWhenPrinting(boolean value) voidsetHorizontalResolution(double arg0) voidsetICCProfile(ColorProfile colorProfile) Sets the ICC Profile of the colorspace to be used for rendering to a known value.voidsetICCProfileCustomPath(String colorProfilePath) Sets the ICC Profile of the colorspace to be used for rendering from a custom file path.voidvoidsetPageDrawFlags(EnumSet<DrawFlags> arg0) voidsetPixelHeight(int arg0) voidsetPixelWidth(int arg0) voidsetRenderIntent(RenderIntent arg0) voidsetSmoothing(EnumSet<SmoothFlags> smoothflag) voidsetThinLineHeuristics(boolean arg0) voidsetUseDeviceNForImageSeparations(boolean value) Sets the UseDeviceNForImageSeparations setting, which indicates when GetImageSeparations() is called if a DeviceN colorspace will be used for rasterization. When false, if only Process colorants are provided to GetImageSeparations() then it's rendered using DeviceCMYK. When true, then it's rendered using DeviceN. NOTE: This member is only applicable when calling the GetImageSeparations() method, only when Colorants used are only Process.voidsetVerticalResolution(double arg0)
-
Constructor Details
-
PageImageParams
public PageImageParams() -
PageImageParams
public PageImageParams(ColorSpace ColorSpace, EnumSet<SmoothFlags> Smoothing, int PixelWidth, int PixelHeight, double HorizontalResolution, double VerticalResolution, EnumSet<DrawFlags> PageDrawFlags) Set up the parameters for rendering a PDF page to an image. Horizontal and Vertical Resolution have to be either both zero or both non-zero.- Parameters:
ColorSpace- The desired color space for the image, DEVICERGB, DEVICECMYK or DEVICEGRAY only.Smoothing- Indicates what parts of PDF Page (text, image, art, none) are to be smoothed in rendering to an image. Note these flags can be or'd togetherPixelWidth- The desired witdth in pixels of the output image.PixelHeight- The desired height in pixels of the output image.HorizontalResolution- The desired horizontal resolution in pixels/inch of the output image. If you pass in 0.0, 300.0 dpi is used.VerticalResolution- The desired vertical resolution in pixels/inch of the output image. If you pass in 0.0, 300.0 dpi is used.PageDrawFlags- An OR of the flags from DrawFlags which control how the PDF page is to be drawn.
-
-
Method Details
-
delete
public void delete() -
getImageColorSpace
The ColorSpace used in exporting a PDF page to an image -
setImageColorSpace
-
getSmoothing
The SmoothFlags used in exporting a PDF page to an image -
setSmoothing
-
getPixelWidth
public int getPixelWidth()The width in pixels of the image to be created from a PDF page. -
setPixelWidth
public void setPixelWidth(int arg0) -
getPixelHeight
public int getPixelHeight()The height in pixels of the image to be created from a PDF page. -
setPixelHeight
public void setPixelHeight(int arg0) -
getHorizontalResolution
public double getHorizontalResolution()The desired horizontal resolution in pixels/inch of the output image. -
setHorizontalResolution
public void setHorizontalResolution(double arg0) -
getVerticalResolution
public double getVerticalResolution()The desired vertical resolution in pixels/inch of the output image. -
setVerticalResolution
public void setVerticalResolution(double arg0) -
getPageDrawFlags
the DrawFlags used or rendering a PDF page to an image. -
setPageDrawFlags
-
getRenderIntent
The RenderIntent used to specify color translation for colors outside gamut of the color profile used. -
setRenderIntent
-
getBlackPointCompensation
public boolean getBlackPointCompensation()The BlackPointCompensation desired (default is true if not explicitly set) -
setBlackPointCompensation
public void setBlackPointCompensation(boolean arg0) -
getThinLineHeuristics
public boolean getThinLineHeuristics()The ThinLineHeuristics used to determine whether thin lines will be fattened non-linearly or the stroke adjust will be applied to thin rectangles. return true if thin line heuristics are applied, false otherwise. -
setThinLineHeuristics
public void setThinLineHeuristics(boolean arg0) -
getBypassCopyPerm
public boolean getBypassCopyPerm()The BypassCopyPerm allows to bypass copy permitions.- Returns:
- true if this option is turned on.
-
setBypassCopyPerm
public void setBypassCopyPerm(boolean value) -
getCalibrateDeviceSpacesWhenPrinting
public boolean getCalibrateDeviceSpacesWhenPrinting()Sets if Device spaces should be treated as calibrated to the associated working profile (when true), otherwise it treats them as uncalibrated (when false) when printing.- Returns:
- true if this option is turned on.
-
setCalibrateDeviceSpacesWhenPrinting
public void setCalibrateDeviceSpacesWhenPrinting(boolean value) -
getICCProfile
Gets the ICC Profile of the colorspace to be used for rendering from a known value.NOTE: The ICCProfileCustomPath must not be set for this property to be used. The profile must be compatible with the ColorSpace property value, which can't be set to ICCBased either.
-
setICCProfile
Sets the ICC Profile of the colorspace to be used for rendering to a known value.NOTE: The ICCProfileCustomPath must not be set for this property to be used. The profile must be compatible with the ColorSpace property value, which can't be set to ICCBased either.
-
getICCProfileCustomPath
Gets the ICC Profile of the colorspace to be used for rendering from a custom file path.NOTE: The ICCProfile is ignored when this property is a non-empty string. The profile must be compatible with the ColorSpace property value, which can't be set to ICCBased either.
-
setICCProfileCustomPath
Sets the ICC Profile of the colorspace to be used for rendering from a custom file path.NOTE: The ICCProfile is ignored when this property is a non-empty string. The profile must be compatible with the ColorSpace property value, which can't be set to ICCBased either.
-
getUseDeviceNForImageSeparations
public boolean getUseDeviceNForImageSeparations()Gets the UseDeviceNForImageSeparations setting, which indicates when the GetImageSeparations() method is called if a DeviceN colorspace will be used for rasterization. When false, if only Process colorants are provided to GetImageSeparations() then it's rendered using DeviceCMYK. When true, then it's rendered using DeviceN.- Returns:
- true if this option is turned on. NOTE: This member is only applicable when calling the GetImageSeparations() method, only when Colorants used are only Process.
-
setUseDeviceNForImageSeparations
public void setUseDeviceNForImageSeparations(boolean value) Sets the UseDeviceNForImageSeparations setting, which indicates when GetImageSeparations() is called if a DeviceN colorspace will be used for rasterization. When false, if only Process colorants are provided to GetImageSeparations() then it's rendered using DeviceCMYK. When true, then it's rendered using DeviceN. NOTE: This member is only applicable when calling the GetImageSeparations() method, only when Colorants used are only Process.
-