Mesh SVG output and small code cleanup