Struct kiss3d_trackball::Input
source · pub struct Input<N: Copy + RealField> { /* private fields */ }
Expand description
Input keys/buttons and their modifiers.
Implementations§
source§impl<N: Copy + RealField> Input<N>
impl<N: Copy + RealField> Input<N>
sourcepub fn first_key(&self) -> Option<Key>
pub fn first_key(&self) -> Option<Key>
Key used to enable first person view as long as being pressed.
sourcepub fn rebind_first_key(&mut self, key: Option<Key>)
pub fn rebind_first_key(&mut self, key: Option<Key>)
Sets key used to enable first person view as long as being pressed.
Use None
to disable key.
sourcepub fn ortho_key(&self) -> Option<Key>
pub fn ortho_key(&self) -> Option<Key>
Key used to switch between orthographic and perspective projection.
sourcepub fn rebind_ortho_key(&mut self, key: Option<Key>)
pub fn rebind_ortho_key(&mut self, key: Option<Key>)
Sets key used to switch between orthographic and perspective projection.
Use None
to disable key.
sourcepub fn rebind_reset_key(&mut self, key: Option<Key>)
pub fn rebind_reset_key(&mut self, key: Option<Key>)
Sets key used to reset camera.
Use None
to disable key.
Button used to orbit camera.
Sets button used to orbit camera.
Use None
to disable button.
sourcepub fn orbit_modifiers(&self) -> Option<Modifiers>
pub fn orbit_modifiers(&self) -> Option<Modifiers>
Modifiers that must be pressed for orbit to occur.
sourcepub fn set_orbit_modifiers(&mut self, modifiers: Option<Modifiers>)
pub fn set_orbit_modifiers(&mut self, modifiers: Option<Modifiers>)
Sets modifiers that must be pressed for orbit to occur.
- If set to
None
, then pressing any modifier will not prevent orbit. - If different from
None
, orbit will occur only if the exact specified set of modifiers is pressed. In particular, if set toSome(Modifiers::empty())
, orbit will occur only if no modifier is pressed.
Button used to slide camera.
Sets button used to slide camera.
Use None
to disable button.
sourcepub fn slide_modifiers(&self) -> Option<Modifiers>
pub fn slide_modifiers(&self) -> Option<Modifiers>
Modifiers that must be pressed for slide to occur.
sourcepub fn set_slide_modifiers(&mut self, modifiers: Option<Modifiers>)
pub fn set_slide_modifiers(&mut self, modifiers: Option<Modifiers>)
Sets modifiers that must be pressed for slide to occur.
- If set to
None
, then pressing any modifier will not prevent slide. - If different from
None
, slide will occur only if the exact specified set of modifiers is pressed. In particular, if set toSome(Modifiers::empty())
, slide will occur only if no modifier is pressed.
Trait Implementations§
Auto Trait Implementations§
impl<N> RefUnwindSafe for Input<N>where N: RefUnwindSafe,
impl<N> Send for Input<N>
impl<N> Sync for Input<N>
impl<N> Unpin for Input<N>where N: Unpin,
impl<N> UnwindSafe for Input<N>where N: UnwindSafe,
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
§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere T: Any,
§fn into_any(self: Box<T, Global>) -> Box<dyn Any, Global>
fn into_any(self: Box<T, Global>) -> Box<dyn Any, Global>
Box<dyn Trait>
(where Trait: Downcast
) to Box<dyn Any>
. Box<dyn Any>
can
then be further downcast
into Box<ConcreteType>
where ConcreteType
implements Trait
.§fn into_any_rc(self: Rc<T, Global>) -> Rc<dyn Any, Global>
fn into_any_rc(self: Rc<T, Global>) -> Rc<dyn Any, Global>
Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
. Rc<Any>
can then be
further downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
.§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &Any
’s vtable from &Trait
’s.§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &mut Any
’s vtable from &mut Trait
’s.§impl<T> Pointable for T
impl<T> Pointable for T
§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere SS: SubsetOf<SP>,
§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
self
from the equivalent element of its
superset. Read more§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
self
is actually part of its subset T
(and can be converted to it).§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
self.to_subset
but without any property checks. Always succeeds.§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
self
to the equivalent element of its superset.