com.jme3.terrain.heightmap
クラス FaultHeightMap

java.lang.Object
  上位を拡張 com.jme3.terrain.heightmap.AbstractHeightMap
      上位を拡張 com.jme3.terrain.heightmap.FaultHeightMap
すべての実装されたインタフェース:
HeightMap

public class FaultHeightMap
extends AbstractHeightMap

Creates an heightmap based on the fault algorithm. Each iteration, a random line crossing the map is generated. On one side height values are raised, on the other side lowered.


フィールドの概要
static int FAULTSHAPE_CIRCLE
          A circular fault is created.
static int FAULTSHAPE_LINE
          A linear fault is created
static int FAULTTYPE_COSINE
          Values are lowered on one side, increased on the other, creating a cosine curve on the fault line
static int FAULTTYPE_LINEAR
          Values on one side are lowered, then increase lineary while crossing the fault line to the other side.
static int FAULTTYPE_SINE
          Value are lowered on both side, but increased on the fault line creating a smooth ridge on the fault line.
static int FAULTTYPE_STEP
          Values on one side are lowered, on the other side increased, creating a step at the fault line
 
クラス com.jme3.terrain.heightmap.AbstractHeightMap から継承されたフィールド
NORMALIZE_RANGE
 
コンストラクタの概要
FaultHeightMap(int size, int iterations, float minFaultHeight, float maxFaultHeight)
          Create an heightmap with linear step faults.
FaultHeightMap(int size, int iterations, int faultType, int faultShape, float minFaultHeight, float maxFaultHeight, long seed)
          Constructor creates the fault.
 
メソッドの概要
 int getFaultShape()
           
 int getFaultType()
           
 int getIterations()
           
 float getMaxFaultHeight()
           
 float getMaxRadius()
           
 float getMaxRange()
           
 float getMinFaultHeight()
           
 float getMinRadius()
           
 float getMinRange()
           
 long getSeed()
           
 boolean load()
          load populates the height map data.
 void setFaultShape(int faultShape)
           
 void setFaultType(int faultType)
           
 void setIterations(int iterations)
           
 void setMaxFaultHeight(float maxFaultHeight)
           
 void setMaxRadius(float maxRadius)
           
 void setMaxRange(float maxRange)
           
 void setMinFaultHeight(float minFaultHeight)
           
 void setMinRadius(float minRadius)
           
 void setMinRange(float minRange)
           
 void setSeed(long seed)
           
 
クラス com.jme3.terrain.heightmap.AbstractHeightMap から継承されたメソッド
erodeTerrain, findMinMaxHeights, flatten, getHeightMap, getInterpolatedHeight, getScaledHeightAtPoint, getScaledHeightMap, getSize, getTrueHeightAtPoint, normalizeTerrain, save, setHeightAtPoint, setHeightScale, setMagnificationFilter, setSize, smooth, unloadHeightMap
 
クラス java.lang.Object から継承されたメソッド
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

フィールドの詳細

FAULTTYPE_STEP

public static final int FAULTTYPE_STEP
Values on one side are lowered, on the other side increased, creating a step at the fault line

関連項目:
定数フィールド値

FAULTTYPE_LINEAR

public static final int FAULTTYPE_LINEAR
Values on one side are lowered, then increase lineary while crossing the fault line to the other side. The fault line will be a inclined plane

関連項目:
定数フィールド値

FAULTTYPE_COSINE

public static final int FAULTTYPE_COSINE
Values are lowered on one side, increased on the other, creating a cosine curve on the fault line

関連項目:
定数フィールド値

FAULTTYPE_SINE

public static final int FAULTTYPE_SINE
Value are lowered on both side, but increased on the fault line creating a smooth ridge on the fault line.

関連項目:
定数フィールド値

FAULTSHAPE_LINE

public static final int FAULTSHAPE_LINE
A linear fault is created

関連項目:
定数フィールド値

FAULTSHAPE_CIRCLE

public static final int FAULTSHAPE_CIRCLE
A circular fault is created.

関連項目:
定数フィールド値
コンストラクタの詳細

FaultHeightMap

public FaultHeightMap(int size,
                      int iterations,
                      int faultType,
                      int faultShape,
                      float minFaultHeight,
                      float maxFaultHeight,
                      long seed)
               throws java.lang.Exception
Constructor creates the fault. For faulttype other than STEP, a range can be provided. For faultshape circle, min and max radii can be provided. Don't forget to reload the map if you have set parameters after the constructor call.

パラメータ:
size - The size of the heightmap
iterations - Iterations to perform
faultType - Type of fault
faultShape - Shape of the fault -line or circle
minFaultHeight - Height modified on each side
maxFaultHeight - Height modified on each side
faultHeight - Height modified on each side
seed - A seed to feed the Random generator
例外:
java.lang.Exception
関連項目:
setFaultRange, setMinRadius, setMaxRadius

FaultHeightMap

public FaultHeightMap(int size,
                      int iterations,
                      float minFaultHeight,
                      float maxFaultHeight)
               throws java.lang.Exception
Create an heightmap with linear step faults.

パラメータ:
size - size of heightmap
iterations - number of iterations
faultHeight - height to modify
例外:
java.lang.Exception
メソッドの詳細

load

public boolean load()
インタフェース HeightMap の記述:
load populates the height map data. This is dependent on the subclass's implementation.

戻り値:
true if the load was successful, false otherwise.

getFaultShape

public int getFaultShape()

setFaultShape

public void setFaultShape(int faultShape)

getFaultType

public int getFaultType()

setFaultType

public void setFaultType(int faultType)

getIterations

public int getIterations()

setIterations

public void setIterations(int iterations)

getMaxFaultHeight

public float getMaxFaultHeight()

setMaxFaultHeight

public void setMaxFaultHeight(float maxFaultHeight)

getMaxRadius

public float getMaxRadius()

setMaxRadius

public void setMaxRadius(float maxRadius)

getMaxRange

public float getMaxRange()

setMaxRange

public void setMaxRange(float maxRange)

getMinFaultHeight

public float getMinFaultHeight()

setMinFaultHeight

public void setMinFaultHeight(float minFaultHeight)

getMinRadius

public float getMinRadius()

setMinRadius

public void setMinRadius(float minRadius)

getMinRange

public float getMinRange()

setMinRange

public void setMinRange(float minRange)

getSeed

public long getSeed()

setSeed

public void setSeed(long seed)