erixon Posted February 22, 2015 Share Posted February 22, 2015 I want one building to shadow another building, but when an object both sends and receives shadows it become more or less black, any solutions to this? Like Three.js shadowBias? kind regardsTomas Quote Link to comment Share on other sites More sharing options...
joshcamas Posted February 23, 2015 Share Posted February 23, 2015 could you show a picture, or even better a playground example? www.babylonjs.com/playground/# Quote Link to comment Share on other sites More sharing options...
RaananW Posted February 23, 2015 Share Posted February 23, 2015 We had a long discussion about this a few weeks ago, try adding ://assuming shadowGenerator to be the variable name :-)shadowGenerator.useVarianceShadowMap = false;after initializing the shadow generator and see if it solves the problem. Quote Link to comment Share on other sites More sharing options...
erixon Posted February 23, 2015 Author Share Posted February 23, 2015 http://www.babylonjs-playground.com/#14RGDA Thanks RaananW, it worked better with useVarianceShadowMap = false. I hope shadows get better support in the future. Quote Link to comment Share on other sites More sharing options...
GameMonetize Posted February 23, 2015 Share Posted February 23, 2015 You could use usePoissonSampling = true instead Quote Link to comment Share on other sites More sharing options...
erixon Posted February 23, 2015 Author Share Posted February 23, 2015 It's hard to understand what to use when. Sometimes the shadows are outside the shadowmap and are clipped. How is this debugged? Quote Link to comment Share on other sites More sharing options...
GameMonetize Posted February 24, 2015 Share Posted February 24, 2015 this is because we do not support cascaded shadow maps (for now). So you have to position your light carefully (because the shadow map is generated from the POV of the light) Quote Link to comment Share on other sites More sharing options...
iiceman Posted May 2, 2015 Share Posted May 2, 2015 sorry to dig the up again but I am still not sure I understand how to use it. I created this very simple playground: http://www.babylonjs-playground.com/#1OI7BE Is it possible to use the blur variance shadow map while the mesh casts and receives shadow or am I forced to deactivate cast/receive to avoid that black effect? I am not really happy with the other shadow versions, I would really love to have the blur shadow map. But I also need my meshes to receive shadow (looks just stupid if they don't). Any way to do that? I played around with the light position and the bias value, but doesn't seem to make a difference as far as I can tell. Quote Link to comment Share on other sites More sharing options...
GameMonetize Posted May 2, 2015 Share Posted May 2, 2015 Unfortunately, this is a strong constraint of the blurred shadows (due mainly to the lack of precision of RGBA32 texture). Quote Link to comment Share on other sites More sharing options...
iiceman Posted May 3, 2015 Share Posted May 3, 2015 Hmm, I see, that's too bad. Follow up question: why does this shadow with PoissonSampling look so off? The cube is on the ground, so the shadow should start right at it's corners but it is somehow shifted. http://www.babylonjs-playground.com/#1OI7BE#1 Quote Link to comment Share on other sites More sharing options...
GameMonetize Posted May 3, 2015 Share Posted May 3, 2015 You need to tweak shadows with biasing:http://www.babylonjs-playground.com/#1OI7BE#2 Quote Link to comment Share on other sites More sharing options...
iiceman Posted May 4, 2015 Share Posted May 4, 2015 okidok, thanks alot Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.