Log in or register to post comments

Moving object by tilting image target?

December 10, 2012 - 4:04am #2

Hi, the problem with this is that Vuforia produces a Pose (i.e. a 3D reference frame) of the target with respect to the camera; 

then Unity will set (by default) the World Center (and the world reference frame) on the target; i.e. the target (once detected) represents your World reference; this means that all the physics are referred to the target reference frame (so, no matter how you move/tilt your target, as the gravity vector will always be the vertical direction which is perpendicular to the target itself).

If you want to achieve that effect you describe, you probably need to use 2 image targets simultaneously; 

the first target then will be used by Unity to set the World reference frame (which will be centered on such target), while the second image target will be the one that you can manipulate and tilt; in this case the physics will work as expected because the second target is actually tilted/moved with respect to the first target (i.e. with respect to the World reference which has been "froozen" with the first target).

I hope this helps.

Note: in the QCARBehaviour (in the Unity inspector) make sure that the World Center Mode is set to "AUTO" (this is the default setting anyway).



Log in or register to post comments