#[repr(transparent)]pub struct PxShape<U, M: Material> { /* private fields */ }
Expand description
A new type wrapper for PxShape. Parametrized by it’s user data type, and the type of it’s Material.
Trait Implementations
sourceimpl<S, U, M: Material> Class<S> for PxShape<U, M>where
PxShape: Class<S>,
impl<S, U, M: Material> Class<S> for PxShape<U, M>where
PxShape: Class<S>,
sourcefn as_ptr(&self) -> *const S
fn as_ptr(&self) -> *const S
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. Read more
sourcefn as_mut_ptr(&mut self) -> *mut S
fn as_mut_ptr(&mut self) -> *mut S
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. Read more
sourceimpl<U, M: Material> Shape for PxShape<U, M>
impl<U, M: Material> Shape for PxShape<U, M>
type Material = M
sourceunsafe fn from_raw(
ptr: *mut PxShape,
user_data: Self::UserData
) -> Option<Owner<Self>>
unsafe fn from_raw(
ptr: *mut PxShape,
user_data: Self::UserData
) -> Option<Owner<Self>>
Safety Read more
sourcefn get_user_data(&self) -> &Self::UserData
fn get_user_data(&self) -> &Self::UserData
Get a reference to the user data.
sourcefn get_user_data_mut(&mut self) -> &mut Self::UserData
fn get_user_data_mut(&mut self) -> &mut Self::UserData
Get a mutable reference to the user data.
sourcefn set_simulation_filter_data(
&mut self,
this_layers: BitFlags<CollisionLayer>,
other_layers: BitFlags<CollisionLayer>,
word3: u32,
word4: u32
)
fn set_simulation_filter_data(
&mut self,
this_layers: BitFlags<CollisionLayer>,
other_layers: BitFlags<CollisionLayer>,
word3: u32,
word4: u32
)
Set the simulation (collision) filter of this shape
sourcefn get_simulation_filter_data(&self) -> PxFilterData
fn get_simulation_filter_data(&self) -> PxFilterData
Read the collision filter data of this shape
sourcefn get_reference_count(&self) -> u32
fn get_reference_count(&self) -> u32
Get the reference count
sourcefn set_query_filter_data(&mut self, this_layers: BitFlags<CollisionLayer>)
fn set_query_filter_data(&mut self, this_layers: BitFlags<CollisionLayer>)
Set the query filter of this shape
sourcefn get_query_filter_data(&self) -> PxFilterData
fn get_query_filter_data(&self) -> PxFilterData
Read the query filter data of this shape
sourcefn get_nb_materials(&self) -> u16
fn get_nb_materials(&self) -> u16
Get the number of materials associated with this shape
sourcefn get_materials(&self) -> Vec<&Self::Material>
fn get_materials(&self) -> Vec<&Self::Material>
Get a vector of all materials associated with this shape
sourcefn get_materials_mut(&mut self) -> Vec<&mut Self::Material>
fn get_materials_mut(&mut self) -> Vec<&mut Self::Material>
Get a mut vector of all materials associated with this shape
impl<U: Send, M: Material + Send> Send for PxShape<U, M>
impl<U: Sync, M: Material + Send> Sync for PxShape<U, M>
Auto Trait Implementations
impl<U, M> RefUnwindSafe for PxShape<U, M>where
M: RefUnwindSafe,
U: RefUnwindSafe,
impl<U, M> Unpin for PxShape<U, M>where
M: Unpin,
U: Unpin,
impl<U, M> UnwindSafe for PxShape<U, M>where
M: UnwindSafe,
U: UnwindSafe,
Blanket Implementations
sourceimpl<T> Base for Twhere
T: Class<PxBase>,
impl<T> Base for Twhere
T: Class<PxBase>,
sourcefn get_concrete_type_name(&self) -> Option<&str>
fn get_concrete_type_name(&self) -> Option<&str>
Get the name of the real type referenced by this pointer, or None if the returned string is not valid
sourcefn get_concrete_type(&self) -> ConcreteType
fn get_concrete_type(&self) -> ConcreteType
Returns an enumerated value identifying the type. This may return ConcreteType::Undefined
in surprising situations, notably this does not seem to work with
get_active_actors
. Use
get_type
for actors if possible. Read moresourcefn set_base_flag(&mut self, flag: BaseFlag, value: bool)
fn set_base_flag(&mut self, flag: BaseFlag, value: bool)
Set or unset the specified flag on this object.
sourcefn set_base_flags(&mut self, in_flags: BitFlags<BaseFlag>)
fn set_base_flags(&mut self, in_flags: BitFlags<BaseFlag>)
Set the BaseFlags of this object. Note that replaces all flags currently
on the object. Use
set_base_flag
to set individual flags. Read moresourcefn get_base_flags(&self) -> BitFlags<BaseFlag>
fn get_base_flags(&self) -> BitFlags<BaseFlag>
Read the BaseFlags of this object
sourcefn is_releasable(&self) -> bool
fn is_releasable(&self) -> bool
Returns true if this object can be released, i.e., it is not subordinate.
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more