Stefan Dösinger : ddraw: Store a WineD3DBaseTexture instead of a WineD3DTexture.
Module: wine Branch: master Commit: 7ca369d9b6aefa53bfb611cdcd5d18327ac4ad2f URL: http://source.winehq.org/git/wine.git/?a=commit;h=7ca369d9b6aefa53bfb611cdcd... Author: Stefan Dösinger <stefan(a)codeweavers.com> Date: Tue Apr 24 02:04:11 2007 +0200 ddraw: Store a WineD3DBaseTexture instead of a WineD3DTexture. --- dlls/ddraw/ddraw.c | 2 +- dlls/ddraw/ddraw_private.h | 2 +- dlls/ddraw/device.c | 4 ++-- dlls/ddraw/surface.c | 8 ++++---- 4 files changed, 8 insertions(+), 8 deletions(-) diff --git a/dlls/ddraw/ddraw.c b/dlls/ddraw/ddraw.c index 17adb27..9f641e1 100644 --- a/dlls/ddraw/ddraw.c +++ b/dlls/ddraw/ddraw.c @@ -2406,7 +2406,7 @@ IDirectDrawImpl_CreateSurface(IDirectDraw7 *iface, 0, /* usage */ Format, Pool, - &object->wineD3DTexture, + (IWineD3DTexture **) &object->wineD3DTexture, 0, /* SharedHandle */ (IUnknown *) ICOM_INTERFACE(object, IDirectDrawSurface7), D3D7CB_CreateSurface ); diff --git a/dlls/ddraw/ddraw_private.h b/dlls/ddraw/ddraw_private.h index 85e15bc..b2fc8b3 100644 --- a/dlls/ddraw/ddraw_private.h +++ b/dlls/ddraw/ddraw_private.h @@ -227,7 +227,7 @@ struct IDirectDrawSurfaceImpl /* Connections to other Objects */ IDirectDrawImpl *ddraw; IWineD3DSurface *WineD3DSurface; - IWineD3DTexture *wineD3DTexture; + IWineD3DBaseTexture *wineD3DTexture; /* This implementation handles attaching surfaces to other surfaces */ IDirectDrawSurfaceImpl *next_attached; diff --git a/dlls/ddraw/device.c b/dlls/ddraw/device.c index d26c39d..61be064 100644 --- a/dlls/ddraw/device.c +++ b/dlls/ddraw/device.c @@ -2295,7 +2295,7 @@ IDirect3DDeviceImpl_7_SetRenderState(IDirect3DDevice7 *iface, IDirectDrawSurfaceImpl *surf = (IDirectDrawSurfaceImpl *) This->Handles[Value - 1].ptr; return IWineD3DDevice_SetTexture(This->wineD3DDevice, 0, - (IWineD3DBaseTexture *) surf->wineD3DTexture); + surf->wineD3DTexture); } } @@ -3946,7 +3946,7 @@ IDirect3DDeviceImpl_7_SetTexture(IDirect3DDevice7 *iface, /* Texture may be NULL here */ return IWineD3DDevice_SetTexture(This->wineD3DDevice, Stage, - surf ? (IWineD3DBaseTexture * ) surf->wineD3DTexture : NULL); + surf ? surf->wineD3DTexture : NULL); } static HRESULT WINAPI diff --git a/dlls/ddraw/surface.c b/dlls/ddraw/surface.c index ea09f85..96aec40 100644 --- a/dlls/ddraw/surface.c +++ b/dlls/ddraw/surface.c @@ -301,7 +301,7 @@ IDirectDrawSurfaceImpl_Release(IDirectDrawSurface7 *iface) */ if(This->wineD3DTexture) { - IWineD3DTexture_Release(This->wineD3DTexture); + IWineD3DBaseTexture_Release(This->wineD3DTexture); } /* If it's the RenderTarget, destroy the d3ddevice */ else if( (ddraw->d3d_initialized) && (This == ddraw->d3d_target)) @@ -1815,8 +1815,8 @@ IDirectDrawSurfaceImpl_SetLOD(IDirectDrawSurface7 *iface, return DDERR_INVALIDOBJECT; } - return IWineD3DTexture_SetLOD(This->wineD3DTexture, - MaxLOD); + return IWineD3DBaseTexture_SetLOD(This->wineD3DTexture, + MaxLOD); } /***************************************************************************** @@ -1846,7 +1846,7 @@ IDirectDrawSurfaceImpl_GetLOD(IDirectDrawSurface7 *iface, if (!(This->surface_desc.ddsCaps.dwCaps2 & DDSCAPS2_TEXTUREMANAGE)) return DDERR_INVALIDOBJECT; - *MaxLOD = IWineD3DTexture_GetLOD(This->wineD3DTexture); + *MaxLOD = IWineD3DBaseTexture_GetLOD(This->wineD3DTexture); return DD_OK; }
participants (1)
-
Alexandre Julliard