14#include "libmesh/bounding_box.h"
64 std::vector<std::unique_ptr<SurfaceElement>>
_elements;
A group of surface elements wrapped for point-containment / distance queries.
const libMesh::BoundingBox & boundingBox() const
Global AABB of the group (plain union of element loose bounding boxes).
void addElement(const Elem *elem)
Validate, wrap, and append a single element, growing centroids and the AABB.
std::vector< std::unique_ptr< SurfaceElement > > _elements
std::size_t size() const
Number of surface elements in the group.
static SurfaceElementSet fromElements(const std::vector< const Elem * > &elems)
Build a set from a caller-provided subset of surface elements.
static SurfaceElementSet fromMesh(const MeshBase &mesh)
Build a set from every active element of a surface mesh.
libMesh::BoundingBox _bounding_box
const std::vector< Point > & centroids() const
Per-element centroids (vertex averages), aligned index-for-index with elements().
const std::vector< std::unique_ptr< SurfaceElement > > & elements() const
Owned surface-element wrappers, one per input element (input order preserved).
std::vector< Point > _centroids
SurfaceElementSet()=default
Built only through the factories.