6.6.3. Tag Description

<!-- TGS TerrainViz X.X -->

File header with TerrainViz version in XML comment format.

<TerrainViz>

Begins the file.

<data>

Begins the data block.

<format> <value> </format> Ex: <format> "REGULARGRID" </format>

Specifies the format. Can be "REGULARGRID" (data is organized in a 2D array). Default: "REGULARGRID".

<fileName> <value> </fileName> Ex: <fileName> "elevation.dat" </fileName>

Data file name between "".

<step> <value> </step> Ex: <step> (2.5E-4, 2.5E-4, 2.5E-4) </step>

Sample size along the three dimensions.

<realOffset> <value> </realOffset> Ex: <realOffset> (0., 0., 0.) </realOffset>

Offset of the terrain. The terrain starts at (x=0, y=0, z(0, 0)) by default. Default (0., 0., 0.).

<encoding> <value> </encoding> Ex: <encoding> "BIG_ENDIAN" </encoding>

Can be "LITTLE_ENDIAN" or "BIG_ENDIAN". UNIX systems are generally big endian whereas Intel systems are usually little endian. This field must refer to the system encoding where the binary file was created (necessary for binary files).

<openMode> <value> </openMode> Ex: <openMode> "BINARY" </openMode>

Can be "ASCII" or "BINARY". Tells if the file is binary or ASCII. In the binary case, the encoding field is necessary.

<type> <value> </type> Ex: <type> "UCHAR" </type>

Gives the data type (unsigned char, unsigned short, or float). Can be "UCHAR", "USHORT", "UINT", "FLOAT", "CHAR", "SHORT", "INT".

</data>

Ends the data block.

<texture>

Begins the texture block.

<fileName> <value> </fileName> Ex: <fileName> "tex00.jpg" </fileName>

Texture file name between "".

<level> <value> </level> Ex: <level> 0 </level>

Level of the texture. This is the level of the quadtree in which this texture appears. Levels start at 0.

<position> <value> </position> Ex: <position> (0, 0) </position>

Position of the texture. This is the position of the texture inside the level. Can be omitted if level is zero.

</texture>

Ends the texture block.

</TerrainViz>

Ends the file.

[Important]

Blocks are order independent. Fields within the parent block are order independent too. There should be one data block and zero or more texture blocks.