Found another bug.
If you are working with Geometry (not BufferedGeometry) raycasting fails because indexes are not stored in the octree.
This will store the indexes (a b c - are undefined, should be face.a, face.b,face.c):
Mesh_octree_injection.js
286c282
< let faceIndices = [a, b, c];
---
> let faceIndices = [face.a, face.b, face.c, f];
Also I’ve added storing of the face index. For BufferedGeometry it’s basically faceIndex = a, which is not for just Geometry, so:
Mesh_octree_injection.js
309c305
< for (let [a,b,c] of otn.content) {
---
> for (let [a,b,c,f] of otn.content) {
320d315
<
332d326
< intersection.face = face;
333a328
> intersection.face = geometry.faces[f];
356c351
please find the attached fixed files.
OTNode.js (2.6 KB)
Mesh_octree_injection.js (9.1 KB)