11#ifndef EBGEOMETRY_TRIANGLEAOSOA_HPP
12#define EBGEOMETRY_TRIANGLEAOSOA_HPP
50template <class T, class Meta, size_t W = TriangleSoA::DefaultWidth<T>()>
53 static_assert(
W > 0,
"W must be positive");
54 static_assert(std::is_floating_point_v<T>,
"TriangleAoSoA requires a floating-point type T");
140#include "EBGeometry_TriangleAoSoAImplem.hpp"
Declaration of SoA triangle group for SIMD signed-distance evaluation.
Declaration of a triangle class with signed distance functionality.
Declaration of 2D and 3D point/vector classes with templated precision. Used with DCEL tools.
Three-dimensional vector class with arithmetic operators.
Definition EBGeometry_Vec.hpp:225
Namespace containing all of EBGeometry's functionality.
Definition EBGeometry_AnalyticDistanceFunctions.hpp:31
Metadata-carrying wrapper around a single TriangleSoAT<T, W>.
Definition EBGeometry_TriangleAoSoA.hpp:52
std::array< Meta, W > m_metaData
Per-lane metadata, physically separate from m_triangles. m_metaData[j] = metadata of triangle j....
Definition EBGeometry_TriangleAoSoA.hpp:125
T signedDistance(const Vec3T< T > &a_point) const noexcept
Evaluate signed distance from a_point to the closest triangle in this group.
void pack(const Triangle< T, Meta > *a_triangles, uint32_t a_count) noexcept
Pack a_count triangles from a_triangles[0..a_count-1] into this group.
const Meta & getMetaData(size_t a_lane) const noexcept
Get the metadata for one lane of this group.
T signedDistance(const Vec3T< T > &a_point, Meta &a_closestMeta) const noexcept
Evaluate signed distance from a_point to the closest triangle and report that triangle's metadata.
BV computeBoundingVolume() const noexcept
Compute the bounding volume enclosing all valid triangles in this group.
TriangleSoAT< T, W > m_triangles
The wrapped, coordinate-only SoA block. SIMD-hot: this is all signedDistance() touches.
Definition EBGeometry_TriangleAoSoA.hpp:119
uint32_t m_validCount
Number of valid (non-padded) triangles in this group (1..W).
Definition EBGeometry_TriangleAoSoA.hpp:135
SoA (Structure of Arrays) layout for W triangles, enabling SIMD evaluation.
Definition EBGeometry_TriangleSoA.hpp:102