Ok so here's what I'm looking to do. In unity say if my marker is at origin i would like to display an object X distance away from it.
Eg: Say i have a full page newspaper ad and a quarter page ad on another paper(bottom right). When the camera tracks the marker i would like my model to always be displayed at the left bottom of the newspaper.
Any suggestions?
GetSize() returns the size of the target as defined by the config.xml file. This is the size you used when you created the target in the online system. It does not change.
The size assumption trick isn't directly supported by QCAR, you'll have to do some math. You could get an estimate from the distance between the ARCamera and the target in Unity. If you assume that the device is a fixed distance from the newspaper, then the ARCamera will be farther away for small targets and closer up for large targets (imagine zooming the camera in and out so the target fills more or less of the screen).
Again, this is an imperfect way of determining target size, and most likely won't work well in a user-driven environment. If a user moves the device in or out to get the entire target in view this clearly won't work.
- Kim