Skip to content

Commit

Permalink
Merge branch 'production' of github.com:rdiankov/openrave into truckb…
Browse files Browse the repository at this point in the history
…otv2
  • Loading branch information
yoshikikanemoto committed Jan 29, 2024
2 parents 5b3401e + 6323362 commit 4e27bf5
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 14 deletions.
2 changes: 1 addition & 1 deletion plugins/configurationcache/configurationjitterer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -740,7 +740,7 @@ By default will sample the robot's active DOFs. Parameters part of the interface
}
}
ss << "]";
RAVELOG_VERBOSE_FORMAT("env=%s, link '%s' exceeded linkdisthresh=%e. ellipdist[%e] > rhs[%e], %s", GetEnv()->GetNameId()%_linkdistthresh%_vLinks[ilink]->GetName()%ellipdist%rhs%ss.str());
RAVELOG_VERBOSE_FORMAT("env=%s, link '%s' exceeded linkdisthresh=%e. ellipdist[%e] > rhs[%e], %s", GetEnv()->GetNameId()%_vLinks[ilink]->GetName()%_linkdistthresh%ellipdist%rhs%ss.str());
}
break;
}
Expand Down
8 changes: 4 additions & 4 deletions python/bindings/openravepy_int.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2472,13 +2472,13 @@ object PyEnvironmentBase::plot3(object opoints,float pointsize,object ocolors, i
return toPyGraphHandle(phandle);
}
BOOST_ASSERT(vcolors.size()<=4);
RaveVector<float> vcolor;
for(int i = 0; i < (int)vcolors.size(); ++i) {
vcolor[i] = vcolors[i];
}
GraphHandlePtr phandle;
{
PythonThreadSaver saver;
RaveVector<float> vcolor;
for(int i = 0; i < (int)vcolors.size(); ++i) {
vcolor[i] = vcolors[i];
}
phandle = _penv->plot3(vpoints.data(),sizes.first,sizeof(float)*3,pointsize,vcolor,drawstyle);
}
return toPyGraphHandle(phandle);
Expand Down
21 changes: 12 additions & 9 deletions python/bindings/openravepy_kinbody.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -366,10 +366,10 @@ object PyGeometryInfo::SerializeJSON(dReal fUnitScale, object options)
{
rapidjson::Document doc;
KinBody::GeometryInfoPtr pgeominfo = GetGeometryInfo();
const int intOption = pyGetIntFromPy(options, 0);
const int intOptions = pyGetIntFromPy(options, 0);
{
openravepy::PythonThreadSaver threadsaver;
pgeominfo->SerializeJSON(doc, doc.GetAllocator(), fUnitScale, intOption);
pgeominfo->SerializeJSON(doc, doc.GetAllocator(), fUnitScale, intOptions);
}
return toPyObject(doc);
}
Expand All @@ -379,10 +379,10 @@ void PyGeometryInfo::DeserializeJSON(object obj, dReal fUnitScale, object option
rapidjson::Document doc;
toRapidJSONValue(obj, doc, doc.GetAllocator());
KinBody::GeometryInfoPtr pgeominfo = GetGeometryInfo();
const int intOption = pyGetIntFromPy(options, 0);
const int intOptions = pyGetIntFromPy(options, 0);
{
openravepy::PythonThreadSaver threadsaver;
pgeominfo->DeserializeJSON(doc, fUnitScale, intOption);
pgeominfo->DeserializeJSON(doc, fUnitScale, intOptions);
}
Init(*pgeominfo);
}
Expand Down Expand Up @@ -616,10 +616,10 @@ py::object PyLinkInfo::SerializeJSON(dReal fUnitScale, object options)
{
rapidjson::Document doc;
KinBody::LinkInfoPtr pInfo = GetLinkInfo();
const int intOption = pyGetIntFromPy(options, 0);
const int intOptions = pyGetIntFromPy(options, 0);
{
openravepy::PythonThreadSaver threadsaver;
pInfo->SerializeJSON(doc, doc.GetAllocator(), fUnitScale, intOption);
pInfo->SerializeJSON(doc, doc.GetAllocator(), fUnitScale, intOptions);
}
return toPyObject(doc);
}
Expand All @@ -629,10 +629,10 @@ void PyLinkInfo::DeserializeJSON(object obj, dReal fUnitScale, py::object option
rapidjson::Document doc;
toRapidJSONValue(obj, doc, doc.GetAllocator());
KinBody::LinkInfoPtr pInfo = GetLinkInfo();
const int intOption = pyGetIntFromPy(options, 0);
const int intOptions = pyGetIntFromPy(options, 0);
{
openravepy::PythonThreadSaver threadsaver;
pInfo->DeserializeJSON(doc, fUnitScale, intOption);
pInfo->DeserializeJSON(doc, fUnitScale, intOptions);
}
_Update(*pInfo);
}
Expand Down Expand Up @@ -4294,7 +4294,10 @@ PyStateRestoreContextBase* PyKinBody::CreateKinBodyStateSaver(object options)
object PyKinBody::ExtractInfo(ExtractInfoOptions options) const
{
KinBody::KinBodyInfo info;
_pbody->ExtractInfo(info, options);
{
openravepy::PythonThreadSaver threadsaver;
_pbody->ExtractInfo(info, options);
}
return py::to_object(boost::shared_ptr<PyKinBody::PyKinBodyInfo>(new PyKinBody::PyKinBodyInfo(info)));
}

Expand Down

0 comments on commit 4e27bf5

Please sign in to comment.