[PATCH 2/7] d3dx9: Add IUnknown method calls to ID3DXMesh.

Misha Koshelev misha680 at gmail.com
Wed Jun 23 22:18:34 CDT 2010


---
 include/d3dx9mesh.h |   12 ++++++++++++
 1 files changed, 12 insertions(+), 0 deletions(-)

diff --git a/include/d3dx9mesh.h b/include/d3dx9mesh.h
index 5773d24..7e07561 100644
--- a/include/d3dx9mesh.h
+++ b/include/d3dx9mesh.h
@@ -120,6 +120,18 @@ DECLARE_INTERFACE_(ID3DXMesh, ID3DXBaseMesh)
     STDMETHOD(SetAttributeTable)(THIS_ CONST D3DXATTRIBUTERANGE* attrib_table, DWORD attrib_table_size) PURE;
 };
 
+#if !defined(__cplusplus) || defined(CINTERFACE)
+/*** IUnknown methods ***/
+#define ID3DXMesh_QueryInterface(p,a,b)    (p)->lpVtbl->QueryInterface(p,a,b)
+#define ID3DXMesh_AddRef(p)                (p)->lpVtbl->AddRef(p)
+#define ID3DXMesh_Release(p)               (p)->lpVtbl->Release(p)
+#else
+/*** IUnknown methods ***/
+#define ID3DXMesh_QueryInterface(p,a,b)    (p)->QueryInterface(a,b)
+#define ID3DXMesh_AddRef(p)                (p)->AddRef()
+#define ID3DXMesh_Release(p)               (p)->Release()
+#endif
+
 #ifdef __cplusplus
 extern "C" {
 #endif
-- 
1.7.1







More information about the wine-patches mailing list