2014-11-28 06:13:18 -05:00
|
|
|
#ifndef ORIGINAL_EDGE_DATA_HPP
|
|
|
|
#define ORIGINAL_EDGE_DATA_HPP
|
2013-12-09 11:47:42 -05:00
|
|
|
|
2016-03-01 16:30:31 -05:00
|
|
|
#include "extractor/guidance/turn_instruction.hpp"
|
2016-04-26 07:27:40 -04:00
|
|
|
#include "extractor/travel_mode.hpp"
|
2016-08-17 03:49:19 -04:00
|
|
|
#include "util/guidance/turn_bearing.hpp"
|
2016-01-02 11:13:44 -05:00
|
|
|
#include "util/typedefs.hpp"
|
2013-12-09 11:47:42 -05:00
|
|
|
|
2016-04-26 07:27:40 -04:00
|
|
|
#include <cstddef>
|
2014-01-29 05:30:04 -05:00
|
|
|
#include <limits>
|
2013-12-09 11:47:42 -05:00
|
|
|
|
2016-01-05 10:51:13 -05:00
|
|
|
namespace osrm
|
|
|
|
{
|
|
|
|
namespace extractor
|
|
|
|
{
|
|
|
|
|
2014-05-07 12:39:16 -04:00
|
|
|
struct OriginalEdgeData
|
|
|
|
{
|
2016-07-22 12:23:54 -04:00
|
|
|
explicit OriginalEdgeData(GeometryID via_geometry,
|
2016-10-21 18:24:55 -04:00
|
|
|
NameID name_id,
|
2016-06-15 08:38:24 -04:00
|
|
|
LaneDataID lane_data_id,
|
2016-03-01 16:30:31 -05:00
|
|
|
guidance::TurnInstruction turn_instruction,
|
2016-04-26 07:27:40 -04:00
|
|
|
EntryClassID entry_classid,
|
2016-08-17 03:49:19 -04:00
|
|
|
TravelMode travel_mode,
|
|
|
|
util::guidance::TurnBearing pre_turn_bearing,
|
|
|
|
util::guidance::TurnBearing post_turn_bearing)
|
2016-07-22 12:23:54 -04:00
|
|
|
: via_geometry(via_geometry), name_id(name_id), entry_classid(entry_classid),
|
2016-08-17 03:49:19 -04:00
|
|
|
lane_data_id(lane_data_id), turn_instruction(turn_instruction), travel_mode(travel_mode),
|
|
|
|
pre_turn_bearing(pre_turn_bearing), post_turn_bearing(post_turn_bearing)
|
2014-05-07 12:39:16 -04:00
|
|
|
{
|
|
|
|
}
|
|
|
|
|
|
|
|
OriginalEdgeData()
|
2016-07-22 12:23:54 -04:00
|
|
|
: via_geometry{std::numeric_limits<unsigned>::max() >> 1, false},
|
2016-05-27 15:05:04 -04:00
|
|
|
name_id(std::numeric_limits<unsigned>::max()), entry_classid(INVALID_ENTRY_CLASSID),
|
2016-06-15 08:38:24 -04:00
|
|
|
lane_data_id(INVALID_LANE_DATAID), turn_instruction(guidance::TurnInstruction::INVALID()),
|
2016-08-17 03:49:19 -04:00
|
|
|
travel_mode(TRAVEL_MODE_INACCESSIBLE), pre_turn_bearing(0.0), post_turn_bearing(0.0)
|
2014-05-07 12:39:16 -04:00
|
|
|
{
|
|
|
|
}
|
2013-12-09 11:47:42 -05:00
|
|
|
|
2016-07-22 12:23:54 -04:00
|
|
|
GeometryID via_geometry;
|
2016-08-17 03:49:19 -04:00
|
|
|
NameID name_id;
|
2016-04-26 07:27:40 -04:00
|
|
|
EntryClassID entry_classid;
|
2016-06-15 08:38:24 -04:00
|
|
|
LaneDataID lane_data_id;
|
2016-05-19 17:26:07 -04:00
|
|
|
guidance::TurnInstruction turn_instruction;
|
2014-08-09 09:13:04 -04:00
|
|
|
TravelMode travel_mode;
|
2016-08-17 03:49:19 -04:00
|
|
|
util::guidance::TurnBearing pre_turn_bearing;
|
|
|
|
util::guidance::TurnBearing post_turn_bearing;
|
2013-12-09 11:47:42 -05:00
|
|
|
};
|
2016-06-15 08:38:24 -04:00
|
|
|
|
|
|
|
static_assert(sizeof(OriginalEdgeData) == 16,
|
|
|
|
"Increasing the size of OriginalEdgeData increases memory consumption");
|
2016-01-05 10:51:13 -05:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2014-11-28 06:13:18 -05:00
|
|
|
#endif // ORIGINAL_EDGE_DATA_HPP
|