   D3DX10CompileFromFile failing!
  I am learning D3D10 now, and i want to create a demo without DXUT or Effect system, so i need to set the global variables manually, but when i am using D3DX10CompileFromFile to compile MyTest_VS.vsh but it is failing with E_FAIL. The code I'm using is as follows:    DWORD dwShaderFlags = 0;    dwShaderFlags |= D3D10_SHADER_DEBUG;    ID3D10Blob* pVSBuf = NULL;    ID3D10Blob* pErrorMsg = NULL;    hr = D3DX10CompileFromFile( L"MyTest_VS.vsh", NULL, NULL, "VS", "vs_4_0", dwShaderFlags, NULL, NULL, &pVSBuf, &pErrorMsg, NULL ) ;    if( FAILED( hr ))return hr;and i have setup the device with the Device creation flags like this:    createDeviceFlags = D3D10_CREATE_DEVICE_DEBUG;    D3D10CreateDeviceAndSwapChain( NULL, g_driverType, NULL, createDeviceFlags,D3D10_SDK_VERSION, &sd, &g_pSwapChain, &g_pd3dDevice );Anybody can give me some information about this error??thx!   
  E_FAIL is just a generic error, you must give us the exact detailed error or post the shader so we can test it. (try with fxc and tell us what it says)   ;Quote:Original post by feal87E_FAIL is just a generic error, you must give us the exact detailed error or post the shader so we can test it. (try with fxc and tell us what it says)Thank you very much! your words give me the afflatus. I have fixed this issue, the problem is the VS shader output,   