-
I'm rendering a pinball table with small meshes. Eg the ball is 27mm Starting with https://bevyengine.org/examples/3d-rendering/3d-scene/ and reducing the size of the cube until it's that small will cause it to lose it's shadow. Below examples for cubes of 0.04, 0.06, 0.08 and 0.10 Also the shadow looks rather low-res at this scale. Sphere with radius 0.05 shown here. And a movie that shows the issue, shadows disappear before the objects hit the floor. Screencast.From.2025-04-04.14-45-00.webmShould I somehow indicate I would like to have the shadows working on a smaller scale? |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 1 reply
-
Try playing around with the shadow settings, there's some on the PointLight component and there's the PointLightShadowMap resource. I assume when the object is too small, it becomes smaller than 1 pixel from the point light's POV so increasing the point light shadow map resolution's from the 1024 default with:
will fix the problem but will increase rendering cost. The settings are intended to make sense with a "standard" scene size but its intentional that you'll have to tweak things with small or big scenes. |
Beta Was this translation helpful? Give feedback.
-
Somewhat answering my own question after some research:
Other things I triedIncreasing the The camera I tried playing with the |
Beta Was this translation helpful? Give feedback.
Somewhat answering my own question after some research:
shadow_depth_bias: 0.01
or lower fixed the disappearing part. I'm not sure why and if that comes with other implications.Other things I tried
Increasing the
PointLightShadowMap
makes the shadows a bit sharper but this might be expensive.The camera
ShadowFilteringMethod
Gaussian
orTemporal
improves the look of the shadow.I tried playing with the
CascadeShadowConfigBuilder
values but did not see any difference, probably because the distance from the light to the objects is not varying that much.