|
Double sided shader that works with PSSM
#465743
05/11/17 00:03
05/11/17 00:03
|
Joined: Apr 2002
Posts: 1,246 ny
jumpman
OP
Serious User
|
OP
Serious User
Joined: Apr 2002
Posts: 1,246
ny
|
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!
Last edited by jumpman; 05/11/17 00:03.
|
|
|
Re: Double sided shader that works with PSSM
[Re: sivan]
#465893
05/16/17 16:46
05/16/17 16:46
|
Joined: May 2009
Posts: 5,370 Caucasus
3run
Senior Expert
|
Senior Expert
Joined: May 2009
Posts: 5,370
Caucasus
|
@sivan, if I'm not mistaken, you used shadows from older shade-c, right? I even got the rip-off, did you add any adjustments/tweaks to it (version I have does have darkness adjustments + different blurring algorithms, but not moving shadows from trees and grass)? If it's the latest version, I could share my ripoff with jumpman, but if there is a newer version, I would like to get my hands on it as well Greets
|
|
|
|