b3CreateBoxCommandSetColorRGBA: allow to specify color when creating bodies through shared memory API

Parse and use colors from URDF file (single rgba color per link, not per visual)
Rename btMultiBody 'stepVelocities' to 'computeAccelerationsArticulatedBodyAlgorithmMultiDof'
btHashMap, add const Value* operator[]
remove a few more obsolete btMultiBody methods (on the non-multi-dof path)
fix spelling typo in fillConstraintJacobianMultiDof (fil -> fill)
Add mention to Jakub Stepien for his work on btMultiBody
This commit is contained in:
erwincoumans
2015-11-06 17:11:15 -08:00
parent 8160354d02
commit 3b9b803683
16 changed files with 96 additions and 588 deletions

View File

@@ -346,6 +346,8 @@ bool UrdfParser::parseVisual(UrdfVisual& visual, TiXmlElement* config, ErrorLogg
{
if (parseMaterial(visual.m_localMaterial, mat,logger))
{
UrdfMaterial* matPtr = new UrdfMaterial(visual.m_localMaterial);
m_model.m_materials.insert(matPtr->m_name.c_str(),matPtr);
visual.m_hasLocalMaterial = true;
}
}
@@ -786,7 +788,7 @@ bool UrdfParser::loadUrdf(const char* urdfText, ErrorLogger* logger, bool forceF
for (int i=0;i<link->m_visualArray.size();i++)
{
UrdfVisual& vis = link->m_visualArray.at(i);
if (!vis.m_hasLocalMaterial)
if (!vis.m_hasLocalMaterial && vis.m_materialName.c_str())
{
UrdfMaterial** mat = m_model.m_materials.find(vis.m_materialName.c_str());
if (mat && *mat)