• Advertisement
Sign in to follow this  

[D3D10] D3DReflect results in E_NOINTERFACE

This topic is 2744 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

ID3D10Blob *error = NULL;

/////// Vertex Shader
HRESULT CompileVShaderResult = D3DX10CompileFromFile( ShaderPathAndName, NULL, NULL, "Main_VS", "vs_4_0", ShaderFlags, NULL, NULL, &VSCode.pD3D10Buffer, &error, NULL );
if( error )
MessageBoxA( 0, (LPCSTR)(error->GetBufferPointer()), 0, 0 );

HRESULT CreateVShaderResult = m_pd3dDevice->CreateVertexShader( VSCode.pD3D10Buffer->GetBufferPointer(), VSCode.pD3D10Buffer->GetBufferSize(), &pD3D10VertexShader );
if( CreateVShaderResult != D3D_OK )
assert( CreateVShaderResult == D3D_OK );
// create constant buffer for vertex shader
ID3D10ShaderReflection *pReflector = NULL;
HRESULT VShaderReflectResult = D3DReflect( VSCode.pD3D10Buffer->GetBufferPointer(), VSCode.pD3D10Buffer->GetBufferSize(), IID_ID3D10ShaderReflection, (void**)&pReflector );
assert( VShaderReflectResult == D3D_OK );

where VSCode.pD3D10Buffer is ID3D10Blob*, and both CompileVShaderResult and CreateVShaderResult returns an S_OK.

I'm using the D3DCompiler_42.dll from "C:\Windows\System32" and the Feb 2010 SDK.

Any ideas? Thanks.

[Edited by - 16bit_port on October 19, 2010 8:50:53 PM]

Share this post

Link to post
Share on other sites
Sign in to follow this  

  • Advertisement