3
\$\begingroup\$

I'm currently porting an old XNA game over to MonoGame and everything (including custom shaders) build fine.

However when i try to load the xnb file using content.Load<Effect>("BaseDraw"); I receive the following error:

An unhandled exception of type 'SharpDX.SharpDXException' occurred in SharpDX.dll

Additional information: HRESULT: [0x80070057], Module: [General], 
    ApiCode: [E_INVALIDARG/Invalid Arguments], Message: The parameter is incorrect.

I even tried building the shaders with 2MGFX.exe and loading it manually but that throws the same error.

I have no idea what to so any help would be appreciated!

\$\endgroup\$
3
\$\begingroup\$

Figured I had the shader versions too high (vs_5_0/ps_5_0) lowering them to their 4_0 variant fixed the error.

\$\endgroup\$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.