Public Member Functions | Private Attributes | List of all members
tuw_graph::Crossing Class Reference

#include <crossing.h>

Public Member Functions

 Crossing (const std::vector< Eigen::Vector2d > &_segment_points)
 constructor More...
 
Eigen::Vector2d getCenter () const
 returns the center of the crossing (average of all pts) More...
 
void setSegmentReference (const std::shared_ptr< std::vector< Segment >> &segs)
 saves the reference to the vector containing all segments to have access to them to alter other segments from try Add segments More...
 
bool tryAddSegment (Segment &_seg)
 tries to add the segment to the crossing and adds the given segment to each segments neighbors in the crossing More...
 

Private Attributes

Eigen::Vector2d center_
 
std::shared_ptr< std::vector< Segment > > segmentReference_
 
std::vector< uint32_t > segments_end_
 
std::vector< uint32_t > segments_start_
 
std::vector< Eigen::Vector2d > surroundingPoints_
 

Detailed Description

Definition at line 38 of file crossing.h.

Constructor & Destructor Documentation

tuw_graph::Crossing::Crossing ( const std::vector< Eigen::Vector2d > &  _segment_points)

constructor

Parameters
_segment_pointsthe endpoint of each segment in the crossing, which is on the crossing side

Definition at line 35 of file crossing.cpp.

Member Function Documentation

Eigen::Vector2d tuw_graph::Crossing::getCenter ( ) const

returns the center of the crossing (average of all pts)

Returns
the center of the crossing

Definition at line 114 of file crossing.cpp.

void tuw_graph::Crossing::setSegmentReference ( const std::shared_ptr< std::vector< Segment >> &  segs)

saves the reference to the vector containing all segments to have access to them to alter other segments from try Add segments

Definition at line 119 of file crossing.cpp.

bool tuw_graph::Crossing::tryAddSegment ( Segment _seg)

tries to add the segment to the crossing and adds the given segment to each segments neighbors in the crossing

Parameters
_segthe segment to add
Returns
if the action succeeded

Definition at line 63 of file crossing.cpp.

Member Data Documentation

Eigen::Vector2d tuw_graph::Crossing::center_
private

Definition at line 66 of file crossing.h.

std::shared_ptr<std::vector<Segment> > tuw_graph::Crossing::segmentReference_
private

Definition at line 67 of file crossing.h.

std::vector<uint32_t> tuw_graph::Crossing::segments_end_
private

Definition at line 65 of file crossing.h.

std::vector<uint32_t> tuw_graph::Crossing::segments_start_
private

Definition at line 64 of file crossing.h.

std::vector<Eigen::Vector2d> tuw_graph::Crossing::surroundingPoints_
private

Definition at line 63 of file crossing.h.


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


tuw_voronoi_graph
Author(s): Benjamin Binder
autogenerated on Mon Jun 10 2019 15:42:44