39 #ifndef HPP_FCL_MORTON_H
40 #define HPP_FCL_MORTON_H
53 uint32_t quantize(S x, uint32_t n);
57 uint32_t morton_code(uint32_t x, uint32_t y, uint32_t z);
61 uint64_t morton_code60(uint32_t x, uint32_t y, uint32_t z);
67 template <
typename S,
typename T>
68 struct morton_functor {};
72 struct morton_functor<S, uint32_t> {
73 morton_functor(
const AABB& bbox);
75 uint32_t operator()(
const Vec3f& point)
const;
80 static constexpr
size_t bits();
83 using morton_functoru32f = morton_functor<float, uint32_t>;
84 using morton_functoru32d = morton_functor<FCL_REAL, uint32_t>;
88 struct morton_functor<S, uint64_t> {
89 morton_functor(
const AABB& bbox);
91 uint64_t operator()(
const Vec3f& point)
const;
96 static constexpr
size_t bits();
101 template <
typename S,
size_t N>
102 struct morton_functor<S, std::bitset<N>> {
103 static_assert(N % 3 == 0,
"Number of bits must be a multiple of 3");
105 morton_functor(
const AABB& bbox);
107 std::bitset<N> operator()(
const Vec3f& point)
const;
112 static constexpr
size_t bits();
#define HPP_FCL_DLLAPI
Definition: config.hh:88
Eigen::Matrix< FCL_REAL, 3, 1 > Vec3f
Definition: data_types.h:67
Main namespace.
Definition: broadphase_bruteforce.h:44