Struct input::controller::ControllerAxisArgs [] [src]

pub struct ControllerAxisArgs {
    pub id: i32,
    pub axis: u8,
    pub position: f64,
}
[]

Components of a controller axis move event. Not guaranteed consistent across backends.

Fields

id

Which controller moved.

axis

The axis that moved.

position

Position of the controller. Usually [-1.0, 1.0], though backends may use a different range for various devices.

Methods

impl ControllerAxisArgs

fn new(id: i32, axis: u8, position: f64) -> Self[]

Create a new ControllerAxisArgs object. Intended for use by backends when emitting events.

Trait Implementations

Derived Implementations

impl Debug for ControllerAxisArgs

fn fmt(&self, __arg_0: &mut Formatter) -> Result

impl PartialEq for ControllerAxisArgs

fn eq(&self, __arg_0: &ControllerAxisArgs) -> bool

fn ne(&self, __arg_0: &ControllerAxisArgs) -> bool

impl Encodable for ControllerAxisArgs

fn encode<__S: Encoder>(&self, __arg_0: &mut __S) -> Result<(), __S::Error>

impl Decodable for ControllerAxisArgs

fn decode<__D: Decoder>(__arg_0: &mut __D) -> Result<ControllerAxisArgs, __D::Error>

impl Clone for ControllerAxisArgs

fn clone(&self) -> ControllerAxisArgs

1.0.0fn clone_from(&mut self, source: &Self)

impl Copy for ControllerAxisArgs