Struct DiscreteVisitor

Source
pub struct DiscreteVisitor<'a, B: 'a, T> { /* private fields */ }
Expand description

Visitor for doing discrete intersection testing on the DBVT.

Will return () for intersections with the Discrete implementation of bound.intersects(self.bound).

Implementations§

Source§

impl<'a, B: 'a, T> DiscreteVisitor<'a, B, T>
where T: TreeValue, T::Bound: Discrete<B>,

Source

pub fn new(bound: &'a B) -> Self

Create a new visitor that will do discrete intersection tests using the given bound.

Trait Implementations§

Source§

impl<'a, B: Debug + 'a, T: Debug> Debug for DiscreteVisitor<'a, B, T>

Source§

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

Formats the value using the given formatter. Read more
Source§

impl<'a, B: 'a, T> Visitor for DiscreteVisitor<'a, B, T>
where T: TreeValue, T::Bound: Discrete<B>,

Source§

type Bound = <T as TreeValue>::Bound

Bounding volume accepted by the visitor
Source§

type Result = ()

Result returned by the acceptance test
Source§

fn accept(&mut self, bound: &Self::Bound, _: bool) -> Option<()>

Acceptance test function

Auto Trait Implementations§

§

impl<'a, B, T> Freeze for DiscreteVisitor<'a, B, T>

§

impl<'a, B, T> RefUnwindSafe for DiscreteVisitor<'a, B, T>

§

impl<'a, B, T> Send for DiscreteVisitor<'a, B, T>
where B: Sync, T: Send,

§

impl<'a, B, T> Sync for DiscreteVisitor<'a, B, T>
where B: Sync, T: Sync,

§

impl<'a, B, T> Unpin for DiscreteVisitor<'a, B, T>
where T: Unpin,

§

impl<'a, B, T> UnwindSafe for DiscreteVisitor<'a, B, T>

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> 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, 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.