pub struct TensorField<'a> { /* private fields */ }Expand description
Evaluates a tensor field over a HeightMap, producing orthogonal major/minor
direction vectors at any world-space coordinate.
- Major (contour): follows elevation lines — ideal for winding mountain roads.
- Minor (gradient): points up/down the slope — ideal for steep connecting streets.
Implementations§
Source§impl<'a> TensorField<'a>
impl<'a> TensorField<'a>
Sourcepub fn new(heightmap: &'a HeightMap) -> Self
pub fn new(heightmap: &'a HeightMap) -> Self
Creates a tensor field with default sampling parameters.
Sourcepub fn with_config(heightmap: &'a HeightMap, config: TensorFieldConfig) -> Self
pub fn with_config(heightmap: &'a HeightMap, config: TensorFieldConfig) -> Self
Creates a tensor field with custom sampling parameters.
Auto Trait Implementations§
impl<'a> !Freeze for TensorField<'a>
impl<'a> RefUnwindSafe for TensorField<'a>
impl<'a> Send for TensorField<'a>
impl<'a> Sync for TensorField<'a>
impl<'a> Unpin for TensorField<'a>
impl<'a> UnsafeUnpin for TensorField<'a>
impl<'a> UnwindSafe for TensorField<'a>
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