private generateCurvedCube2(): void {
const shape = new THREE.Shape();
shape.moveTo(0,0);
shape.lineTo(0,3);
shape.absarc(1.5, 1.5, 1.65, 26.2, 5.2, true);
shape.lineTo(0,0);
const extrudeSetting = {
depth: 3,
bevelEnabled: false,
bevelSegments: 0,
steps: 1,
bevelSize: 0,
bevelThickness: 0,
}
const geometry = new THREE.ExtrudeGeometry(shape, extrudeSetting);
console.log(“geometry group”, geometry.groups);
const materials = this.createShapeLabelMaterials(this.availableShapes.CurvedCube2, this.selectedColour);
this.curvedCube2 = new THREE.Mesh(geometry, materials);
this.scene.add(this.curvedCube2);
this.outlineService.addOutline(this.curvedCube2, this.availableShapes.CurvedCube2);
}
This is my code for creating a curved cube with labels on each face. However, I’m currently getting only 2 groups, which is why I see only 2 labels. For example, the ‘Front’ label appears on the opposite side, and the ‘Back’ label appears on the other side. I have 5 faces in total, including one curved face, but the labels for the other faces are not showing up. How can I fix this issue?
For other geometry it is coming properly but for extrude geomtery it is not coming properly.