Fix for older Visual Studio

git-svn-id: https://svn.code.sf.net/p/speed-dreams/code/trunk@7997 30fe4595-0a0c-4342-8851-515496e4dcbd

Former-commit-id: 1be8b6cfe182b220e1a467144a61b866f91a46ea
Former-commit-id: 6a7a892517a5e576ae2fe90dc5556e0fdd9377dd
This commit is contained in:
beaglejoe 2022-02-05 00:31:31 +00:00
parent 2ca56eaa88
commit 921cd00442

View file

@ -1997,9 +1997,10 @@ osg::ref_ptr <osg::Group> SDHUD::generateHudFromXmlFile(int scrH, int scrW)
// line variables
std::vector<OSGPLOT::PlotLineConfig> lines;
long double numLines = lines.size();
//get a list of the sections in this section
std::string linesSectionPath = subSectionPath + "/lines/";
std::string lineSectionPath = linesSectionPath + std::to_string(lines.size() + 1);
std::string lineSectionPath = linesSectionPath + std::to_string(numLines + 1);
//cicle throught each element of the widget
while (GfParmExistsSection(paramHandle, lineSectionPath.c_str()))
@ -2016,8 +2017,8 @@ osg::ref_ptr <osg::Group> SDHUD::generateHudFromXmlFile(int scrH, int scrW)
config.color = colorStringToVec4(GfParmGetStr(paramHandle, lineSectionPath.c_str(), "color", ""));
lines.push_back(config);
lineSectionPath = linesSectionPath + std::to_string(lines.size() + 1);
numLines = lines.size();
lineSectionPath = linesSectionPath + std::to_string(numLines + 1);
}
GfLogDebug("OSGHUD: Generate graph object: %s \n", elementId.c_str());