Hello.
I’m still porting my game. Not I’m fixing the HLSL shaders from XNA 4.0 to Monogame, and I’m having an issue with multiple color output and their ColorWriteEnable states.
Basically, before, I had
void AnimatedModelPS( in float2 iUV : TEXCOORD0,
in float3 iNormal : TEXCOORD1,
in float4 iPos : TEXCOORD2,
in float iDepth : TEXCOORD3,
out float4 oDiffuse : COLOR0,
out float4 oNormal : COLOR1,
out float4 oDepth : COLOR2)
{
// Lots of stuff
}
technique AnimatedModelAlpha
{
pass p0
{
AlphaBlendEnable = true;
DestBlend = InvSrcAlpha;
SrcBlend = SrcAlpha;
ColorWriteEnable = Red | Green | Blue;
ColorWriteEnable1 = 0; // This is not accepted anymore
ColorWriteEnable2 = 0;
VertexShader = compile vs_3_0 AnimatedModelVS();
PixelShader = compile ps_3_0 AnimatedModelPS();
}
pass p1
{
AlphaBlendEnable = false;
ColorWriteEnable = Alpha;
ColorWriteEnable1 = Red | Green | Blue | Alpha; // This is not accepted anymore
ColorWriteEnable2 = Red | Green | Blue | Alpha;
VertexShader = compile vs_3_0 AnimatedModelVS();
PixelShader = compile ps_3_0 AnimatedModelPS();
}
}
But now the compiler complains about the ColorWriteEnable1 and ColorWriteEnable2. Is it still a thing in another notation or has it been completely removed from Monogame? How could I get the same behaviour without touching the C# side of the rendering?
With Regards