Skip to content

Automatic collision bounding boxes for gltfjsx mesh groups #88

Discussion options

You must be logged in to vote

you can get bounds from the returned geometry https://threejs.org/docs/index.html#api/en/core/BufferGeometry.computeBoundingBox

const { nodes } = useLoader(...)
const bounds = useMemo(() => {
  node.foo.geometry.computeBoundingBox()
  return node.foo.boundingBox()
}, [nodes])

Replies: 5 comments 1 reply

Comment options

You must be logged in to vote
0 replies
Answer selected by codynova
Comment options

You must be logged in to vote
1 reply
@AlexanderInglis
Comment options

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
3 participants
Converted from issue

This discussion was converted from issue #88 on June 18, 2020 08:57.