![]() |
MapLink Pro 11.1.1.0.
Envitia MapLink Pro: The Ultimate Mapping Application Toolkit
|
An output data object, which stores data in a 2-dimensional array.
Public Member Functions | |
TSLTerrainVSOutputArray (unsigned int width, unsigned int height, TSLMUExtent extent, const TSLTerrainVSOutput::dataItem &initialValue) | |
virtual bool | setData (unsigned int x, unsigned int y, const TSLTerrainVSOutput::dataUnion &value) |
virtual bool | getData (unsigned int x, unsigned int y, TSLTerrainVSOutput::dataItem &value) |
![]() | |
void | inc () |
void | dec () |
TSLTerrainVSOutput::dataType | type () const |
virtual bool | valid () const |
Additional Inherited Members | |
![]() | |
enum | dataType { typeTSLTerrainVSVisibility , typeShort , typeInt , typeFloat , typeDouble , typeBool } |
![]() | |
TSLTerrainVSOutput () | |
TSLTerrainVSOutput (const TSLTerrainVSOutput &other) | |
TSLTerrainVSOutput (unsigned int width, unsigned int height, TSLMUExtent extent, TSLTerrainVSOutput::dataType dataType=TSLTerrainVSOutput::typeTSLTerrainVSVisibility) | |
virtual | ~TSLTerrainVSOutput () |
![]() | |
unsigned int | m_width |
unsigned int | m_height |
TSLTerrainVSOutput::dataType | m_type |
TSLMUExtent | m_extent |
bool | m_valid |
Validity flag. | |
TSLTerrainVSOutputArray::TSLTerrainVSOutputArray | ( | unsigned int | width, |
unsigned int | height, | ||
TSLMUExtent | extent, | ||
const TSLTerrainVSOutput::dataItem & | initialValue ) |
Initialise the basic output object parameters, and setup the data array.
The array will be initialised with the initialValue parameter, which also specifies the internal data type of the array.
If the internal memory allocation fails or a zero width/height is passed, an error is added to the errorstack, the width and height member variables are zeroed and the valid function will fail (return false).
width | The number of horizontal elements in the output data array. |
height | The number of vertical elements in the output data array. |
extent | The extent of the output data, in map units. |
initialValue | The initial value of the array. |
|
virtual |
Query a value from the output data.
The location given to this method is specified as an offset, from the bottom-left of the data.
If the provided location is valid, the value will be populated, and this method will return true. If the input location is invalid, this method will return false.
x | The x offset to query |
y | The y offset to query |
value | Storage for the returned value |
Implements TSLTerrainVSOutput.
|
virtual |
Set a value in the output data.
The location given to this method is specified as an offset, from the bottom-left of the data. The provided value must have the same type as was specified in the constructor.
x | The x offset in the output data |
y | The y offset in the output data |
value | The value to set |
This method will return true if the data was set, or false if the location was invalid.
Implements TSLTerrainVSOutput.