SUMO - Simulation of Urban MObility
NBHeightMapper::Triangle Class Reference

#include <NBHeightMapper.h>

Collaboration diagram for NBHeightMapper::Triangle:
Collaboration graph

Public Member Functions

void addSelf (const QueryResult &queryResult) const
 callback for RTree search More...
 
bool contains (const Position &pos) const
 checks whether pos lies within triangle (only checks x,y) More...
 
SUMOReal getZ (const Position &geo) const
 returns the projection of the give geoCoordinate (WGS84) onto triangle plane More...
 
Position normalVector () const
 returns the normal vector for this triangles plane More...
 
 Triangle (const PositionVector &corners)
 
 ~Triangle ()
 

Data Fields

PositionVector myCorners
 the corners of the triangle More...
 

Detailed Description

Definition at line 97 of file NBHeightMapper.h.

Constructor & Destructor Documentation

NBHeightMapper::Triangle::Triangle ( const PositionVector corners)

Definition at line 348 of file NBHeightMapper.cpp.

References myCorners.

NBHeightMapper::Triangle::~Triangle ( )
inline

Definition at line 101 of file NBHeightMapper.h.

References addSelf(), contains(), getZ(), normalVector(), and SUMOReal.

Member Function Documentation

void NBHeightMapper::Triangle::addSelf ( const QueryResult queryResult) const

callback for RTree search

Definition at line 356 of file NBHeightMapper.cpp.

References NBHeightMapper::QueryResult::triangles.

Referenced by ~Triangle().

bool NBHeightMapper::Triangle::contains ( const Position pos) const

checks whether pos lies within triangle (only checks x,y)

Definition at line 362 of file NBHeightMapper.cpp.

References PositionVector::around(), myCorners, and SUMOReal.

Referenced by NBHeightMapper::getZ(), and ~Triangle().

SUMOReal NBHeightMapper::Triangle::getZ ( const Position geo) const

returns the projection of the give geoCoordinate (WGS84) onto triangle plane

Definition at line 368 of file NBHeightMapper.cpp.

References Position::dotProduct(), myCorners, normalVector(), and Position::sub().

Referenced by NBHeightMapper::getZ(), and ~Triangle().

Position NBHeightMapper::Triangle::normalVector ( ) const

returns the normal vector for this triangles plane

Definition at line 379 of file NBHeightMapper.cpp.

References Position::crossProduct(), and myCorners.

Referenced by getZ(), and ~Triangle().

Field Documentation

PositionVector NBHeightMapper::Triangle::myCorners

the corners of the triangle

Definition at line 116 of file NBHeightMapper.h.

Referenced by contains(), getZ(), normalVector(), and Triangle().


The documentation for this class was generated from the following files: