Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

375
Visualizações
How to read triangles and vertices of the model from the STL format?

I need to get information about the vertices and triangles of the STL format model, please tell me how to extract this data in ThreeJS

about 4 years ago · Juan Pablo Isaza
1 Respostas
Responde à pergunta

0

You can use the STLLoader class for this task. So you define an instance of the loader and use it to load a STL asset from a specific path. In the onLoad() callback, you get an instance of BufferGeometry representing the geometry data from the STL file.

const loader = new STLLoader();
loader.load( './models/stl/ascii/slotted_disk.stl', function ( geometry ) {

    const material = new THREE.MeshBasicMaterial();
    const mesh = new THREE.Mesh( geometry, material );

    scene.add( mesh );

} );

Keep in mind that the geometry is non-indexed. So the faces/triangles are defined by three consecutive vertices in the position buffer attribute.

Full example: https://threejs.org/examples/webgl_loader_stl

about 4 years ago · Juan Pablo Isaza Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda