useGyro(...)
Studio is being deprecated, please head over to the documentation page for Mattercraft, our most advanced 3D tool for the web, where you can find the most recent information and tutorials.
useGyro(val: boolean): this;
Sets if the TargetInstance should use the device’s gyroscope hardware to aid in tracking.
If set to true, objects relative to the target will attempt to keep their position when the user looks around, even when image tracking fails. This is useful when dealing with large objects that will not fit into frame without requiring the user to alter the direction they are facing.
Parameters
Section titled “Parameters”Parameter | Type | Description |
---|---|---|
val | boolean | Whether the TargetInstance should use the gyro or not. |