Mako 8.3.0 API
MakoCore SDK API Documentation
Loading...
Searching...
No Matches
JawsMako::IImageUpsamplerTransform Class Referenceabstract

A transform for upsampling images below a given effective resolution to a desired target effective resolution. More...

#include <jawsmako/transforms.h>

Inheritance diagram for JawsMako::IImageUpsamplerTransform:
[legend]

Public Member Functions

virtual void setColorUpsamplingMethod (IDOMImageUpsamplerFilter::eUpsamplingMethod method)=0
 Set the desired upsampling method for color images. The default is bicubic.
virtual void setGrayUpsamplingMethod (IDOMImageUpsamplerFilter::eUpsamplingMethod method)=0
 Set the desired upsampling method for gray images The default is bicubic.
virtual void setMonoUpsamplingMethod (IDOMImageUpsamplerFilter::eUpsamplingMethod method)=0
 Set the desired upsampling method for monochrome images. The result will always be a gray image. The default is bicubic.
virtual void setTargetResolution (float resolution)=0
 Set a blanket target resolution (dpi) for upsampling all images. This will also set the threshold resolution to the same value.
virtual void setThresholdResolution (float resolution)=0
 Set a blanket threshold resolution (dpi) for upsampling all images. Only images with an effective resolution lower than this value will be upsampled.
virtual void setColorTargetResolution (float resolution)=0
 Set a target resolution (dpi) for upsampling color images. This will also set the threshold resolution to the same value. Setting this to 0.0 will result in no upsampling for this image type. The default is 0.0.
virtual void setColorThresholdResolution (float resolution)=0
 Set a threshold resolution (dpi) for upsampling color images. Only images with an effective resolution lower than this value will be upsampled.
virtual void setGrayTargetResolution (float resolution)=0
 Set a target resolution (dpi) for upsampling gray images. This will also set the threshold resolution to the same value. Setting this to 0.0 will result in no upsampling for this image type. The default is 0.0.
virtual void setGrayThresholdResolution (float resolution)=0
 Set a threshold resolution (dpi) for upsampling gray images. Only images with an effective resolution lower than this value will be upsampled.
virtual void setMonoTargetResolution (float resolution)=0
 Set a target resolution (dpi) for upsampling monochrome images. This will also set the threshold resolution to the same value. Setting this to 0.0 will result in no upsampling for this image type. The default is 0.0.
virtual void setMonoThresholdResolution (float resolution)=0
 Set a threshold resolution (dpi) for upsampling monochrome images. Only images with an effective resolution lower than this value will be upsampled.
virtual void setUpsampleMaskedImages (bool upsampleMaskedImages)=0
 Set whether to upsample masked images.
virtual void setUseMaskResolutionForMaskedImages (bool useMaskResolutionSettingForMaskedImages)=0
 Set whether or not the mask resolution setting should be applied to the image portion of a masked image.
virtual void setUseFloatingPointResolutions (bool useFloatingPointResolutions)=0
 Set whether or not to force final images to have integer resolutions.
Public Member Functions inherited from JawsMako::ITransform
virtual ~ITransform ()
virtual IDOMBrushPtr transform (const IDOMBrushPtr &brush, eBrushUsage usage=eBUGeneral, const CTransformState &state=CTransformState())=0
 Apply the transform to the given brush, if applicable. These transforms are thread safe.
virtual IDOMImagePtr transform (const IDOMImagePtr &image, const CTransformState &state=CTransformState())=0
 Apply the transform to the given image, if applicable. These transforms are thread safe.
virtual IDOMColorPtr transform (const IDOMColorPtr &color, const CTransformState &state=CTransformState())=0
 Apply the transform to the given color, if applicable. These transforms are thread safe.
virtual IDOMColorSpacePtr transform (const IDOMColorSpacePtr &colorSpace, const CTransformState &state=CTransformState())=0
 Apply the transform to the given color space, if applicable. These transforms are thread safe.
virtual IDOMNodePtr transform (const IDOMNodePtr &node, bool &changed, bool transformChildren=true, const CTransformState &state=CTransformState())=0
 Apply the transform to the given node, if applicable. These transforms are thread safe, providing no other transforms are being applied to the same nodes at the same time.
