pub(super) struct MeshRow<'a> {Show 13 fields
pub express_id: u32,
pub ifc_type: &'a str,
pub v_start: u32,
pub vert_count: u32,
pub i_start: u32,
pub index_count: u32,
pub color: [f32; 4],
pub origin: [f64; 3],
pub geometry_class: u8,
pub geometry_item_id: Option<u32>,
pub material_id: Option<u32>,
pub finish: [f32; 2],
pub rotation: [f32; 9],
}Expand description
One mesh’s row across the three tables, in the order mesh_schema() lists.
A struct, not the 11-element tuple this was. That tuple was POSITIONAL and
several slots share a type – the four u32 offsets/counts, and the two
Option<u32> source ids. Measured BEFORE this branch grew its tests:
swapping the two ids compiled and left 202/202 green, writing every
representation-item id into the material column and back.
It is caught now – mesh_table_carries_both_source_ids_on_the_right_columns
fails on that swap. Named fields make it unreachable at the construction
site as well, which is belt and braces, not a reason to drop the test: the
RecordBatch arrays are still positional against the schema.
Fields§
§express_id: u32§ifc_type: &'a str§v_start: u32§vert_count: u32§i_start: u32§index_count: u32§color: [f32; 4]§origin: [f64; 3]In the SAME Y-up frame as the emitted positions. The swap is linear, so
swap(origin + position) = swap(origin) + swap(position); see
services::axis for the one definition.
geometry_class: u8§geometry_item_id: Option<u32>§material_id: Option<u32>§finish: [f32; 2][metallic, roughness], NaN where unauthored (#5984).
rotation: [f32; 9]Row-major 3x3, Y-up, placing the SHARED block this row points at:
world = origin + R * p. Identity for a row that owns its geometry.
Implementations§
Source§impl<'a> MeshRow<'a>
impl<'a> MeshRow<'a>
Sourcepub fn new(mesh: &'a MeshData, placement: RowPlacement) -> Self
pub fn new(mesh: &'a MeshData, placement: RowPlacement) -> Self
Build one row from an occurrence and the placement of the shape block it draws.
Here rather than at the call site so the field order is stated once,
next to the schema whose column order it feeds. On every unshared row,
which is every row of a -parquet-v8 payload, the block is mesh’s own.
Auto Trait Implementations§
impl<'a> Freeze for MeshRow<'a>
impl<'a> RefUnwindSafe for MeshRow<'a>
impl<'a> Send for MeshRow<'a>
impl<'a> Sync for MeshRow<'a>
impl<'a> Unpin for MeshRow<'a>
impl<'a> UnwindSafe for MeshRow<'a>
Blanket Implementations§
§impl<U> As for U
impl<U> As for U
§fn as_<T>(self) -> Twhere
T: CastFrom<U>,
fn as_<T>(self) -> Twhere
T: CastFrom<U>,
self to type T. The semantics of numeric casting with the as operator are followed, so <T as As>::as_::<U> can be used in the same way as T as U for numeric conversions. Read moreSource§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
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more§impl<T> Pointable for T
impl<T> Pointable for T
§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
self from the equivalent element of its
superset. Read more§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
self is actually part of its subset T (and can be converted to it).§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
self.to_subset but without any property checks. Always succeeds.§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
self to the equivalent element of its superset.