Point on a Hilbert-Peano space filling curve. More...
Public Types | |
| using | point_t |
| Point type to represent coordinates. | |
Public Types inherited from filling_curve_key< DIM, T, hilbert_key< DIM, T > > | |
| using | int_t |
| Integer type used to represent the key. | |
Public Member Functions | |
| point_t | coordinates (const std::array< point_t, 2 > &range) const |
| Convert this key to coordinates in range. | |
| hilbert_key (const std::array< point_t, 2 > &range, const point_t &p, const std::size_t depth=max_depth_) | |
| Create a Hilbert key at a specific depth. | |
Public Member Functions inherited from filling_curve_key< DIM, T, hilbert_key< DIM, T > > | |
| std::size_t | depth () const |
| Find the depth of the current key. | |
| constexpr | filling_curve_key () |
| Default constructor: create an invalid key containing only zeros. | |
| constexpr | filling_curve_key (int_t value) |
| Construct a key from an integer of type int_t. | |
| int_t | last_value () const |
| Return the last bits of the key. | |
| constexpr filling_curve_key | parent () const |
| Return the parent of this key (depth - 1) | |
| int_t | pop () |
| Pop last bits and return its value. | |
| void | pop (std::size_t d) |
| Pop the depth d bits from the end of this key. | |
| constexpr auto | push (int_t bits) const |
| Push bits onto the end of this key. | |
| constexpr int_t | value () const |
| Get the value associated to this key. | |
| constexpr bool | operator<= (const filling_curve_key &bid) const |
| Less than or equal to operator. | |
| constexpr bool | operator>= (const filling_curve_key &bid) const |
| Greater than or equal to operator. | |
| constexpr bool | operator> (const filling_curve_key &bid) const |
| Greater than operator. | |
| constexpr bool | operator< (const filling_curve_key &bid) const |
| Less than operator. | |
| constexpr bool | operator!= (const filling_curve_key &bid) const |
| Inequality operator. | |
Additional Inherited Members | |
Static Public Member Functions inherited from filling_curve_key< DIM, T, hilbert_key< DIM, T > > | |
| static constexpr hilbert_key< DIM, T > | max () |
| Biggest value possible at max_depth. | |
| static constexpr std::size_t | max_depth () |
| Max depth possible for this type of key. | |
| static constexpr hilbert_key< DIM, T > | min () |
| Smallest value possible at max_depth. | |
| static constexpr hilbert_key< DIM, T > | root () |
| Get the root key (depth 0) | |
Protected Member Functions inherited from filling_curve_key< DIM, T, hilbert_key< DIM, T > > | |
Protected Attributes inherited from filling_curve_key< DIM, T, hilbert_key< DIM, T > > | |
| int_t | value_ |
| Value of the filling curve key. | |
Static Protected Attributes inherited from filling_curve_key< DIM, T, hilbert_key< DIM, T > > | |
Point on a Hilbert-Peano space filling curve.
| hilbert_key | ( | const std::array< point_t, 2 > & | range, |
| const point_t & | p, | ||
| const std::size_t | depth = max_depth_ ) |
Create a Hilbert key at a specific depth.
For Hilbert key, they key is generated to the max_depth_ and then truncated
| range | The bounding box of the overall domain |
| p | The point that the key will represent in the range |
| depth | The depth at which to generate the key. |