Mercator::CraterTerrainMod Class Reference

Terrain modifier that defines a crater. More...

#include <TerrainMod.h>

Inheritance diagram for Mercator::CraterTerrainMod:

Mercator::TerrainMod

List of all members.

Public Member Functions

 CraterTerrainMod (const WFMath::Ball< 3 > &s)
 Constructor.
virtual WFMath::AxisBox< 2 > bbox () const
 Get the boundingbox of the modifier.
virtual void apply (float &point, int x, int y) const
 Apply this modifier on a terrain segment.
virtual TerrainModclone () const
 Create a copy of this modifier.

Private Member Functions

 CraterTerrainMod (CraterTerrainMod &)
 Copy constructor.

Private Attributes

WFMath::Ball< 3 > m_shape
 Sphere that defines the shape of the crater.
WFMath::AxisBox< 2 > ab
 Box containing this modification.


Detailed Description

Terrain modifier that defines a crater.

This modifier creates an area where a sphere shaped volume has been subtracted from the terrain surface to create a spherical crater.


Constructor & Destructor Documentation

Mercator::CraterTerrainMod::CraterTerrainMod ( const WFMath::Ball< 3 > &  s  )  [inline]

Constructor.

Parameters:
s Sphere that defines the shape of the crater.

References ab, and m_shape.

Referenced by clone().


Member Function Documentation

void Mercator::CraterTerrainMod::apply ( float &  point,
int  x,
int  y 
) const [virtual]

Apply this modifier on a terrain segment.

The segment is at x,y in local coordinates. Output is placed into point.

Implements Mercator::TerrainMod.

References m_shape.


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

Generated for Mercator by  doxygen 1.5.6