pub struct EscapeResult {
pub escaped: bool,
pub iterations: u32,
pub smooth: f64,
pub final_norm: f64,
pub final_z: Complex,
}Expand description
Result of an escape-time fractal iteration.
Fields§
§escaped: boolWhether the orbit escaped within max_iter.
iterations: u32Number of iterations before escape (or max_iter).
smooth: f64Smooth iteration count for anti-banding coloring.
final_norm: f64Final z magnitude before escape.
final_z: ComplexFinal z value at escape.
Implementations§
Source§impl EscapeResult
impl EscapeResult
Sourcepub fn normalized(&self, max_iter: u32) -> f64
pub fn normalized(&self, max_iter: u32) -> f64
Normalized [0, 1] escape value using smooth iteration count.
Sourcepub fn orbit_angle(&self) -> f64
pub fn orbit_angle(&self) -> f64
Hue angle [0, 2π] from the orbit angle of the final z.
Trait Implementations§
Source§impl Clone for EscapeResult
impl Clone for EscapeResult
Source§fn clone(&self) -> EscapeResult
fn clone(&self) -> EscapeResult
Returns a duplicate 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 moreSource§impl Debug for EscapeResult
impl Debug for EscapeResult
impl Copy for EscapeResult
Auto Trait Implementations§
impl Freeze for EscapeResult
impl RefUnwindSafe for EscapeResult
impl Send for EscapeResult
impl Sync for EscapeResult
impl Unpin for EscapeResult
impl UnsafeUnpin for EscapeResult
impl UnwindSafe for EscapeResult
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
Source§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Convert
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.Source§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Convert
Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be
further downcast into Rc<ConcreteType> where ConcreteType implements Trait.Source§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
Convert
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.Source§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
Convert
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.