Populates a three.js BufferGeometry from a ndarray.