升级过程中遇到两个问题要注意一下,
m_pD3DD->CopyRects(pSourceSurface,pSourceRectsArray,cRects,pDestinationSurface,pDestPointsArray)
改为
for (int i = 0; i < cRects; ++i)
{
hr = m_pD3DD->UpdateSurface(pSourceSurface, pSourceRectsArray+i, pDestinationSurface, pDestPointsArray+i);
}
其次,SetIndices的第二个参数放到DrawIndexedPrimitive的第二个参数。