Enum gilrs::ev::Axis[][src]

#[repr(u16)]
pub enum Axis { LeftStickX, LeftStickY, LeftZ, RightStickX, RightStickY, RightZ, DPadX, DPadY, Unknown, }

Gamepad's elements which state can be represented by value from -1.0 to 1.0.

Controller layout

Variants

Methods

impl Axis
[src]

Returns true if axis is LeftStickX, LeftStickY, RightStickX or RightStickY.

Returns the other axis from same element of gamepad, if any.

input output
LeftStickX Some(LeftStickY)
LeftStickY Some(LeftStickX)
RightStickXSome(RightStickY)
RightStickYSome(RightStickX)
None

Trait Implementations

impl Debug for Axis
[src]

Formats the value using the given formatter. Read more

impl Clone for Axis
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl Copy for Axis
[src]

impl Eq for Axis
[src]

impl PartialEq for Axis
[src]

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

impl Hash for Axis
[src]

Feeds this value into the given [Hasher]. Read more

Feeds a slice of this type into the given [Hasher]. Read more

Auto Trait Implementations

impl Send for Axis

impl Sync for Axis