我在以下代码的标题中得到错误:
std::vector<short> GetIndicesFromID3DXMesh(ID3DXMesh* model)
{
//LPVOID * ppData;
DWORD stride = sizeof(short);
BYTE* ibptr = NULL;
short* indices = new short[model->GetNumFaces() * 3];
std::vector<short> copy;
model->LockIndexBuffer(0, (LPVOID*)&indices);
for(size_t i = 0; i < model->GetNumFaces() * 3; i++)
{
copy.push_back(indices[i]);
}
model->UnlockIndexBuffer();
delete []indices;
return copy;
}
在行删除[]索引
我不知道为什么我得到它,我不知道我怎么得到它,我不能得到它吗?