OrcaSlicer latest
OrcaSlicer
Loading...
Searching...
No Matches
Slic3r::AABBTreeIndirect::detail::IndexedTriangleSetDistancer< AVertexType, AIndexedFaceType, ATreeType, AVectorType > Struct Template Reference

#include </home/runner/work/OrcaSlicer/OrcaSlicer/src/libslic3r/AABBTreeIndirect.hpp>

Collaboration diagram for Slic3r::AABBTreeIndirect::detail::IndexedTriangleSetDistancer< AVertexType, AIndexedFaceType, ATreeType, AVectorType >:

Public Types

using VertexType = AVertexType
using IndexedFaceType = AIndexedFaceType
using TreeType = ATreeType
using VectorType = AVectorType
using ScalarType = typename VectorType::Scalar

Public Member Functions

VectorType closest_point_to_origin (size_t primitive_index, ScalarType &squared_distance) const

Public Attributes

const std::vector< VertexType > & vertices
const std::vector< IndexedFaceType > & faces
const TreeType & tree
const VectorType origin

Detailed Description

template<typename AVertexType, typename AIndexedFaceType, typename ATreeType, typename AVectorType>
struct Slic3r::AABBTreeIndirect::detail::IndexedTriangleSetDistancer< AVertexType, AIndexedFaceType, ATreeType, AVectorType >

Member Typedef Documentation

◆ IndexedFaceType

template<typename AVertexType, typename AIndexedFaceType, typename ATreeType, typename AVectorType>
using Slic3r::AABBTreeIndirect::detail::IndexedTriangleSetDistancer< AVertexType, AIndexedFaceType, ATreeType, AVectorType >::IndexedFaceType = AIndexedFaceType

◆ ScalarType

template<typename AVertexType, typename AIndexedFaceType, typename ATreeType, typename AVectorType>
using Slic3r::AABBTreeIndirect::detail::IndexedTriangleSetDistancer< AVertexType, AIndexedFaceType, ATreeType, AVectorType >::ScalarType = typename VectorType::Scalar

◆ TreeType

template<typename AVertexType, typename AIndexedFaceType, typename ATreeType, typename AVectorType>
using Slic3r::AABBTreeIndirect::detail::IndexedTriangleSetDistancer< AVertexType, AIndexedFaceType, ATreeType, AVectorType >::TreeType = ATreeType

◆ VectorType

template<typename AVertexType, typename AIndexedFaceType, typename ATreeType, typename AVectorType>
using Slic3r::AABBTreeIndirect::detail::IndexedTriangleSetDistancer< AVertexType, AIndexedFaceType, ATreeType, AVectorType >::VectorType = AVectorType

◆ VertexType

template<typename AVertexType, typename AIndexedFaceType, typename ATreeType, typename AVectorType>
using Slic3r::AABBTreeIndirect::detail::IndexedTriangleSetDistancer< AVertexType, AIndexedFaceType, ATreeType, AVectorType >::VertexType = AVertexType

Member Function Documentation

◆ closest_point_to_origin()

template<typename AVertexType, typename AIndexedFaceType, typename ATreeType, typename AVectorType>
VectorType Slic3r::AABBTreeIndirect::detail::IndexedTriangleSetDistancer< AVertexType, AIndexedFaceType, ATreeType, AVectorType >::closest_point_to_origin ( size_t primitive_index,
ScalarType & squared_distance ) const
inline
545 {
546 const auto &triangle = this->faces[primitive_index];
548 this->vertices[triangle(0)].template cast<ScalarType>(),
549 this->vertices[triangle(1)].template cast<ScalarType>(),
550 this->vertices[triangle(2)].template cast<ScalarType>());
552 return closest_point;
553 }
static Vector closest_point_to_triangle(const Vector &p, const Vector &a, const Vector &b, const Vector &c)
Definition AABBTreeIndirect.hpp:480
const std::vector< VertexType > & vertices
Definition AABBTreeIndirect.hpp:538
AVectorType VectorType
Definition AABBTreeIndirect.hpp:535
const std::vector< IndexedFaceType > & faces
Definition AABBTreeIndirect.hpp:539
const VectorType origin
Definition AABBTreeIndirect.hpp:542

References Slic3r::cast(), Slic3r::AABBTreeIndirect::detail::closest_point_to_triangle(), and origin.

Here is the call graph for this function:

Member Data Documentation

◆ faces

template<typename AVertexType, typename AIndexedFaceType, typename ATreeType, typename AVectorType>
const std::vector<IndexedFaceType>& Slic3r::AABBTreeIndirect::detail::IndexedTriangleSetDistancer< AVertexType, AIndexedFaceType, ATreeType, AVectorType >::faces

◆ origin

template<typename AVertexType, typename AIndexedFaceType, typename ATreeType, typename AVectorType>
const VectorType Slic3r::AABBTreeIndirect::detail::IndexedTriangleSetDistancer< AVertexType, AIndexedFaceType, ATreeType, AVectorType >::origin

Referenced by closest_point_to_origin().

◆ tree

template<typename AVertexType, typename AIndexedFaceType, typename ATreeType, typename AVectorType>
const TreeType& Slic3r::AABBTreeIndirect::detail::IndexedTriangleSetDistancer< AVertexType, AIndexedFaceType, ATreeType, AVectorType >::tree

◆ vertices

template<typename AVertexType, typename AIndexedFaceType, typename ATreeType, typename AVectorType>
const std::vector<VertexType>& Slic3r::AABBTreeIndirect::detail::IndexedTriangleSetDistancer< AVertexType, AIndexedFaceType, ATreeType, AVectorType >::vertices

The documentation for this struct was generated from the following file: