fixes issue #161

This commit is contained in:
DennisOSRM 2012-03-05 09:36:20 +01:00
parent 22e1e6c92f
commit 77d5c44664
2 changed files with 4 additions and 2 deletions

View File

@ -28,7 +28,7 @@
#include "EdgeBasedGraphFactory.h"
template<>
EdgeBasedGraphFactory::EdgeBasedGraphFactory(int nodes, std::vector<NodeBasedEdge> & inputEdges, std::vector<NodeID> & bn, std::vector<NodeID> & tl, std::vector<_Restriction> & irs, std::vector<NodeInfo> & nI, boost::property_tree::ptree speedProfile, std::string & srtm) : inputNodeInfoList(nI), numberOfTurnRestrictions(irs.size()) {
EdgeBasedGraphFactory::EdgeBasedGraphFactory(int nodes, std::vector<NodeBasedEdge> & inputEdges, std::vector<NodeID> & bn, std::vector<NodeID> & tl, std::vector<_Restriction> & irs, std::vector<NodeInfo> & nI, boost::property_tree::ptree speedProfile, std::string & srtm) : inputNodeInfoList(nI), numberOfTurnRestrictions(irs.size()), trafficSignalPenalty(0) {
INFO("Nodes size: " << inputNodeInfoList.size());
BOOST_FOREACH(_Restriction & restriction, irs) {
std::pair<NodeID, NodeID> restrictionSource = std::make_pair(restriction.fromNode, restriction.viaNode);
@ -64,6 +64,8 @@ EdgeBasedGraphFactory::EdgeBasedGraphFactory(int nodes, std::vector<NodeBasedEdg
}
}
INFO("traffic signal penalty: " << trafficSignalPenalty);
BOOST_FOREACH(NodeID id, bn)
_barrierNodes[id] = true;
BOOST_FOREACH(NodeID id, tl)

View File

@ -100,7 +100,6 @@ private:
std::vector<EmanatingRestrictionsVector> _restrictionBucketVector;
RestrictionMap _restrictionMap;
int trafficSignalPenalty;
std::vector<EdgeBasedEdge> edgeBasedEdges;
std::vector<EdgeBasedNode> edgeBasedNodes;
@ -116,6 +115,7 @@ private:
double GetAngleBetweenTwoEdges(const CoordinateT& A, const CoordinateT& C, const CoordinateT& B) const;
// SRTMLookup srtmLookup;
unsigned numberOfTurnRestrictions;
unsigned trafficSignalPenalty;
public:
template< class InputEdgeT >