Chunks
Moddable voxel sandbox for room-scale VR.
Public Member Functions | Public Attributes | Protected Member Functions | Properties | List of all members
LibNoise.Noise2D Class Reference

Provides a two-dimensional noise map. More...

Inheritance diagram for LibNoise.Noise2D:

Public Member Functions

 Noise2D (int size)
 Initializes a new instance of Noise2D. More...
 
 Noise2D (int size, ModuleBase generator)
 Initializes a new instance of Noise2D. More...
 
 Noise2D (int width, int height)
 Initializes a new instance of Noise2D. More...
 
 Noise2D (int width, int height, ModuleBase generator)
 Initializes a new instance of Noise2D. More...
 
void Clear ()
 Clears the noise map. More...
 
void Clear (float value)
 Clears the noise map. More...
 
void GenerateCylindrical (double angleMin, double angleMax, double heightMin, double heightMax)
 Generates a cylindrical projection of the noise map. More...
 
void GeneratePlanar (double left, double right, double top, double bottom)
 Generates a planar projection of the noise map. More...
 
void GeneratePlanar (double left, double right, double top, double bottom, bool seamless)
 Generates a non-seamless planar projection of the noise map. More...
 
void GenerateSpherical (double south, double north, double west, double east)
 Generates a spherical projection of the noise map. More...
 
Texture2D GetNormalMap (float scale)
 Creates a normal map for the current content of the noise map. More...
 
Texture2D GetTexture ()
 Creates a grayscale texture map for the current content of the noise map. More...
 
Texture2D GetTexture (Gradient gradient)
 Creates a texture map for the current content of the noise map. More...
 
Texture2D GetTexture (ref Gradient gradient)
 Creates a texture map for the current content of the noise map. More...
 
void Dispose ()
 Immediately releases the unmanaged resources used by this object. More...
 

Public Attributes

const double South = -90.0
 
const double North = 90.0
 
const double West = -180.0
 
const double East = 180.0
 
const double AngleMin = -180.0
 
const double AngleMax = 180.0
 
const double Left = -1.0
 
const double Right = 1.0
 
const double Top = -1.0
 
const double Bottom = 1.0
 

Protected Member Functions

 Noise2D ()
 Initializes a new instance of Noise2D. More...
 
virtual bool Disposing ()
 Immediately releases the unmanaged resources used by this object. More...
 

Properties

float this[int x, int y] [get, set]
 Gets or sets a value in the noise map by its position. More...
 
float Border [get, set]
 Gets or sets the constant value at the noise maps borders. More...
 
ModuleBase Generator [get, set]
 Gets or sets the generator module. More...
 
int Height [get]
 Gets the height of the noise map. More...
 
int Width [get]
 Gets the width of the noise map. More...
 
bool IsDisposed [get]
 Gets a value whether the object is disposed. More...
 

Detailed Description

Provides a two-dimensional noise map.

Constructor & Destructor Documentation

LibNoise.Noise2D.Noise2D ( )
protected

Initializes a new instance of Noise2D.

LibNoise.Noise2D.Noise2D ( int  size)

Initializes a new instance of Noise2D.

Parameters
sizeThe width and height of the noise map.
LibNoise.Noise2D.Noise2D ( int  size,
ModuleBase  generator 
)

Initializes a new instance of Noise2D.

Parameters
sizeThe width and height of the noise map.
generatorThe generator module.
LibNoise.Noise2D.Noise2D ( int  width,
int  height 
)

Initializes a new instance of Noise2D.

Parameters
widthThe width of the noise map.
heightThe height of the noise map.
LibNoise.Noise2D.Noise2D ( int  width,
int  height,
ModuleBase  generator 
)

Initializes a new instance of Noise2D.

Parameters
widthThe width of the noise map.
heightThe height of the noise map.
generatorThe generator module.

Member Function Documentation

void LibNoise.Noise2D.Clear ( )

