Not able to generate interaction forces.
I am trying to interact with a hollow thin sphere, It has a hole on the surface so that my haptic tool/point can move in and out of the sphere.
I am able to feel the force when my haptic point is interacting on the external(outer) surface of the sphere. But not able to feel any interaction forces (haptic point piercing through the surface as if nothing is present in front of it), while trying to interact with the object from the inner surface...
I tried creating a Double or two-sided mesh. But it feels the same as the previous one.
I am wondering if it is a problem with mesh creation or does I need to put some extra lines of code to make it happen?
I resolved it.
Initially, my mesh object is made of just faces...
And later I made solid mesh model with some thickness. But my interacting tool is pushed radially outward when interacting with the inner surface of the model. This happened because my inner surface normals are pointing radially outward rather than radially inwards.
Then I changed my inner surface normals to point inward. And my model worked fine.
Hope this might help someone in the future.
You can define on which side haptic forces are rendered by calling the following method.
The first argument indicates if forces are exerted when encountering polygons on their front side. The second argument indicates if forces are exerted when encountering polygons on their back side.
// enable haptic interactions on both sides of polygons object->m_material->setHapticTriangleSides(true, true);