Rico Schüller : d3d10: Implement ID3D10EffectVariable: :AsConstantBuffer().

Alexandre Julliard julliard at winehq.org
Wed Oct 28 10:12:26 CDT 2009


Module: wine
Branch: master
Commit: b1e56fae0118578836c41a06861f1d6a292bff92
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=b1e56fae0118578836c41a06861f1d6a292bff92

Author: Rico Schüller <kgbricola at web.de>
Date:   Tue Oct 27 20:12:11 2009 +0100

d3d10: Implement ID3D10EffectVariable::AsConstantBuffer().

---

 dlls/d3d10/effect.c |    9 +++++++--
 1 files changed, 7 insertions(+), 2 deletions(-)

diff --git a/dlls/d3d10/effect.c b/dlls/d3d10/effect.c
index 36941da..acb0f23 100644
--- a/dlls/d3d10/effect.c
+++ b/dlls/d3d10/effect.c
@@ -2609,9 +2609,14 @@ static struct ID3D10EffectDepthStencilViewVariable * STDMETHODCALLTYPE d3d10_eff
 static struct ID3D10EffectConstantBuffer * STDMETHODCALLTYPE d3d10_effect_variable_AsConstantBuffer(
         ID3D10EffectVariable *iface)
 {
-    FIXME("iface %p stub!\n", iface);
+    struct d3d10_effect_variable *This = (struct d3d10_effect_variable *)iface;
 
-    return NULL;
+    TRACE("iface %p\n", iface);
+
+    if (This->vtbl == (ID3D10EffectVariableVtbl *)&d3d10_effect_constant_buffer_vtbl)
+        return (ID3D10EffectConstantBuffer *)This;
+
+    return (ID3D10EffectConstantBuffer *)&null_local_buffer;
 }
 
 static struct ID3D10EffectShaderVariable * STDMETHODCALLTYPE d3d10_effect_variable_AsShader(




More information about the wine-cvs mailing list