wined3d: Pass an IWineD3DDeviceImpl pointer to alloc_private().

This commit is contained in:
Henri Verbeet 2010-12-08 18:28:10 +01:00 committed by Alexandre Julliard
parent a3b2407824
commit 4ba3b64c57
4 changed files with 7 additions and 7 deletions

View File

@ -6503,8 +6503,8 @@ struct arbfp_blit_priv {
GLuint palette_texture; GLuint palette_texture;
}; };
static HRESULT arbfp_blit_alloc(IWineD3DDevice *iface) { static HRESULT arbfp_blit_alloc(IWineD3DDeviceImpl *device)
IWineD3DDeviceImpl *device = (IWineD3DDeviceImpl *) iface; {
device->blit_priv = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(struct arbfp_blit_priv)); device->blit_priv = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(struct arbfp_blit_priv));
if(!device->blit_priv) { if(!device->blit_priv) {
ERR("Out of memory\n"); ERR("Out of memory\n");

View File

@ -1973,7 +1973,7 @@ static HRESULT WINAPI IWineD3DDeviceImpl_Init3D(IWineD3DDevice *iface,
TRACE("Fragment pipeline private data couldn't be allocated\n"); TRACE("Fragment pipeline private data couldn't be allocated\n");
goto err_out; goto err_out;
} }
hr = This->blitter->alloc_private(iface); hr = This->blitter->alloc_private(This);
if(FAILED(hr)) { if(FAILED(hr)) {
TRACE("Blitter private data couldn't be allocated\n"); TRACE("Blitter private data couldn't be allocated\n");
goto err_out; goto err_out;
@ -6259,7 +6259,7 @@ static HRESULT create_primary_opengl_context(IWineD3DDevice *iface, IWineD3DSwap
goto err; goto err;
} }
hr = This->blitter->alloc_private(iface); hr = This->blitter->alloc_private(This);
if (FAILED(hr)) if (FAILED(hr))
{ {
ERR("Failed to allocate blitter private data, hr %#x.\n", hr); ERR("Failed to allocate blitter private data, hr %#x.\n", hr);

View File

@ -4732,7 +4732,7 @@ const IWineD3DSurfaceVtbl IWineD3DSurface_Vtbl =
IWineD3DSurfaceImpl_DrawOverlay IWineD3DSurfaceImpl_DrawOverlay
}; };
static HRESULT ffp_blit_alloc(IWineD3DDevice *iface) { return WINED3D_OK; } static HRESULT ffp_blit_alloc(IWineD3DDeviceImpl *device) { return WINED3D_OK; }
/* Context activation is done by the caller. */ /* Context activation is done by the caller. */
static void ffp_blit_free(IWineD3DDevice *iface) { } static void ffp_blit_free(IWineD3DDevice *iface) { }
@ -4865,7 +4865,7 @@ const struct blit_shader ffp_blit = {
ffp_blit_color_fill ffp_blit_color_fill
}; };
static HRESULT cpu_blit_alloc(IWineD3DDevice *iface) static HRESULT cpu_blit_alloc(IWineD3DDeviceImpl *device)
{ {
return WINED3D_OK; return WINED3D_OK;
} }

View File

@ -1175,7 +1175,7 @@ enum blit_operation
* already under the GL lock. */ * already under the GL lock. */
struct blit_shader struct blit_shader
{ {
HRESULT (*alloc_private)(IWineD3DDevice *iface); HRESULT (*alloc_private)(IWineD3DDeviceImpl *device);
void (*free_private)(IWineD3DDevice *iface); void (*free_private)(IWineD3DDevice *iface);
HRESULT (*set_shader)(IWineD3DDevice *iface, IWineD3DSurfaceImpl *surface); HRESULT (*set_shader)(IWineD3DDevice *iface, IWineD3DSurfaceImpl *surface);
void (*unset_shader)(IWineD3DDevice *iface); void (*unset_shader)(IWineD3DDevice *iface);