float x { get; set; }

book_4_sparkGenerated
code_blocksInput

Description

The x property of the Rotation struct represents the X component of the quaternion rotation. This component is part of the vector that defines the axis of rotation in 3D space.

Usage

Use the x property to access or modify the X component of a Rotation instance. This is typically used in conjunction with the other components (y, z, and w) to fully define a quaternion rotation.

Example

// Example of accessing the x component of a Rotation
Rotation rotation = new Rotation();
float xComponent = rotation.x;

// Example of setting the x component of a Rotation
rotation.x = 0.5f;