d3dx9: Use 0 instead of D3DLOCK_DISCARD in D3DXCreateSphere.

This commit is contained in:
Michael Mc Donnell 2011-08-19 19:03:52 +02:00 committed by Alexandre Julliard
parent 1150c1558e
commit d6a7c2cce0
1 changed files with 2 additions and 2 deletions

View File

@ -4060,14 +4060,14 @@ HRESULT WINAPI D3DXCreateSphere(LPDIRECT3DDEVICE9 device, FLOAT radius, UINT sli
return hr; return hr;
} }
hr = sphere->lpVtbl->LockVertexBuffer(sphere, D3DLOCK_DISCARD, (LPVOID *)&vertices); hr = sphere->lpVtbl->LockVertexBuffer(sphere, 0, (LPVOID *)&vertices);
if (FAILED(hr)) if (FAILED(hr))
{ {
sphere->lpVtbl->Release(sphere); sphere->lpVtbl->Release(sphere);
return hr; return hr;
} }
hr = sphere->lpVtbl->LockIndexBuffer(sphere, D3DLOCK_DISCARD, (LPVOID *)&faces); hr = sphere->lpVtbl->LockIndexBuffer(sphere, 0, (LPVOID *)&faces);
if (FAILED(hr)) if (FAILED(hr))
{ {
sphere->lpVtbl->UnlockVertexBuffer(sphere); sphere->lpVtbl->UnlockVertexBuffer(sphere);