# \#octree

**URL:** https://discourse.threejs.org/tag/octree/642.md

[Latest](https://discourse.threejs.org/latest.md) · [Categories](https://discourse.threejs.org/categories.md) · [Tags](https://discourse.threejs.org/tags.md)

---

## [Getting "Invalid array length" at OctreeHelper](https://discourse.threejs.org/t/getting-invalid-array-length-at-octreehelper/78840)

<div class="topic-metadata">

**Author:** [@dedadev](https://discourse.threejs.org/u/dedadev)\
**Replies:** 2\
**Last updated:** [March 3, 2025, 3:02am UTC](https://discourse.threejs.org/t/getting-invalid-array-length-at-octreehelper/78840 "2025-03-03T03:02:22Z")

</div>

I am trying to load 700kb model in my scene (glb), and then apply an Octree, but I keep getting this error this is exactly where it breaks: (in code) const octree = new OctreeHelper( collider ); (in console) m…

---

## [How to store an octree](https://discourse.threejs.org/t/how-to-store-an-octree/57687)

<div class="topic-metadata">

**Author:** [@JS\_Padawan](https://discourse.threejs.org/u/JS_Padawan)\
**Replies:** 9\
**Last updated:** [June 29, 2024, 10:57am UTC](https://discourse.threejs.org/t/how-to-store-an-octree/57687 "2024-06-29T10:57:45Z")

</div>

Hi Everyone ! I’m creating a FPS (not COD but almost !), and i need to handle players collisions with the objects on the map, terrain etc… I chose to use an Octree because of the good performance it offers. In fact, e…

---

## [I found that using Octree would penetrate inside TubeGeometry](https://discourse.threejs.org/t/i-found-that-using-octree-would-penetrate-inside-tubegeometry/54118)

<div class="topic-metadata">

**Author:** [@NightMoom](https://discourse.threejs.org/u/NightMoom)\
**Replies:** 6\
**Last updated:** [November 12, 2023, 9:32am UTC](https://discourse.threejs.org/t/i-found-that-using-octree-would-penetrate-inside-tubegeometry/54118 "2023-11-12T09:32:34Z")

</div>

for example file games\_fps.html. I created a TubeGeometry. and set worldOctree.fromGraphNode() This is the code I added // other code container.appendChild( stats.domElement ); // line 87 let points = \[new THREE.Vec…

---

## [Guide on octree traversal for LOD](https://discourse.threejs.org/t/guide-on-octree-traversal-for-lod/48527)

<div class="topic-metadata">

**Author:** [@Pravin\_Poudel](https://discourse.threejs.org/u/Pravin_Poudel)\
**Replies:** 0\
**Last updated:** [February 28, 2023, 6:53am UTC](https://discourse.threejs.org/t/guide-on-octree-traversal-for-lod/48527 "2023-02-28T06:53:46Z")

</div>

I am building an octree LOD for point cloud data visualization. I have octree and every time a camera is moved, I traverse a tree to find nodes and levels ( with throttle; I mean it checks with the throttle of 3 seconds)…

---

## [How do i add geometry to the octree in the games\_fps example](https://discourse.threejs.org/t/how-do-i-add-geometry-to-the-octree-in-the-games-fps-example/34571)

<div class="topic-metadata">

**Author:** [@steven](https://discourse.threejs.org/u/steven)\
**Replies:** 4\
**Last updated:** [December 25, 2022, 1:01am UTC](https://discourse.threejs.org/t/how-do-i-add-geometry-to-the-octree-in-the-games-fps-example/34571 "2022-12-25T01:01:17Z")

</div>

when i convert the glb to an obj and import it and add geometry and export it again as glb , it works as long as i just add some flat planes but when i add a more complex building with doors windows stairs and floors …

---

## [What does "fromGraphNode" function do in Octree.js?](https://discourse.threejs.org/t/what-does-fromgraphnode-function-do-in-octree-js/41068)

<div class="topic-metadata">

**Author:** [@panda\_warrior](https://discourse.threejs.org/u/panda_warrior)\
**Replies:** 1\
**Last updated:** [August 5, 2022, 8:55am UTC](https://discourse.threejs.org/t/what-does-fromgraphnode-function-do-in-octree-js/41068 "2022-08-05T08:55:00Z")

</div>

I’m trying to understand this code, but I’m hitting a roadblock, what does this code actually do from Octree.js? My understanding is that it creates triangles for each vertex. fromGraphNode( group ) { group.updateWor…

---

## [Octree injection for faster raycasting/raytracing](https://discourse.threejs.org/t/octree-injection-for-faster-raycasting-raytracing/8291)

<div class="topic-metadata">

**Author:** [@EliasHasle](https://discourse.threejs.org/u/EliasHasle)\
**Replies:** 6\
**Last updated:** [November 28, 2021, 1:47pm UTC](https://discourse.threejs.org/t/octree-injection-for-faster-raycasting-raytracing/8291 "2021-11-28T13:47:58Z")

</div>

\*\*NEW update: I never really established a proper repository for this, and it seems I have let through some serious bugs. I refer to corrected versions by @Nick\_Drobchenko here: Octree injection for faster raycasting/ray…
