iiceman Posted January 4, 2015 Share Posted January 4, 2015 Hi again, just a quick (maybe weird) question: I want an invisible mesh to cast a shadow and cant get it to work. As soon as I set visibility on the mesh or alpha on the material to something else than 1, I don't get a shadow anymore. Am I doing something wrong or is this maybe intended like that? What could be a work around to get my shadow without the user seeing the mesh. Playground example here: http://playground.babylonjs.com/#I2H3M Quote Link to comment Share on other sites More sharing options...
JCPalmer Posted January 4, 2015 Share Posted January 4, 2015 Cannot answer, but have "improved" you example: http://playground.babylonjs.com/#I2H3M#1 Torus2 was never added to the render list. Also turned problem lines into comments. Un-comment to see problem Quote Link to comment Share on other sites More sharing options...
RaananW Posted January 4, 2015 Share Posted January 4, 2015 shadowGenerator.setTransparencyShadow(true); seems to solve the problem. http://playground.babylonjs.com/#I2H3M#2 meteoritool, dreinzy and Dieterich 3 Quote Link to comment Share on other sites More sharing options...
iiceman Posted January 4, 2015 Author Share Posted January 4, 2015 Thank you guys! Again a quick and helpful answer, very nice! @JCPalmer, I was in a hurry and just threw that playground together after it didn't work in my actual project, thanks for fixing things up! 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.