hr = D3DXCompileShaderFromFile(
"shader.vs",
0,
0,
"Main", // entry point function name
"vs_1_1",
/*D3DXSHADER_DEBUG*/D3DXSHADER_USE_LEGACY_D3DX9_31_DLL,
&shader,
&error,
&ConstTable);
此处更改D3DXSHADER_DEBUG为D3DXSHADER_USE_LEGACY_D3DX9_31_DLL;