I am working on a project, and part of it needs to measure the rotation of the device. I assume that the most efficient way to do this would be with the gyroscope, but please correct me if I am wrong. I really have no idea where to start, so any pointers would be greatly appreciated.
1271 次
2 に答える
1
You'd have to start by including the CoreMotion
framework. Then refer to the documentation for a good outline of the CMMotionManager
class.
The actual implementation is very easy - implement the delegate and tell the manager that you want to start receiving notifications.
于 2012-01-01T01:07:28.503 に答える
0
4.0以降のiOSで利用可能なCoreMotionフレームワークを確認してください。これは、低レベルのデータを処理する必要なしに、ジャイロと加速度計を高レベルで動作させるための多くの準備が整ったものを提供します。
于 2012-01-01T01:08:06.400 に答える