parry3d::partitioning

Trait ParallelSimdSimultaneousVisitor

source
pub trait ParallelSimdSimultaneousVisitor<LeafData1, LeafData2>: Sync {
    type Data: Copy + Sync + Default;

    // Required method
    fn visit(
        &self,
        left_node_id: SimdNodeIndex,
        left_node: &QbvhNode,
        left_data: Option<[Option<&LeafData1>; 4]>,
        right_node_id: SimdNodeIndex,
        right_node: &QbvhNode,
        right_data: Option<[Option<&LeafData2>; 4]>,
        visitor_data: Self::Data,
    ) -> (SimdSimultaneousVisitStatus, Self::Data);
}
Expand description

Trait implemented by visitor called during a parallel simultaneous spatial partitioning data structure traversal.

Required Associated Types§

source

type Data: Copy + Sync + Default

Visitor state data that will be passed down the recursion.

Required Methods§

source

fn visit( &self, left_node_id: SimdNodeIndex, left_node: &QbvhNode, left_data: Option<[Option<&LeafData1>; 4]>, right_node_id: SimdNodeIndex, right_node: &QbvhNode, right_data: Option<[Option<&LeafData2>; 4]>, visitor_data: Self::Data, ) -> (SimdSimultaneousVisitStatus, Self::Data)

Execute an operation on the content of two nodes, one from each structure.

Returns whether the traversal should continue on the nodes children, if it should not continue on those children, or if the whole traversal should be exited early.

Implementors§

source§

impl<LeafData1: Sync, LeafData2: Sync, F> ParallelSimdSimultaneousVisitor<LeafData1, LeafData2> for BoundingVolumeIntersectionsSimultaneousVisitor<LeafData1, LeafData2, F>
where F: Sync + Fn(&LeafData1, &LeafData2) -> bool,