GraphicalLandscapeMap Class Reference

#include <GraphicalLandscapeMap.h>

Inheritance diagram for GraphicalLandscapeMap:

GraphicalHeightMap

List of all members.

Public Member Functions

 GraphicalLandscapeMap ()
virtual ~GraphicalLandscapeMap ()
void create (int width, int height)
void reset ()
void updateWholeBuffer ()
virtual void setHeight (int w, int h, float height)
virtual void setNormal (int w, int h, Vector &normal)
int getMapWidth ()
int getMapHeight ()
HeightDatagetHeightData ()
GLVertexBufferObjectgetBufferObject ()

Protected Attributes

int width_
int height_
int bufferSizeBytes_
HeightDataheightData_
GLVertexBufferObjectbufferObject_

Classes

struct  HeightData


Detailed Description

Definition at line 28 of file GraphicalLandscapeMap.h.


Constructor & Destructor Documentation

GraphicalLandscapeMap::GraphicalLandscapeMap (  ) 

Definition at line 26 of file GraphicalLandscapeMap.cpp.

GraphicalLandscapeMap::~GraphicalLandscapeMap (  )  [virtual]

Definition at line 32 of file GraphicalLandscapeMap.cpp.

References heightData_.


Member Function Documentation

void GraphicalLandscapeMap::create ( int  width,
int  height 
) [virtual]

Implements GraphicalHeightMap.

Definition at line 37 of file GraphicalLandscapeMap.cpp.

References bufferObject_, bufferSizeBytes_, GLVertexBufferObject::get_map_size(), GL_STATIC_DRAW, GLStateExtension::hasVBO(), height_, heightData_, GLVertexBufferObject::init_data(), reset(), and width_.

void GraphicalLandscapeMap::reset (  ) 

Definition at line 60 of file GraphicalLandscapeMap.cpp.

References GraphicalLandscapeMap::HeightData::floatNormal, GraphicalLandscapeMap::HeightData::floatPosition, height_, heightData_, GraphicalLandscapeMap::HeightData::texCoord1x, GraphicalLandscapeMap::HeightData::texCoord1y, GraphicalLandscapeMap::HeightData::texCoord2x, GraphicalLandscapeMap::HeightData::texCoord2y, and width_.

Referenced by create().

void GraphicalLandscapeMap::updateWholeBuffer (  ) 

Definition at line 106 of file GraphicalLandscapeMap.cpp.

References bufferObject_, bufferSizeBytes_, GL_STATIC_DRAW, GLStateExtension::hasVBO(), heightData_, and GLVertexBufferObject::init_data().

Referenced by Landscape::generate(), and Landscape::simulate().

void GraphicalLandscapeMap::setHeight ( int  w,
int  h,
float  height 
) [virtual]

Implements GraphicalHeightMap.

Definition at line 90 of file GraphicalLandscapeMap.cpp.

References DIALOG_ASSERT, GraphicalLandscapeMap::HeightData::floatPosition, height_, heightData_, and width_.

void GraphicalLandscapeMap::setNormal ( int  w,
int  h,
Vector normal 
) [virtual]

Implements GraphicalHeightMap.

Definition at line 98 of file GraphicalLandscapeMap.cpp.

References DIALOG_ASSERT, GraphicalLandscapeMap::HeightData::floatNormal, height_, heightData_, and width_.

int GraphicalLandscapeMap::getMapWidth (  )  [inline]

Definition at line 50 of file GraphicalLandscapeMap.h.

References width_.

int GraphicalLandscapeMap::getMapHeight (  )  [inline]

Definition at line 51 of file GraphicalLandscapeMap.h.

References height_.

HeightData* GraphicalLandscapeMap::getHeightData (  )  [inline]

Definition at line 53 of file GraphicalLandscapeMap.h.

References heightData_.

Referenced by LandVisibilityPatch::draw(), LandVisibilityPatch::drawLODLevel(), and getHeight().

GLVertexBufferObject* GraphicalLandscapeMap::getBufferObject (  )  [inline]

Definition at line 54 of file GraphicalLandscapeMap.h.

References bufferObject_.

Referenced by LandVisibilityPatch::draw(), and VisibilityPatchGrid::drawLand().


Member Data Documentation

int GraphicalLandscapeMap::width_ [protected]

Definition at line 57 of file GraphicalLandscapeMap.h.

Referenced by create(), getMapWidth(), reset(), setHeight(), and setNormal().

int GraphicalLandscapeMap::height_ [protected]

Definition at line 57 of file GraphicalLandscapeMap.h.

Referenced by create(), getMapHeight(), reset(), setHeight(), and setNormal().

int GraphicalLandscapeMap::bufferSizeBytes_ [protected]

Definition at line 58 of file GraphicalLandscapeMap.h.

Referenced by create(), and updateWholeBuffer().

HeightData* GraphicalLandscapeMap::heightData_ [protected]

Definition at line 59 of file GraphicalLandscapeMap.h.

Referenced by create(), getHeightData(), reset(), setHeight(), setNormal(), updateWholeBuffer(), and ~GraphicalLandscapeMap().

GLVertexBufferObject* GraphicalLandscapeMap::bufferObject_ [protected]

Definition at line 60 of file GraphicalLandscapeMap.h.

Referenced by create(), getBufferObject(), and updateWholeBuffer().


The documentation for this class was generated from the following files:
Generated on Mon Feb 16 15:15:03 2009 for Scorched3D by  doxygen 1.5.3