Log in or register to post comments

[Unity] Vuforia Camera Incorrect Z Rotation

September 14, 2015 - 10:33am #1

Vuforia SDK Version: 5.0.5 -

Description with steps to reproduce:

Hello, we were testing our game when we noticed that sometimes the AR objects appear upside-down. Since we are using "FIRST_TARGET" world center mode we knew that something was very wrong.
Upon further investigations, using Unity Editor and a Webcam, we noticed that sometimes Vuforia calculates the camera Z rotation in a way that the Camera itself is upside down.
Is there a way to fix this behaviour? Is there an incoming Vuforia fix for this bug?

Please note that if you add 180 degrees to the bugged Z rotation the problem is solved.

Screenshot links: https://drive.google.com/folderview?id=0B17Gjkrc6uZEN3VWWHNBbmZ6dDA&usp=sharing

 

-

Development OS (Mac OS X, Windows, Linux): Windows -

Mobile OS and Version: Android, Unity Editor, etc -

Mobile Device Manufacturer and Model name: Samsung Galaxy S6 SM-G920 -

Do the Vuforia Sample Applications show the same behavior?: Yes, just keep moving the camera until it happens.

[Unity] Vuforia Camera Incorrect Z Rotation

September 14, 2015 - 11:48am #2
The Trackable Pose is estimated as “upside down”, i.e. the target normal is considered pointing downwards instead of upwards.
Then, given that you are using World Center Mode = “First Target” , Unity will keep the Target position "static" in World Space and will rotate the Camera accordingly (that is, Unity updates the Camera pose instead of the Trackable Pose, so that the relative pose of one w.r.t the other holds).
  
This can happen when the target outline sides of the trapezoid tend to be nearly parallel, and so the same image can occasionally be incorrectly interpreted by the Tracker as a facing down surface.
 
See attached image (“TargetNormalDirection.png”) that illustrates the concept.
 
This is something that may affect more frequently those targets where the features are more concentrated near the center of the target, with little or no features near the boundaries.  It should be possible to improve this by adding some features in the peripheral areas, i.e. near the corner and the boundaries of the target rectangle. 
AttachmentSize
Image icon TargetNormalDirection.png12.63 KB
Log in or register to post comments