ycw
February 12, 2020, 3:17pm
1
PG Description:
All boxes are instanced meshes
the source mesh is set to receive shadows, and
each instanced mesh is a shadow caster.
https://www.babylonjs-playground.com/#RLQ5JX#1
Expected that all boxes receive shadows;
Actually, those on the west (-x) do not.
Pryme8
February 12, 2020, 4:24pm
2
2 Likes
It still should work without a direction (using a direction makes the point light simulates a spot light and does not use a cube texture).
I’m going to have a look.
2 Likes
You have to put the master mesh in the shadow caster list, even if you don’t display it:
https://www.babylonjs-playground.com/#RLQ5JX#3
I don’t really know why, I think it’s because it’s the master mesh that drives the shadow rendering of the instances…
1 Like
ycw
February 12, 2020, 5:59pm
5
That’s exactly my goal, … casting shadow in all directions from a bulb …
I even tried to add 5 more light 5 shadow gens to achieve this
https://www.babylonjs-playground.com/##DWIYIP
Thanks!
Pryme8
February 12, 2020, 8:45pm
6
ooof I thought it was a directional light…
It should not be mandatory
Let me check that
It will be fine in next nightly (no more need to add the root mesh)
2 Likes