Skip to main content

NodeTemporalEntry

Struct NodeTemporalEntry 

Source
pub struct NodeTemporalEntry {
    pub key: VoxelKey,
    /* private fields */
}
Expand description

Per-node temporal data: a set of sampled GPS timestamps.

Fields§

§key: VoxelKey

The octree node this entry describes.

Implementations§

Source§

impl NodeTemporalEntry

Source

pub fn new(key: VoxelKey, samples: Vec<GpsTime>) -> Self

Create a new entry with the given key and samples.

§Panics

Panics if samples is empty — every node must have at least one sample.

Source

pub fn samples(&self) -> &[GpsTime]

The sampled GPS time values for this node.

Source

pub fn time_range(&self) -> (GpsTime, GpsTime)

Returns (min_time, max_time) for this node.

Source

pub fn overlaps(&self, start: GpsTime, end: GpsTime) -> bool

Returns true if this node may contain points in [start, end].

Source

pub fn estimate_point_range( &self, start: GpsTime, end: GpsTime, stride: u32, point_count: u32, ) -> Range<u32>

Estimate the point index range within the decompressed chunk for a time range.

Implements the binary search logic from spec section 8.2:

  1. Find first sample index i where samples[i] >= t_start
  2. Find last sample index j where samples[j] <= t_end
  3. Start point = i * stride
  4. End point = min(j * stride + stride - 1, point_count - 1)

Trait Implementations§

Source§

impl Clone for NodeTemporalEntry

Source§

fn clone(&self) -> NodeTemporalEntry

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for NodeTemporalEntry

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.