Torque Shader Engine DocumentationCVS Revision Label 0.1.x |
This section discusses three major aspects of the Atlas engine runtime: the script interface, the runtime parameters, and the C++ code layout. Together, knowledge of these sections will result in familiarity with how the runtime operates.
The Atlas engine resides in the Atlas sub directory. The header files are annotated with Doxygen-compatible comments, which fully explain the functioning of the various classes and components of the terrain. The terrain itself is self-contained, and should not require any modifications to existing objects to work properly.
If you should require a C++ reference, simply run doxygen on the TSE codebase and refer to the appropriate sections. Or, you can read the comments, which are what the Doxygen documentation is generated from.
There is only one class exposed to the script system, AtlasInstance. Beyond the position and rotation fields, these are the other important fields:
AtlasInstance Fields
Path to the .TQT file for this instance.
Path to the .CHU file for this instance.
Detail texture for the terrain.
Name of the CustomMaterial used to render this instance. "AtlasMaterial" by default, and likely best to leave it that way. Don't change this if you don't know what you're doing. Will not work except with custom shaders!
There is one method of note, which is purge(). This method causes all paged-in resources for the geometry and texture files to be unloaded, forcing the system to page everything in from scratch.
Runtime parameters can be access from the console to control various aspects of the runtime behavior of the Atlas engine. They have global, immediate effect, and are not networked.
Atlas Engine Runtime Parameters
In engine/atlas/atlasTQTFile.cpp, there is a variable AtlasTQTFile::smDumpGeneratedTextures, which controls a debug feature of the TQT generation code. If set to true, it will cause every subtexture generated by the TQT code to be dumped to the current working directory of the game. This is useful for diagnosing problems with the generation code.