![]() |
MapLink Pro 11.1.1.0.
Envitia MapLink Pro: The Ultimate Mapping Application Toolkit
|
3D sensor specific access methods.
A 3D sensor represents a volume of space that is within a given radius from a point in 3D space. The azimuth and elevation angles are used to limit this volume to certain creation directions.
This class represents the access methods that are specific to a 3D sensor. They also allow setting of the various attributes.
Public Member Functions | |
const TSL3DCoord & | centre () const |
void | centre (const TSL3DCoord &coord) |
bool | ENURotation () const |
void | ENURotation (bool newValue) |
bool | isPointInVolume (const TSLCoord &point) const |
bool | isPointInVolume (const TSL3DCoord &point) const |
double | maximumAzimuth () const |
void | maximumAzimuth (double newValue) |
double | maximumElevation () const |
void | maximumElevation (double newValue) |
double | minimumAzimuth () const |
void | minimumAzimuth (double newValue) |
double | minimumElevation () const |
void | minimumElevation (double newValue) |
double | radius () const |
void | radius (double newRadius) |
double | xRotation () const |
void | xRotation (double newRotation) |
double | yRotation () const |
void | yRotation (double newRotation) |
double | zRotation () const |
void | zRotation (double newRotation) |
![]() | |
TSL3DBoundingBox | boundingBox (int surfaceID=-1) const |
void | boundingBox (TSL3DCoord &bottomLeft, TSL3DCoord &topRight, int surfaceID=-1) const |
TSL3DCoord | centroid () const |
TSL3DEntity * | clone () const |
double | distance (const TSL3DCoord &point, bool useRenderedExtent=true, int drawingSurfaceID=-1) const |
bool | equals (const TSL3DEntity *other) const |
void | move (const TSL3DCoord &location, const TSL3DCoord &reference) |
TSL3DEntitySet * | parent () |
const TSL3DEntitySet * | parent () const |
void | scale (double scaleParam, const TSL3DCoord *origin=0) |
void | scale (double scaleX, double scaleY, double scaleZ, const TSL3DCoord *origin=0) |
double | squareDistance (const TSL3DCoord &point, bool useRenderedExtent=true, int drawingSurfaceID=-1) const |
void | translate (double latitudeOffset, double longitudeOffset, double altitudeOffset) |
![]() | |
bool | addDataSet () |
bool | addDataSet (TSLDataHandler *toUseDataHandler) |
bool | clearRenderingAttributes () |
TSLDataSet * | dataSet () |
const TSLDataSet * | dataSet () const |
short | dataSourceID () const |
void | dataSourceID (short dataSourceID) |
bool | deleteDataSet () |
void | destroy () |
TSLEntityID | entityID () const |
void | entityID (TSLEntityID value) |
TSLFeatureID | featureID () const |
void | featureID (TSLFeatureID newValue) |
bool | getRendering (TSLRenderingAttributeInt attribute, int *result) const |
bool | getRendering (TSLRenderingAttributeDouble attribute, double *result) const |
bool | getRendering (TSLRenderingAttributeBool attribute, bool *result) const |
bool | getRendering (TSLRenderingAttributes &result) const |
TSL3DEntity * | is3DEntity () |
const TSL3DEntity * | is3DEntity () const |
TSLEntity * | isEntity () |
const TSLEntity * | isEntity () const |
bool | isOptimisedEntity () const |
void | name (const char *newValue) |
const char * | name () const |
void | releaseResources (int surfaceID) |
bool | setRendering (TSLRenderingAttributeInt attribute, int value) |
bool | setRendering (TSLRenderingAttributeDouble attribute, double value) |
bool | setRendering (TSLRenderingAttributeBool attribute, bool value) |
bool | setRendering (const TSLRenderingAttributes &attributes) |
void | sourceID (int value) |
int | sourceID () const |
TSLGeometryType | type () const |
void | version (TSLVersion value) |
TSLVersion | version () const |
Static Public Member Functions | |
static TSL3DSensor * | create (TSLFeatureID featureID, const TSL3DCoord &coord, double radius, double minAzimuth, double maxAzimuth, double minElevation, double maxElevation, bool ENURotation=true, double rotationX=0.0, double rotationY=0.0, double rotationZ=0.0) |
static TSL3DSensor * | is3DSensor (TSL3DEntity *entity) |
static const TSL3DSensor * | is3DSensor (const TSL3DEntity *entity) |
Additional Inherited Members | |
![]() | |
~TSLEntityBase () | |
const TSL3DCoord & TSL3DSensor::centre | ( | ) | const |
Returns the 3D sensor's coord.
void TSL3DSensor::centre | ( | const TSL3DCoord & | coord | ) |
Sets the 3D sensor's coord.
The sensor will be drawn with its reference point at the specified position.
coord | coord value to set |
|
static |
Static method for the creation of new TSL3DSensor.
This call should only be used for temporary entities. For example, this call may be used to create entities that are used in the spatial tests.
featureID | ID of the feature code to assign to the entity. This is used when rendering map features if no specific attribute set has been created for the entity. |
coord | Coordinate at which to place the 3d sensor |
radius | Radius of the sensor in metres, this is dependent on the ENURotation flag |
minAzimuth | Minimum sweep angle in the unrotated z-axis, specified in radians where +ve is the same as the +ve z-axis; this is dependent on the ENURotation flag |
maxAzimuth | Maximum sweep angle in the unrotated z-axis, specified in radians where +ve is the same as the +ve z-axis; this is dependent on the ENURotation flag |
minElevation | Minimum sweep angle in the unrotated y-axis, specified in radians where +ve is the same as the +ve y-axis; this is dependent on the ENURotation flag |
maxElevation | Maximum sweep angle in the unrotated y-axis, specified in radians where +ve is the same as the +ve y-axis; this is dependent on the ENURotation flag |
ENURotation | Set whether to use geocentric coordinate space for the rotations of the sensor or Easting, Northing and Up from the sensor's coord tangentally on the earth. With this flag set to false, the sensor is created down the x-axis, rotated and then translated; set to true and the sensor is created down the easting axis, rotated and translated. This value also determines how the azimuth and elevation angles are interpreted; set to false then the azimuth and elevation sweep in the unrotated z and y axes respectively, set to true then they sweep in the unrotated Up and Northing axes respectively. |
rotationX | Rotation about the x-axis, anti-clockwise being +ve, in radians; this is dependent on the ENURotation flag |
rotationY | Rotation about the y-axis, anti-clockwise being +ve, in radians; this is dependent on the ENURotation flag |
rotationZ | Rotation about the z-axis, anti-clockwise being +ve, in radians; this is dependent on the ENURotation flag |
bool TSL3DSensor::ENURotation | ( | ) | const |
Returns whether ENU rotation is used. ENU, standing for East, North and Up, determines how the rotation angles are interpreted.
If the ENURotation flag is set to true, then rotations are applied to the sensor once it has been translated so that its plane is tangental to the earth's surface. In this case the x-axis is in the east direction, the y-axis is in the north direction and the z-axis is up, or the vector from the centre of the earth to the center point of the ellipse.
If the ENURotation flag is set to false, then rotations are applied to the sensor in geocentric coordinate space. In this case the x-axis is the vector from the centre of the earth towards the geodetic location 0 degrees latitude and 0 degrees longitude, the y-axis is the vector from the centre of the earth towards the geodetic location 0 degrees latitude and 90 degrees longitude and the z-axis is the vector from the centre of the earth towards the north pole.
This value also determines how the azimuth and elevation angles are interpreted; set to false then the azimuth and elevation sweep in the unrotated z and y axes respectively, set to true then they sweep in the unrotated Up and Northing axes respectively.
void TSL3DSensor::ENURotation | ( | bool | newValue | ) |
Sets whether ENU rotation is used. ENU, standing for East, North and Up, determines how the rotation angles are interpreted.
If the ENURotation flag is set to true, then rotations are applied to the sensor once it has been translated so that its plane is tangental to the earth's surface. In this case the x-axis is in the east direction, the y-axis is in the north direction and the z-axis is up, or the vector from the centre of the earth to the center point of the sensor.
If the ENURotation flag is set to false, then rotations are applied to the sensor in geocentric coordinate space. In this case the x-axis is the vector from the centre of the earth towards the geodetic location 0 degrees latitude and 0 degrees longitude, the y-axis is the vector from the centre of the earth towards the geodetic location 0 degrees latitude and 90 degrees longitude and the z-axis is the vector from the centre of the earth towards the north pole.
This value also determines how the azimuth and elevation angles are interpreted; set to false then the azimuth and elevation sweep in the unrotated z and y axes respectively, set to true then they sweep in the unrotated Up and Northing axes respectively.
newValue | The new value for the ENURotation flag. |
|
static |
Query whether the entity is a 3d ellipse.
If this entity is a 3D ellipse, returns an accessor, otherwise returns NULL.
entity | the entity to query. |
|
static |
Query whether the entity is a 3d sensor.
If this entity is a 3D sensor, returns an accessor, otherwise returns NULL.
entity | the entity to query. |
bool TSL3DSensor::isPointInVolume | ( | const TSL3DCoord & | point | ) | const |
This method checks to see if the specified point is contained within the sensor volume.
This method takes a TSLCoord where the altitude is assumed to be 0 (Sea Level). The position is in TMCs.
The tests performed are as follows:
Check to see if point is the center point - if yes return true. Check to see if the point fits within the bounding sphere. If not return false. Check to see of the point fits in the elevation and azimuth angles. If it does return true, if not return false.
This does mean that if the point is on the boundary of the elevation and azimuth angles false is returned.
Argument Description:
point : A 3D position to check containment of.
Returns true if the point is in the sensor volume, false otherwise.
bool TSL3DSensor::isPointInVolume | ( | const TSLCoord & | point | ) | const |
This method checks to see if the specified point is contained within the sensor volume.
This method takes a TSLCoord where the altitude is assumed to be 0 (Sea Level). The position is in TMCs.
The tests performed are as follows:
Check to see if point is the center point - if yes return true. Check to see if the point fits within the bounding sphere. If not return false. Check to see of the point fits in the elevation and azimuth angles. If it does return true, if not return false.
This does mean that if the point is on the boundary of the elevation and azimuth angles false is returned.
Argument Description:
point: A 2D position represented in TMC to check containment of.
Returns true if the point is in the sensor volume, false otherwise.
double TSL3DSensor::maximumAzimuth | ( | ) | const |
Retrieves the maximum azimuth angle in radians. This defines the maximum sweep angle in the unrotated z-axis. If the ENURotation flag is set to true, then this value is the sweep in the unrotated Up axis.
void TSL3DSensor::maximumAzimuth | ( | double | newValue | ) |
Sets the maximum azimuth angle in radians. This defines the maximum sweep angle in the unrotated z-axis. If the ENURotation flag is set to true, then this value is the sweep in the unrotated Up axis.
double TSL3DSensor::maximumElevation | ( | ) | const |
Retrieves the maximum elevation angle in radians. This defines the maximum sweep angle in the unrotated y-axis. If the ENURotation flag is set to true, then this value is the sweep in the unrotated Northing axis.
void TSL3DSensor::maximumElevation | ( | double | newValue | ) |
Sets the maximum elevation angle in radians. This defines the maximum sweep angle in the unrotated y-axis. If the ENURotation flag is set to true, then this value is the sweep in the unrotated Northing axis.
double TSL3DSensor::minimumAzimuth | ( | ) | const |
Retrieves the minimum azimuth angle in radians. This defines the minimum sweep angle in the unrotated z-axis. If the ENURotation flag is set to true, then this value is the sweep in the unrotated Up axis.
void TSL3DSensor::minimumAzimuth | ( | double | newValue | ) |
Sets the minimum azimuth angle in radians. This defines the minimum sweep angle in the unrotated z-axis. If the ENURotation flag is set to true, then this value is the sweep in the unrotated Up axis.
double TSL3DSensor::minimumElevation | ( | ) | const |
Retrieves the minimum elevation angle in radians. This defines the minimum sweep angle in the unrotated y-axis. If the ENURotation flag is set to true, then this value is the sweep in the unrotated Northing axis.
void TSL3DSensor::minimumElevation | ( | double | newValue | ) |
Sets the minimum elevation angle in radians. This defines the minimum sweep angle in the unrotated y-axis. If the ENURotation flag is set to true, then this value is the sweep in the unrotated Northing axis.
double TSL3DSensor::radius | ( | ) | const |
Returns the 3D Sensor's radius.
void TSL3DSensor::radius | ( | double | newRadius | ) |
Sets the 3D Sensor's radius.
newRadius | The new sensor radius in metres |
double TSL3DSensor::xRotation | ( | ) | const |
Returns the 3D Sensor's rotation about the x-axis, anti-clockwise being +ve, in radians. If the ENURotation flag is set to true, then this value is about the Easting axis.
void TSL3DSensor::xRotation | ( | double | newRotation | ) |
Sets the 3D Sensor's rotation about the x-axis, anti-clockwise being +ve, in radians. If the ENURotation flag is set to true, then this value is about the Easting axis.
newRotation | The new rotation value. |
double TSL3DSensor::yRotation | ( | ) | const |
Returns the 3D Sensor's rotation about the y-axis, anti-clockwise being +ve, in radians. If the ENURotation flag is set to true, then this value is about the Northing axis.
void TSL3DSensor::yRotation | ( | double | newRotation | ) |
Sets the 3D Sensor's rotation about the y-axis, anti-clockwise being +ve, in radians. If the ENURotation flag is set to true, then this value is about the Northing axis.
newRotation | The new rotation value. |
double TSL3DSensor::zRotation | ( | ) | const |
Returns the 3D Sensor's rotation about the z-axis, anti-clockwise being +ve, in radians. If the ENURotation flag is set to true, then this value is about the Up axis.
void TSL3DSensor::zRotation | ( | double | newRotation | ) |
Sets the 3D Sensor's rotation about the z-axis, anti-clockwise being +ve, in radians. If the ENURotation flag is set to true, then this value is about the Up axis.
newRotation | The new rotation value. |