Module coords_internal

Source
Expand description

S2 Coordinates internal methods

Constants§

K_FACE_UVW_AXES
The precomputed neighbors of each face (see GetUVWFace).
K_FACE_UVW_FACES
The U,V,W axes for each face.
K_IJTO_POS
kIJtoPos[orientation][ij] -> pos
K_INVERT_MASK
‘kInvertMask’ is true, then the traversal order is rotated by 180 degrees (i.e. the bits of i and j are inverted, or equivalently, the axis directions are reversed).
K_POS_TO_IJ
kPosToIJ[orientation][pos] -> ij
K_POS_TO_ORIENTATION
kPosToOrientation[pos] -> orientation_modifier
K_SWAP_MASK
Together these flags define a cell orientation. If ‘kSwapMask’ is true, then canonical traversal order is flipped around the diagonal (i.e. i and j are swapped with each other). If
LOOKUP_IJ
[1 << (2 * kLookupBits + 2)]u16;
LOOKUP_POS
[1 << (2 * kLookupBits + 2)]u16;