Heightfield 1.0
AnalyticRidged Class Reference

Ridged-simplex-turbulence's multifractal terrain model. More...

#include <analyticfield.h>

Inheritance diagram for AnalyticRidged:
AnalyticHeightField SimplexTurbulence2 AnalyticScalarField2 SimplexNoise2 AnalyticScalarField2

Public Member Functions

 AnalyticRidged (const double &, const double &, const double &, const double &, const double &, int, const Vector2 &=Vector::Null)
 Create the fractal terrain.
 
double Value (const Vector2 &) const
 Compute the field function.
 
- Public Member Functions inherited from AnalyticHeightField
 AnalyticHeightField ()
 Empty.
 
virtual double Height (const Vector2 &) const
 Compute elevation at a given point.
 
virtual Vector Normal (const Vector2 &) const
 Compute the normal to the field.
 
HeightField CreateHeightField (const Box2 &, int, int) const
 Create a HeightField given an input domain.
 
double Slope (const Vector2 &) const
 Compute the slope at a given point.
 
double AverageSlope (const Vector2 &, int=8) const
 Compute the average slope at a given point.
 
double Slope (const Vector2 &, const Vector2 &) const
 Compute the slope in a given direction and at a given point.
 
QVector< double > Cross (const Vector2 &, const Vector2 &, int) const
 Compute the elevation along a segment.
 

Additional Inherited Members

- Static Public Member Functions inherited from AnalyticHeightField
static double Ridge (const double &, const double &=0.0)
 Ridge function.
 
- Static Protected Attributes inherited from AnalyticHeightField
static double Epsilon = 1e-6
 Epsilon value used for gradient computation.
 

Detailed Description

Ridged-simplex-turbulence's multifractal terrain model.

Constructor & Destructor Documentation

◆ AnalyticRidged()

AnalyticRidged::AnalyticRidged ( const double & v,
const double & a,
const double & l,
const double & alpha,
const double & lambda,
int octaves,
const Vector2 & t = Vector::Null )
explicit

Create the fractal terrain.

Parameters
v,a,lBase value, amplitude and wavelength.
alphaAmplitude attenuation factor (~0.5, should be less than 1.0).
lambdaWavelength attenuation factor (~0.5, should be less than 1.0).
octavesNumber of octaves.
tTranslation offset.

Member Function Documentation

◆ Value()

double AnalyticRidged::Value ( const Vector2 & q) const
virtual

Compute the field function.

Parameters
qPoint.

Reimplemented from AnalyticScalarField2.