diff --git a/gazebo/common/ColladaLoader.cc b/gazebo/common/ColladaLoader.cc index 578719c08c..c9c89af445 100644 --- a/gazebo/common/ColladaLoader.cc +++ b/gazebo/common/ColladaLoader.cc @@ -1595,8 +1595,11 @@ void ColladaLoader::LoadPolylist(TiXmlElement *_polylistXml, polylistInputXml = polylistInputXml->NextSiblingElement("input"); } - for (const auto &input : inputs) - inputSize += input.second.size(); + std::set total_inputs; + for (const auto &input : inputs) { + total_inputs.insert(input.second.begin(), input.second.end()); + } + inputSize += total_inputs.size(); // read vcount // break poly into triangles