d3dcompiler: Implement ID3D11ShaderReflectionType::GetMemberTypeName().
authorRico Schüller <kgbricola@web.de>
Mon, 28 Feb 2011 18:47:34 +0000 (19:47 +0100)
committerAlexandre Julliard <julliard@winehq.org>
Tue, 1 Mar 2011 12:21:58 +0000 (13:21 +0100)
dlls/d3dcompiler_43/reflection.c

index c0ade4344e06b2e10d0d6aa2866760f8a692fea2..130c1e4e22fe04b736bb35c7b9706e1a6f1eded2 100644 (file)
@@ -847,9 +847,23 @@ static ID3D11ShaderReflectionType * STDMETHODCALLTYPE d3dcompiler_shader_reflect
 static LPCSTR STDMETHODCALLTYPE d3dcompiler_shader_reflection_type_GetMemberTypeName(
         ID3D11ShaderReflectionType *iface, UINT index)
 {
-    FIXME("iface %p, index %u stub!\n", iface, index);
+    struct d3dcompiler_shader_reflection_type *This = impl_from_ID3D11ShaderReflectionType(iface);
 
-    return NULL;
+    TRACE("iface %p, index %u\n", iface, index);
+
+    if (This == &null_type)
+    {
+        WARN("Null type specified\n");
+        return "$Invalid";
+    }
+
+    if (index >= This->desc.Members)
+    {
+        WARN("Invalid index specified\n");
+        return NULL;
+    }
+
+    return This->members[index].name;
 }
 
 static HRESULT STDMETHODCALLTYPE d3dcompiler_shader_reflection_type_IsEqual(