proland::RoadElevationLayer::RoadElevationCurveData Class Reference

An ElevationCurveData for road elevation profiles. More...

#include <RoadElevationLayer.h>

Inheritance diagram for proland::RoadElevationLayer::RoadElevationCurveData:
proland::ElevationCurveData proland::CurveData

List of all members.

Public Types

enum  roadType { ,
  ROAD = 0,
  UNKNOWN = 1,
  BRIDGE = 2
}
 

Predefined types for roads.

More...

Public Member Functions

 RoadElevationCurveData (CurveId id, CurvePtr flattenCurve, ptr< TileProducer > elevations)
 Creates a new RoadElevationCurveData.
 ~RoadElevationCurveData ()
 Deletes this RoadElevationCurveData.
virtual float getStartHeight ()
 Returns the height of the starting point of the curve.
virtual float getEndHeight ()
 Returns the height of the ending point of the curve.
virtual float getAltitude (float s)
 Returns the height corresponding to the given s coordinate.
virtual void getUsedTiles (set< TileCache::Tile::Id > &tiles, float rootSampleLength)
 Returns the list of tiles intersected by the curve with which this ElevationCurveData is associated.

Protected Member Functions

virtual float getCapLength (NodePtr p, vec2d q)
 Computes the cap length at a given extremity.

Protected Attributes

bool startBridge
 True if the starting point of the road is connected to a bridge.
bool endBridge
 True if the ending point of the road is connected to a bridge.
float startBridgez
 Elevation at the starting point of the road, if connected to a bridge.
float endBridgez
 Elevation at the ending point of the road, if connected to a bridge.
bool initBridges
 True if extremities were checked.

Detailed Description

An ElevationCurveData for road elevation profiles.


Member Enumeration Documentation

Predefined types for roads.

Used for drawing and managing roads.

Enumerator:
ROAD 

Basic road.

UNKNOWN 

Undefined.

BRIDGE 

Bridge linking 2 roads, passing on top of another.


Constructor & Destructor Documentation

proland::RoadElevationLayer::RoadElevationCurveData::RoadElevationCurveData ( CurveId  id,
CurvePtr  flattenCurve,
ptr< TileProducer >  elevations 
)

Creates a new RoadElevationCurveData.

Parameters:
id the id of the curve for which we need to store the data.
flattenCurve the flattened version of the curve for which we need to store the data.
elevations the producer used to compute raw terrain elevations, themselves used to compute the elevation profile.
proland::RoadElevationLayer::RoadElevationCurveData::~RoadElevationCurveData (  ) 

Deletes this RoadElevationCurveData.


Member Function Documentation

virtual float proland::RoadElevationLayer::RoadElevationCurveData::getAltitude ( float  s  )  [virtual]

Returns the height corresponding to the given s coordinate.

Parameters:
s a pseudo curvilinear coordinate (see Curve::Vertex::s).

Reimplemented from proland::ElevationCurveData.

virtual float proland::RoadElevationLayer::RoadElevationCurveData::getCapLength ( NodePtr  p,
vec2d  q 
) [protected, virtual]

Computes the cap length at a given extremity.

Parameters:
p the Node from which to compute the cap length.
q a point determining the direction of the cap length.
path the Curve to compute the cap length from. Must contain p & q.

Reimplemented from proland::CurveData.

virtual float proland::RoadElevationLayer::RoadElevationCurveData::getEndHeight (  )  [virtual]

Returns the height of the ending point of the curve.

Reimplemented from proland::ElevationCurveData.

virtual float proland::RoadElevationLayer::RoadElevationCurveData::getStartHeight (  )  [virtual]

Returns the height of the starting point of the curve.

Reimplemented from proland::ElevationCurveData.

virtual void proland::RoadElevationLayer::RoadElevationCurveData::getUsedTiles ( set< TileCache::Tile::Id > &  tiles,
float  rootSampleLength 
) [virtual]

Returns the list of tiles intersected by the curve with which this ElevationCurveData is associated.

Parameters:
[out] tiles the list of usedTiles.
rootSampleLength Curve sample length at level 0.

Reimplemented from proland::ElevationCurveData.


Member Data Documentation

True if the ending point of the road is connected to a bridge.

Elevation at the ending point of the road, if connected to a bridge.

True if extremities were checked.

True if the starting point of the road is connected to a bridge.

Elevation at the starting point of the road, if connected to a bridge.


Generated on Sat May 12 09:42:46 2012 for proland by  doxygen 1.6.1