Module: wine Branch: master Commit: 77e6dcca02080c065fa1d68d2cf6077b882e0cf7 URL: http://source.winehq.org/git/wine.git/?a=commit;h=77e6dcca02080c065fa1d68d2c...
Author: Stefan Dösinger stefan@codeweavers.com Date: Thu Apr 9 10:48:42 2009 +0200
d3d9: Store the FVF in the d3d9 vertex buffer.
---
dlls/d3d9/d3d9_private.h | 2 ++ dlls/d3d9/vertexbuffer.c | 3 ++- 2 files changed, 4 insertions(+), 1 deletions(-)
diff --git a/dlls/d3d9/d3d9_private.h b/dlls/d3d9/d3d9_private.h index 8436b1d..9338f97 100644 --- a/dlls/d3d9/d3d9_private.h +++ b/dlls/d3d9/d3d9_private.h @@ -329,6 +329,8 @@ typedef struct IDirect3DVertexBuffer9Impl
/* Parent reference */ LPDIRECT3DDEVICE9EX parentDevice; + + DWORD fvf; } IDirect3DVertexBuffer9Impl;
/* --------------------- */ diff --git a/dlls/d3d9/vertexbuffer.c b/dlls/d3d9/vertexbuffer.c index 63cac92..d13ebef 100644 --- a/dlls/d3d9/vertexbuffer.c +++ b/dlls/d3d9/vertexbuffer.c @@ -197,8 +197,8 @@ static HRESULT WINAPI IDirect3DVertexBuffer9Impl_GetDesc(LPDIRECT3DVERTEXBUFFER9 pDesc->Usage = desc.Usage; pDesc->Pool = desc.Pool; pDesc->Size = desc.Size; - pDesc->FVF = desc.FVF; pDesc->Type = D3DRTYPE_VERTEXBUFFER; + pDesc->FVF = This->fvf; }
@@ -245,6 +245,7 @@ HRESULT WINAPI IDirect3DDevice9Impl_CreateVertexBuffer(LPDIRECT3DDEVICE9EX iface
object->lpVtbl = &Direct3DVertexBuffer9_Vtbl; object->ref = 1; + object->fvf = FVF; EnterCriticalSection(&d3d9_cs); hrc = IWineD3DDevice_CreateVertexBuffer(This->WineD3DDevice, Size, Usage & WINED3DUSAGE_MASK, FVF, (WINED3DPOOL) Pool, &(object->wineD3DVertexBuffer), pSharedHandle, (IUnknown *)object); LeaveCriticalSection(&d3d9_cs);