encodeTriangle

fun encodeTriangle(bytes: ByteArray, aY: Int, aX: Int, ab: Boolean, bY: Int, bX: Int, bc: Boolean, cY: Int, cX: Int, ca: Boolean)

A triangle is encoded using 6 points and an extra point with encoded information in three bits of how to reconstruct it. Triangles are encoded with CCW orientation and might be rotated to limit the number of possible reconstructions to 2^3. Reconstruction always happens from west to east.