pub struct Gradient { /* private fields */ }
Implementations§
Source§impl Gradient
impl Gradient
pub fn new_with_len(len: usize) -> Self
pub fn new_with_mesh(mesh: &impl Mesh) -> Self
pub fn spread_forward(&mut self, mesh: &impl Mesh, incr: f64) -> usize
pub fn spread_backward(&mut self, mesh: &impl Mesh, incr: f64) -> usize
pub fn spread_both(&mut self, mesh: &impl Mesh, incr: f64) -> usize
pub fn spread_slot( &mut self, here_index: usize, mesh: &impl Mesh, incr: f64, ) -> bool
pub fn incr(&mut self, incr: f64)
pub fn spread(&mut self, mesh: &impl Mesh)
pub fn set_distance(&mut self, slot_index: usize, value: f64)
pub fn get_distance(&self, slot_index: usize) -> f64
pub fn get_target(&self, slot_index: usize) -> usize
pub fn get(&self, slot_index: usize) -> &Gate
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Gradient
impl RefUnwindSafe for Gradient
impl Send for Gradient
impl Sync for Gradient
impl Unpin for Gradient
impl UnwindSafe for Gradient
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