|
Represent a terrain object in a Torque 3D level. More...
Public Member Functions | |
bool | exportHeightMap (string filename,[string format]) |
export the terrain block's heightmap to a bitmap file (default: png) | |
bool | exportLayerMaps (string filePrefix,[string format]) |
export the terrain block's layer maps to bitmap files (default: png) | |
int | import (String terrainName, String heightMap, F32 metersPerPixel, F32 heightScale, String materials, String opacityLayers) |
bool | save (string fileName) |
Saves the terrain block's terrain file to the specified file name. | |
Public Attributes | |
int | createNew |
TerrainBlock.create( String terrainName, U32 resolution, String materialName, bool genNoise ). | |
Misc | |
int | baseTexSize |
Size of base texture size per meter. | |
bool | castShadows |
Allows the terrain to cast shadows onto itself and other objects. | |
int | lightMapSize |
Light map dimensions in pixels. | |
int | screenError |
Not yet implemented. | |
float | squareSize |
Indicates the spacing between points on the XY plane on the terrain. | |
Media | |
filename | terrainFile |
The source terrain data file. | |
Static Public Attributes | |
static bool | debugRender |
Triggers debug rendering of terrain cells. | |
static bool | isRenderable |
Disables rendering of all instances of this type. | |
static bool | isSelectable |
Disables selection of all instances of this type. |
Represent a terrain object in a Torque 3D level.
new TerrainBlock(theTerrain) { terrainFile = "art/terrains/Deathball Desert_0.ter"; squareSize = "2"; tile = "0"; baseTexSize = "1024"; screenError = "16"; position = "-1024 -1024 179.978"; rotation = "1 0 0 0"; scale = "1 1 1"; isRenderEnabled = "true"; canSaveDynamicFields = "1"; };
bool TerrainBlock::exportHeightMap | ( | string | filename | ) |
export the terrain block's heightmap to a bitmap file (default: png)
bool TerrainBlock::exportLayerMaps | ( | string | filePrefix | ) |
export the terrain block's layer maps to bitmap files (default: png)
int TerrainBlock::import | ( | String | terrainName, | |
String | heightMap, | |||
F32 | metersPerPixel, | |||
F32 | heightScale, | |||
String | materials, | |||
String | opacityLayers | |||
) |
bool TerrainBlock::save | ( | string | fileName | ) |
Saves the terrain block's terrain file to the specified file name.
fileName | Name and path of file to save terrain data to. |
Size of base texture size per meter.
Allows the terrain to cast shadows onto itself and other objects.
TerrainBlock.create( String terrainName, U32 resolution, String materialName, bool genNoise ).
bool TerrainBlock::isRenderable [static] |
Disables rendering of all instances of this type.
Reimplemented from SceneObject.
bool TerrainBlock::isSelectable [static] |
Disables selection of all instances of this type.
Reimplemented from SceneObject.
Light map dimensions in pixels.
Not yet implemented.
float TerrainBlock::squareSize |
Indicates the spacing between points on the XY plane on the terrain.
filename TerrainBlock::terrainFile |
The source terrain data file.