Hi all,
I try to obtain the screen position of a UIbutton. But I get ALL DIFFERENT results by using the
WorkingCam.WorldToScreenPoint(obj.transform.positi on) // obj is the button. WorkingCam is the 2D camera.
in different resolutions output, runing in Android phone, such as 480x320, 800x480. (Android system..) I wanna know why ?
Some results are negative in its x component when I minus its 0.5*width to calculate its left-top position, although it does show and locate on the screen, which must not be negative.
It led to some errors during calculating touching area in some resolutions.
But in this situation, it seems only the 480x320 worked right. I have no idea about it.
In general, no matter what the resolution is , the screen positions of this button should remain the same , right?
What's the possible reason that might lead to this situation ?
thanks for every help.