Struct noise::TranslatePoint
[−]
[src]
pub struct TranslatePoint<Source, T> { pub source: Source, pub x_translation: T, pub y_translation: T, pub z_translation: T, pub u_translation: T, }
Noise Module that moves the coordinates of the input value before returning the output value from the source module.
The get() method moves the coordinates of the input value by a translation amount before returning the output value from the source module.
Fields
source: Source
Source Module that outputs a value
x_translation: T
Translation amount applied to the x coordinate of the input value. The default translation amount is set to 0.0.
y_translation: T
Translation amount applied to the y coordinate of the input value. The default translation amount is set to 0.0.
z_translation: T
Translation amount applied to the z coordinate of the input value. The default translation amount is set to 0.0.
u_translation: T
Translation amount applied to the u coordinate of the input value. The default translation amount is set to 0.0.
Methods
impl<Source, T> TranslatePoint<Source, T> where
T: Float,
[src]
T: Float,
fn new(source: Source) -> TranslatePoint<Source, T>
fn set_x_translation(self, x_translation: T) -> TranslatePoint<Source, T>
Sets the scaling factor to apply to the x coordinate of the input value.
fn set_y_translation(self, y_translation: T) -> TranslatePoint<Source, T>
Sets the scaling factor to apply to the x coordinate of the input value.
fn set_z_translation(self, z_translation: T) -> TranslatePoint<Source, T>
Sets the scaling factor to apply to the x coordinate of the input value.
fn set_u_translation(self, u_translation: T) -> TranslatePoint<Source, T>
Sets the scaling factor to apply to the x coordinate of the input value.
fn set_translation(self, scale: T) -> TranslatePoint<Source, T>
Sets the translation amount to apply to all coordinates of the input value.
fn set_all_translations(
self,
x_translation: T,
y_translation: T,
z_translation: T,
u_translation: T
) -> TranslatePoint<Source, T>
self,
x_translation: T,
y_translation: T,
z_translation: T,
u_translation: T
) -> TranslatePoint<Source, T>
Sets the individual translation amounts to apply to each coordinate of the input value.
Trait Implementations
impl<Source, T> NoiseModule<Point2<T>> for TranslatePoint<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 TranslatePoint<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 TranslatePoint<Source, T> where
Source: NoiseModule<Point4<T>, Output = T>,
T: Float,
[src]
Source: NoiseModule<Point4<T>, Output = T>,
T: Float,