build123d
build123d copied to clipboard
Circle SVG imported as multiple ellipses
circle_svg = StringIO("""
<svg viewBox="0 0 100 100" xmlns="http://www.w3.org/2000/svg">
<circle cx="50" cy="50" r="50" />
</svg>
""")
circle = import_svg(circle_svg)
v = circle.vertices()
print(circle.edges()[0].geom_type())
circle.edges()[0].geom_type() = 'ELLIPSE'
build123d uses the svg importer from here: https://github.com/snoyer/ocpsvg. Try raising the issue there.
The underlying issue has been handled in ocpsvg and it looks like it fixed this issue in build123d
print([e.geom_type for e in import_svg(StringIO('<svg><circle r="1"/></svg>')).edges()])
[<GeomType.CIRCLE>]
maybe @MatthiasJ1 can confirm and close if applicable
I get GeomType.CIRCLE with ocpsvg 0.2.1. Closing the issue. Thanks @snoyer!