IVectorFunction

Description

[ShutdownSurvive]
interface Tinman.Terrain.Procedural.IVectorFunction

Derived from

INoiseFunctionOps<Vec3D, IVectorFunction>

Extended by

VectorFunction abstract

Base interface for classes that compute procedural vector noise values.

Public / Methods

Add


[Pure]
public method Add → (1)

function in : IVectorFunction

[not-null]
The other noise function.

returns → IVectorFunction

The resulting noise function.

Adds the vector values of this noise function and the given noise function.

result := this + function

Mul


[Pure]
public method Mul → (1)

function in : IVectorFunction

[not-null]
The other noise function.

returns → IVectorFunction

The resulting noise function.

Multiplies the vector values of this noise function with the vector values of the the given noise function.

result := this * factor

Norm


[Pure]
public method Norm → ()

returns → IVectorFunction

The resulting noise function.

Normalizes the vector values of this noise function.

result := this / |this|

Sub


[Pure]
public method Sub → (1)

function in : IVectorFunction

[not-null]
The other noise function.

returns → IVectorFunction

The resulting noise function.

Subtracts the vector values of the given noise function from the vector values of this noise function.

result := this - function

Extensions

Add


[Pure]
public static method Add → (1)

value in : Vec3D

The value to add.

returns → IVectorFunction

The resulting noise function.

Adds the vector values of this noise function and the given vector value.

result := this + value

Mul


[Pure]
public static method Mul → (1)

value in : Vec3D

The value to multiply with.

returns → IVectorFunction

The resulting noise function.

Multiplies the vector values of this noise function with the given scalar value.

result := this * value

Multi​Sum


[Pure]
public static method MultiSum → (3)

octaves in : int32

[>=1]
The number of octaves.

amplitude opt : float64 = 0.5

Factor to apply to amplitude when going to the next octave. The amplitude of the first octave is 1.

frequency opt : float64 = 2

Factor to apply to frequency when going to the next octave. The frequency of the first octave is 1.

returns → IVectorFunction

The resulting noise function.

Returns a multifractal noise function based on this noise function.

Op

2 overloads


public static method Op1 → (2)

op in : VectorFunctionOpCode

The operation to use.

other opt : IVectorFunction = null

The other noise function or null if op in is unary.

returns → IVectorFunction

The resulting noise function.

Applies the given function operator to this noise function and the given one (for binary operators only).


public static method Op2 → (2)

op in : VectorFunctionOpCode

The operation to use.

value in : Vec3D

The vector value to combine with.

returns → IVectorFunction

The resulting noise function.

Applies the given function operator to this noise function and the given vector value (for binary operators only).

Sub


[Pure]
public static method Sub → (1)

value in : Vec3D

The value to subtract.

returns → IVectorFunction

The resulting noise function.

Subtracts the given vector value from the vector values of this noise function.

result := this - value