Commit 49b55f67 authored by Henri Verbeet's avatar Henri Verbeet Committed by Alexandre Julliard

wined3d: Don't call IWineD3DSurfaceImpl_GetData() from surface_gdi.c.

parent b4f0b5bd
......@@ -680,16 +680,6 @@ void WINAPI IWineD3DSurfaceImpl_GetGlDesc(IWineD3DSurface *iface, glDescriptor *
*glDescription = &This->glDescription;
}
/* TODO: think about moving this down to resource? */
const void *WINAPI IWineD3DSurfaceImpl_GetData(IWineD3DSurface *iface) {
IWineD3DSurfaceImpl *This = (IWineD3DSurfaceImpl *)iface;
/* This should only be called for sysmem textures, it may be a good idea to extend this to all pools at some point in the future */
if (This->resource.pool != WINED3DPOOL_SYSTEMMEM) {
FIXME(" (%p)Attempting to get system memory for a non-system memory texture\n", iface);
}
return (CONST void*)(This->resource.allocatedMemory);
}
/* Read the framebuffer back into the surface */
static void read_from_framebuffer(IWineD3DSurfaceImpl *This, CONST RECT *rect, void *dest, UINT pitch) {
IWineD3DSwapChainImpl *swapchain;
......@@ -4801,7 +4791,7 @@ const IWineD3DSurfaceVtbl IWineD3DSurface_Vtbl =
IWineD3DSurfaceImpl_SaveSnapshot,
IWineD3DSurfaceImpl_SetContainer,
IWineD3DSurfaceImpl_GetGlDesc,
IWineD3DSurfaceImpl_GetData,
IWineD3DBaseSurfaceImpl_GetData,
IWineD3DSurfaceImpl_SetFormat,
IWineD3DSurfaceImpl_PrivateSetup,
IWineD3DSurfaceImpl_ModifyLocation,
......
......@@ -1818,3 +1818,17 @@ void WINAPI IWineD3DBaseSurfaceImpl_BindTexture(IWineD3DSurface *iface) {
ERR("Should not be called on base texture\n");
return;
}
/* TODO: think about moving this down to resource? */
const void *WINAPI IWineD3DBaseSurfaceImpl_GetData(IWineD3DSurface *iface)
{
IWineD3DSurfaceImpl *This = (IWineD3DSurfaceImpl *)iface;
/* This should only be called for sysmem textures, it may be a good idea
* to extend this to all pools at some point in the future */
if (This->resource.pool != WINED3DPOOL_SYSTEMMEM)
{
FIXME("(%p) Attempting to get system memory for a non-system memory texture\n", iface);
}
return This->resource.allocatedMemory;
}
......@@ -679,7 +679,7 @@ const IWineD3DSurfaceVtbl IWineGDISurface_Vtbl =
IWineGDISurfaceImpl_SaveSnapshot,
IWineD3DBaseSurfaceImpl_SetContainer,
IWineGDISurfaceImpl_GetGlDesc,
IWineD3DSurfaceImpl_GetData,
IWineD3DBaseSurfaceImpl_GetData,
IWineD3DBaseSurfaceImpl_SetFormat,
IWineGDISurfaceImpl_PrivateSetup,
IWineGDISurfaceImpl_ModifyLocation,
......
......@@ -1490,8 +1490,7 @@ HRESULT WINAPI IWineD3DBaseSurfaceImpl_BltFast(IWineD3DSurface *iface, DWORD dst
IWineD3DSurface *Source, const RECT *rsrc, DWORD trans);
HRESULT WINAPI IWineD3DBaseSurfaceImpl_LockRect(IWineD3DSurface *iface, WINED3DLOCKED_RECT* pLockedRect, CONST RECT* pRect, DWORD Flags);
void WINAPI IWineD3DBaseSurfaceImpl_BindTexture(IWineD3DSurface *iface);
const void *WINAPI IWineD3DSurfaceImpl_GetData(IWineD3DSurface *iface);
const void *WINAPI IWineD3DBaseSurfaceImpl_GetData(IWineD3DSurface *iface);
void get_drawable_size_swapchain(IWineD3DSurfaceImpl *This, UINT *width, UINT *height);
void get_drawable_size_backbuffer(IWineD3DSurfaceImpl *This, UINT *width, UINT *height);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment