Eclipse SUMO - Simulation of Urban MObility
GNEGeometry::DottedGeometry Struct Reference

struct for pack all variables related with DottedGeometry of stop More...

#include <GNEGeometry.h>

Collaboration diagram for GNEGeometry::DottedGeometry:
[legend]

Public Member Functions

 DottedGeometry ()
 constructor More...
 
const PositiongetCentroid () const
 get Centroid More...
 
double getRotation () const
 get rotation More...
 
const PositionVectorgetShape () const
 The shape of the additional element. More...
 
const std::vector< RGBColor > & getShapeColors () const
 The colors of the single shape parts. More...
 
const std::vector< double > & getShapeLengths () const
 The lengths of the single shape parts. More...
 
const std::vector< double > & getShapeRotations () const
 The rotations of the single shape parts. More...
 
bool isGeometryDeprecated () const
 check if geometry is deprecated More...
 
void markDottedGeometryDeprecated ()
 mark dotted geometry deprecated More...
 
void updateDottedGeometry (const GUIVisualizationSettings &s, const PositionVector &contourShape)
 update DottedGeometry (using an existent shape) More...
 
void updateDottedGeometry (const GUIVisualizationSettings &s, const PositionVector &lineShape, const double width)
 update DottedGeometry (using an line shape and a width) More...
 
void updateDottedGeometry (const GUIVisualizationSettings &s, const Position &position, const double rotation, const double width, const double height)
 update DottedGeometry (using a position, rotation, width and height) More...
 

Private Member Functions

void calculateShapeRotationsAndLengths ()
 calculate shape rotations and lengths More...
 
DottedGeometryoperator= (const DottedGeometry &other)=delete
 Invalidated assignment operator. More...
 

Private Attributes

Position myCentroid
 shape's centroid More...
 
bool myDottedGeometryDeprecated
 flag to mark dotted geometry depreciated More...
 
double myRotation
 shape's rotation (only used in certain dotted contours) More...
 
