Struct veloren_common::terrain::map::MapSample
source · pub struct MapSample {
pub rgb: Rgb<u8>,
pub alt: f64,
pub downhill_wpos: Vec2<i32>,
pub connections: Option<[Option<Connection>; 8]>,
}
Expand description
Per-chunk data the map needs to be able to sample in order to correctly render.
Fields§
§rgb: Rgb<u8>
the base RGB color for a particular map pixel using the current settings (i.e. the color without lighting).
alt: f64
Surface altitude information (correctly reflecting settings like is_basement and is_water)
downhill_wpos: Vec2<i32>
Downhill chunk (may not be meaningful on ocean tiles, or at least edge tiles)
connections: Option<[Option<Connection>; 8]>
Connection information about any connections to/from this chunk (e.g. rivers).
Connections at each index correspond to the same index in NEIGHBOR_DELTA.
Trait Implementations§
Auto Trait Implementations§
impl RefUnwindSafe for MapSample
impl Send for MapSample
impl Sync for MapSample
impl Unpin for MapSample
impl UnwindSafe for MapSample
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