railo.runtime.img.filter
Class PolarFilter

java.lang.Object
  extended by railo.runtime.img.filter.AbstractBufferedImageOp
      extended by railo.runtime.img.filter.TransformFilter
          extended by railo.runtime.img.filter.PolarFilter
All Implemented Interfaces:
BufferedImageOp, Cloneable, DynFiltering

public class PolarFilter
extends TransformFilter
implements DynFiltering

A filter which distorts and image by performing coordinate conversions between rectangular and polar coordinates.


Field Summary
static int INVERT_IN_CIRCLE
          Invert the image in a circle.
static int POLAR_TO_RECT
          Convert from polar to rectangular coordinates.
static int RECT_TO_POLAR
          Convert from rectangular to polar coordinates.
 
Fields inherited from class railo.runtime.img.filter.TransformFilter
BILINEAR, NEAREST_NEIGHBOUR
 
Constructor Summary
PolarFilter()
          Construct a PolarFilter.
PolarFilter(int type)
          Construct a PolarFilter.
 
Method Summary
 BufferedImage filter(BufferedImage src, BufferedImage dst)
           
 BufferedImage filter(BufferedImage src, Struct parameters)
           
 int getType()
          Get the distortion type.
 void setType(String type)
          Set the distortion type, valid values are - RECT_TO_POLAR = Convert from rectangular to polar coordinates - POLAR_TO_RECT = Convert from polar to rectangular coordinates - INVERT_IN_CIRCLE = Invert the image in a circle
 String toString()
           
 
Methods inherited from class railo.runtime.img.filter.TransformFilter
getEdgeAction, getInterpolation, setEdgeAction, setInterpolation
 
Methods inherited from class railo.runtime.img.filter.AbstractBufferedImageOp
clone, createCompatibleDestImage, getBounds2D, getPoint2D, getRenderingHints, getRGB, setRGB
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

RECT_TO_POLAR

public static final int RECT_TO_POLAR
Convert from rectangular to polar coordinates.

See Also:
Constant Field Values

POLAR_TO_RECT

public static final int POLAR_TO_RECT
Convert from polar to rectangular coordinates.

See Also:
Constant Field Values

INVERT_IN_CIRCLE

public static final int INVERT_IN_CIRCLE
Invert the image in a circle.

See Also:
Constant Field Values
Constructor Detail

PolarFilter

public PolarFilter()
Construct a PolarFilter.


PolarFilter

public PolarFilter(int type)
Construct a PolarFilter.

Parameters:
type - the distortion type
Method Detail

filter

public BufferedImage filter(BufferedImage src,
                            BufferedImage dst)
Specified by:
filter in interface BufferedImageOp
Overrides:
filter in class TransformFilter

setType

public void setType(String type)
             throws ExpressionException
Set the distortion type, valid values are - RECT_TO_POLAR = Convert from rectangular to polar coordinates - POLAR_TO_RECT = Convert from polar to rectangular coordinates - INVERT_IN_CIRCLE = Invert the image in a circle

Throws:
ExpressionException

getType

public int getType()
Get the distortion type.

Returns:
the distortion type
See Also:
setType(java.lang.String)

toString

public String toString()
Overrides:
toString in class Object

filter

public BufferedImage filter(BufferedImage src,
                            Struct parameters)
                     throws PageException
Specified by:
filter in interface DynFiltering
Overrides:
filter in class TransformFilter
Throws:
PageException


Copyright © 2012 Railo