9thAzure / Complex_Shape_Creation

A Godot Engine addon for creating / modifying shapes
MIT License
6 stars 0 forks source link

Width is Slightly Off At Corners When Using Rounded Corners and Without Drawn Arc #52

Closed 9thAzure closed 2 months ago

9thAzure commented 2 months ago

The width is slightly lower than it should be. Interestingly, this is not present if drawn_arc is used.

In the example below, the yellow shape's corners have a width of ~4.91, when it should be 5 (which the blue shape is) Screen Shot 2024-04-21 at 6 18 41 PM

9thAzure commented 2 months ago

The issue is the order in which changes to the shape are applied.

If drawn_arc is used, the shape is made a ring shape, then its corners are smoothed. Otherwise, the corners are smoothed first, then it is made into a ring.

9thAzure commented 2 months ago

Since the first case (using drawn_arc) is better, the fix should be to make to add the ring shape first in all cases, then smooth corners.

9thAzure commented 2 months ago

Another thing I noticed is that if Corner_Size is greater than the inner part of the ring, it deviates its shape from the outer part of the ring and becomes very circlely.

I don't think I'll be changing this, at least anytime soon. I doesn't look that bad at all.