pub struct ColorField {
pub coordinate: FieldCoordinate,
pub range: [f32; 2],
pub colors: ColorCurve,
}Expand description
Color sampled from position or speed, with an explicit normalization interval.
Fields§
§coordinate: FieldCoordinateSource coordinate.
range: [f32; 2]Strictly increasing finite normalization interval.
colors: ColorCurveOutput color curve.
Trait Implementations§
Source§impl Clone for ColorField
impl Clone for ColorField
Source§impl ParticleModifier for ColorField
impl ParticleModifier for ColorField
Source§fn apply(
&self,
particle: &mut Particle,
_: f32,
_: Time,
_: &mut Random,
) -> Result<(), ValidationError>
fn apply( &self, particle: &mut Particle, _: f32, _: Time, _: &mut Random, ) -> Result<(), ValidationError>
Updates one live particle; index and canonical age remain engine-owned.
Source§fn resets_color(&self) -> bool
fn resets_color(&self) -> bool
Requests birth-color restoration before the ordered modifier chain.
Multiplicative lifetime energy curves use this to avoid frame-count accumulation.
Source§fn apply_event(
&self,
particle: &mut Particle,
step_seconds: f32,
time: Time,
random: &mut Random,
) -> Result<bool, ValidationError>
fn apply_event( &self, particle: &mut Particle, step_seconds: f32, time: Time, random: &mut Random, ) -> Result<bool, ValidationError>
Optional predicted-step collision response, preserving the original callback API.
Auto Trait Implementations§
impl !RefUnwindSafe for ColorField
impl !UnwindSafe for ColorField
impl Forget for ColorField
impl Freeze for ColorField
impl Move for ColorField
impl Send for ColorField
impl Sync for ColorField
impl Unpin for ColorField
impl UnsafeUnpin for ColorField
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