pub struct SafeNode(/* private fields */);
Expand description
Implementations§
Source§impl SafeNode
impl SafeNode
Sourcepub fn from_encoded_node_tree(
encoded_node_tree: &str,
) -> Result<Self, FastNoiseError>
pub fn from_encoded_node_tree( encoded_node_tree: &str, ) -> Result<Self, FastNoiseError>
pub fn get_simd_level(&self) -> u32
Sourcepub fn gen_uniform_grid_2d(
&self,
noise_out: &mut [f32],
x_start: i32,
y_start: i32,
x_size: i32,
y_size: i32,
frequency: f32,
seed: i32,
) -> OutputMinMax
pub fn gen_uniform_grid_2d( &self, noise_out: &mut [f32], x_start: i32, y_start: i32, x_size: i32, y_size: i32, frequency: f32, seed: i32, ) -> OutputMinMax
§Panics
Panics if noise_out.len() < x_size * y_size
.
Sourcepub fn gen_uniform_grid_3d(
&self,
noise_out: &mut [f32],
x_start: i32,
y_start: i32,
z_start: i32,
x_size: i32,
y_size: i32,
z_size: i32,
frequency: f32,
seed: i32,
) -> OutputMinMax
pub fn gen_uniform_grid_3d( &self, noise_out: &mut [f32], x_start: i32, y_start: i32, z_start: i32, x_size: i32, y_size: i32, z_size: i32, frequency: f32, seed: i32, ) -> OutputMinMax
§Panics
Panics if noise_out.len() < x_size * y_size * z_size
.
Sourcepub fn gen_uniform_grid_4d(
&self,
noise_out: &mut [f32],
x_start: i32,
y_start: i32,
z_start: i32,
w_start: i32,
x_size: i32,
y_size: i32,
z_size: i32,
w_size: i32,
frequency: f32,
seed: i32,
) -> OutputMinMax
pub fn gen_uniform_grid_4d( &self, noise_out: &mut [f32], x_start: i32, y_start: i32, z_start: i32, w_start: i32, x_size: i32, y_size: i32, z_size: i32, w_size: i32, frequency: f32, seed: i32, ) -> OutputMinMax
§Panics
Panics if noise_out.len() < x_size * y_size * z_size * w_size
.
Sourcepub fn gen_position_array_2d(
&self,
noise_out: &mut [f32],
x_pos_array: &[f32],
y_pos_array: &[f32],
x_offset: f32,
y_offset: f32,
seed: i32,
) -> OutputMinMax
pub fn gen_position_array_2d( &self, noise_out: &mut [f32], x_pos_array: &[f32], y_pos_array: &[f32], x_offset: f32, y_offset: f32, seed: i32, ) -> OutputMinMax
§Panics
Panics if noise_out
, x_pos_array
, and y_pos_array
do not have the same length.
Sourcepub fn gen_position_array_3d(
&self,
noise_out: &mut [f32],
x_pos_array: &[f32],
y_pos_array: &[f32],
z_pos_array: &[f32],
x_offset: f32,
y_offset: f32,
z_offset: f32,
seed: i32,
) -> OutputMinMax
pub fn gen_position_array_3d( &self, noise_out: &mut [f32], x_pos_array: &[f32], y_pos_array: &[f32], z_pos_array: &[f32], x_offset: f32, y_offset: f32, z_offset: f32, seed: i32, ) -> OutputMinMax
§Panics
Panics if noise_out
, x_pos_array
, y_pos_array
, and z_pos_array
do not have the same length.
Sourcepub fn gen_position_array_4d(
&self,
noise_out: &mut [f32],
x_pos_array: &[f32],
y_pos_array: &[f32],
z_pos_array: &[f32],
w_pos_array: &[f32],
x_offset: f32,
y_offset: f32,
z_offset: f32,
w_offset: f32,
seed: i32,
) -> OutputMinMax
pub fn gen_position_array_4d( &self, noise_out: &mut [f32], x_pos_array: &[f32], y_pos_array: &[f32], z_pos_array: &[f32], w_pos_array: &[f32], x_offset: f32, y_offset: f32, z_offset: f32, w_offset: f32, seed: i32, ) -> OutputMinMax
§Panics
Panics if noise_out
, x_pos_array
, y_pos_array
, z_pos_array
and w_pos_array
do not have the same length.
Sourcepub fn gen_tileable_2d(
&self,
noise_out: &mut [f32],
x_size: i32,
y_size: i32,
frequency: f32,
seed: i32,
) -> OutputMinMax
pub fn gen_tileable_2d( &self, noise_out: &mut [f32], x_size: i32, y_size: i32, frequency: f32, seed: i32, ) -> OutputMinMax
§Panics
Panics if noise_out.len() < x_size * y_size
.
pub fn gen_single_2d(&self, x: f32, y: f32, seed: i32) -> f32
pub fn gen_single_3d(&self, x: f32, y: f32, z: f32, seed: i32) -> f32
pub fn gen_single_4d(&self, x: f32, y: f32, z: f32, w: f32, seed: i32) -> f32
Trait Implementations§
impl Send for SafeNode
impl Sync for SafeNode
Auto Trait Implementations§
impl Freeze for SafeNode
impl RefUnwindSafe for SafeNode
impl Unpin for SafeNode
impl UnwindSafe for SafeNode
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