Rico Schüller : d3d10: Implement GetConstantBufferByName.
Alexandre Julliard
julliard at winehq.org
Fri Aug 21 09:32:20 CDT 2009
Module: wine
Branch: master
Commit: 2381c0e5608c142a0c060bf8b52e43d18008768a
URL: http://source.winehq.org/git/wine.git/?a=commit;h=2381c0e5608c142a0c060bf8b52e43d18008768a
Author: Rico Schüller <kgbricola at web.de>
Date: Thu Aug 20 19:06:20 2009 +0200
d3d10: Implement GetConstantBufferByName.
---
dlls/d3d10/effect.c | 16 +++++++++++++++-
1 files changed, 15 insertions(+), 1 deletions(-)
diff --git a/dlls/d3d10/effect.c b/dlls/d3d10/effect.c
index ed849bb..f40d5fd 100644
--- a/dlls/d3d10/effect.c
+++ b/dlls/d3d10/effect.c
@@ -839,7 +839,21 @@ static struct ID3D10EffectConstantBuffer * STDMETHODCALLTYPE d3d10_effect_GetCon
static struct ID3D10EffectConstantBuffer * STDMETHODCALLTYPE d3d10_effect_GetConstantBufferByName(ID3D10Effect *iface,
LPCSTR name)
{
- FIXME("iface %p, name \"%s\" stub!\n", iface, name);
+ struct d3d10_effect *This = (struct d3d10_effect *)iface;
+ unsigned int i;
+
+ TRACE("iface %p, name \"%s\"\n", iface, name);
+
+ for (i = 0; i < This->local_buffer_count; ++i)
+ {
+ struct d3d10_effect_local_buffer *l = &This->local_buffers[i];
+
+ if (!strcmp(l->name, name))
+ {
+ TRACE("Returning buffer %p.\n", l);
+ return (ID3D10EffectConstantBuffer *)l;
+ }
+ }
return NULL;
}
More information about the wine-cvs
mailing list