Hi everyone, I am using this 2 sided shader that cuts out the alpha information and correctly sorts polygons:
MATERIAL* mat_Correct_Alpha_3 = //------------------------------- CORRECT SORTING OF TGA ALPHA IN A MODEL!! 2 sided
{
specular_blue = 100;
specular_green = 100;
specular_red = 100;
power = 10;
flags = ENABLE_TREE | PASS_SOLID;
//my.transparent=on;
effect="
DWORD ref=128.0f;
technique test
{ pass p0
{
cullmode=NONE;
zenable=true;
zwriteenable=true;
alphablendenable=false;
alphatestenable=true;
AlphaRef=<ref>;
AlphaFunc=Greater;
}
}
";
}
Is there a way to get this shader, or any shader to work on both sides for PSSM shadows? The shadows are correctly cast on the main side of a triangle, but the backside (cullmode=NONE) of the polygon, you can see the shadow through it!