OpenMW
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
Public Member Functions | Protected Attributes | List of all members
Terrain::World Class Reference

The basic interface for a terrain world. How the terrain chunks are paged and displayed is up to the implementation. More...

#include <world.hpp>

Inheritance diagram for Terrain::World:
Collaboration diagram for Terrain::World:

Public Member Functions

 World (osg::Group *parent, Resource::ResourceSystem *resourceSystem, osgUtil::IncrementalCompileOperation *ico, Storage *storage, int nodeMask)
 
virtual ~World ()
 
virtual void updateTextureFiltering ()
 
virtual void updateCache ()
 
float getHeightAt (const osg::Vec3f &worldPos)
 
virtual osg::ref_ptr< osg::Node > cacheCell (int x, int y)
 
virtual void loadCell (int x, int y)
 
virtual void unloadCell (int x, int y)
 
StoragegetStorage ()
 

Protected Attributes

StoragemStorage
 
osg::ref_ptr< osg::Group > mParent
 
osg::ref_ptr< osg::Group > mTerrainRoot
 
Resource::ResourceSystemmResourceSystem
 
osg::ref_ptr
< osgUtil::IncrementalCompileOperation > 
mIncrementalCompileOperation
 

Detailed Description

The basic interface for a terrain world. How the terrain chunks are paged and displayed is up to the implementation.

Constructor & Destructor Documentation

Terrain::World::World ( osg::Group *  parent,
Resource::ResourceSystem resourceSystem,
osgUtil::IncrementalCompileOperation *  ico,
Storage storage,
int  nodeMask 
)
Note
takes ownership of storage
Parameters
storageStorage instance to get terrain data from (heights, normals, colors, textures..)
nodeMaskmask for the terrain root
Terrain::World::~World ( )
virtual

Member Function Documentation

virtual osg::ref_ptr<osg::Node> Terrain::World::cacheCell ( int  x,
int  y 
)
inlinevirtual

Reimplemented in Terrain::TerrainGrid.

Here is the caller graph for this function:

float Terrain::World::getHeightAt ( const osg::Vec3f &  worldPos)

Here is the call graph for this function:

Storage* Terrain::World::getStorage ( )
inline
virtual void Terrain::World::loadCell ( int  x,
int  y 
)
inlinevirtual

Reimplemented in Terrain::TerrainGrid.

virtual void Terrain::World::unloadCell ( int  x,
int  y 
)
inlinevirtual

Reimplemented in Terrain::TerrainGrid.

virtual void Terrain::World::updateCache ( )
inlinevirtual

Reimplemented in Terrain::TerrainGrid.

Here is the caller graph for this function:

virtual void Terrain::World::updateTextureFiltering ( )
inlinevirtual

Reimplemented in Terrain::TerrainGrid.

Member Data Documentation

osg::ref_ptr<osgUtil::IncrementalCompileOperation> Terrain::World::mIncrementalCompileOperation
protected
osg::ref_ptr<osg::Group> Terrain::World::mParent
protected
Resource::ResourceSystem* Terrain::World::mResourceSystem
protected
Storage* Terrain::World::mStorage
protected
osg::ref_ptr<osg::Group> Terrain::World::mTerrainRoot
protected

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