Skip to content

Instantly share code, notes, and snippets.

@vicapow
Created November 28, 2015 21:27
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save vicapow/de57cac76ace278e31bb to your computer and use it in GitHub Desktop.
Save vicapow/de57cac76ace278e31bb to your computer and use it in GitHub Desktop.
split a double into two floats, hi and low
function splitDouble(value) {
var hi = Float32Array.from([value])[0];
var low = value - hi;
return [hi, low];
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment