-
Notifications
You must be signed in to change notification settings - Fork 421
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Reference frame of nearest point #382
Comments
The cited issues address the frame if you use the The most obvious point for confusion here would come from the poses of the two geometries. Have they been reported in the world frame? If the poses (called via Do you have code that illustrates erroneous query results that we can run? |
I set both objects in the world frame. I am sure of that because I use the same 4x4 matrix for VTK and for FCL. So I can display what i give to FCL.
}` where So, to set the position of each part, i set them in the std::vector to use it later. |
I note that you're using I can't promise that it'll solve your problem, but, at the very least, it'll put it into the domain with which I'm more familiar. |
I have changed from |
Several more questions:
bool defaultDistanceFunctionMine(CollisionObject* o1, CollisionObject* o2, void* cdata_,
FCL_REAL& distmin) {
DistanceData* cdata = static_cast<DistanceData*>(cdata_);
const DistanceRequest& request = cdata->request;
DistanceResult& result = cdata->result;
FCL_REAL dist;
FCL_REAL res;
if (cdata->done) { // This will never become true.
dist = result.min_distance; // this assignment has no affect.
return true; // if cdata->done were ever true, you'd consider that a collision.
}
res = distance(o1, o2, request, result);
if (res == -1) return true;
dist = result.min_distance;
if (dist <= distmin) return true; // in collision or in touch return cdata->done;
} I now have the following thoughts on this function.
|
I strongly suspect that your assumptions of what you're passing in may not be as correct as you hope. I strongly suggest you exercise your code with simple primitives (spheres, for example). They are easy to reason about and it is trivial to determine what the correct answer is. This will allow you to validate the code that is exercising FCL. Unfortunately, I can't offer much more hlep because I have no idea how to reproduce your problem locally. We can continue playing 20 questions in order to try and help find where the bug is but it'll be a very long process -- it's up to you if you want to do that. I definitely want to get this to work for you -- particularly if it reveals a bug in FCL, but my view into your problem is too limited to help in any significant degree. |
Hi,
I'm currently using fcl 0.5 and i would like to compute the distance between 2 objects.
Both of them are placed in the world frame, so I can display them correctly (with VTK)
The blue and red sphere are corresponding to the closest points given by the distance method.
I want to compute the distance between the tool and the join 4 which is the part on the left
But when I try to compute the distance between them, I get a wrong value and the closest points are not even the closest one.
I guess that this is the closest one but they are given in the wrong frame.
I 've seen the post :
#171 and #288
I would like to know when FCL 0.6 will be released or how i can fix manually this issue.
Regards
The text was updated successfully, but these errors were encountered: