org.icepdf.core.pobjects.graphics
Class ImageReferenceFactory

java.lang.Object
  extended by org.icepdf.core.pobjects.graphics.ImageReferenceFactory

public class ImageReferenceFactory
extends java.lang.Object

The ImageReferenceFactory determines which implementation of the Image Reference should be created. The ImageReference type can be specified by the following system properties or alternatively by the enum type.

The default value returns an unaltered image, scaled returns a scaled image instance and there MIP mapped returns/picks a scaled image that best fits the current zoom level for a balance of render speed and quality.

Since:
5.0
See Also:
MipMappedImageReference, ImageStreamReference, ScaledImageReference

Nested Class Summary
static class ImageReferenceFactory.ImageReference
           
 
Method Summary
static ImageReference getImageReference(ImageStream imageStream, Resources resources, java.awt.Color fillColor)
          Gets an instance of an ImageReference object for the given image data.
static ImageReferenceFactory.ImageReference getScaleType()
           
static void setScaleType(ImageReferenceFactory.ImageReference scaleType)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getScaleType

public static ImageReferenceFactory.ImageReference getScaleType()

setScaleType

public static void setScaleType(ImageReferenceFactory.ImageReference scaleType)

getImageReference

public static ImageReference getImageReference(ImageStream imageStream,
                                               Resources resources,
                                               java.awt.Color fillColor)
Gets an instance of an ImageReference object for the given image data. The ImageReference is specified by the system property org.icepdf.core.imageReference or by the static instance variable scale type.

Parameters:
imageStream - image data
resources - parent resource object.
fillColor - file colour.
Returns:
newly create ImageReference.