updated convertToSeparateBuffers to ensure the subgeometry array is
correctly stepped through. Fixes #491