Rico Schüller : d3d10: Implement ID3D10EffectVariable: :GetDesc().
Alexandre Julliard
julliard at winehq.org
Fri Sep 11 10:53:23 CDT 2009
Module: wine
Branch: master
Commit: f1d4ab32243b9bcb33550afa8cf97b8529b03382
URL: http://source.winehq.org/git/wine.git/?a=commit;h=f1d4ab32243b9bcb33550afa8cf97b8529b03382
Author: Rico Schüller <kgbricola at web.de>
Date: Thu Sep 10 21:27:11 2009 +0200
d3d10: Implement ID3D10EffectVariable::GetDesc().
---
dlls/d3d10/effect.c | 34 ++++++++++++++++++++++++++++++++--
1 files changed, 32 insertions(+), 2 deletions(-)
diff --git a/dlls/d3d10/effect.c b/dlls/d3d10/effect.c
index d468896..d1bd7ee 100644
--- a/dlls/d3d10/effect.c
+++ b/dlls/d3d10/effect.c
@@ -1677,9 +1677,39 @@ static struct ID3D10EffectType * STDMETHODCALLTYPE d3d10_effect_variable_GetType
static HRESULT STDMETHODCALLTYPE d3d10_effect_variable_GetDesc(ID3D10EffectVariable *iface,
D3D10_EFFECT_VARIABLE_DESC *desc)
{
- FIXME("iface %p, desc %p stub!\n", iface, desc);
+ struct d3d10_effect_variable *This = (struct d3d10_effect_variable *)iface;
- return E_NOTIMPL;
+ TRACE("iface %p, desc %p\n", iface, desc);
+
+ if(This == &null_variable)
+ {
+ WARN("Null variable specified\n");
+ return E_FAIL;
+ }
+
+ if(!desc)
+ {
+ WARN("Invalid argument specified\n");
+ return E_INVALIDARG;
+ }
+
+ memset(desc, 0, sizeof(*desc));
+ desc->Name = This->name;
+ desc->Semantic = This->semantic;
+ desc->Flags = This->flag;
+ desc->Annotations = This->annotation_count;
+ desc->BufferOffset = This->buffer_offset;
+
+ if( This->flag == D3D10_EFFECT_VARIABLE_EXPLICIT_BIND_POINT)
+ {
+ desc->ExplicitBindPoint = This->buffer_offset;
+ }
+ else if(This->flag)
+ {
+ FIXME("Unhandled flag %#x!\n", This->flag);
+ }
+
+ return S_OK;
}
static struct ID3D10EffectVariable * STDMETHODCALLTYPE d3d10_effect_variable_GetAnnotationByIndex(
More information about the wine-cvs
mailing list