Skip to content

Geometries

Bruno Turcksin edited this page Feb 10, 2026 · 2 revisions

ArborX

Geometries

ArborX::GeometryTraits

Defined in header <ArborX_GeometryTraits.hpp>

The struct templates specialized in the ArborX::GeometryTraits namespace provide ArborX information about geometry.

template <typename Geometry>
struct ArborX::GeometryTraits::dimension<Geometry>
{
  static constexpr int value = ...;
};

Specialization of dimension describes geometry's dimension.

template <typename Geometry>
struct ArborX::GeometryTraits::coordinate_type<Geometry>
{
  using type = ...;
};

Specialization of coordinate_type describes the precision of the stored data.

template <typename Geometry>
struct ArborX::GeometryTraits::tag<Geometry>
{
  using type = ...;
};

Specialization of tag describes the type of the geometry.

Note

For a user provided data, dimension and coordinate_type are required specializations. If a tag specialization is provided and is one of the ArborX known tags, the algorithms implemented in ArborX will be used for calculations.

Provided Geometries

Currently, ArborX provides the following geometries:

  • Box (axis-aligned)
  • ellipsoid (EXPERIMENTAL]
  • k-DOP [EXPERIMENTAL]
  • point
  • ray [EXPERIMENTAL]
  • segment [EXPERIMENTAL]
  • sphere
  • tetrahedron [EXPERIMENTAL]
  • triangle

Clone this wiki locally