virtual void transformPage (const IPagePtr &page, bool transformContent=true, bool transformAnnotations=true)=0
 Apply the transform to the given page, if applicable. These transforms are thread safe, providing no other transforms are being applied to the same nodes at the same time. The transform will also apply to the annotations appearances.
virtual void flushCaches ()=0
 Flush the caches used by the transform. Most transforms cache recently transformed results to improve the performance of repeated transformations of equivalent results. However, it is possible that some cached results may point to entities that no longer exist, such as content inside an XPS file that no longer exists. If you are deleting or replacing files where transforms have been used, it is advisable to invoke this routine to clear the caches.
virtual void setProgressMonitor (const IProgressMonitorPtr &progressMonitor)=0
 Set the IProgressMonitor object for this transform to allow for monitoring the progress of the transform.
Public Member Functions inherited from IRCObject
virtual void addRef () const =0
 Increases the reference count of the actual object pointed to. This would take place during an assignment or copying.
virtual bool decRef () const =0
 Decreases the reference count of the actual object pointed to. When the reference count falls to Zero, it deletes the actual object pointed to.
virtual int32 getRefCount () const =0
 Retrieve the current reference count of the actual object pointed to.

Static Public Member Functions

static JAWSMAKO_API IImageUpsamplerTransformPtr create (const IJawsMakoPtr &jawsMako, const IProgressMonitorPtr &progressMonitor=IProgressMonitorPtr())
 Create the transform.

Additional Inherited Members

Protected Member Functions inherited from IRCObject
virtual ~IRCObject ()
 Virtual destructor.

Detailed Description

A transform for upsampling images below a given effective resolution to a desired target effective resolution.

Please note that images inside uncolored tiling patterns cannot be upsampled, as this transform will upsample mono images to grayscale.

Member Function Documentation

◆ create()

JAWSMAKO_API IImageUpsamplerTransformPtr JawsMako::IImageUpsamplerTransform::create ( const IJawsMakoPtr & jawsMako,
const IProgressMonitorPtr & progressMonitor = IProgressMonitorPtr() )
static

Create the transform.

Parameters
jawsMakoThe JawsMako instance.
progressMonitorA progress monitor for cancelling, and monitoring the job progress.
Returns
IImageUpsamplerTransformPtr The new instance.

◆ setColorTargetResolution()

virtual void JawsMako::IImageUpsamplerTransform::setColorTargetResolution ( float resolution)
pure virtual

Set a target resolution (dpi) for upsampling color images. This will also set the threshold resolution to the same value. Setting this to 0.0 will result in no upsampling for this image type. The default is 0.0.

Parameters
resolutionThe target resolution, in dpi.

◆ setColorThresholdResolution()

virtual void JawsMako::IImageUpsamplerTransform::setColorThresholdResolution ( float resolution)
pure virtual

Set a threshold resolution (dpi) for upsampling color images. Only images with an effective resolution lower than this value will be upsampled.

Parameters
resolutionThe threshold resolution, in dpi.

◆ setColorUpsamplingMethod()

virtual void JawsMako::IImageUpsamplerTransform::setColorUpsamplingMethod ( IDOMImageUpsamplerFilter::eUpsamplingMethod method)
pure virtual

Set the desired upsampling method for color images. The default is bicubic.

Parameters
methodThe upsampling method to apply.

◆ setGrayTargetResolution()

virtual void JawsMako::IImageUpsamplerTransform::setGrayTargetResolution ( float resolution)
pure virtual

Set a target resolution (dpi) for upsampling gray images. This will also set the threshold resolution to the same value. Setting this to 0.0 will result in no upsampling for this image type. The default is 0.0.

Parameters
resolutionThe target resolution, in dpi.

◆ setGrayThresholdResolution()

virtual void JawsMako::IImageUpsamplerTransform::setGrayThresholdResolution ( float resolution)
pure virtual

Set a threshold resolution (dpi) for upsampling gray images. Only images with an effective resolution lower than this value will be upsampled.

Parameters
resolutionThe threshold resolution, in dpi.

◆ setGrayUpsamplingMethod()

virtual void JawsMako::IImageUpsamplerTransform::setGrayUpsamplingMethod ( IDOMImageUpsamplerFilter::eUpsamplingMethod method)
pure virtual

