#[repr(C)]pub struct Vibration {
pub left_motor_speed: u16,
pub right_motor_speed: u16,
}Expand description
[microsoft.com] XINPUT_VIBRATION
Specifies motor speed levels for the vibration function of a controller.
Fields§
§left_motor_speed: u16Speed of the left, lower-frequency (heavier?) rumble motor.
| Value | Rumble |
|---|---|
| 0 | None |
| 65535 | 100% |
right_motor_speed: u16Speed of the right, higher-frequency (lighter?) rumble motor.
| Value | Rumble |
|---|---|
| 0 | None |
| 65535 | 100% |
Trait Implementations§
Source§impl AsMut<Vibration> for XINPUT_VIBRATION
Available on crate feature winapi-0-3 only.
impl AsMut<Vibration> for XINPUT_VIBRATION
Available on crate feature
winapi-0-3 only.Source§impl AsMut<XINPUT_VIBRATION> for Vibration
Available on crate feature winapi-0-3 only.
impl AsMut<XINPUT_VIBRATION> for Vibration
Available on crate feature
winapi-0-3 only.Source§fn as_mut(&mut self) -> &mut XINPUT_VIBRATION
fn as_mut(&mut self) -> &mut XINPUT_VIBRATION
Converts this type into a mutable reference of the (usually inferred) input type.
Source§impl AsRef<Vibration> for XINPUT_VIBRATION
Available on crate feature winapi-0-3 only.
impl AsRef<Vibration> for XINPUT_VIBRATION
Available on crate feature
winapi-0-3 only.Source§impl AsRef<XINPUT_VIBRATION> for Vibration
Available on crate feature winapi-0-3 only.
impl AsRef<XINPUT_VIBRATION> for Vibration
Available on crate feature
winapi-0-3 only.Source§fn as_ref(&self) -> &XINPUT_VIBRATION
fn as_ref(&self) -> &XINPUT_VIBRATION
Converts this type into a shared reference of the (usually inferred) input type.
Source§impl From<Vibration> for XINPUT_VIBRATION
Available on crate feature winapi-0-3 only.
impl From<Vibration> for XINPUT_VIBRATION
Available on crate feature
winapi-0-3 only.Source§impl From<XINPUT_VIBRATION> for Vibration
Available on crate feature winapi-0-3 only.
impl From<XINPUT_VIBRATION> for Vibration
Available on crate feature
winapi-0-3 only.Source§fn from(value: XINPUT_VIBRATION) -> Self
fn from(value: XINPUT_VIBRATION) -> Self
Converts to this type from the input type.
impl Copy for Vibration
impl Pod for Vibration
Auto Trait Implementations§
impl Freeze for Vibration
impl RefUnwindSafe for Vibration
impl Send for Vibration
impl Sync for Vibration
impl Unpin for Vibration
impl UnwindSafe for Vibration
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CheckedBitPattern for Twhere
T: AnyBitPattern,
impl<T> CheckedBitPattern for Twhere
T: AnyBitPattern,
Source§type Bits = T
type Bits = T
Self must have the same layout as the specified Bits except for
the possible invalid bit patterns being checked during
is_valid_bit_pattern.Source§fn is_valid_bit_pattern(_bits: &T) -> bool
fn is_valid_bit_pattern(_bits: &T) -> bool
If this function returns true, then it must be valid to reinterpret
bits
as &Self.