OpenGL buffer refactoring