Class TurbulenceRable8Bit
java.lang.Object
org.apache.batik.ext.awt.image.renderable.AbstractRable
org.apache.batik.ext.awt.image.renderable.AbstractColorInterpolationRable
org.apache.batik.ext.awt.image.renderable.TurbulenceRable8Bit
- All Implemented Interfaces:
RenderableImage, Filter, FilterColorInterpolation, TurbulenceRable
Creates a sourceless image from a turbulence function.
- Version:
- $Id$
-
Field Summary
FieldsModifier and TypeFieldDescription(package private) double(package private) double(package private) boolean(package private) int(package private) Rectangle2D(package private) int(package private) booleanFields inherited from class AbstractColorInterpolationRable
csLinearFields inherited from class AbstractRable
props, srcs, stampFields inherited from interface RenderableImage
HINTS_OBSERVED -
Constructor Summary
ConstructorsConstructorDescriptionTurbulenceRable8Bit(Rectangle2D region) TurbulenceRable8Bit(Rectangle2D region, int seed, int numOctaves, double baseFreqX, double baseFreqY, boolean stitched, boolean fractalNoise) -
Method Summary
Modifier and TypeMethodDescriptiondoubleGet the current base fequency in x direction.doubleGet the current base fequency in y direction.Get the turbulence regionintGet the current number of octaves for the noise function .intgetSeed()Get the current seed value for the pseudo random number generator.Get the turbulence regionbooleanReturns true if the turbulence function is using fractal noise, instead of turbulence noise.booleanReturns true if the turbulence function is currently stitching tiles.voidsetBaseFrequencyX(double baseFreqX) Set the base fequency in x direction.voidsetBaseFrequencyY(double baseFreqY) Set the base fequency in y direction.voidsetFractalNoise(boolean fractalNoise) Turns on/off fractal noise.voidsetNumOctaves(int numOctaves) Set the number of octaves for the noise function .voidsetSeed(int seed) Set the seed value for the pseudo random number generator.voidsetStitched(boolean stitched) Set stitching state for tiles.voidsetTurbulenceRegion(Rectangle2D turbulenceRegion) Sets the turbulence regionMethods inherited from class AbstractColorInterpolationRable
convertSourceCS, convertSourceCS, getOperationColorSpace, isColorSpaceLinear, setColorSpaceLinearMethods inherited from class AbstractRable
createDefaultRendering, createScaledRendering, getDependencyRegion, getDirtyRegion, getHeight, getMinX, getMinY, getProperty, getPropertyNames, getSources, getTimeStamp, getWidth, init, init, init, init, isDynamic, touchMethods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface Filter
getDependencyRegion, getDirtyRegion, getTimeStampMethods inherited from interface FilterColorInterpolation
getOperationColorSpace, isColorSpaceLinear, setColorSpaceLinearMethods inherited from interface RenderableImage
createDefaultRendering, createScaledRendering, getHeight, getMinX, getMinY, getProperty, getPropertyNames, getSources, getWidth, isDynamic
-
Field Details
-
seed
int seed -
numOctaves
int numOctaves -
baseFreqX
double baseFreqX -
baseFreqY
double baseFreqY -
stitched
boolean stitched -
fractalNoise
boolean fractalNoise -
region
Rectangle2D region
-
-
Constructor Details
-
TurbulenceRable8Bit
-
TurbulenceRable8Bit
public TurbulenceRable8Bit(Rectangle2D region, int seed, int numOctaves, double baseFreqX, double baseFreqY, boolean stitched, boolean fractalNoise)
-
-
Method Details
-
getTurbulenceRegion
Get the turbulence region- Specified by:
getTurbulenceRegionin interfaceTurbulenceRable
-
getBounds2D
Get the turbulence region- Specified by:
getBounds2Din interfaceFilter- Overrides:
getBounds2Din classAbstractRable
-
getSeed
public int getSeed()Get the current seed value for the pseudo random number generator.- Specified by:
getSeedin interfaceTurbulenceRable- Returns:
- The current seed value for the pseudo random number generator.
-
getNumOctaves
public int getNumOctaves()Get the current number of octaves for the noise function .- Specified by:
getNumOctavesin interfaceTurbulenceRable- Returns:
- The current number of octaves for the noise function .
-
getBaseFrequencyX
public double getBaseFrequencyX()Get the current base fequency in x direction.- Specified by:
getBaseFrequencyXin interfaceTurbulenceRable- Returns:
- The current base fequency in x direction.
-
getBaseFrequencyY
public double getBaseFrequencyY()Get the current base fequency in y direction.- Specified by:
getBaseFrequencyYin interfaceTurbulenceRable- Returns:
- The current base fequency in y direction.
-
isStitched
public boolean isStitched()Returns true if the turbulence function is currently stitching tiles.- Specified by:
isStitchedin interfaceTurbulenceRable- Returns:
- true if the turbulence function is currently stitching tiles.
-
isFractalNoise
public boolean isFractalNoise()Returns true if the turbulence function is using fractal noise, instead of turbulence noise.- Specified by:
isFractalNoisein interfaceTurbulenceRable- Returns:
- true if the turbulence function is using fractal noise, instead of turbulence noise.
-
setTurbulenceRegion
Sets the turbulence region- Specified by:
setTurbulenceRegionin interfaceTurbulenceRable- Parameters:
turbulenceRegion- region to fill with turbulence function.
-
setSeed
public void setSeed(int seed) Set the seed value for the pseudo random number generator.- Specified by:
setSeedin interfaceTurbulenceRable- Parameters:
seed- The new seed value for the pseudo random number generator.
-
setNumOctaves
public void setNumOctaves(int numOctaves) Set the number of octaves for the noise function .- Specified by:
setNumOctavesin interfaceTurbulenceRable- Parameters:
numOctaves- The new number of octaves for the noise function .
-
setBaseFrequencyX
public void setBaseFrequencyX(double baseFreqX) Set the base fequency in x direction.- Specified by:
setBaseFrequencyXin interfaceTurbulenceRable- Parameters:
baseFreqX- The new base fequency in x direction.
-
setBaseFrequencyY
public void setBaseFrequencyY(double baseFreqY) Set the base fequency in y direction.- Specified by:
setBaseFrequencyYin interfaceTurbulenceRable- Parameters:
baseFreqY- The new base fequency in y direction.
-
setStitched
public void setStitched(boolean stitched) Set stitching state for tiles.- Specified by:
setStitchedin interfaceTurbulenceRable- Parameters:
stitched- true if the turbulence operator should stitch tiles.
-
setFractalNoise
public void setFractalNoise(boolean fractalNoise) Turns on/off fractal noise.- Specified by:
setFractalNoisein interfaceTurbulenceRable- Parameters:
fractalNoise- true if fractal noise should be used.
-
createRendering
- Specified by:
createRenderingin interfaceRenderableImage
-