Cortex 6.0.0
Public Types | Public Member Functions

IECore::PerlinNoise< P, V, F > Class Template Reference

#include <PerlinNoise.h>

List of all members.

Public Types

typedef PerlinNoise< P, V, F > * Ptr
typedef P Point
typedef VectorTraits< P > PointTraits
typedef VectorTraits< P >::BaseType PointBaseType
typedef V Value
typedef VectorTraits< V > ValueTraits
typedef VectorTraits< V >::BaseType ValueBaseType

Public Member Functions

 PerlinNoise (unsigned long int seed=0)
 PerlinNoise (const PerlinNoise &other)
 Copy constructor.
void initGradients (unsigned long int seed)
Value noise (const Point &p) const
Value noise (const Point &p, PointBaseType filterWidth) const
 As above but performs antialiasing using frequency clamping.
Value operator() (const Point &p) const
Value operator() (const Point &p, PointBaseType filterWidth) const
 As above but performs antialiasing using frequency clamping.

Detailed Description

template<typename P, typename V, typename F>
class IECore::PerlinNoise< P, V, F >

The PerlinNoise class template provides perlin noise functions across arbitrary dimensions of input and output. It uses the VectorTraits.h and VectorOps.h functionality to operate with different input and output types. P is the type of the Point class over which the noise is defined and V is the type of the value computed as the noise result. Both P and V must be types for which VectorTraits have been properly defined. F is the type of a functor providing a falloff function - see SmoothStepFalloff for an example of one of these.

Todo:
4d ones

Constructor & Destructor Documentation

template<typename P , typename V , typename F >
IECore::PerlinNoise< P, V, F >::PerlinNoise ( unsigned long int  seed = 0)

Constructs a new PerlinNoise object, passing the seed used by the random number generator to construct the gradient and permutations tables.


Member Function Documentation

template<typename P , typename V , typename F >
void IECore::PerlinNoise< P, V, F >::initGradients ( unsigned long int  seed)

Reinitialises the random gradient table using a potentially different seed.

template<typename P , typename V , typename F >
Value IECore::PerlinNoise< P, V, F >::noise ( const Point &  p) const [inline]

Computes the noise value at the given point. The components of the returned value will range from -0.5 to 0.5.

template<typename P , typename V , typename F >
Value IECore::PerlinNoise< P, V, F >::operator() ( const Point &  p) const [inline]

Computes the noise value at the given point. The components of the returned value will range from -0.5 to 0.5.


The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends