I am troubleshooting a code snippet that is throwing an error:
const geometry = new THREE.BufferGeometry();
const indices = new THREE.InterleavedBufferAttribute(...);
geometry.setIndex(indices); // this is invalid
After running this code, I receive a compiler error message stating:
Type 'InterleavedBufferAttribute' is missing the following properties from type 'Bufferattribute': dynamic, updateRange, version, needsUpdate and 12 more.
I'm wondering if it's possible to utilize InterleavedBufferAttribute
in order to properly set my indices?
On another note: Can interleaved arrays be used for indices in general? I've never encountered this in any programming language. While this is a minor question, it piques my curiosity.