drei
drei copied to clipboard
Bvh raycast: Cannot read properties of undefined (reading 'count')
-
three
version: [email protected] -
@react-three/fiber
version: @react-three/[email protected] -
@react-three/drei
version: @react-three/[email protected] -
node
version: v18.18.2 -
npm
(oryarn
) version: 9.8.1
Problem description:
Enabling Bvh on my scene and holding a ref to my ecctrl controlled character causes an error. related to https://github.com/pmndrs/ecctrl/issues/97
Relevant code:
https://github.com/pmndrs/ecctrl/tree/main/example
<Canvas>
<Bvh firstHitOnly>
<Scene />
</Bvh>
</Canvas>
Suggested solution:
i'm thinking maybe it's because drei is using an older version of three-mesh-bvh