|
@@ -1763,15 +1763,17 @@ bool OpenDriveXmlParser::ReadObjectOutlinesOutline(Object_outlines * pObject_out
|
|
}
|
|
}
|
|
|
|
|
|
TiXmlElement *subNode = node->FirstChildElement("cornerRoad");
|
|
TiXmlElement *subNode = node->FirstChildElement("cornerRoad");
|
|
- if (subNode)
|
|
|
|
|
|
+ while (subNode)
|
|
{
|
|
{
|
|
ReadObjectOutlinesOutlinecornerRoad(&xoutline, subNode);
|
|
ReadObjectOutlinesOutlinecornerRoad(&xoutline, subNode);
|
|
|
|
+ subNode = subNode->NextSiblingElement("cornerRoad");
|
|
}
|
|
}
|
|
|
|
|
|
subNode = node->FirstChildElement("cornerLocal");
|
|
subNode = node->FirstChildElement("cornerLocal");
|
|
- if (subNode)
|
|
|
|
|
|
+ while (subNode)
|
|
{
|
|
{
|
|
- ReadObjectOutlinesOutlinecornerRoad(&xoutline, subNode);
|
|
|
|
|
|
+ ReadObjectOutlinesOutlinecornerLocal(&xoutline, subNode);
|
|
|
|
+ subNode = subNode->NextSiblingElement("cornerLocal");
|
|
}
|
|
}
|
|
|
|
|
|
pObject_outlines->SetObject_outlines_outline(xoutline);
|
|
pObject_outlines->SetObject_outlines_outline(xoutline);
|
|
@@ -1840,15 +1842,17 @@ bool OpenDriveXmlParser::ReadObjectOutlinesOutline(Object * pObject,TiXmlElement
|
|
}
|
|
}
|
|
|
|
|
|
TiXmlElement *subNode = node->FirstChildElement("cornerRoad");
|
|
TiXmlElement *subNode = node->FirstChildElement("cornerRoad");
|
|
- if (subNode)
|
|
|
|
|
|
+ while (subNode)
|
|
{
|
|
{
|
|
ReadObjectOutlinesOutlinecornerRoad(poutline, subNode);
|
|
ReadObjectOutlinesOutlinecornerRoad(poutline, subNode);
|
|
|
|
+ subNode = subNode->NextSiblingElement("cornerRoad");
|
|
}
|
|
}
|
|
|
|
|
|
subNode = node->FirstChildElement("cornerLocal");
|
|
subNode = node->FirstChildElement("cornerLocal");
|
|
- if (subNode)
|
|
|
|
|
|
+ while (subNode)
|
|
{
|
|
{
|
|
- ReadObjectOutlinesOutlinecornerRoad(poutline, subNode);
|
|
|
|
|
|
+ ReadObjectOutlinesOutlinecornerLocal(poutline, subNode);
|
|
|
|
+ subNode = subNode->NextSiblingElement("cornerLocal");
|
|
}
|
|
}
|
|
|
|
|
|
|
|
|
|
@@ -1900,12 +1904,12 @@ bool OpenDriveXmlParser::ReadObjectOutlinesOutlinecornerLocal(Object_outlines_ou
|
|
int checker=TIXML_SUCCESS;
|
|
int checker=TIXML_SUCCESS;
|
|
checker+=node->QueryDoubleAttribute("u",&u);
|
|
checker+=node->QueryDoubleAttribute("u",&u);
|
|
checker+=node->QueryDoubleAttribute("v",&v);
|
|
checker+=node->QueryDoubleAttribute("v",&v);
|
|
- checker+=node->QueryDoubleAttribute("zz",&z);
|
|
|
|
|
|
+ checker+=node->QueryDoubleAttribute("z",&z);
|
|
checker+=node->QueryDoubleAttribute("height",&height);
|
|
checker+=node->QueryDoubleAttribute("height",&height);
|
|
|
|
|
|
if (checker!=TIXML_SUCCESS)
|
|
if (checker!=TIXML_SUCCESS)
|
|
{
|
|
{
|
|
- cout<<"Error parsing Object outline cornerRoad attributes"<<endl;
|
|
|
|
|
|
+ cout<<"Error parsing Object outline cornerLocal attributes"<<endl;
|
|
return false;
|
|
return false;
|
|
}
|
|
}
|
|
|
|
|
|
@@ -2958,7 +2962,7 @@ bool OpenDriveXmlParser::ReadJunction (TiXmlElement *node)
|
|
string id;
|
|
string id;
|
|
|
|
|
|
int checker=TIXML_SUCCESS;
|
|
int checker=TIXML_SUCCESS;
|
|
- checker+=node->QueryStringAttribute("name",&name);
|
|
|
|
|
|
+
|
|
checker+=node->QueryStringAttribute("id",&id);
|
|
checker+=node->QueryStringAttribute("id",&id);
|
|
if (checker!=TIXML_SUCCESS)
|
|
if (checker!=TIXML_SUCCESS)
|
|
{
|
|
{
|
|
@@ -2966,6 +2970,12 @@ bool OpenDriveXmlParser::ReadJunction (TiXmlElement *node)
|
|
return false;
|
|
return false;
|
|
}
|
|
}
|
|
|
|
|
|
|
|
+ checker+=node->QueryStringAttribute("name",&name);
|
|
|
|
+ if(checker != TIXML_SUCCESS)
|
|
|
|
+ {
|
|
|
|
+ name = "";
|
|
|
|
+ }
|
|
|
|
+
|
|
mOpenDrive->AddJunction(name,id);
|
|
mOpenDrive->AddJunction(name,id);
|
|
Junction* junction=mOpenDrive->GetLastJunction();
|
|
Junction* junction=mOpenDrive->GetLastJunction();
|
|
|
|
|