shadows getting clipped on shadowMaterial #1202
-
I am very new to three js and was just going through some tutorials. I am facing 2 problems at the moment:
It'd be really great if someone can provide detailed documentation of @react-three Here's the demo I've created https://codesandbox.io/s/cocky-jennings-n31mv <group>
<mesh
receiveShadow
rotation={[-Math.PI / 2, 0, 0]}
position={[0, -3, 0]}
>
<planeBufferGeometry attach="geometry" args={[100, 100]} />
<shadowMaterial attach="material" />
</mesh>
</group> |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 4 replies
-
thats normal, this has to do with the light, <directionalLight
shadow-camera-right={10}
shadow-camera-top={10}
shadow-camera-left={-10}
shadow-camera-bottom={-10}
... /> increase/decrease as you need it, it could also be related to the planeGeometry being too small. softlights are very expensive thought, you might get better results with contact shadows https://codesandbox.io/s/baked-ao-f5sgi or lightmaps https://codesandbox.io/s/v6-adaptive-regression-forked-wsg13 and the fastest would be to bake in blender, but that only works for static scenes. |
Beta Was this translation helpful? Give feedback.
thats normal, this has to do with the light,
increase/decrease as you need it, it could also be related to the planeGeometry being too small. softlights are very expensive thought, you might get better results with contact shadows https://codesandbox.io/s/baked-ao-f5sgi or lightmaps https://codesandbox.io/s/v6-adaptive-regression-forked-wsg13 and the fastest would be to bake in blender, but that only works for static scenes.