Assume we start with an axis aligned cube at known origin/corner Origin with known dimension Dim.
This cube is divided into 8 equally big cubes with length Dim/2 and corners
Origin, Origin + (0,0,dim/2), origin +(0,dim/2,0)...
Until we hit all 8 corners (the origins of the subcubes)
Given the corners for one of these cubes, we wish to mapp them such that each maps to an index from 0 to 7 without collisions.
How cna this be achieved?