pub struct LightGridLeaf {
pub mins: UVec3,
/* private fields */
}Fields§
§mins: UVec3Implementations§
Source§impl LightGridLeaf
impl LightGridLeaf
pub fn cells(&self) -> &[LightGridCell]
Sourcepub const fn cell_idx(&self, x: u32, y: u32, z: u32) -> usize
pub const fn cell_idx(&self, x: u32, y: u32, z: u32) -> usize
Returns the index into data of the cell at the position specified.
Sourcepub fn get_cell(&self, x: u32, y: u32, z: u32) -> &LightGridCell
pub fn get_cell(&self, x: u32, y: u32, z: u32) -> &LightGridCell
Returns the cell at the specified position, panics if the position is out of bounds.
Sourcepub fn get_cell_mut(&mut self, x: u32, y: u32, z: u32) -> &mut LightGridCell
pub fn get_cell_mut(&mut self, x: u32, y: u32, z: u32) -> &mut LightGridCell
Returns the cell at the specified position, panics if the position is out of bounds.
pub const fn size(&self) -> UVec3
Trait Implementations§
Source§impl BspValue for LightGridLeaf
impl BspValue for LightGridLeaf
Source§fn bsp_parse(reader: &mut BspByteReader<'_>) -> BspResult<Self>
fn bsp_parse(reader: &mut BspByteReader<'_>) -> BspResult<Self>
Parse this value, advancing the byte reader.
Source§fn bsp_struct_size(_ctx: &BspParseContext) -> usize
fn bsp_struct_size(_ctx: &BspParseContext) -> usize
How big this value is in the BSP file in bytes. If it is a variable size, return
unimplemented!(), as calling this on variable-sized values would be a bug.Source§impl Clone for LightGridLeaf
impl Clone for LightGridLeaf
Source§fn clone(&self) -> LightGridLeaf
fn clone(&self) -> LightGridLeaf
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for LightGridLeaf
impl RefUnwindSafe for LightGridLeaf
impl Send for LightGridLeaf
impl Sync for LightGridLeaf
impl Unpin for LightGridLeaf
impl UnwindSafe for LightGridLeaf
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