LSSTApplications
20.0.0
LSSTDataManagementBasePackage
|
Go to the documentation of this file.
22 #include "pybind11/pybind11.h"
27 using namespace pybind11::literals;
34 mod.def(
"log2", (uint8_t(*)(uint64_t)) &
log2);
35 mod.def(
"mortonIndex", (uint64_t(*)(uint32_t, uint32_t)) &
mortonIndex,
37 mod.def(
"mortonIndexInverse",
42 mod.def(
"hilbertIndex",
43 (uint64_t(*)(uint32_t, uint32_t,
int)) &
hilbertIndex,
"x"_a,
"y"_a,
45 mod.def(
"hilbertIndexInverse",
std::tuple< uint32_t, uint32_t > hilbertIndexInverse(uint64_t h, int m)
hilbertIndexInverse returns the point (x, y) with Hilbert index h, where x and y are m bit integers.
uint64_t hilbertIndex(uint32_t x, uint32_t y, int m)
hilbertIndex returns the index of (x, y) in a 2-D Hilbert curve.
std::tuple< uint32_t, uint32_t > mortonIndexInverse(uint64_t z)
mortonIndexInverse separates the even and odd bits of z.
A base class for image defects.
uint64_t mortonToHilbert(uint64_t z, int m)
mortonToHilbert converts the 2m-bit Morton index z to the corresponding Hilbert index.
uint64_t hilbertToMorton(uint64_t h, int m)
hilbertToMorton converts the 2m-bit Hilbert index h to the corresponding Morton index.
This file contains functions for space-filling curves.
uint64_t mortonIndex(uint32_t x, uint32_t y)
mortonIndex interleaves the bits of x and y.
PYBIND11_MODULE(camera, mod)