Struct noise::ScalePoint
[−]
[src]
pub struct ScalePoint<Source, T> { pub source: Source, pub x_scale: T, pub y_scale: T, pub z_scale: T, pub u_scale: T, }
Noise Module that scales the coordinates of the input value before returning the output value from the source module.
The get() method multiplies the coordinates of the input value with a scaling factor before returning the output value from the source module.
Fields
source: Source
Source Module that outputs a value
x_scale: T
Scaling factor applied to the x coordinate of the input value. The default scaling factor is set to 1.0.
y_scale: T
Scaling factor applied to the y coordinate of the input value. The default scaling factor is set to 1.0.
z_scale: T
Scaling factor applied to the z coordinate of the input value. The default scaling factor is set to 1.0.
u_scale: T
Scaling factor applied to the u coordinate of the input value. The default scaling factor is set to 1.0.
Methods
impl<Source, T> ScalePoint<Source, T> where
T: Float,
[src]
T: Float,
fn new(source: Source) -> ScalePoint<Source, T>
fn set_x_scale(self, x_scale: T) -> ScalePoint<Source, T>
Sets the scaling factor to apply to the x coordinate of the input value.
fn set_y_scale(self, y_scale: T) -> ScalePoint<Source, T>
Sets the scaling factor to apply to the x coordinate of the input value.
fn set_z_scale(self, z_scale: T) -> ScalePoint<Source, T>
Sets the scaling factor to apply to the x coordinate of the input value.
fn set_u_scale(self, u_scale: T) -> ScalePoint<Source, T>
Sets the scaling factor to apply to the x coordinate of the input value.
fn set_scale(self, scale: T) -> ScalePoint<Source, T>
Sets the scaling factor to apply to all coordinates of the input value.
fn set_all_scales(
self,
x_scale: T,
y_scale: T,
z_scale: T,
u_scale: T
) -> ScalePoint<Source, T>
self,
x_scale: T,
y_scale: T,
z_scale: T,
u_scale: T
) -> ScalePoint<Source, T>
Sets the individual scaling factors to apply to each coordinate of the input value.
Trait Implementations
impl<Source, T> NoiseModule<Point2<T>> for ScalePoint<Source, T> where
Source: NoiseModule<Point2<T>, Output = T>,
T: Float,
[src]
Source: NoiseModule<Point2<T>, Output = T>,
T: Float,
impl<Source, T> NoiseModule<Point3<T>> for ScalePoint<Source, T> where
Source: NoiseModule<Point3<T>, Output = T>,
T: Float,
[src]
Source: NoiseModule<Point3<T>, Output = T>,
T: Float,
impl<Source, T> NoiseModule<Point4<T>> for ScalePoint<Source, T> where
Source: NoiseModule<Point4<T>, Output = T>,
T: Float,
[src]
Source: NoiseModule<Point4<T>, Output = T>,
T: Float,