Pyrogenesis
13997
|
Base class for texture-based terrain overlays, with an arbitrary number of texels per terrain tile, intended for debugging purposes. More...
#include <TerrainOverlay.h>
Public Member Functions | |
TerrainTextureOverlay (float texelsPerTile, int priority=100) | |
virtual | ~TerrainTextureOverlay () |
![]() | |
virtual | ~ITerrainOverlay () |
virtual void | RenderBeforeWater () |
Protected Member Functions | |
virtual void | BuildTextureRGBA (u8 *data, size_t w, size_t h)=0 |
Called each frame to generate the texture to render on the terrain. More... | |
![]() | |
ITerrainOverlay (int priority) | |
Private Member Functions | |
void | RenderAfterWater () |
Private Attributes | |
float | m_TexelsPerTile |
GLuint | m_Texture |
GLsizei | m_TextureW |
GLsizei | m_TextureH |
Additional Inherited Members | |
![]() | |
static void | RenderOverlaysBeforeWater () |
Draw all ITerrainOverlay objects that exist and that should be drawn before water. More... | |
static void | RenderOverlaysAfterWater () |
Draw all ITerrainOverlay objects that exist and that should be drawn after water. More... | |
Base class for texture-based terrain overlays, with an arbitrary number of texels per terrain tile, intended for debugging purposes.
Subclasses must implement BuildTextureRGBA which will be called each frame.
Definition at line 173 of file TerrainOverlay.h.
TerrainTextureOverlay::TerrainTextureOverlay | ( | float | texelsPerTile, |
int | priority = 100 |
||
) |
Definition at line 283 of file TerrainOverlay.cpp.
|
virtual |
Definition at line 289 of file TerrainOverlay.cpp.
|
protectedpure virtual |
Called each frame to generate the texture to render on the terrain.
data
is w*h*4 bytes, where w and h are the terrain size multiplied by texelsPerTile. data
defaults to fully transparent, and should be filled with data in RGBA order.
|
privatevirtual |
Reimplemented from ITerrainOverlay.
Definition at line 294 of file TerrainOverlay.cpp.
|
private |
Definition at line 192 of file TerrainOverlay.h.
|
private |
Definition at line 193 of file TerrainOverlay.h.
|
private |
Definition at line 194 of file TerrainOverlay.h.
|
private |
Definition at line 194 of file TerrainOverlay.h.