July 27, 2019, 4:16pm
Is it possible to use the functionality of the Import SVG Plugin in a C# context? I’ve tried referencing the RHP and poked around a bit… I see almost all the classes are internal/protected/private.
Ideally I’d like to go straight from an SVG file to a collection of Geometry (or maybe RhinoObjects)
without importing them into the active rhinodoc… any chance this is possible?
July 27, 2019, 4:41pm
This should be possible in the Rhino 7 WIP.
// create a headless doc and import
using(var doc = RhinoDoc.New(null))
// copy objects out of Document.Object table for use later
Thanks for your example, it worked great for importing many file types. However, I noticed that when trying to importing .3dm files using your example, the UI prompts user for a import scale (as shown below). Is importing rhino files headlessly not supported yet?
December 16, 2020, 5:35am
I never thanked you for this bug report. I added it to our todo list at
February 19, 2021, 6:39pm
This should work in Rhino 7 if you use the
function to create your doc. The SVG importer will not prompt for input when the doc is “headless”