Specialisation of PageStrategyData for Grid2DPageStrategy. More...
#include <OgreGrid2DPageStrategy.h>
Public Member Functions | |
Grid2DPageStrategyData () | |
~Grid2DPageStrategyData () | |
void | calculateCell (PageID inPageID, int32 *x, int32 *y) |
PageID | calculatePageID (int32 x, int32 y) |
virtual void | convertGridToWorldSpace (const Vector2 &grid, Vector3 &world) |
Convert a grid point to world space - note only 2 axes populated. | |
virtual void | convertWorldToGridSpace (const Vector3 &world, Vector2 &grid) |
Convert a world point to grid space (not relative to origin) | |
void | determineGridLocation (const Vector2 &gridpos, int32 *x, int32 *y) |
Convert a grid position into a row and column index. | |
virtual void | getBottomLeftGridSpace (int32 x, int32 y, Vector2 &bl) |
Get the (grid space) bottom-left of a cell. | |
virtual int32 | getCellRangeMaxX () const |
get the index range of all cells (values outside this will be ignored) | |
virtual int32 | getCellRangeMaxY () const |
get the index range of all cells (values outside this will be ignored) | |
virtual int32 | getCellRangeMinX () const |
get the index range of all cells (values outside this will be ignored) | |
virtual int32 | getCellRangeMinY () const |
get the index range of all cells (values outside this will be ignored) | |
virtual Real | getCellSize () const |
Get the size of the cells in the grid. | |
virtual void | getCornersGridSpace (int32 x, int32 y, Vector2 *pFourPoints) |
Get the (grid space) corners of a cell. | |
virtual Real | getHoldRadius () const |
Get the Holding radius. | |
virtual Real | getHoldRadiusInCells () |
Get the Hold radius as a multiple of cells. | |
virtual Real | getLoadRadius () const |
Get the loading radius. | |
virtual Real | getLoadRadiusInCells () |
Get the load radius as a multiple of cells. | |
virtual void | getMidPointGridSpace (int32 x, int32 y, Vector2 &mid) |
Get the (grid space) mid point of a cell. | |
virtual Grid2DMode | getMode () const |
Set the grid alignment mode. | |
virtual const Vector3 & | getOrigin (const Vector3 &worldOrigin) |
Get the origin of the grid in world space. | |
bool | load (StreamSerialiser &stream) |
Load this data from a stream (returns true if successful) | |
void | operator delete (void *ptr) |
void | operator delete (void *ptr, const char *, int, const char *) |
void | operator delete (void *ptr, void *) |
void | operator delete[] (void *ptr) |
void | operator delete[] (void *ptr, const char *, int, const char *) |
void * | operator new (size_t sz) |
void * | operator new (size_t sz, const char *file, int line, const char *func) |
operator new, with debug line info | |
void * | operator new (size_t sz, void *ptr) |
placement operator new | |
void * | operator new[] (size_t sz) |
void * | operator new[] (size_t sz, const char *file, int line, const char *func) |
array operator new, with debug line info | |
void | save (StreamSerialiser &stream) |
Save this data to a stream. | |
virtual void | setCellRange (int32 minX, int32 minY, int32 maxX, int32 maxY) |
Set the index range of all cells (values outside this will be ignored) | |
virtual void | setCellRangeMaxX (int32 maxX) |
Set the index range of all cells (values outside this will be ignored) | |
virtual void | setCellRangeMaxY (int32 maxY) |
Set the index range of all cells (values outside this will be ignored) | |
virtual void | setCellRangeMinX (int32 minX) |
Set the index range of all cells (values outside this will be ignored) | |
virtual void | setCellRangeMinY (int32 minY) |
Set the index range of all cells (values outside this will be ignored) | |
virtual void | setCellSize (Real sz) |
Set the size of the cells in the grid. | |
virtual void | setHoldRadius (Real sz) |
Set the Holding radius. | |
virtual void | setLoadRadius (Real sz) |
Set the loading radius. | |
virtual void | setMode (Grid2DMode mode) |
Set the grid alignment mode. | |
virtual void | setOrigin (const Vector3 &worldOrigin) |
Set the origin of the grid in world space. | |
Static Public Attributes | |
static const uint32 | CHUNK_ID |
static const uint16 | CHUNK_VERSION |
Protected Member Functions | |
void | updateDerivedMetrics () |
Protected Attributes | |
Real | mCellSize |
Grid cell (page) size. | |
Real | mHoldRadius |
Hold radius. | |
Real | mHoldRadiusInCells |
Real | mLoadRadius |
Load radius. | |
Real | mLoadRadiusInCells |
int32 | mMaxCellX |
int32 | mMaxCellY |
int32 | mMinCellX |
int32 | mMinCellY |
Grid2DMode | mMode |
Orientation of the grid. | |
Vector2 | mOrigin |
Origin (grid-aligned world space) | |
Vector3 | mWorldOrigin |
Origin (world space) | |
Specialisation of PageStrategyData for Grid2DPageStrategy.
Name | Type | Description |
Grid orientation | uint8 | The orientation of the grid; XZ = 0, XY = 1, YZ = 2 |
Grid origin | Vector3 | World origin of the grid. |
Grid cell size | Real | The size of each cell (page) in the grid |
Grid cell range (minx, maxx, miny, maxy) | int16 * 4 | The extents of the world in cell indexes |
Load radius | Real | The outer radius at which new pages should start loading |
Hold radius | Real | The radius at which existing pages should be held if already loaded but not actively loaded (should be larger than Load radius) |
Definition at line 120 of file OgreGrid2DPageStrategy.h.
Ogre::Grid2DPageStrategyData::Grid2DPageStrategyData | ( | ) |
Ogre::Grid2DPageStrategyData::~Grid2DPageStrategyData | ( | ) |
|
virtual |
Convert a grid point to world space - note only 2 axes populated.
|
virtual |
Convert a world point to grid space (not relative to origin)
void Ogre::Grid2DPageStrategyData::determineGridLocation | ( | const Vector2 & | gridpos, |
int32 * | x, | ||
int32 * | y | ||
) |
Convert a grid position into a row and column index.
|
virtual |
Get the (grid space) bottom-left of a cell.
get the index range of all cells (values outside this will be ignored)
Definition at line 193 of file OgreGrid2DPageStrategy.h.
get the index range of all cells (values outside this will be ignored)
Definition at line 195 of file OgreGrid2DPageStrategy.h.
get the index range of all cells (values outside this will be ignored)
Definition at line 189 of file OgreGrid2DPageStrategy.h.
get the index range of all cells (values outside this will be ignored)
Definition at line 191 of file OgreGrid2DPageStrategy.h.
Get the size of the cells in the grid.
Definition at line 164 of file OgreGrid2DPageStrategy.h.
|
virtual |
Get the (grid space) corners of a cell.
Get the Holding radius.
Definition at line 172 of file OgreGrid2DPageStrategy.h.
Get the Hold radius as a multiple of cells.
Definition at line 176 of file OgreGrid2DPageStrategy.h.
Get the loading radius.
Definition at line 168 of file OgreGrid2DPageStrategy.h.
Get the load radius as a multiple of cells.
Definition at line 174 of file OgreGrid2DPageStrategy.h.
|
virtual |
Get the (grid space) mid point of a cell.
|
virtual |
Set the grid alignment mode.
Definition at line 155 of file OgreGrid2DPageStrategy.h.
|
virtual |
Get the origin of the grid in world space.
Definition at line 160 of file OgreGrid2DPageStrategy.h.
|
virtual |
Load this data from a stream (returns true if successful)
Implements Ogre::PageStrategyData.
Definition at line 96 of file OgreMemoryAllocatedObject.h.
|
inherited |
Definition at line 108 of file OgreMemoryAllocatedObject.h.
Definition at line 102 of file OgreMemoryAllocatedObject.h.
|
inherited |
Definition at line 113 of file OgreMemoryAllocatedObject.h.
|
inherited |
Definition at line 119 of file OgreMemoryAllocatedObject.h.
Definition at line 73 of file OgreMemoryAllocatedObject.h.
|
inherited |
operator new, with debug line info
Definition at line 68 of file OgreMemoryAllocatedObject.h.
placement operator new
Definition at line 79 of file OgreMemoryAllocatedObject.h.
Definition at line 91 of file OgreMemoryAllocatedObject.h.
|
inherited |
array operator new, with debug line info
Definition at line 86 of file OgreMemoryAllocatedObject.h.
|
virtual |
Save this data to a stream.
Implements Ogre::PageStrategyData.
|
virtual |
Set the index range of all cells (values outside this will be ignored)
Set the index range of all cells (values outside this will be ignored)
Set the index range of all cells (values outside this will be ignored)
Set the index range of all cells (values outside this will be ignored)
Set the index range of all cells (values outside this will be ignored)
Set the size of the cells in the grid.
|
virtual |
Set the grid alignment mode.
Set the origin of the grid in world space.
|
protected |
Definition at line 145 of file OgreGrid2DPageStrategy.h.
Definition at line 146 of file OgreGrid2DPageStrategy.h.
|
protected |
Grid cell (page) size.
Definition at line 130 of file OgreGrid2DPageStrategy.h.
|
protected |
Hold radius.
Definition at line 134 of file OgreGrid2DPageStrategy.h.
|
protected |
Definition at line 136 of file OgreGrid2DPageStrategy.h.
|
protected |
Load radius.
Definition at line 132 of file OgreGrid2DPageStrategy.h.
|
protected |
Definition at line 135 of file OgreGrid2DPageStrategy.h.
|
protected |
Definition at line 139 of file OgreGrid2DPageStrategy.h.
|
protected |
Definition at line 140 of file OgreGrid2DPageStrategy.h.
|
protected |
Definition at line 137 of file OgreGrid2DPageStrategy.h.
|
protected |
Definition at line 138 of file OgreGrid2DPageStrategy.h.
|
protected |
Orientation of the grid.
Definition at line 124 of file OgreGrid2DPageStrategy.h.
|
protected |
Origin (grid-aligned world space)
Definition at line 128 of file OgreGrid2DPageStrategy.h.
|
protected |
Origin (world space)
Definition at line 126 of file OgreGrid2DPageStrategy.h.
Copyright © 2012 Torus Knot Software Ltd
This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 Unported License.