noise_functions::modifiers

Struct MulSeed

Source
pub struct MulSeed<Noise> {
    pub noise: Noise,
    pub value: i32,
}
Expand description

Multiplies the seed by value.

Fields§

§noise: Noise§value: i32

Trait Implementations§

Source§

impl<Noise: Clone> Clone for MulSeed<Noise>

Source§

fn clone(&self) -> MulSeed<Noise>

Returns a copy of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl<Noise: Debug> Debug for MulSeed<Noise>

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<N> Noise for MulSeed<N>

Source§

fn seed(self, seed: i32) -> Seeded<Self>
where Self: Sized,

Sets a seed to be sampled with. Read more
Source§

fn frequency(self, frequency: f32) -> Frequency<Self>
where Self: Sized,

Modifies a noise with a frequency multiplier. Read more
Source§

fn fbm(self, octaves: u32, gain: f32, lacunarity: f32) -> Fbm<Self>
where Self: Sized,

Creates a fractal from this noise with the provided octaves, gain and lacunarity. Read more
Source§

fn ridged(self) -> Ridged<Self>
where Self: Sized,

Modifies a noise to create a peak at 0. Read more
Source§

fn triangle_wave(self, frequency: f32) -> TriangleWave<Self>
where Self: Sized,

Applies a triangle wave to the output of a base noise function. Read more
Source§

fn tileable(self, width: f32, height: f32) -> Tileable<Self>
where Self: Sized,

Creates a tileable 2D noise from a 4D noise. Read more
Source§

fn mul_seed(self, value: i32) -> MulSeed<Self>
where Self: Sized,

Multiplies the seed by value.
Source§

impl<Noise: PartialEq> PartialEq for MulSeed<Noise>

Source§

fn eq(&self, other: &MulSeed<Noise>) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl<Noise, const DIM: usize> Sample<DIM> for MulSeed<Noise>
where Noise: SampleWithSeed<DIM>,

Source§

fn sample(&self, point: [f32; DIM]) -> f32

Source§

impl<Noise, const DIM: usize, const LANES: usize> Sample<DIM, Simd<f32, LANES>> for MulSeed<Noise>
where Noise: SampleWithSeed<DIM, Simd<f32, LANES>>, LaneCount<LANES>: SupportedLaneCount,

Available on crate feature nightly-simd only.
Source§

fn sample(&self, point: Simd<f32, LANES>) -> f32

Source§

impl<Noise, const DIM: usize> SampleWithSeed<DIM> for MulSeed<Noise>
where Noise: SampleWithSeed<DIM>,

Source§

fn sample_with_seed(&self, point: [f32; DIM], seed: i32) -> f32

Source§

impl<Noise, const DIM: usize, const LANES: usize> SampleWithSeed<DIM, Simd<f32, LANES>> for MulSeed<Noise>
where Noise: SampleWithSeed<DIM, Simd<f32, LANES>>, LaneCount<LANES>: SupportedLaneCount,

Available on crate feature nightly-simd only.
Source§

fn sample_with_seed(&self, point: Simd<f32, LANES>, seed: i32) -> f32

Source§

impl<Noise: Copy> Copy for MulSeed<Noise>

Source§

impl<Noise: Eq> Eq for MulSeed<Noise>

Source§

impl<Noise> StructuralPartialEq for MulSeed<Noise>

Auto Trait Implementations§

§

impl<Noise> Freeze for MulSeed<Noise>
where Noise: Freeze,

§

impl<Noise> RefUnwindSafe for MulSeed<Noise>
where Noise: RefUnwindSafe,

§

impl<Noise> Send for MulSeed<Noise>
where Noise: Send,

§

impl<Noise> Sync for MulSeed<Noise>
where Noise: Sync,

§

impl<Noise> Unpin for MulSeed<Noise>
where Noise: Unpin,

§

impl<Noise> UnwindSafe for MulSeed<Noise>
where Noise: UnwindSafe,

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dst: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dst. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<N> Sample2 for N
where N: Sample<2>,

Source§

fn sample2(&self, point: impl Into<[f32; 2]>) -> f32

Source§

impl<N> Sample2a for N
where N: Sample<2, Simd<f32, 2>>,

Source§

fn sample2a(&self, point: impl Into<Simd<f32, 2>>) -> f32

Available on crate feature nightly-simd only.
Source§

impl<N> Sample3 for N
where N: Sample<3>,

Source§

fn sample3(&self, point: impl Into<[f32; 3]>) -> f32

Source§

impl<N> Sample3a for N
where N: Sample<3, Simd<f32, 4>>,

Source§

fn sample3a(&self, point: impl Into<Simd<f32, 4>>) -> f32

Available on crate feature nightly-simd only.
Source§

impl<N> Sample4 for N
where N: Sample<4>,

Source§

fn sample4(&self, point: impl Into<[f32; 4]>) -> f32

Source§

impl<N> Sample4a for N
where N: Sample<4, Simd<f32, 4>>,

Source§

fn sample4a(&self, point: impl Into<Simd<f32, 4>>) -> f32

Available on crate feature nightly-simd only.
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.