APIdia Launch Partner
Top Description Inners Fields Methods
com.sun.scenario.effect.impl.state

public Interface RenderState

Known Direct Implementers
com.sun.scenario.effect.impl.state.LinearConvolveRenderState
Imports
com.sun.javafx.geom.Rectangle, com.sun.javafx.geom.transform.BaseTransform

A class that encapsulates all of the information needed to plan and execute a single filter operation. An instance of the class is instantiated at the start of an Effect.filter() operation and it is queried for various pieces of information required to perform that operation including, but not limited to, the coordinate space to be used for the child input Effect operations and the coordinate transform to be applied to the resulting final ImageData object produced as the result of that filter operation. Some effect-specific subclasses may also plan and supply information about how the various pixels are to be computed in the inner loops of the effect filter algorithm.

Nested and Inner Type Summary

Modifier and TypeClass and Description
public static enum
RenderState.EffectCoordinateSpace

This enum characterizes the types of coordinate spaces that will be used for the filter operation (i.e. handed to the dependent input Effect objects) and applied to the result of the filter.

Field Summary

Modifier and TypeField and Description
public static final RenderState
RenderSpaceRenderState

A helper implementation of RenderState that handles the case of EffectCoordinateSpace.RenderSpace and passes along the outputClip to the inputs unmodified.

public static final RenderState
UnclippedUserSpaceRenderState

A helper implementation of RenderState that handles the case of EffectCoordinateSpace.UserSpace and passes along the outputClip to the inputs unmodified.

public static final RenderState
UserSpaceRenderState

A helper implementation of RenderState that handles the case of EffectCoordinateSpace.UserSpace and passes along the outputClip to the inputs unmodified.

Method Summary

Modifier and TypeMethod and Description
public RenderState.EffectCoordinateSpace

Returns:

an EffectSpace value to describe the expected output from the getEffectTransform(...) and getResultTransform(...) methods.
getEffectTransformSpace
()

Return a hint indicating which coordinate space should be used for the pixel filtering for this particular filtering operation.

public Rectangle

Returns:

the required rectangle from the indicated input to provide enough pixels to produce the indicated output clip
getInputClip
(int
the index of the input being processed
i
,
Rectangle
the output clip supplied to the given filter operation
filterClip
)

Return the clip for the indicated input based on the indicated output clip.

public BaseTransform

Returns:

the BaseTransform object to use for the input effects
getInputTransform
(BaseTransform
the BaseTransform object for the filter operation
filterTransform
)

Return the transform that should be used to obtain pixel input from the Effect inputs for this filter operation.

public BaseTransform

Returns:

the BaseTransform object to be applied to the result texture
getResultTransform
(BaseTransform
the BaseTransform object for the filter operation
filterTransform
)

Return the transform that should be used to transform the results of the filter operation.

Field Detail

RenderSpaceRenderStateback to summary
public static final RenderState RenderSpaceRenderState

A helper implementation of RenderState that handles the case of EffectCoordinateSpace.RenderSpace and passes along the outputClip to the inputs unmodified.

UnclippedUserSpaceRenderStateback to summary
public static final RenderState UnclippedUserSpaceRenderState

A helper implementation of RenderState that handles the case of EffectCoordinateSpace.UserSpace and passes along the outputClip to the inputs unmodified.

UserSpaceRenderStateback to summary
public static final RenderState UserSpaceRenderState

A helper implementation of RenderState that handles the case of EffectCoordinateSpace.UserSpace and passes along the outputClip to the inputs unmodified.

Method Detail

getEffectTransformSpaceback to summary
public RenderState.EffectCoordinateSpace getEffectTransformSpace()

Return a hint indicating which coordinate space should be used for the pixel filtering for this particular filtering operation. The getEffectTransform() and getResultTransform() methods will always be used to get the actual transforms to be used to get input data and transform the results, but this method can help to set the expectations of the caller to optimize techniques.

Returns:RenderState.EffectCoordinateSpace

