参考 pRotationZ

pRotationZ

The system variable pRotationZ always contains the rotation of the device along the z axis in the frame previous to the current frame. If the sketch angleMode() is set to DEGREES, the value will be 0 to 360. If it is set to RADIANS, the value will be 0 to 2*PI.

pRotationZ can also be used with rotationZ to determine the rotate direction of the device along the Z-axis.

示例

Notice any errors or typos? Please let us know. Please feel free to edit src/events/acceleration.js and open a pull request!

相关参考