Log in or register to post comments

Tracking offset on iPhone 7 and +

February 5, 2018 - 5:59pm #1

Hi everyone.

We're building an AR app with Unity that requires very precise tracking. In short, we're trying to position a virtual video on top of a real image, and they need to align perfectly.

While it works exactly as expected on Android and up to iPhone 6, we're facing an issue on iPhone 7/8/X. Basically, when the camera is out of focus, the overlapped video (black shape on the below screenshot) seems to align well, but as soon as the auto focus triggers, the alignment is lost.

Please look at the screenshots enclosed.

Did anybody experience that issue before? Any help would be much appreciated.

- Florian


Image icon iphone6_OK.jpg389.88 KB
Image icon iphone7_OK.jpg240.95 KB
Image icon iphone7_NOK.jpg222.28 KB

Tracking offset on iPhone 7 and +

June 8, 2019 - 4:25am #13

Hi buddy, that is true. Even things were with the upgrade of Unity 2018.




Tracking offset on iPhone 7 and +

October 8, 2018 - 2:18pm #12

I can also verify that upgrading to Unity 2018 and the latest version of Vuforia fixed this offset bug. I was able to remove that strange code (below) that referenced the gyroscope. We just upgraded Unity today.

Tracking offset on iPhone 7 and +

May 25, 2018 - 3:23am #11

This issue was fixed for me upgrading to 2018 and the new Vuforia. 

Tracking offset on iPhone 7 and +

May 23, 2018 - 11:37am #10


Apologies for the delayed response. We did some investigation into these reports and unfortunately were not able to reproduce them directly.

For the iPhone X, Vuforia does not utilize the stereo cameras. We use the "wide-angle" (i.e. non-telephoto) lens alone. We also perform intrinsic camera calibration upon a representative device for each Vuforia supported resolutions (as set by MODE_OPTIMIZE_SPEED, MODE_DEFAULT & MODE_OPTIMIZE_QUALITY).

The observations in this thread seem to indicate two possibilities:

  1. Augmentation registration accuracy is being degraded due to the camera image being out of focus
  2. Vuforia's calibration data does not match other devices in market

For #1, it is important to understand the following:

  • Vuforia *does not* provide an autofocus implementation. We rely upon the device OEM for this, and Vuforia APIs directly call the platform APIs. Thus, any performance issues related to an OEMs autofocus implementation are likely not related to Vuforia. This is a common misconception which is understandable.
  • Blurred images, due to autofocus issues or rapid motion, will affect the precision of Vuforia’s algorithms to return an accurate pose. Inaccurate poses can result in augmentations not being properly registered.
  • Using the camera in a “macro mode” (i.e. trying to focus the camera when it is close to the target) can cause significant autofocus issues, such as ‘pumping’ or ‘hunting’. The effect here is either the target is not detected, or the tracking performance is degraded.

For #2, the challenge is that Vuforia cannot perform intrinsic camera calibration on all iOS devices (iPhone X or otherwise). Manufacturing processes cannot make any two cameras the same, so it is expected that there will be variance in the values measured (and propagated) by Vuforia compared to other devices. Previous studies have indicated that this variance is not large and should be well within our algorithm's tolerance. However, this means that the accuracy and precision of an augmentatation's registration on a target will likely also show variance, especially when the tolerance requirements are high.


Vuforia Support

Tracking offset on iPhone 7 and +

May 11, 2018 - 12:29pm #9

I am posting this here because I had received a personal message from magglemitch in March about this issue, but I didn't notice it until today.

I wrote a script that used the gyroscope to figure out the orientation of the device, and adjust the video background texture offsets. This doesn't work very well, but is slightly better than the default.



static private bool useGyro = false;

static public float bgScale = 1.02f;

static public float bgOffset = -0.02f;




  // speculative fix for scaling issue on certain iPhone models

  UnityEngine.iOS.DeviceGeneration iOSDevice = UnityEngine.iOS.Device.generation;

  switch (iOSDevice)


  case UnityEngine.iOS.DeviceGeneration.iPhone7Plus:

  case UnityEngine.iOS.DeviceGeneration.iPhone8:

  case UnityEngine.iOS.DeviceGeneration.iPhone8Plus:

  case UnityEngine.iOS.DeviceGeneration.iPhoneX:

   useGyro = true;

   Input.gyro.enabled = true;

   Input.gyro.updateInterval = 1.0f / 60.0f;






  if (useGyro && Input.gyro.enabled && (backgroundPlaneBehaviour != null))


   Vector3 up = -Input.gyro.gravity;

   Vector2 right = new Vector2(up.y, up.x).normalized;

   Vector2 scale = Vector2.one + (bgScale - 1.0f) * right;

   Vector2 offset = bgOffset * right;

   MeshRenderer meshRenderer = backgroundPlaneBehaviour.GetComponent<MeshRenderer>();

   meshRenderer.sharedMaterial.mainTextureScale = scale;

   meshRenderer.sharedMaterial.mainTextureOffset = offset;




We only enabled this on late model iOS devices. Our presumption (?) is that it is broken on the 'stereo' cameras. I think that the first stereo camera was introduced in the iPhone 7+ model. But that is just speculation.

Note that the math above might need to be adjusted depending on how you set your screen orientation settings.

Tracking offset on iPhone 7 and +

April 14, 2018 - 9:38am #8


I'm having the same problem. Tried it on iPhone 8, Iphone 5 and iPhone X.

Have anyone confirmed that downgrading to 2017.2 works?

Using Unity 2017.3.1p4 now.


Tracking offset on iPhone 7 and +

April 9, 2018 - 7:43am #7

I think you'll have to downgrade to 2017.2 until this is fixed.  I think I read somewhere it's slated to be fixed in 2018.2  



Tracking offset on iPhone 7 and +

April 9, 2018 - 2:31am #6

I am facing the same issue on ipad Pro...it was 100% perfect on editor mode, but offset weird when running on ipad.

noted: I use Vuforia 7 with Unity2017.3

Tracking offset on iPhone 7 and +

March 8, 2018 - 10:26am #5

I am also seeing the same issues with the iPad Pro; does anyone have any suggestions on how to resolve this?

Tracking offset on iPhone 7 and +

February 21, 2018 - 8:55pm #4

Had any luck with this? I'm facing the same issue on devices with ARKit.

Tracking offset on iPhone 7 and +

February 10, 2018 - 2:06pm #3

I'm running into the same problem on an iPhone X. An iPad Air 2 and an iPhone 6S both place the rendered object over the target correctly but it seems like the iPhone X has issues with placement. The rendered object seems to be rendered smaller and slightly skewed and gets worse the longer it is exposed with movement over the image. I tried the SmoothCamera script to see if it helps but it didn't make any difference. Would love to get some help.

Tracking offset on iPhone 7 and +

February 7, 2018 - 8:26am #2


Can anybody from Vuforia help? It's quite urgent.

Log in or register to post comments