wined3d: Pass an IWineD3DResourceImpl pointer to resource_get_type().

This commit is contained in:
Henri Verbeet 2011-01-07 10:16:41 +01:00 committed by Alexandre Julliard
parent 7e67bcedfd
commit c117248bd1
8 changed files with 20 additions and 17 deletions

View File

@ -1190,7 +1190,7 @@ end:
static WINED3DRESOURCETYPE STDMETHODCALLTYPE buffer_GetType(IWineD3DBuffer *iface) static WINED3DRESOURCETYPE STDMETHODCALLTYPE buffer_GetType(IWineD3DBuffer *iface)
{ {
return resource_get_type((IWineD3DResource *)iface); return resource_get_type((IWineD3DResourceImpl *)iface);
} }
/* IWineD3DBuffer methods */ /* IWineD3DBuffer methods */

View File

@ -270,8 +270,9 @@ static void WINAPI IWineD3DCubeTextureImpl_UnLoad(IWineD3DCubeTexture *iface)
basetexture_unload((IWineD3DBaseTextureImpl *)This); basetexture_unload((IWineD3DBaseTextureImpl *)This);
} }
static WINED3DRESOURCETYPE WINAPI IWineD3DCubeTextureImpl_GetType(IWineD3DCubeTexture *iface) { static WINED3DRESOURCETYPE WINAPI IWineD3DCubeTextureImpl_GetType(IWineD3DCubeTexture *iface)
return resource_get_type((IWineD3DResource *)iface); {
return resource_get_type((IWineD3DResourceImpl *)iface);
} }
static void * WINAPI IWineD3DCubeTextureImpl_GetParent(IWineD3DCubeTexture *iface) static void * WINAPI IWineD3DCubeTextureImpl_GetParent(IWineD3DCubeTexture *iface)

View File

@ -264,9 +264,8 @@ DWORD resource_get_priority(struct IWineD3DResourceImpl *resource)
return resource->resource.priority; return resource->resource.priority;
} }
WINED3DRESOURCETYPE resource_get_type(IWineD3DResource *iface) WINED3DRESOURCETYPE resource_get_type(struct IWineD3DResourceImpl *resource)
{ {
IWineD3DResourceImpl *This = (IWineD3DResourceImpl *)iface; TRACE("resource %p, returning %#x.\n", resource, resource->resource.resourceType);
TRACE("(%p) : returning %d\n", This, This->resource.resourceType); return resource->resource.resourceType;
return This->resource.resourceType;
} }

View File

@ -138,9 +138,9 @@ DWORD WINAPI IWineD3DBaseSurfaceImpl_GetPriority(IWineD3DSurface *iface)
return resource_get_priority((IWineD3DResourceImpl *)iface); return resource_get_priority((IWineD3DResourceImpl *)iface);
} }
WINED3DRESOURCETYPE WINAPI IWineD3DBaseSurfaceImpl_GetType(IWineD3DSurface *iface) { WINED3DRESOURCETYPE WINAPI IWineD3DBaseSurfaceImpl_GetType(IWineD3DSurface *iface)
TRACE("(%p) : calling resourceimpl_GetType\n", iface); {
return resource_get_type((IWineD3DResource *)iface); return resource_get_type((IWineD3DResourceImpl *)iface);
} }
void * WINAPI IWineD3DBaseSurfaceImpl_GetParent(IWineD3DSurface *iface) void * WINAPI IWineD3DBaseSurfaceImpl_GetParent(IWineD3DSurface *iface)

View File

@ -291,8 +291,9 @@ static void WINAPI IWineD3DTextureImpl_UnLoad(IWineD3DTexture *iface) {
basetexture_unload((IWineD3DBaseTextureImpl *)This); basetexture_unload((IWineD3DBaseTextureImpl *)This);
} }
static WINED3DRESOURCETYPE WINAPI IWineD3DTextureImpl_GetType(IWineD3DTexture *iface) { static WINED3DRESOURCETYPE WINAPI IWineD3DTextureImpl_GetType(IWineD3DTexture *iface)
return resource_get_type((IWineD3DResource *)iface); {
return resource_get_type((IWineD3DResourceImpl *)iface);
} }
static void * WINAPI IWineD3DTextureImpl_GetParent(IWineD3DTexture *iface) static void * WINAPI IWineD3DTextureImpl_GetParent(IWineD3DTexture *iface)

View File

@ -193,8 +193,9 @@ static void WINAPI IWineD3DVolumeImpl_UnLoad(IWineD3DVolume *iface)
resource_unload((IWineD3DResourceImpl *)iface); resource_unload((IWineD3DResourceImpl *)iface);
} }
static WINED3DRESOURCETYPE WINAPI IWineD3DVolumeImpl_GetType(IWineD3DVolume *iface) { static WINED3DRESOURCETYPE WINAPI IWineD3DVolumeImpl_GetType(IWineD3DVolume *iface)
return resource_get_type((IWineD3DResource *)iface); {
return resource_get_type((IWineD3DResourceImpl *)iface);
} }
static void WINAPI IWineD3DVolumeImpl_GetDesc(IWineD3DVolume *iface, WINED3DVOLUME_DESC *desc) static void WINAPI IWineD3DVolumeImpl_GetDesc(IWineD3DVolume *iface, WINED3DVOLUME_DESC *desc)

View File

@ -207,8 +207,9 @@ static void WINAPI IWineD3DVolumeTextureImpl_UnLoad(IWineD3DVolumeTexture *iface
basetexture_unload((IWineD3DBaseTextureImpl *)This); basetexture_unload((IWineD3DBaseTextureImpl *)This);
} }
static WINED3DRESOURCETYPE WINAPI IWineD3DVolumeTextureImpl_GetType(IWineD3DVolumeTexture *iface) { static WINED3DRESOURCETYPE WINAPI IWineD3DVolumeTextureImpl_GetType(IWineD3DVolumeTexture *iface)
return resource_get_type((IWineD3DResource *)iface); {
return resource_get_type((IWineD3DResourceImpl *)iface);
} }
static void * WINAPI IWineD3DVolumeTextureImpl_GetParent(IWineD3DVolumeTexture *iface) static void * WINAPI IWineD3DVolumeTextureImpl_GetParent(IWineD3DVolumeTexture *iface)

View File

@ -1836,7 +1836,7 @@ HRESULT resource_get_private_data(struct IWineD3DResourceImpl *resource, REFGUID
HRESULT resource_init(struct IWineD3DResourceImpl *resource, WINED3DRESOURCETYPE resource_type, HRESULT resource_init(struct IWineD3DResourceImpl *resource, WINED3DRESOURCETYPE resource_type,
IWineD3DDeviceImpl *device, UINT size, DWORD usage, const struct wined3d_format *format, IWineD3DDeviceImpl *device, UINT size, DWORD usage, const struct wined3d_format *format,
WINED3DPOOL pool, void *parent, const struct wined3d_parent_ops *parent_ops) DECLSPEC_HIDDEN; WINED3DPOOL pool, void *parent, const struct wined3d_parent_ops *parent_ops) DECLSPEC_HIDDEN;
WINED3DRESOURCETYPE resource_get_type(IWineD3DResource *iface) DECLSPEC_HIDDEN; WINED3DRESOURCETYPE resource_get_type(struct IWineD3DResourceImpl *resource) DECLSPEC_HIDDEN;
DWORD resource_set_priority(struct IWineD3DResourceImpl *resource, DWORD priority) DECLSPEC_HIDDEN; DWORD resource_set_priority(struct IWineD3DResourceImpl *resource, DWORD priority) DECLSPEC_HIDDEN;
HRESULT resource_set_private_data(struct IWineD3DResourceImpl *resource, REFGUID guid, HRESULT resource_set_private_data(struct IWineD3DResourceImpl *resource, REFGUID guid,
const void *data, DWORD data_size, DWORD flags) DECLSPEC_HIDDEN; const void *data, DWORD data_size, DWORD flags) DECLSPEC_HIDDEN;