PositionVector myShape
 dotted element shape (note: It's centered in 0,0 due scaling) More...
 
std::vector< RGBColormyShapeColors
 The colors of the dotted shape. More...
 
std::vector< double > myShapeLengths
 The lengths of the dotted shape. More...
 
std::vector< double > myShapeRotations
 The rotations of the dotted shape. More...
 

Detailed Description

struct for pack all variables related with DottedGeometry of stop

Definition at line 156 of file GNEGeometry.h.

Constructor & Destructor Documentation

◆ DottedGeometry()

GNEGeometry::DottedGeometry::DottedGeometry ( )

constructor

Definition at line 274 of file GNEGeometry.cpp.

Member Function Documentation

◆ calculateShapeRotationsAndLengths()

void GNEGeometry::DottedGeometry::calculateShapeRotationsAndLengths ( )
private

calculate shape rotations and lengths

Definition at line 403 of file GNEGeometry.cpp.

References GNEGeometry::calculateLength(), GNEGeometry::calculateRotation(), myShape, myShapeLengths, and myShapeRotations.

Referenced by updateDottedGeometry().

Here is the caller graph for this function:

◆ getCentroid()

const Position & GNEGeometry::DottedGeometry::getCentroid ( ) const

get Centroid

Definition at line 367 of file GNEGeometry.cpp.

References myCentroid.

Referenced by GNEGeometry::drawShapeDottedContour().

Here is the caller graph for this function:

◆ getRotation()

double GNEGeometry::DottedGeometry::getRotation ( ) const

get rotation

Definition at line 373 of file GNEGeometry.cpp.

References myRotation.

Referenced by GNEGeometry::drawShapeDottedContour().

Here is the caller graph for this function:

◆ getShape()

const PositionVector & GNEGeometry::DottedGeometry::getShape ( ) const

The shape of the additional element.

Definition at line 379 of file GNEGeometry.cpp.

References myShape.

Referenced by GNEGeometry::drawShapeDottedContour().

Here is the caller graph for this function:

◆ getShapeColors()

const std::vector< RGBColor > & GNEGeometry::DottedGeometry::getShapeColors ( ) const

The colors of the single shape parts.

Definition at line 397 of file GNEGeometry.cpp.

References myShapeColors.

Referenced by GNEGeometry::drawShapeDottedContour().

Here is the caller graph for this function:

◆ getShapeLengths()

const std::vector< double > & GNEGeometry::DottedGeometry::getShapeLengths ( ) const

The lengths of the single shape parts.

Definition at line 391 of file GNEGeometry.cpp.

References myShapeLengths.

Referenced by GNEGeometry::drawShapeDottedContour().

Here is the caller graph for this function:

◆ getShapeRotations()

const std::vector< double > & GNEGeometry::DottedGeometry::getShapeRotations ( ) const

The rotations of the single shape parts.

Definition at line 385 of file GNEGeometry.cpp.

References myShapeRotations.

Referenced by GNEGeometry::drawShapeDottedContour().

Here is the caller graph for this function:

◆ isGeometryDeprecated()

bool GNEGeometry::DottedGeometry::isGeometryDeprecated ( ) const

check if geometry is deprecated

Definition at line 361 of file GNEGeometry.cpp.

References myDottedGeometryDeprecated.

Referenced by GNEViewNet::setDottedAC().

Here is the caller graph for this function:

◆ markDottedGeometryDeprecated()

◆ operator=()

DottedGeometry& GNEGeometry::DottedGeometry::operator= ( const DottedGeometry other)
privatedelete

Invalidated assignment operator.

◆ updateDottedGeometry() [1/3]

void GNEGeometry::DottedGeometry::updateDottedGeometry ( const GUIVisualizationSettings s,
const PositionVector contourShape 
)

◆ updateDottedGeometry() [2/3]

void GNEGeometry::DottedGeometry::updateDottedGeometry ( const GUIVisualizationSettings s,
const PositionVector lineShape,
const double  width 
)

update DottedGeometry (using an line shape and a width)

Definition at line 311 of file GNEGeometry.cpp.

References PositionVector::closePolygon(), PositionVector::move2side(), PositionVector::reverse(), and updateDottedGeometry().

◆ updateDottedGeometry() [3/3]

void GNEGeometry::DottedGeometry::updateDottedGeometry ( const GUIVisualizationSettings s,
const Position position,
const double  rotation,
const double  width,
const double  height 
)

update DottedGeometry (using a position, rotation, width and height)

Definition at line 335 of file GNEGeometry.cpp.

References PositionVector::closePolygon(), myRotation, and updateDottedGeometry().

Field Documentation

◆ myCentroid

Position GNEGeometry::DottedGeometry::myCentroid
private

shape's centroid

Definition at line 198 of file GNEGeometry.h.

Referenced by getCentroid(), and updateDottedGeometry().

◆ myDottedGeometryDeprecated

bool GNEGeometry::DottedGeometry::myDottedGeometryDeprecated
private

flag to mark dotted geometry depreciated

Definition at line 216 of file GNEGeometry.h.

Referenced by isGeometryDeprecated(), markDottedGeometryDeprecated(), and updateDottedGeometry().

◆ myRotation

double GNEGeometry::DottedGeometry::myRotation
private

shape's rotation (only used in certain dotted contours)

Definition at line 201 of file GNEGeometry.h.

Referenced by getRotation(), and updateDottedGeometry().

◆ myShape

PositionVector GNEGeometry::DottedGeometry::myShape
private

dotted element shape (note: It's centered in 0,0 due scaling)

Definition at line 204 of file GNEGeometry.h.

Referenced by calculateShapeRotationsAndLengths(), getShape(), and updateDottedGeometry().

◆ myShapeColors

std::vector<RGBColor> GNEGeometry::DottedGeometry::myShapeColors
private

The colors of the dotted shape.

Definition at line 213 of file GNEGeometry.h.

Referenced by getShapeColors(), and updateDottedGeometry().

◆ myShapeLengths

std::vector<double> GNEGeometry::DottedGeometry::myShapeLengths
private

The lengths of the dotted shape.

Definition at line 210 of file GNEGeometry.h.

Referenced by calculateShapeRotationsAndLengths(), and getShapeLengths().

◆ myShapeRotations

std::vector<double> GNEGeometry::DottedGeometry::myShapeRotations
private

The rotations of the dotted shape.

Definition at line 207 of file GNEGeometry.h.

Referenced by calculateShapeRotationsAndLengths(), and getShapeRotations().


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