Open kennyweiss opened 2 weeks ago
I foresee some interesting workflow steps arising from this feature + user creativity... : )
Should the example
svg
files be added toaxom_data
?
Thanks @bmhan12 -- yes, I'm planning to add a few small SVG files and generated MFEM NURBS meshes to axom_data as well as a test.
I also have to add a command line option to the python script to (optionally) reverse the edge orientations.
Summary
README
file insrc/tools/svg2contours/
for more infoExamples
SVG Arcs:
This example uses rotated ellipses, elliptical arcs, and rounded rectangles:
After running svg2contours to generate an mfem mesh and querying that via the quest_winding_number example, we get:
We can visualize the output mesh w/ VisIt. Here are the generated (rounded) winding numbers: (the grid for the query mesh appears as faint gray lines).
Detail: Generated MFEM NURBS mesh
``` MFEM NURBS mesh v1.0 # MFEM Geometry Types (see fem/geom.hpp): # # SEGMENT = 1 | SQUARE = 3 | CUBE = 5 # # element:Inkscape example
A second example uses an SVG generated in inkscape using an (open) spiral curve, a polygon with straight edges, an ellipse and a circle
Detail: Input SVG file
```svg ```Running through svg2contours and the quest_winding_number example, we get the following winding number and inout fields:
Detail: Generated MFEM NURBS mesh
``` MFEM NURBS mesh v1.0 # MFEM Geometry Types (see fem/geom.hpp): # # SEGMENT = 1 | SQUARE = 3 | CUBE = 5 # # element: