the below code is for making convex shape
[AvailableShapes.CurvedCube]: {
// This is how the dimensions are given for custom generated shape.
firstLine: {
x: 0,
y: isForSelector ? 3 : 20,
},
arc: {
x: 0,
y: 0,
radius: isForSelector ? 3 : 20,
startAngle: isForSelector ? 1.5 : 20,
endAngle: 0,
isClockwise: true,
},
lastLine: {
x: 0,
y: 0,
},
extrudeSetting: {
depth: isForSelector ? 3 : 20,
bevelEnabled: false,
bevelSegments: 0,
steps: 1,
bevelSize: 0,
bevelThickness: 0,
},
// This is for placement of the curved cube, has to be changed when new layout is changed.
offSetCoordinates: {
x: -3,
y: 5,
z: 0,
},
color: color,
},
so if i want to make a concave arc instead of tht convex arc
what should i change
can u share urs idea
I would use a circle geometry, much easier than extrude.
To make a concave arc use the opposite part of a circle. If the green arc is used for the convex green shape, the red arc could be used for the concave red shape. This is the idea, you need to figure out the actual circle center (i.e. x
and y
) and arc angles (i.e. startAngle
and endAngle
) for the red arc, similarly to how you figured them out for the green arc.
2 Likes
Thank you