@@ -117,7 +117,7 @@ OpenDriveMap::OpenDriveMap(const std::string& xodr_file,
117117 junction_id.c_str (),
118118 contact_point_str.c_str ());
119119 const JunctionConnection::ContactPoint junction_conn_contact_point =
120- (contact_point_str == " start" ) ? JunctionConnection::ContactPoint_Start : JunctionConnection::ContactPoint_End ;
120+ (contact_point_str == " start" ) ? JunctionConnection::ContactPoint::Start : JunctionConnection::ContactPoint::End ;
121121
122122 const std::string junction_connection_id = connection_node.attribute (" id" ).as_string (" " );
123123 JunctionConnection& junction_connection = junction.id_to_connection
@@ -201,9 +201,9 @@ OpenDriveMap::OpenDriveMap(const std::string& xodr_file,
201201 road_id.c_str (),
202202 is_predecessor ? " predecessor" : " successor" ,
203203 type_str.c_str ());
204- link.type = (type_str == " road" ) ? RoadLink::Type_Road : RoadLink::Type_Junction ;
204+ link.type = (type_str == " road" ) ? RoadLink::Type::Road : RoadLink::Type::Junction ;
205205
206- if (link.type == RoadLink::Type_Road )
206+ if (link.type == RoadLink::Type::Road )
207207 {
208208 // junction connection has no contact point
209209 std::string contact_point_str = road_link_node.attribute (" contactPoint" ).as_string (" " );
@@ -214,7 +214,7 @@ OpenDriveMap::OpenDriveMap(const std::string& xodr_file,
214214 road_id.c_str (),
215215 is_predecessor ? " predecessor" : " successor" ,
216216 contact_point_str.c_str ());
217- link.contact_point = (contact_point_str == " start" ) ? RoadLink::ContactPoint_Start : RoadLink::ContactPoint_End ;
217+ link.contact_point = (contact_point_str == " start" ) ? RoadLink::ContactPoint::Start : RoadLink::ContactPoint::End ;
218218 }
219219 }
220220 }
@@ -379,11 +379,11 @@ OpenDriveMap::OpenDriveMap(const std::string& xodr_file,
379379 std::string side_str = side.as_string (" " );
380380 std::transform (side_str.begin (), side_str.end (), side_str.begin (), [](unsigned char c) { return std::tolower (c); });
381381 if (side_str == " left" )
382- road.crossfall .sides [s0] = Crossfall::Side_Left ;
382+ road.crossfall .sides [s0] = Crossfall::Side::Left ;
383383 else if (side_str == " right" )
384- road.crossfall .sides [s0] = Crossfall::Side_Right ;
384+ road.crossfall .sides [s0] = Crossfall::Side::Right ;
385385 else
386- road.crossfall .sides [s0] = Crossfall::Side_Both ;
386+ road.crossfall .sides [s0] = Crossfall::Side::Both ;
387387 }
388388 }
389389
@@ -579,7 +579,7 @@ OpenDriveMap::OpenDriveMap(const std::string& xodr_file,
579579 if (with_road_objects)
580580 {
581581 const RoadObjectCorner::Type default_local_outline_type =
582- abs_z_for_for_local_road_obj_outline ? RoadObjectCorner::Type_Local_AbsZ : RoadObjectCorner::Type_Local_RelZ ;
582+ abs_z_for_for_local_road_obj_outline ? RoadObjectCorner::Type::Local_AbsZ : RoadObjectCorner::Type::Local_RelZ ;
583583
584584 for (pugi::xml_node object_node : road_node.child (" objects" ).children (" object" ))
585585 {
@@ -705,7 +705,7 @@ OpenDriveMap::OpenDriveMap(const std::string& xodr_file,
705705 RoadObjectCorner road_object_corner_road (corner_road_node.attribute (" id" ).as_int (-1 ),
706706 pt_road,
707707 corner_road_node.attribute (" height" ).as_double (0 ),
708- RoadObjectCorner::Type_Road );
708+ RoadObjectCorner::Type::Road );
709709 road_object_outline.outline .push_back (road_object_corner_road);
710710 }
711711
@@ -875,14 +875,14 @@ RoutingGraph OpenDriveMap::get_routing_graph() const
875875 if (!lanesection)
876876 {
877877 const RoadLink& road_link = predecessors ? current_road.predecessor : current_road.successor ;
878- if (road_link.type == RoadLink::Type_Road && road_link.contact_point != RoadLink::ContactPoint_None )
878+ if (road_link.type == RoadLink::Type::Road && road_link.contact_point != RoadLink::ContactPoint::None )
879879 {
880880 auto next_road_iter = id_to_road.find (road_link.id );
881881 if (next_road_iter != id_to_road.end ())
882882 {
883883 const Road& next_road = next_road_iter->second ;
884- lanesection = (road_link.contact_point == RoadLink::ContactPoint_Start ) ? next_road.s_to_lanesection .begin ()->second
885- : next_road.s_to_lanesection .rbegin ()->second ;
884+ lanesection = (road_link.contact_point == RoadLink::ContactPoint::Start ) ? next_road.s_to_lanesection .begin ()->second
885+ : next_road.s_to_lanesection .rbegin ()->second ;
886886 }
887887 }
888888 }
@@ -963,11 +963,11 @@ RoutingGraph OpenDriveMap::get_routing_graph() const
963963 const Road& connecting_road = connecting_road_iter->second ;
964964
965965 const LaneSection& incoming_lanesec =
966- (incoming_road.successor .type == RoadLink::Type_Junction && incoming_road.successor .id == junction.id )
966+ (incoming_road.successor .type == RoadLink::Type::Junction && incoming_road.successor .id == junction.id )
967967 ? incoming_road.s_to_lanesection .rbegin ()->second
968968 : incoming_road.s_to_lanesection .begin ()->second ;
969969
970- const LaneSection& connecting_lanesec = (conn.contact_point == JunctionConnection::ContactPoint_Start )
970+ const LaneSection& connecting_lanesec = (conn.contact_point == JunctionConnection::ContactPoint::Start )
971971 ? connecting_road.s_to_lanesection .begin ()->second
972972 : connecting_road.s_to_lanesection .rbegin ()->second ;
973973
0 commit comments