Closed tichise closed 3 weeks ago
Hey, this is unfortunately a Unity physics limitation and not something that can be fixed. Unity's physics system cannot handle non-convex meshes reliably (specifically when using non-kinematic rigidbodies), they essentially have no volume and the physics system can't calculate them.
My suggestion would be to do one of a few things:
Please note that I do not have any prior experience with AR foundation's workings, so cannot provide any support with it.
This error should be resolved by #1660
Description
I am using the Ultraleap Plugin 7.1.0 in Unity with the LeapServiceProvider in DesktopMode. I have added Physical Hands Manager to my scene, and I am generating AR planes and meshes using ARFoundation. However, when attempting to interact with non-convex objects (such as ARPlane or ARMesh), I encounter the following error:
I tried adding the IgnorePhysicalHands component to ARPlane and ARMesh, but this did not resolve the issue. Additionally, I attempted to disable collision using layers, but this approach was also unsuccessful. Since ARPlanes and ARMeshes are dynamically generated and non-convex by nature, it is difficult to make them convex. This is because making them convex would affect other processes. This issue also has a significant impact on other behaviors in the scene.
It seems that the Physics.ClosestPoint method is being called on non-convex colliders, which is unsupported. Is there a recommended workaround for handling AR-generated planes and meshes when interacting with Physical Hands Manager?
Steps to Reproduce
Expected Behavior
Physical Hands Manager should be able to interact with AR planes and meshes without causing the
Physics.ClosestPoint
error.Actual Behavior
The error occurs when interacting with non-convex colliders, such as AR-generated planes or meshes, which aren't supported by the
Physics.ClosestPoint
method.Environment