peterqliu / threebox

A three.js plugin for Mapbox GL JS, with support for basic animation and advanced 3D rendering.
MIT License
528 stars 320 forks source link

how to use ExtrudeGeometry to make a mesh? #92

Open limzgiser opened 4 years ago

limzgiser commented 4 years ago

like this?
const shapeGeometry = new THREE.ExtrudeGeometry(shape, { depth: 3, bevelThickness: 2, bevelSegments: 10 }); const mesh = new THREE.Mesh( shapeGeometry, new THREE.MeshBasicMaterial({ color: 0xb8b730 * Math.random(), opacity: 1 }) );

I hope someone gives me a demo? 3Q.

jscastro76 commented 3 years ago

This issue has been solved in the my Threebox fork. There's a specific example on creating extrusions from THREE.Vector2 arrays and from geoJson features. image