Hello!
I’m trying to project the corners of a marker into the screen. The code below is working fine with a mockup scene without AR in the editor but it does’t work on device. Am I missing something really basic here?
var m = Matrix4x4.TRS(MarkerTransform.position, MarkerTransform.rotation, Vector3.one);
var upperLeft = ARCamera.WorldToScreenPoint( m.MultiplyPoint(new Vector3(-hWidth,0, hHeight)));
var upperRight = ARCamera.WorldToScreenPoint(m.MultiplyPoint(new Vector3(hWidth, 0, hHeight)));
var lowerRight = ARCamera.WorldToScreenPoint(m.MultiplyPoint(new Vector3(hWidth, 0,-hHeight)));
var lowerLeft = ARCamera.WorldToScreenPoint(m.MultiplyPoint(new Vector3(-hWidth, 0,-hHeight)));
Thanks so much for any pointers!
seb