pub struct Participant {
pub position: Array1<f64>,
pub velocity: Array1<f64>,
pub radius: f64,
pub confidence: f64,
pub in_obstacle: bool,
/* private fields */
}
Expand description
Struct for representing a participant in the ORCA algorithm.
Fields§
§position: Array1<f64>
§velocity: Array1<f64>
§radius: f64
§confidence: f64
§in_obstacle: bool
Implementations§
Source§impl Participant
impl Participant
pub fn new( position: Array1<f64>, velocity: Array1<f64>, radius: f64, confidence: f64, ) -> Self
Sourcepub fn with_inner_state(self, vmax: f64, target: Array1<f64>) -> Self
pub fn with_inner_state(self, vmax: f64, target: Array1<f64>) -> Self
Assign some inner state to this participant.
Sourcepub fn update_position(&mut self, position: &Array1<f64>)
pub fn update_position(&mut self, position: &Array1<f64>)
Update the position, the velocity and the internal preferred velocity of this participant.
Sourcepub fn in_obstacle(&mut self)
pub fn in_obstacle(&mut self)
Update the information about this participant to be in an obstacle.
Trait Implementations§
Source§impl Clone for Participant
impl Clone for Participant
Source§fn clone(&self) -> Participant
fn clone(&self) -> Participant
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreAuto Trait Implementations§
impl Freeze for Participant
impl RefUnwindSafe for Participant
impl Send for Participant
impl Sync for Participant
impl Unpin for Participant
impl UnwindSafe for Participant
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