Struct physx::controller::PxBoxController
source · #[repr(transparent)]pub struct PxBoxController<U> { /* private fields */ }
Trait Implementations§
source§impl<U> BoxController for PxBoxController<U>
impl<U> BoxController for PxBoxController<U>
source§fn get_half_forward_extent(&self) -> f32
fn get_half_forward_extent(&self) -> f32
Get the half forward extent.
source§fn get_half_height(&self) -> f32
fn get_half_height(&self) -> f32
Get the half height.
source§fn get_half_side_extent(&self) -> f32
fn get_half_side_extent(&self) -> f32
Get the half side extent.
source§fn set_half_forward_extent(&mut self, extent: f32) -> bool
fn set_half_forward_extent(&mut self, extent: f32) -> bool
Set the half forward extent.
source§fn set_half_height(&mut self, height: f32) -> bool
fn set_half_height(&mut self, height: f32) -> bool
Set the half height.
source§fn set_half_side_extent(&mut self, extent: f32) -> bool
fn set_half_side_extent(&mut self, extent: f32) -> bool
Set the half side extent.
source§impl<T, U> Class<T> for PxBoxController<U>where
PxBoxController: Class<T>,
impl<T, U> Class<T> for PxBoxController<U>where PxBoxController: Class<T>,
source§fn as_ptr(&self) -> *const T
fn as_ptr(&self) -> *const T
Returns a raw const pointer to the wrapped type.
Retrieving a raw pointer is safe. However, pretty much any use of a raw pointer is unsafe.
In particular: this pointer should not be used to construct a second owning wrapper around the pointer.
source§fn as_mut_ptr(&mut self) -> *mut T
fn as_mut_ptr(&mut self) -> *mut T
Returns a raw mut pointer to the wrapped type.
Retrieving a raw pointer is safe. However, pretty much any use of a raw pointer is unsafe.
In particular: this pointer should not be used to construct a second owning wrapper around the pointer.
source§impl<U> Controller for PxBoxController<U>
impl<U> Controller for PxBoxController<U>
type UserData = U
type Descriptor = PxBoxControllerDesc<U>
source§fn get_user_data(&self) -> &Self::UserData
fn get_user_data(&self) -> &Self::UserData
Retrieve the user data from the controller.
source§fn set_user_data(&mut self, user_data: Self::UserData) -> &mut Self
fn set_user_data(&mut self, user_data: Self::UserData) -> &mut Self
Sets the controllers user data. If U is larger than a *mut _, it is heap allocated in a box.
Otherwise, it is packed directly into the *mut c_void userData field.
source§fn set_position(&mut self, position: impl Into<PxExtendedVec3>)
fn set_position(&mut self, position: impl Into<PxExtendedVec3>)
Set the position of teh controller
source§fn get_position(&self) -> PxVec3
fn get_position(&self) -> PxVec3
Get the position of the controller.