zRotationByGyro property

double zRotationByGyro
final

How much the child should spin on the z axis when a z-axis gyroscope movement is sampled.

If the goal is actually to "spin" the widget as the device spins, this value should be non-zero.

As gyroscope events are read non-zero only as an axis movement is occuring, this XLayer can read rapidly different values depending on sampling rate and when the rotation was in motion.

Furthermore this value will normalize itself down to near 0, or whatever the "stationary" z-axis value is for the gyroscope, beginning immediately after any jump in value is sampled.

Example Usage Scenario

Use a large zRotationByGyro to spin the line-wound reel of a fishing pole as a mobile phone is "flicked" to simulate casting a line.

Implementation

final double zRotationByGyro;