javax.media.jai.operator
Class TransposeDescriptor

java.lang.Object
  extended byjavax.media.jai.OperationDescriptorImpl
      extended byjavax.media.jai.operator.TransposeDescriptor
All Implemented Interfaces:
OperationDescriptor, RegistryElementDescriptor, Serializable

public class TransposeDescriptor
extends OperationDescriptorImpl

An OperationDescriptor describing the "Transpose" operation.

The "Transpose" operation performs the following operations:

In all cases, the resulting image will have the same origin (as defined by the return values of its getMinX() and getMinY() methods) as the source image.

It should be noted that this operation automatically adds a value of Boolean.TRUE for the JAI.KEY_REPLACE_INDEX_COLOR_MODEL to the given configuration so that the operation is performed on the pixel values instead of being performed on the indices into the color map if the source(s) have an IndexColorModel. This addition will take place only if a value for the JAI.KEY_REPLACE_INDEX_COLOR_MODEL has not already been provided by the user. Note that the configuration Map is cloned before the new hint is added to it. The operation can be smart about the value of the JAI.KEY_REPLACE_INDEX_COLOR_MODEL RenderingHints, i.e. while the default value for the JAI.KEY_REPLACE_INDEX_COLOR_MODEL is Boolean.TRUE, in some cases the operator could set the default.

"Transpose" defines a PropertyGenerator that performs an identical transformation on the "ROI" property of the source image, which can be retrieved by calling the getProperty method with "ROI" as the property name.

Resource List
Name Value
GlobalName transpose
LocalName transpose
Vendor com.sun.media.jai
Description Reflects an image in a specified direction or rotates an image in multiples of 90 degrees.
DocURL http://java.sun.com/products/java-media/jai/forDevelopers/jai-apidocs/javax/media/jai/operator/TransposeDescriptor.html
Version 1.0
arg0Desc The type of flip operation to be performed.

Parameter List
Name Class Type Default Value
type javax.media.jai.operator.TransposeType NO_PARAMETER_DEFAULT

See Also:
OperationDescriptor, TransposeType, Serialized Form

Field Summary
static TransposeType FLIP_ANTIDIAGONAL
           
static TransposeType FLIP_DIAGONAL
           
static TransposeType FLIP_HORIZONTAL
           
static TransposeType FLIP_VERTICAL
           
static TransposeType ROTATE_180
           
static TransposeType ROTATE_270
           
static TransposeType ROTATE_90
           
 
Fields inherited from class javax.media.jai.OperationDescriptorImpl
sourceNames, supportedModes
 
Fields inherited from interface javax.media.jai.OperationDescriptor
NO_PARAMETER_DEFAULT
 
Constructor Summary
TransposeDescriptor()
          Constructor.
 
Method Summary
static RenderedOp create(RenderedImage source0, TransposeType type, RenderingHints hints)
          Reflects an image in a specified direction or rotates an image in multiples of 90 degrees.
static RenderableOp createRenderable(RenderableImage source0, TransposeType type, RenderingHints hints)
          Reflects an image in a specified direction or rotates an image in multiples of 90 degrees.
 PropertyGenerator[] getPropertyGenerators()
          Returns an array of PropertyGenerators implementing property inheritance for the "Transpose" operation.
 boolean isRenderableSupported()
          Returns true since renderable operation is supported.
 
Methods inherited from class javax.media.jai.OperationDescriptorImpl
arePropertiesSupported, getDefaultSourceClass, getDestClass, getDestClass, getInvalidRegion, getName, getNumParameters, getNumSources, getParamClasses, getParamDefaults, getParamDefaultValue, getParameterListDescriptor, getParamMaxValue, getParamMinValue, getParamNames, getPropertyGenerators, getRenderableDestClass, getRenderableSourceClasses, getResourceBundle, getResources, getSourceClasses, getSourceClasses, getSourceNames, getSupportedModes, isImmediate, isModeSupported, isRenderedSupported, makeDefaultSourceClassList, validateArguments, validateArguments, validateParameters, validateParameters, validateRenderableArguments, validateRenderableSources, validateSources, validateSources
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

FLIP_VERTICAL

public static final TransposeType FLIP_VERTICAL

FLIP_HORIZONTAL

public static final TransposeType FLIP_HORIZONTAL

FLIP_DIAGONAL

public static final TransposeType FLIP_DIAGONAL

FLIP_ANTIDIAGONAL

public static final TransposeType FLIP_ANTIDIAGONAL

ROTATE_90

public static final TransposeType ROTATE_90

ROTATE_180

public static final TransposeType ROTATE_180

ROTATE_270

public static final TransposeType ROTATE_270
Constructor Detail

TransposeDescriptor

public TransposeDescriptor()
Constructor.

Method Detail

isRenderableSupported

public boolean isRenderableSupported()
Returns true since renderable operation is supported.

Specified by:
isRenderableSupported in interface OperationDescriptor
Overrides:
isRenderableSupported in class OperationDescriptorImpl
See Also:
OperationDescriptorImpl.isModeSupported(java.lang.String)

getPropertyGenerators

public PropertyGenerator[] getPropertyGenerators()
Returns an array of PropertyGenerators implementing property inheritance for the "Transpose" operation.

Specified by:
getPropertyGenerators in interface OperationDescriptor
Overrides:
getPropertyGenerators in class OperationDescriptorImpl
Returns:
An array of property generators.
See Also:
OperationDescriptorImpl.getPropertyGenerators(java.lang.String)

create

public static RenderedOp create(RenderedImage source0,
                                TransposeType type,
                                RenderingHints hints)
Reflects an image in a specified direction or rotates an image in multiples of 90 degrees.

Creates a ParameterBlockJAI from all supplied arguments except hints and invokes JAI.create(String,ParameterBlock,RenderingHints).

Parameters:
source0 - RenderedImage source 0.
type - The The type of flip operation to be performed.
hints - The RenderingHints to use. May be null.
Returns:
The RenderedOp destination.
Throws:
IllegalArgumentException - if source0 is null.
IllegalArgumentException - if type is null.
See Also:
JAI, ParameterBlockJAI, RenderedOp

createRenderable

public static RenderableOp createRenderable(RenderableImage source0,
                                            TransposeType type,
                                            RenderingHints hints)
Reflects an image in a specified direction or rotates an image in multiples of 90 degrees.

Creates a ParameterBlockJAI from all supplied arguments except hints and invokes JAI.createRenderable(String,ParameterBlock,RenderingHints).

Parameters:
source0 - RenderableImage source 0.
type - The The type of flip operation to be performed.
hints - The RenderingHints to use. May be null.
Returns:
The RenderableOp destination.
Throws:
IllegalArgumentException - if source0 is null.
IllegalArgumentException - if type is null.
See Also:
JAI, ParameterBlockJAI, RenderableOp