plugins.engines
Class FastWorley
java.lang.Object
Utilities.NoiseEngine
plugins.engines.FastWorley
public class FastWorley
- extends NoiseEngine
- Author:
- David
|
Constructor Summary |
FastWorley()
Creates a new instance of CacheWorley |
|
Method Summary |
protected double[] |
calculateDistanceArray(double x,
double y,
double z)
|
NoiseEngine |
copy()
|
java.lang.String |
description()
|
protected double |
FindNeighbours(double x1,
double y1,
double z1,
double xFloor,
double yFloor,
double zFloor,
double[] distances,
int index)
|
java.lang.String |
getDetails()
|
double |
getNoiseForVertex(int vertex)
|
double |
getNoiseForVertex(Vertex vertex)
|
Vertex |
getNoiseOffset()
|
Vertex |
getNoiseSize()
|
javax.swing.JPanel |
getPanel()
returns JPanel for noise settings |
Vertex[] |
getPreviewVertices()
|
double |
getScaledMovedNoiseForVertex(double x,
double y,
double z)
Range 0 to 1 spans the width of the preview window. |
void |
initNoise()
|
void |
load(java.io.ObjectInputStream file)
|
static void |
main(java.lang.String[] args)
|
void |
makePreview()
|
java.lang.String |
name()
|
void |
Parameters()
|
void |
restoreSettings()
|
void |
save(java.io.ObjectOutputStream file)
|
void |
setTerrain(Landscape terrain)
|
void |
storeSettings()
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
panel
protected ExtendedHashBasedPanel panel
nth
protected int nth
gridProjection
protected int gridProjection
cellCount
protected int cellCount
distanceCalc
protected FastWorley.DistanceCalculation distanceCalc
cells
protected double[][][] cells
xNoise
protected double xNoise
yNoise
protected double yNoise
zNoise
protected double zNoise
xOffset
protected double xOffset
yOffset
protected double yOffset
zOffset
protected double zOffset
seed
protected long seed
metric
protected java.lang.String metric
tmp
protected double[] tmp
HASH_MOD_VALUE
protected static final double HASH_MOD_VALUE
- See Also:
- Constant Field Values
HASH_AND_VALUE
protected static final int HASH_AND_VALUE
- See Also:
- Constant Field Values
rand
protected static final java.util.Random rand
FastWorley
public FastWorley()
- Creates a new instance of CacheWorley
main
public static void main(java.lang.String[] args)
name
public java.lang.String name()
- Specified by:
name in class NoiseEngine
description
public java.lang.String description()
- Specified by:
description in class NoiseEngine
Parameters
public void Parameters()
initNoise
public void initNoise()
- Specified by:
initNoise in class NoiseEngine
getPanel
public javax.swing.JPanel getPanel()
- returns JPanel for noise settings
- Specified by:
getPanel in class NoiseEngine
getNoiseForVertex
public double getNoiseForVertex(Vertex vertex)
- Specified by:
getNoiseForVertex in class NoiseEngine
getScaledMovedNoiseForVertex
public double getScaledMovedNoiseForVertex(double x,
double y,
double z)
- Description copied from class:
NoiseEngine
- Range 0 to 1 spans the width of the preview window.
- Specified by:
getScaledMovedNoiseForVertex in class NoiseEngine
- Returns:
calculateDistanceArray
protected double[] calculateDistanceArray(double x,
double y,
double z)
getNoiseSize
public Vertex getNoiseSize()
- Overrides:
getNoiseSize in class NoiseEngine
getNoiseOffset
public Vertex getNoiseOffset()
- Overrides:
getNoiseOffset in class NoiseEngine
getNoiseForVertex
public double getNoiseForVertex(int vertex)
- Specified by:
getNoiseForVertex in class NoiseEngine
setTerrain
public void setTerrain(Landscape terrain)
- Overrides:
setTerrain in class NoiseEngine
FindNeighbours
protected double FindNeighbours(double x1,
double y1,
double z1,
double xFloor,
double yFloor,
double zFloor,
double[] distances,
int index)
makePreview
public void makePreview()
- Specified by:
makePreview in class NoiseEngine
storeSettings
public void storeSettings()
- Specified by:
storeSettings in class NoiseEngine
restoreSettings
public void restoreSettings()
- Specified by:
restoreSettings in class NoiseEngine
save
public void save(java.io.ObjectOutputStream file)
throws java.io.IOException
- Specified by:
save in class NoiseEngine
- Throws:
java.io.IOException
load
public void load(java.io.ObjectInputStream file)
throws java.lang.ClassNotFoundException,
java.io.IOException
- Specified by:
load in class NoiseEngine
- Throws:
java.lang.ClassNotFoundException
java.io.IOException
copy
public NoiseEngine copy()
- Specified by:
copy in class NoiseEngine
getDetails
public java.lang.String getDetails()
- Specified by:
getDetails in class NoiseEngine
getPreviewVertices
public Vertex[] getPreviewVertices()
- Overrides:
getPreviewVertices in class NoiseEngine