开发者

Spinning iphone based on ground

I am rotate iphone based on the ground

But the UIAcceleration values of (x&y&z) are same . Can you tell me exactly what happens here ?

Also i want know how to its calculate UIAcceleration values of(x&y&z) ?

I am really intere开发者_StackOverflow社区sted to work with UIAcceleration values.

Can anyone help me?

Thanks in advance.....


The UIAcceleration value can only detect acceleration relative to the orientation of the device.

By rotating the iPhone, in its frame of reference there is a constant gravity force (along the z axis) and a constant centrifugal force (on the xy-plane), so the UIAcceleration will not change.

You cannot distinguish acceleration due to gravity or linear acceleration or rotation by the accelerometer. You need other devices e.g. the compass (magnetometer) to detect a rotational change.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