refactor step 5 - vertexbuffering