railo.runtime.img.filter
Class CausticsFilter

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

public class CausticsFilter
extends WholeImageFilter
implements DynFiltering

A filter which simulates underwater caustics. This can be animated to get a bottom-of-the-swimming-pool effect.


Constructor Summary
CausticsFilter()
           
 
Method Summary
 BufferedImage filter(BufferedImage src, Struct parameters)
           
 float getAmount()
          Get the amount of effect.
 int getBgColor()
          Get the background color.
 int getBrightness()
          Get the brightness.
 float getDispersion()
          Get the dispersion.
 int getSamples()
          Get the number of samples per pixel.
 float getScale()
          Returns the scale of the texture.
 float getTime()
          Set the time.
 float getTurbulence()
          Returns the turbulence of the effect.
 void setAmount(float amount)
          Set the amount of effect.
 void setBgColor(int c)
          Set the background color.
 void setBrightness(int brightness)
          Set the brightness.
 void setDispersion(float dispersion)
          Set the dispersion.
 void setSamples(int samples)
          Set the number of samples per pixel.
 void setScale(float scale)
          Specifies the scale of the texture.
 void setTime(float time)
          Set the time.
 void setTurbulence(float turbulence)
          Specifies the turbulence of the texture.
 String toString()
           
 
Methods inherited from class railo.runtime.img.filter.WholeImageFilter
filter
 
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
 

Constructor Detail

CausticsFilter

public CausticsFilter()
Method Detail

setScale

public void setScale(float scale)
Specifies the scale of the texture.

Parameters:
scale - the scale of the texture.
See Also:
getScale()

getScale

public float getScale()
Returns the scale of the texture.

Returns:
the scale of the texture.
See Also:
setScale(float)

setBrightness

public void setBrightness(int brightness)
Set the brightness.

Parameters:
brightness - the brightness.
See Also:
getBrightness()

getBrightness

public int getBrightness()
Get the brightness.

Returns:
the brightness.
See Also:
setBrightness(int)

setTurbulence

public void setTurbulence(float turbulence)
Specifies the turbulence of the texture.

Parameters:
turbulence - the turbulence of the texture.
See Also:
getTurbulence()

getTurbulence

public float getTurbulence()
Returns the turbulence of the effect.

Returns:
the turbulence of the effect.
See Also:
setTurbulence(float)

setAmount

public void setAmount(float amount)
Set the amount of effect.

Parameters:
amount - the amount
See Also:
getAmount()

getAmount

public float getAmount()
Get the amount of effect.

Returns:
the amount
See Also:
setAmount(float)

setDispersion

public void setDispersion(float dispersion)
Set the dispersion.

Parameters:
dispersion - the dispersion
See Also:
getDispersion()

getDispersion

public float getDispersion()
Get the dispersion.

Returns:
the dispersion
See Also:
setDispersion(float)

setTime

public void setTime(float time)
Set the time. Use this to animate the effect.

Parameters:
time - the time
See Also:
getTime()

getTime

public float getTime()
Set the time.

Returns:
the time
See Also:
setTime(float)

setSamples

public void setSamples(int samples)
Set the number of samples per pixel. More samples means better quality, but slower rendering.

Parameters:
samples - the number of samples
See Also:
getSamples()

getSamples

public int getSamples()
Get the number of samples per pixel.

Returns:
the number of samples
See Also:
setSamples(int)

setBgColor

public void setBgColor(int c)
Set the background color.

Parameters:
c - the color
See Also:
getBgColor()

getBgColor

public int getBgColor()
Get the background color.

Returns:
the color
See Also:
setBgColor(int)

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 WholeImageFilter
Throws:
PageException


Copyright © 2012 Railo