Handling texture and buffer implementation for OpenGL