Log in or register to post comments

Using Vuforia and Coremotion together

April 1, 2012 - 9:43pm #1

I am trying to develop an app that uses Coremotion to handle tracking if Vuforia loses track of the initial marker.

In my initial attempt to make the app, when it switches over to Coremotion the view or projection matrix break and I get a flattened and stretched image.

I have tried both multiplying and adding the matrix produced by Coremotion data with the pose matrix from Vuforia but both produce incorrect output.

Is it even possible to do this? Do I need to separate out model and the view matrix from getPose, and if so how would I go about doing this? Is there anything else I would have factor in order to achieve this effect?

Many thanks in advance for any help.

Re: Using Vuforia and Coremotion together

April 2, 2012 - 9:12am #2

You'll probably need to apply a correction to the matrix returned by CoreMotion to bring it into the same coordinate system that Vuforia uses. Vuforia sets up a camera at the origin pointing in the positive Z direction with X to the right and Y down. This is a right-handed coordinate system. Do you know what CoreMotion returns?

Moreover, you need to know how the CoreMotion matrix relates to the last known pose of the target. Perhaps you could record the CMRotationMatrix while tracking, and then use the multiplyByInverseOfAttitude method to find an offset matrix once tracking is lost? I haven't tried any of this btw, you'll need to experiment :)

- Kim

Log in or register to post comments