C# 클래스 LibNoise.NMath

Provides math operations not found in System.Math.
파일 보기 프로젝트 열기: MadoxLabs/NoiseTool

공개 프로퍼티들

프로퍼티 타입 설명
DEG_TO_RAD double
PI double
RAD_TO_DEG double
Sqrt2 double
Sqrt3 double

공개 메소드들

메소드 설명
ClampValue ( double value, double lowerBound, double upperBound ) : double
ClampValue ( int value, int lowerBound, int upperBound ) : int

Returns the given value clamped between the given lower and upper bounds. - @a value if @a value lies between @a lowerBound and @a upperBound. - @a lowerBound if @a value is less than @a lowerBound. - @a upperBound if @a value is greater than @a upperBound.

CubicInterpolate ( double n0, double n1, double n2, double n3, double a ) : double

Returns the cubic interpolation of two values bound between two other values.

GetLarger ( double a, double b ) : double

Returns the larger of the two given numbers.

GetSmaller ( double a, double b ) : double

Returns the smaller of the two given numbers.

GradientCoherentNoise ( double x, double y, double z, int seed, NoiseQuality noiseQuality ) : double
GradientNoise ( double fx, double fy, double fz, int ix, int iy, int iz, long seed ) : double
IntValueNoise ( int x, int y, int z, int seed ) : int
LatLonToXYZ ( double lat, double lon, double &x, double &y, double &z ) : void

Provides the X, Y, and Z coordinates on the surface of a sphere cooresponding to the given latitude and longitude.

LinearInterpolate ( double n0, double n1, double a ) : double

Returns the linear interpolation of two values with the given alpha.

MakeInt32Range ( double n ) : double

Returns the given value, modified to be able to fit into a 32-bit integer.

SCurve3 ( double a ) : double

Returns the given value mapped onto a cubic S-curve. @a a should range from 0.0 to 1.0. The derivitive of a cubic S-curve is zero at @a a = 0.0 and @a a = 1.0

SCurve5 ( double a ) : double

Returns the given value mapped onto a quintic S-curve. @a a should range from 0.0 to 1.0. The first derivitive of a quintic S-curve is zero at @a a = 0.0 and @a a = 1.0 The second derivitive of a quintic S-curve is zero at @a a = 0.0 and @a a = 1.0

SwapValues ( double &a, double &b ) : void

Swaps the values contained by the two given variables.

ValueCoherentNoise ( double x, double y, double z, int seed, NoiseQuality noiseQuality ) : double
ValueNoise ( int x, int y, int z ) : double
ValueNoise ( int x, int y, int z, int seed ) : double

메소드 상세

ClampValue() 공개 정적인 메소드

public static ClampValue ( double value, double lowerBound, double upperBound ) : double
value double
lowerBound double
upperBound double
리턴 double

ClampValue() 공개 정적인 메소드

Returns the given value clamped between the given lower and upper bounds. - @a value if @a value lies between @a lowerBound and @a upperBound. - @a lowerBound if @a value is less than @a lowerBound. - @a upperBound if @a value is greater than @a upperBound.
public static ClampValue ( int value, int lowerBound, int upperBound ) : int
value int
lowerBound int
upperBound int
리턴 int

CubicInterpolate() 공개 정적인 메소드

Returns the cubic interpolation of two values bound between two other values.
public static CubicInterpolate ( double n0, double n1, double n2, double n3, double a ) : double
n0 double The value before the first value.
n1 double The first value.
n2 double The second value.
n3 double The value after the second value.
a double The alpha value.
리턴 double

GetLarger() 공개 정적인 메소드

Returns the larger of the two given numbers.
public static GetLarger ( double a, double b ) : double
a double
b double
리턴 double

GetSmaller() 공개 정적인 메소드

Returns the smaller of the two given numbers.
public static GetSmaller ( double a, double b ) : double
a double
b double
리턴 double

GradientCoherentNoise() 공개 정적인 메소드

public static GradientCoherentNoise ( double x, double y, double z, int seed, NoiseQuality noiseQuality ) : double
x double
y double
z double
seed int
noiseQuality NoiseQuality
리턴 double

GradientNoise() 공개 정적인 메소드

public static GradientNoise ( double fx, double fy, double fz, int ix, int iy, int iz, long seed ) : double
fx double
fy double
fz double
ix int
iy int
iz int
seed long
리턴 double

IntValueNoise() 공개 정적인 메소드

public static IntValueNoise ( int x, int y, int z, int seed ) : int
x int
y int
z int
seed int
리턴 int

LatLonToXYZ() 공개 정적인 메소드

Provides the X, Y, and Z coordinates on the surface of a sphere cooresponding to the given latitude and longitude.
public static LatLonToXYZ ( double lat, double lon, double &x, double &y, double &z ) : void
lat double
lon double
x double
y double
z double
리턴 void

LinearInterpolate() 공개 정적인 메소드

Returns the linear interpolation of two values with the given alpha.
public static LinearInterpolate ( double n0, double n1, double a ) : double
n0 double
n1 double
a double
리턴 double

MakeInt32Range() 공개 정적인 메소드

Returns the given value, modified to be able to fit into a 32-bit integer.
public static MakeInt32Range ( double n ) : double
n double
리턴 double

SCurve3() 공개 정적인 메소드

Returns the given value mapped onto a cubic S-curve. @a a should range from 0.0 to 1.0. The derivitive of a cubic S-curve is zero at @a a = 0.0 and @a a = 1.0
public static SCurve3 ( double a ) : double
a double
리턴 double

SCurve5() 공개 정적인 메소드

Returns the given value mapped onto a quintic S-curve. @a a should range from 0.0 to 1.0. The first derivitive of a quintic S-curve is zero at @a a = 0.0 and @a a = 1.0 The second derivitive of a quintic S-curve is zero at @a a = 0.0 and @a a = 1.0
public static SCurve5 ( double a ) : double
a double
리턴 double

SwapValues() 공개 정적인 메소드

Swaps the values contained by the two given variables.
public static SwapValues ( double &a, double &b ) : void
a double
b double
리턴 void

ValueCoherentNoise() 공개 정적인 메소드

public static ValueCoherentNoise ( double x, double y, double z, int seed, NoiseQuality noiseQuality ) : double
x double
y double
z double
seed int
noiseQuality NoiseQuality
리턴 double

ValueNoise() 공개 정적인 메소드

public static ValueNoise ( int x, int y, int z ) : double
x int
y int
z int
리턴 double

ValueNoise() 공개 정적인 메소드

public static ValueNoise ( int x, int y, int z, int seed ) : double
x int
y int
z int
seed int
리턴 double

프로퍼티 상세

DEG_TO_RAD 공개적으로 정적으로 프로퍼티

public static double DEG_TO_RAD
리턴 double

PI 공개적으로 정적으로 프로퍼티

public static double PI
리턴 double

RAD_TO_DEG 공개적으로 정적으로 프로퍼티

public static double RAD_TO_DEG
리턴 double

Sqrt2 공개적으로 정적으로 프로퍼티

public static double Sqrt2
리턴 double

Sqrt3 공개적으로 정적으로 프로퍼티

public static double Sqrt3
리턴 double