11#ifndef EBGEOMETRY_TRIANGLE_HPP
12#define EBGEOMETRY_TRIANGLE_HPP
46template <
class T,
class Meta>
49 static_assert(std::is_floating_point_v<T>,
"T must be a floating-point type");
234#include "EBGeometry_TriangleImplem.hpp"
Declaration of 2D and 3D point/vector classes with templated precision. Used with DCEL tools.
Triangle class with signed distance functionality.
Definition EBGeometry_Triangle.hpp:48
const std::array< Vec3, 3 > & getVertexNormals() const noexcept
Get the vertex normals.
void setNormal(const Vec3 &a_normal) noexcept
Set the triangle normal vector.
const std::array< Vec3, 3 > & getVertexPositions() const noexcept
Get the vertex positions.
std::array< Vec3, 3 > m_edgeNormals
Triangle edge normals.
Definition EBGeometry_Triangle.hpp:225
const std::array< Vec3, 3 > & getEdgeNormals() const noexcept
Get the edge normals.
std::array< Vec3, 3 > m_vertexNormals
Triangle vertex normals.
Definition EBGeometry_Triangle.hpp:220
const Meta & getMetaData() const noexcept
Get the triangle meta-data.
Vec3 m_triangleNormal
Triangle face normal.
Definition EBGeometry_Triangle.hpp:210
void setEdgeNormals(const std::array< Vec3, 3 > &a_edgeNormals) noexcept
Set the triangle edge normals.
void computeNormal() noexcept
Compute the triangle normal vector.
void setMetaData(const Meta &a_metaData) noexcept
Set the triangle meta-data.
Meta m_metaData
Triangle meta-data normals.
Definition EBGeometry_Triangle.hpp:230
std::array< Vec3, 3 > m_vertexPositions
Triangle vertex positions.
Definition EBGeometry_Triangle.hpp:215
void setVertexNormals(const std::array< Vec3, 3 > &a_vertexNormals) noexcept
Set the triangle vertex normals.
const Vec3 & getNormal() const noexcept
Get the triangle normal vector.
T signedDistance(const Vec3 &a_point) const noexcept
Compute the signed distance from the input point x to the triangle.
Triangle() noexcept=default
Default constructor. Does not put the triangle in a usable state.
void setVertexPositions(const std::array< Vec3, 3 > &a_vertexPositions) noexcept
Set the triangle vertex positions.
Three-dimensional vector class with arithmetic operators.
Definition EBGeometry_Vec.hpp:225
static constexpr Vec3T< T > max() noexcept
Return the most-positive representable vector.
Namespace containing all of EBGeometry's functionality.
Definition EBGeometry_AnalyticDistanceFunctions.hpp:31
Vec2T< T > max(const Vec2T< T > &u, const Vec2T< T > &v) noexcept
Component-wise maximum of two vectors.