I would like to basically know how do I access the list of vertices and triangular faces from the scene of gltf file. What I have currently is this.
return from(fetch(targetUrl.toString(), {
method: 'GET',
headers: {
'Content-Type': 'application/json'
}
}).then(response => {
response.arrayBuffer()
.then(data => {
const loader = new GLTFLoader();
loader.parse(data, "", gltf => {
this.scene.add(gltf.scene);
})
})
})).pipe(
map((surfaceMesh) => {
this.surfaceMeshes.set(surfaceMeshKey, surfaceMesh);
}
))
}
I would like to have the array of vertices and triangular faces in this regard, not the count! Can somebody please help me out in this case? It would mean a lot to me if you guys do the syntax of how the modified code would look like?