I have simple shader from CG tutorial:
struct v_Output {
float4 position : POSITION;
float4 color : COLOR;
};
v_Output vert(float2 position : POSITION)
{
v_Output OUT;
OUT.position = float4(position, 0, 1);
OUT.color = float4(0, 1, 0, 1);
return OUT;
}
struct f_Output {
float4 color : COLOR;
};
f_Output frag(float4 color: COLOR)
{
f_Output OUT;
OUT.color = color;
return OUT;
}
In one project it works fine, but if I copy the shader to my old project it doesn’t work as I expected.