I’m getting crazy, Camera.mainCamera.ViewportToScreenPoint doesn’t seems to work for me…
I’m calling this function on a GUITexture passing transform.position as parameter and on 1,1 it will give me the position on the screen (857,310) instead of (480, 320) that I would expect…
As mentioned above, but potentially not in as much detail, above your game screen is a drop down of various sizes. iPhone Wide will limit it to be a 480x320 screen, there’s also tall, etc.
I was calling the camera function inside the OnDrawGizmos so it was using the editor camera instead of the game camera (i was trying to draw some 2d line in the game view without luck…)