@Peon501, @Jjagg, thanks for the follow up.
Both solutions we tried worked fine until yesterday. I chose to use MG build from source, so a to be able to recompile my shader if need be.
So this morning I modified one of my shader and recompiled it using the remote plugin, and got the initial error message once again: System.Exception : This MGFX effect is for an older release of MonoGame and needs to be rebuilt.
So I debugged the MG code, and easily found the place where it happens in Microsoft.Xna.Framework.Graphics.Effect.ReadHeader
.
Line 130, there is this check:
if (header.Version < MGFXHeader.MGFXVersion) throw new Exception("This MGFX effect is for an older release of MonoGame and needs to be rebuilt.");
In my case header.Version
is 7 while MGFXHeader.MGFXVersion
is 8.
I don’t understand how I was able to pass this test before modifying my shader, as it was already compiled with the same remote service.
Edit: from here, I can see that MGFXVersion
was incremented to version 8 in April 2016, and hence that this change has been part of MG since 3.6. So I really don’t understand why I get effects compiled in version 7…
Edit2: from here, I think that the pipeline service tries to get the MG version used by the client, and falls back to MG 3.5 if it doesn’t recognize it.
@dellis1972: Could you please confirm?
Edit3: so my guess is that the problem root is not the header version, but rather the MG version exposed to the pipeline service when calling it from .net core. The version is ok by itself, but it is not recognized properly here.
@Jjagg: What do you think?
Edit4: submitted issue in InfinitespaceStudios.Pipeline repo.