Clears the noise map.

void LibNoise.Noise2D.Clear ( float  value)

Clears the noise map.

Parameters
valueThe constant value to clear the noise map with.
void LibNoise.Noise2D.Dispose ( )

Immediately releases the unmanaged resources used by this object.

virtual bool LibNoise.Noise2D.Disposing ( )
protectedvirtual

Immediately releases the unmanaged resources used by this object.

Returns
True if the object is completely disposed.
void LibNoise.Noise2D.GenerateCylindrical ( double  angleMin,
double  angleMax,
double  heightMin,
double  heightMax 
)

Generates a cylindrical projection of the noise map.

Parameters
angleMinThe maximum angle of the clip region.
angleMaxThe minimum angle of the clip region.
heightMinThe minimum height of the clip region.
heightMaxThe maximum height of the clip region.
void LibNoise.Noise2D.GeneratePlanar ( double  left,
double  right,
double  top,
double  bottom 
)

Generates a planar projection of the noise map.

Parameters
leftThe clip region to the left.
rightThe clip region to the right.
topThe clip region to the top.
bottomThe clip region to the bottom.
void LibNoise.Noise2D.GeneratePlanar ( double  left,
double  right,
double  top,
double  bottom,
bool  seamless 
)

Generates a non-seamless planar projection of the noise map.

Parameters
leftThe clip region to the left.
rightThe clip region to the right.
topThe clip region to the top.
bottomThe clip region to the bottom.
seamlessIndicates whether the resulting noise map should be seamless.
void LibNoise.Noise2D.GenerateSpherical ( double  south,
double  north,
double  west,
double  east 
)

Generates a spherical projection of the noise map.

Parameters
southThe clip region to the south.
northThe clip region to the north.
westThe clip region to the west.
eastThe clip region to the east.
Texture2D LibNoise.Noise2D.GetNormalMap ( float  scale)

Creates a normal map for the current content of the noise map.

Parameters
scaleThe scaling of the normal map values.
Returns
The created normal map.
Texture2D LibNoise.Noise2D.GetTexture ( )

Creates a grayscale texture map for the current content of the noise map.

Returns
The created texture map.
Texture2D LibNoise.Noise2D.GetTexture ( Gradient  gradient)

Creates a texture map for the current content of the noise map.

Parameters
gradientThe gradient to color the texture map with.
Returns
The created texture map.
Texture2D LibNoise.Noise2D.GetTexture ( ref Gradient  gradient)

Creates a texture map for the current content of the noise map.

Parameters
gradientThe gradient to color the texture map with.
Returns
The created texture map.

Member Data Documentation

const double LibNoise.Noise2D.AngleMax = 180.0
const double LibNoise.Noise2D.AngleMin = -180.0
const double LibNoise.Noise2D.Bottom = 1.0
const double LibNoise.Noise2D.East = 180.0
const double LibNoise.Noise2D.Left = -1.0
const double LibNoise.Noise2D.North = 90.0
const double LibNoise.Noise2D.Right = 1.0
const double LibNoise.Noise2D.South = -90.0
const double LibNoise.Noise2D.Top = -1.0
const double LibNoise.Noise2D.West = -180.0

Property Documentation

float LibNoise.Noise2D.Border
getset

Gets or sets the constant value at the noise maps borders.

ModuleBase LibNoise.Noise2D.Generator
getset

Gets or sets the generator module.

int LibNoise.Noise2D.Height
get

Gets the height of the noise map.

bool LibNoise.Noise2D.IsDisposed
get

Gets a value whether the object is disposed.

float LibNoise.Noise2D.this[int x, int y]
getset

Gets or sets a value in the noise map by its position.

Parameters
xThe position on the x-axis.
yThe position on the y-axis.
Returns
The corresponding value.
int LibNoise.Noise2D.Width
get

Gets the width of the noise map.


The documentation for this class was generated from the following file: