我尝试在C++中填充两个缓冲区,一个索引缓冲区对象和一个顶点缓冲区对象。
// Create the IBO and VBO data
GLushort* iboData = new GLushort[polyProcessed * 3];
Vertex* vboData = new Vertex[vertProcessed];
int iboPos = 0;
int vboPos = 0;
// Create the VBO and IBO
for(int i = 0; i < fragMap[0x36]; i++)
{
// Copy the data to the IB