XYEncodingUtils

reusable cartesian geometry encoding methods

Properties

Link copied to clipboard
const val MAX_VAL_INCL: Double
Link copied to clipboard
const val MIN_VAL_INCL: Double

Functions

Link copied to clipboard

validates value is a number and finite

Link copied to clipboard
fun decode(encoded: Int): Float

Turns quantized value from .encode back into a double.

fun decode(src: ByteArray, offset: Int): Float

Turns quantized value from byte array back into a double.

Link copied to clipboard
fun encode(x: Float): Int

Quantizes double (64 bit) values into 32 bits

Link copied to clipboard

Convert an array of float numbers to double numbers.