Set the desired upsampling method for gray images The default is bicubic.

Parameters
methodThe upsampling method to apply.

◆ setMonoTargetResolution()

virtual void JawsMako::IImageUpsamplerTransform::setMonoTargetResolution ( float resolution)
pure virtual

Set a target resolution (dpi) for upsampling monochrome images. This will also set the threshold resolution to the same value. Setting this to 0.0 will result in no upsampling for this image type. The default is 0.0.

Parameters
resolutionThe target resolution, in dpi.

◆ setMonoThresholdResolution()

virtual void JawsMako::IImageUpsamplerTransform::setMonoThresholdResolution ( float resolution)
pure virtual

Set a threshold resolution (dpi) for upsampling monochrome images. Only images with an effective resolution lower than this value will be upsampled.

Parameters
resolutionThe threshold resolution, in dpi.

◆ setMonoUpsamplingMethod()

virtual void JawsMako::IImageUpsamplerTransform::setMonoUpsamplingMethod ( IDOMImageUpsamplerFilter::eUpsamplingMethod method)
pure virtual

Set the desired upsampling method for monochrome images. The result will always be a gray image. The default is bicubic.

Parameters
methodThe upsampling method to apply.

◆ setTargetResolution()

virtual void JawsMako::IImageUpsamplerTransform::setTargetResolution ( float resolution)
pure virtual

Set a blanket target resolution (dpi) for upsampling all images. This will also set the threshold resolution to the same value.

Parameters
resolutionThe upsampling resolution in dpi.

◆ setThresholdResolution()

virtual void JawsMako::IImageUpsamplerTransform::setThresholdResolution ( float resolution)
pure virtual

Set a blanket threshold resolution (dpi) for upsampling all images. Only images with an effective resolution lower than this value will be upsampled.

Parameters
resolutionThe threshold resolution, in dpi.

◆ setUpsampleMaskedImages()

virtual void JawsMako::IImageUpsamplerTransform::setUpsampleMaskedImages ( bool upsampleMaskedImages)
pure virtual

Set whether to upsample masked images.

This applies to cases where an image is masked by a separate masked image, such as types of PDF masked or soft-masked images. These are represented in the DOM using IDOMMaskedBrush, where the sub-brush is an image.

The default is true.

Parameters
upsampleMaskedImagesTrue or False

◆ setUseFloatingPointResolutions()

virtual void JawsMako::IImageUpsamplerTransform::setUseFloatingPointResolutions ( bool useFloatingPointResolutions)
pure virtual

Set whether or not to force final images to have integer resolutions.

Unlike IImageDownsamplerTransform, the default is true.

Not all image formats can store floating point resolutions, and as such the transform can emit integer resolutions to prevent scaling issues for PDLs or formats where this is not supported.

Setting this to true will result in the use of floating point resolutions, and should be used with care. However, for formats such as PDF where fractional dpi settings are supported, doing so may result in an effective dpi setting for the downsampled image that is closer to the desired result.

Note
The resolution that is set in the images is not normally the requested resolution, as the requested resolution is relative to the page, while the image resolution is local to the image and will be set based on how each image is scaled.
Parameters
useFloatingPointResolutionsTrue or False

◆ setUseMaskResolutionForMaskedImages()

virtual void JawsMako::IImageUpsamplerTransform::setUseMaskResolutionForMaskedImages ( bool useMaskResolutionSettingForMaskedImages)
pure virtual

Set whether or not the mask resolution setting should be applied to the image portion of a masked image.

This applies to cases where an image is masked by a separate masked image, such as types of PDF masked or soft-masked images. These are represented in the DOM using IDOMMaskedBrush, where the sub-brush is an image.

If false, then the mask and the image are evaluated separately and an upsampling resolution and threshold are chosen. For the mask, this is normally either grayscale or monochrome. The image data can be anything. In this mode it is possible for the upsampled image and mask to be upsampled to different resolutions.

If true, then whatever target resolution and threshold is applied to the mask will also be applied to the image samples. If these images have the same effective resolution before upsampling, then they will also share the same effective resolution after upsampling.

The default is false.

Parameters
useMaskResolutionSettingForMaskedImagesTrue or False

The documentation for this class was generated from the following file: