Commit 5f73f41f authored by Henri Verbeet's avatar Henri Verbeet Committed by Alexandre Julliard

wined3d: Get rid of IWineD3DVolume::GetDesc().

parent 2b18192e
...@@ -190,11 +190,13 @@ static HRESULT WINAPI IDirect3DVolume8Impl_GetDesc(IDirect3DVolume8 *iface, D3DV ...@@ -190,11 +190,13 @@ static HRESULT WINAPI IDirect3DVolume8Impl_GetDesc(IDirect3DVolume8 *iface, D3DV
{ {
IDirect3DVolume8Impl *This = impl_from_IDirect3DVolume8(iface); IDirect3DVolume8Impl *This = impl_from_IDirect3DVolume8(iface);
struct wined3d_resource_desc wined3d_desc; struct wined3d_resource_desc wined3d_desc;
struct wined3d_resource *wined3d_resource;
TRACE("iface %p, desc %p.\n", iface, desc); TRACE("iface %p, desc %p.\n", iface, desc);
wined3d_mutex_lock(); wined3d_mutex_lock();
IWineD3DVolume_GetDesc(This->wineD3DVolume, &wined3d_desc); wined3d_resource = IWineD3DVolume_GetResource(This->wineD3DVolume);
wined3d_resource_get_desc(wined3d_resource, &wined3d_desc);
wined3d_mutex_unlock(); wined3d_mutex_unlock();
desc->Format = d3dformat_from_wined3dformat(wined3d_desc.format); desc->Format = d3dformat_from_wined3dformat(wined3d_desc.format);
......
...@@ -180,13 +180,13 @@ static HRESULT WINAPI IDirect3DVolume9Impl_GetDesc(IDirect3DVolume9 *iface, D3DV ...@@ -180,13 +180,13 @@ static HRESULT WINAPI IDirect3DVolume9Impl_GetDesc(IDirect3DVolume9 *iface, D3DV
{ {
IDirect3DVolume9Impl *This = (IDirect3DVolume9Impl *)iface; IDirect3DVolume9Impl *This = (IDirect3DVolume9Impl *)iface;
struct wined3d_resource_desc wined3d_desc; struct wined3d_resource_desc wined3d_desc;
struct wined3d_resource *wined3d_resource;
TRACE("iface %p, desc %p.\n", iface, desc); TRACE("iface %p, desc %p.\n", iface, desc);
wined3d_mutex_lock(); wined3d_mutex_lock();
wined3d_resource = IWineD3DVolume_GetResource(This->wineD3DVolume);
IWineD3DVolume_GetDesc(This->wineD3DVolume, &wined3d_desc); wined3d_resource_get_desc(wined3d_resource, &wined3d_desc);
wined3d_mutex_unlock(); wined3d_mutex_unlock();
desc->Format = d3dformat_from_wined3dformat(wined3d_desc.format); desc->Format = d3dformat_from_wined3dformat(wined3d_desc.format);
......
...@@ -220,13 +220,11 @@ static WINED3DRESOURCETYPE WINAPI IWineD3DVolumeImpl_GetType(IWineD3DVolume *ifa ...@@ -220,13 +220,11 @@ static WINED3DRESOURCETYPE WINAPI IWineD3DVolumeImpl_GetType(IWineD3DVolume *ifa
return resource_get_type(&((IWineD3DVolumeImpl *)iface)->resource); return resource_get_type(&((IWineD3DVolumeImpl *)iface)->resource);
} }
static void WINAPI IWineD3DVolumeImpl_GetDesc(IWineD3DVolume *iface, struct wined3d_resource_desc *desc) struct wined3d_resource * WINAPI IWineD3DVolumeImpl_GetResource(IWineD3DVolume *iface)
{ {
IWineD3DVolumeImpl *volume = (IWineD3DVolumeImpl *)iface; TRACE("iface %p.\n", iface);
TRACE("iface %p, desc %p.\n", iface, desc);
wined3d_resource_get_desc(&volume->resource, desc); return &((IWineD3DVolumeImpl *)iface)->resource;
} }
static HRESULT WINAPI IWineD3DVolumeImpl_Map(IWineD3DVolume *iface, static HRESULT WINAPI IWineD3DVolumeImpl_Map(IWineD3DVolume *iface,
...@@ -309,7 +307,7 @@ static const IWineD3DVolumeVtbl IWineD3DVolume_Vtbl = ...@@ -309,7 +307,7 @@ static const IWineD3DVolumeVtbl IWineD3DVolume_Vtbl =
IWineD3DVolumeImpl_PreLoad, IWineD3DVolumeImpl_PreLoad,
IWineD3DVolumeImpl_GetType, IWineD3DVolumeImpl_GetType,
/* IWineD3DVolume */ /* IWineD3DVolume */
IWineD3DVolumeImpl_GetDesc, IWineD3DVolumeImpl_GetResource,
IWineD3DVolumeImpl_Map, IWineD3DVolumeImpl_Map,
IWineD3DVolumeImpl_Unmap, IWineD3DVolumeImpl_Unmap,
}; };
......
...@@ -2324,8 +2324,7 @@ interface IWineD3DSurface : IWineD3DResource ...@@ -2324,8 +2324,7 @@ interface IWineD3DSurface : IWineD3DResource
] ]
interface IWineD3DVolume : IWineD3DResource interface IWineD3DVolume : IWineD3DResource
{ {
void GetDesc( struct wined3d_resource *GetResource(
[out] struct wined3d_resource_desc *desc
); );
HRESULT Map( HRESULT Map(
[out] WINED3DLOCKED_BOX *locked_box, [out] WINED3DLOCKED_BOX *locked_box,
......
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