|
morton-arithmetic 0.1.0
Fast Morton (Z-order) codes with O(1) arithmetic
|
Minimal fixed-width unsigned integer backing Morton codes wider than 128 bits. More...
#include <array>#include <cstddef>#include <cstdint>#include <type_traits>#include "morton/hd.hpp"

Go to the source code of this file.
Classes | |
| struct | morton::detail::wide_uint< W > |
| Fixed-width unsigned integer of. More... | |
Namespaces | |
| namespace | morton |
| namespace | morton::detail |
Minimal fixed-width unsigned integer backing Morton codes wider than 128 bits.
detail::wide_uint<W> is W 64-bit words (little-endian) providing exactly the operators Morton<Dim,Bits> uses: + - & | ^ ~ << >> and comparisons. This lets the same Morton implementation work for codes wider than 128 bits, where no built-in integer exists. It is intentionally small and constexpr; it is not a general bignum and should not be tuned for speed unless it becomes a hot path.
SPDX-License-Identifier: MIT