Skip to content
Advertisement

Tag: react-three-fiber

Three.js – Model cannot receive any shadow

I’m currently new and learning about three.js. And i’m using react-three-fiber to make it happen with React, but i stumbled upon a problem. The model however, cannot receive any shadow from another model. I’ve tried to use obj.castShadow = true and obj.receiveShadow = true to one of the receiving shadow model object on the parent and the children as well

bufferGeometry setFromPoints with react-three-fiber

Considering toLinePath function: I want to recreate it using react-three-fiber and been trying something like this: But there’s no output/error at all. I suppose I’ve completely misunderstood react-three-fibers API. What am I doing wrong here? Thanks and here’s the sandbox Answer For a future googler, useUpdate has been removed here: https://github.com/pmndrs/react-three-fiber/pull/996. Use useLayoutEffect instead.

Advertisement