Open wxmerkt opened 6 years ago
Hi, wxmerkt. I have the same problem when I use fcl::distance to get the min_distance to the octomap tree (fcl:collide runs well). So have you ever solved the problem? Thanks.
I switched to LIBCCD for most queries. There are still issues with the quality of the nearest points at distance though.
@wxmerkt: Drake uses FCL for many of its geometric queries. @SeanCurtis-TRI recently ran precision experiments and tabulated the results for various query types in Drake's documentation. For example, see ComputePointPairPenetration() and ComputeSignedDistancePairwiseClosestPoints(). If I may editorialize, you can see that many of the results from FCL are very inaccurate. The high-precision results in the tables are mostly cases we handle ourselves rather than pass to FCL. Our roadmap is to fill that table with high precision results over time. In the meanwhile, user beware!
Are these distance queries signed or unsigned? Generally, they are different code paths. We've put a fair amount of energy to improving the signed distance queries for the libccd solver (and, even then, there are still occasional artifacts that come up that we use to improve further). We have less experience and less insight into either libindep or the separation distance query.
Also, it's worth noting, the tables that @sherm1 linked to above do not strictly represent FCL behavior or potential. In some cases, a cell in the table is filled in by Drake code (and not FCL code). In other cases, particularly the signed distance query, we haven't exposed the iteration tolerance, so we're using the default 1e-6 value that dominates the observed precision. So, don't look at that as an observation of FCL's state, per se.
We run a lot of distance queries using
fcl::distance
where botho1
ando2
are primitive shapes (OT_GEOM
). Very frequently (every few minutes), we receive a segmentation fault when usingGST_INDEP
(not forGST_LIBCCD
):Unfortunately, I do not have a working reproduction use case yet, although, this happens frequently enough to open this issue to document it - in case someone has any insights. The primitives used are boxes, cylinders, and spheres. Based on our logic, we can conclude that the objects are either at a distance (
fcl::collide
does not return any contacts) or perhaps in the ill-defined touching contact case.