[PATCH 6/7] wined3d: remove wined3d_volume_get_resource

Riccardo Bortolato rikyz619 at gmail.com
Mon Sep 14 06:14:03 CDT 2015


---
 dlls/d3d8/volume.c        | 2 +-
 dlls/d3d9/volume.c        | 2 +-
 dlls/wined3d/volume.c     | 7 -------
 dlls/wined3d/wined3d.spec | 2 --
 include/wine/wined3d.h    | 2 --
 5 files changed, 2 insertions(+), 13 deletions(-)

diff --git a/dlls/d3d8/volume.c b/dlls/d3d8/volume.c
index e43e355..f94c685 100644
--- a/dlls/d3d8/volume.c
+++ b/dlls/d3d8/volume.c
@@ -121,7 +121,7 @@ static HRESULT WINAPI d3d8_volume_GetDesc(IDirect3DVolume8 *iface, D3DVOLUME_DES
     TRACE("iface %p, desc %p.\n", iface, desc);
 
     wined3d_mutex_lock();
-    wined3d_resource = wined3d_volume_get_resource(volume->wined3d_volume);
+    wined3d_resource = wined3d_texture_get_sub_resource(volume->wined3d_texture, volume->sub_resource_idx);
     wined3d_resource_get_desc(wined3d_resource, &wined3d_desc);
     wined3d_mutex_unlock();
 
diff --git a/dlls/d3d9/volume.c b/dlls/d3d9/volume.c
index 45e192b..65fe060 100644
--- a/dlls/d3d9/volume.c
+++ b/dlls/d3d9/volume.c
@@ -122,7 +122,7 @@ static HRESULT WINAPI d3d9_volume_GetDesc(IDirect3DVolume9 *iface, D3DVOLUME_DES
     TRACE("iface %p, desc %p.\n", iface, desc);
 
     wined3d_mutex_lock();
-    wined3d_resource = wined3d_volume_get_resource(volume->wined3d_volume);
+    wined3d_resource = wined3d_texture_get_sub_resource(volume->wined3d_texture, volume->sub_resource_idx);
     wined3d_resource_get_desc(wined3d_resource, &wined3d_desc);
     wined3d_mutex_unlock();
 
diff --git a/dlls/wined3d/volume.c b/dlls/wined3d/volume.c
index 8ca6ca7..ee0ad45 100644
--- a/dlls/wined3d/volume.c
+++ b/dlls/wined3d/volume.c
@@ -474,13 +474,6 @@ static ULONG CDECL wined3d_volume_decref(struct wined3d_volume *volume)
     return wined3d_texture_decref(volume->container);
 }
 
-struct wined3d_resource * CDECL wined3d_volume_get_resource(struct wined3d_volume *volume)
-{
-    TRACE("volume %p.\n", volume);
-
-    return &volume->resource;
-}
-
 static BOOL volume_check_block_align(const struct wined3d_volume *volume,
         const struct wined3d_box *box)
 {
diff --git a/dlls/wined3d/wined3d.spec b/dlls/wined3d/wined3d.spec
index c8f8944..da2f80e 100644
--- a/dlls/wined3d/wined3d.spec
+++ b/dlls/wined3d/wined3d.spec
@@ -280,5 +280,3 @@
 @ cdecl wined3d_vertex_declaration_decref(ptr)
 @ cdecl wined3d_vertex_declaration_get_parent(ptr)
 @ cdecl wined3d_vertex_declaration_incref(ptr)
-
-@ cdecl wined3d_volume_get_resource(ptr)
diff --git a/include/wine/wined3d.h b/include/wine/wined3d.h
index 97a3035..ca8a34d 100644
--- a/include/wine/wined3d.h
+++ b/include/wine/wined3d.h
@@ -2566,8 +2566,6 @@ ULONG __cdecl wined3d_vertex_declaration_decref(struct wined3d_vertex_declaratio
 void * __cdecl wined3d_vertex_declaration_get_parent(const struct wined3d_vertex_declaration *declaration);
 ULONG __cdecl wined3d_vertex_declaration_incref(struct wined3d_vertex_declaration *declaration);
 
-struct wined3d_resource * __cdecl wined3d_volume_get_resource(struct wined3d_volume *volume);
-
 /* Return the integer base-2 logarithm of x. Undefined for x == 0. */
 static inline unsigned int wined3d_log2i(unsigned int x)
 {
-- 
1.9.1




More information about the wine-patches mailing list