voxelTerrain
 All Classes Functions Variables Typedefs Enumerations Pages
Public Member Functions | Protected Attributes | List of all members
blub::procedural::voxel::data Class Reference

The data class is the default voxel. Contains an 8-bit interpolation value. Replace/derive it and set it tho the voxel classes by template. Watchout when you reimplement a isMax() and isMin(). voxel-container doesnt save these voxel for memory-optimisation. Only return true on isMax() / isMin() if your are able to restore the state by setMin() / setMax(). setMin() has to to have the same results like the default contructor. More...

#include <data.hpp>

Inheritance diagram for blub::procedural::voxel::data:
data

Public Member Functions

 data ()
 data constructor
 
bool operator== (const data &other) const
 operator == compares interpolation. More...
 
bool operator!= (const data &other) const
 operator != compares interpolation. More...
 
void setInterpolation (const int8 &toSet)
 setInterpolation sets interpolation More...
 
int8 & getInterpolation ()
 getInterpolation returns reference to interpolation. More...
 
const int8 & getInterpolation () const
 getInterpolation returns const reference to interpolation. More...
 
bool isMax () const
 isMax checks if all values are maximum. See class description. More...
 
bool isMin () const
 isMin checks if all values are minimum. See class description. More...
 
void setMin ()
 setMin sets all values to minimum. See class description.
 
void setMax ()
 setMax sets all values to maximum. See class description.
 
void setInterpolationMin ()
 setInterpolationMin sets the interpolation to minimum.
 
void setInterpolationMax ()
 setInterpolationMax set interpolation to maximum.
 

Protected Attributes

int8 interpolation
 interpolation signed 8-bit interpolation value default used by voxel::tile::surface
 

Detailed Description

The data class is the default voxel. Contains an 8-bit interpolation value. Replace/derive it and set it tho the voxel classes by template. Watchout when you reimplement a isMax() and isMin(). voxel-container doesnt save these voxel for memory-optimisation. Only return true on isMax() / isMin() if your are able to restore the state by setMin() / setMax(). setMin() has to to have the same results like the default contructor.

Examples:
customVertexInformation.cpp, and mesh.cpp.

Member Function Documentation

int8& blub::procedural::voxel::data::getInterpolation ( )
inline

getInterpolation returns reference to interpolation.

Returns
const int8& blub::procedural::voxel::data::getInterpolation ( ) const
inline

getInterpolation returns const reference to interpolation.

Returns
bool blub::procedural::voxel::data::isMax ( ) const
inline

isMax checks if all values are maximum. See class description.

Returns
bool blub::procedural::voxel::data::isMin ( ) const
inline

isMin checks if all values are minimum. See class description.

Returns
bool blub::procedural::voxel::data::operator!= ( const data other) const
inline

operator != compares interpolation.

Parameters
other
Returns
bool blub::procedural::voxel::data::operator== ( const data other) const
inline

operator == compares interpolation.

Parameters
other
Returns
void blub::procedural::voxel::data::setInterpolation ( const int8 &  toSet)
inline

setInterpolation sets interpolation

Parameters
toSet

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