Struct FastNoise

Source
pub struct FastNoise { /* private fields */ }

Implementations§

Source§

impl FastNoise

Source

pub fn new() -> FastNoise

Creates a new noise instance, using simplex noise defaults.

Source

pub fn seeded(seed: u64) -> FastNoise

Creates a new noise instance, using simplex noise defaults and specifying a random seed.

Source

pub fn set_seed(&mut self, seed: u64)

Re-seeds the noise system with a new seed.

Source

pub fn get_seed(&self) -> u64

Source

pub fn set_frequency(&mut self, frequency: f32)

Source

pub fn get_frequency(&self) -> f32

Source

pub fn set_interp(&mut self, interp: Interp)

Source

pub fn get_interp(&self) -> Interp

Source

pub fn set_noise_type(&mut self, nt: NoiseType)

Source

pub fn get_noise_type(&self) -> NoiseType

Source

pub fn set_fractal_octaves(&mut self, octaves: i32)

Source

pub fn get_fractal_octaves(&self) -> i32

Source

pub fn set_fractal_lacunarity(&mut self, lacunarity: f32)

Source

pub fn get_fractal_lacunarity(&self) -> f32

Source

pub fn set_fractal_gain(&mut self, gain: f32)

Source

pub fn get_fractal_gain(&self) -> f32

Source

pub fn set_fractal_type(&mut self, fractal_type: FractalType)

Source

pub fn get_fractal_type(&self) -> FractalType

Source

pub fn set_cellular_distance_function( &mut self, cellular_distance_function: CellularDistanceFunction, )

Source

pub fn get_cellular_distance_function(&self) -> CellularDistanceFunction

Source

pub fn set_cellular_return_type( &mut self, cellular_return_type: CellularReturnType, )

Source

pub fn get_cellular_return_type(&self) -> CellularReturnType

Source

pub fn get_cellular_distance_indices(&self) -> (i32, i32)

Source

pub fn set_cellular_jitter(&mut self, jitter: f32)

Source

pub fn get_cellular_jitter(&self) -> f32

Source

pub fn set_gradient_perterb_amp(&mut self, gradient_perturb_amp: f32)

Source

pub fn get_gradient_perterb_amp(&self) -> f32

Source

pub fn set_cellular_distance_indices(&mut self, i1: i32, i2: i32)

Source

pub fn index2d_12(&self, offset: u8, x: i32, y: i32) -> u8

Source

pub fn index3d_12(&self, offset: u8, x: i32, y: i32, z: i32) -> u8

Source

pub fn index4d_32(&self, offset: u8, x: i32, y: i32, z: i32, w: i32) -> u8

Source

pub fn index2d_256(&self, offset: u8, x: i32, y: i32) -> u8

Source

pub fn index3d_256(&self, offset: u8, x: i32, y: i32, z: i32) -> u8

Source

pub fn index4d_256(&self, offset: u8, x: i32, y: i32, z: i32, w: i32) -> u8

Source

pub fn get_noise3d(&self, x: f32, y: f32, z: f32) -> f32

Source

pub fn get_noise(&self, x: f32, y: f32) -> f32

Auto Trait Implementations§

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> 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<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.