tweaked gl matrix for space (removes some speed optimizations, but gains 0.5k)