an EffectSpace value to describe the expected output from the getEffectTransform(...) and getResultTransform(...) methods.

getInputClipback to summary
public Rectangle getInputClip(int i, Rectangle filterClip)

Return the clip for the indicated input based on the indicated output clip.

Parameters
i:int

the index of the input being processed

filterClip:Rectangle

the output clip supplied to the given filter operation

Returns:Rectangle

the required rectangle from the indicated input to provide enough pixels to produce the indicated output clip

getInputTransformback to summary
public BaseTransform getInputTransform(BaseTransform filterTransform)

Return the transform that should be used to obtain pixel input from the Effect inputs for this filter operation. The returned transform is handed to all input Effect objects to obtain pixel data for the inputs. Typically, the output of getInputTransform(transform) and getResultTransform(transform) could be concatenated to produce the original filterTransform.

Parameters
filterTransform:BaseTransform

the BaseTransform object for the filter operation

Returns:BaseTransform

the BaseTransform object to use for the input effects

getResultTransformback to summary
public BaseTransform getResultTransform(BaseTransform filterTransform)

Return the transform that should be used to transform the results of the filter operation. The returned transform is combined with the resulting filter result texture to produce an output ImageData object. Typically, the output of getInputTransform(transform) and getResultTransform(transform) could be concatenated to produce the original filterTransform.

Parameters
filterTransform:BaseTransform

the BaseTransform object for the filter operation

Returns:BaseTransform

the BaseTransform object to be applied to the result texture

com.sun.scenario.effect.impl.state back to summary

public final Enum RenderState.EffectCoordinateSpace

extends Enum<RenderState.EffectCoordinateSpace>
Class Inheritance

This enum characterizes the types of coordinate spaces that will be used for the filter operation (i.e. handed to the dependent input Effect objects) and applied to the result of the filter.

Field Summary

Modifier and TypeField and Description
public static final RenderState.EffectCoordinateSpace
CustomSpace

The RenderState object will specify custom transform objects for both the input transform and the result transform with the only constraint that the two will concatenate to produce the original filter transform.

public static final RenderState.EffectCoordinateSpace
RenderSpace

The RenderState object will specify the original filter transform as the input transform and an IDENTITY transform for the result transform.

public static final RenderState.EffectCoordinateSpace
UserSpace

The RenderState object will specify an IDENTITY transform for the input transform and the original filter transform as the result transform.

Constructor Summary

AccessConstructor and Description
private

Method Summary

Modifier and TypeMethod and Description
public static RenderState.EffectCoordinateSpace
public static RenderState.EffectCoordinateSpace[]
Inherited from java.lang.Enum:
clonecompareTodescribeConstableequalsfinalizegetDeclaringClasshashCodenameordinaltoStringvalueOf

Field Detail

CustomSpaceback to summary
public static final RenderState.EffectCoordinateSpace CustomSpace

The RenderState object will specify custom transform objects for both the input transform and the result transform with the only constraint that the two will concatenate to produce the original filter transform.

    BaseTransform inputtx = getInputTransform(filtertx);
    BaseTransform resulttx = getResultTransform(filtertx);
    // Ignoring the potential for concatenate to modify the
    // return values from the above two methods, this virtual
    // assert statement is just for the sake of documenting
    // the intended constraints.
    assert(filtertx.equalsApproximately(resulttx.concatenate(inputtx)));
RenderSpaceback to summary
public static final RenderState.EffectCoordinateSpace RenderSpace

The RenderState object will specify the original filter transform as the input transform and an IDENTITY transform for the result transform.

UserSpaceback to summary
public static final RenderState.EffectCoordinateSpace UserSpace

The RenderState object will specify an IDENTITY transform for the input transform and the original filter transform as the result transform.

Constructor Detail

EffectCoordinateSpaceback to summary
private EffectCoordinateSpace()

Method Detail

valueOfback to summary
public static RenderState.EffectCoordinateSpace valueOf(String name)
valuesback to summary
public static RenderState.EffectCoordinateSpace[] values()