Ray casting. To constraint the movement of the joints to the 3D
model mesh, we compute a tangent deformation over the surface
by adjusting the coordinate of each jointj
i. The tangent deformation is based on ray casting, and it is an adjustment over the
surfaceRm(seeFig. 8). InAm, the joint j is moved from its initial
positionj0to position j1by the mappingM. To change the joint
coordinate and get to the final joint position over the Rm, the
method calculates the auxiliary pointpauxin front of the mesh by
adding the joint positionj1to the normal vector on the mesh n
!
(paux¼j
1þn
!
). Then, it casts a ray r
!
from paux in the inverse
normal direction. The intersection point between r
!
andRmis j2,
the final position of the joint with thexyzcoordinate computed.