switched to an array based matrix, based on mattdesl's vecmath. Important for webgl