Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[PATCH] broken shadows #2

Open
ghost opened this issue Jan 31, 2012 · 2 comments
Open

[PATCH] broken shadows #2

ghost opened this issue Jan 31, 2012 · 2 comments

Comments

@ghost
Copy link

ghost commented Jan 31, 2012

The shadows are broken (compile error in Base.cg)

Base.cg line 240:

    oColor *= shadow(shadowMap2, shadowPos2);// + float4(0.1, 0.1, 0, 1);

I changed it to:

    oColor *= shadowPCF9(shadowMap2, shadowPos2, invShadowMapSize2.xy);// + float4(0.1, 0.1, 0, 1);

this fixed the shadows.

Another fix would be to comment out the parameter "invShadowMapSize2" in Base.program

@nikki93
Copy link
Owner

nikki93 commented Feb 1, 2012

Ah, thanks for that! Turns out I fixed this locally and forgot to push.

There still seems to be an issue with shadows when the shaders are recompiled (click 'Apply' in the graphics options).

@ghost
Copy link
Author

ghost commented Feb 17, 2012

Just a thought. I see you have code for reloading all the textures when 'Apply' is hit. Maybe you're reloading the shadow textures ? (which you shouldn't do, since they're not saved on disk)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant