I’m trying to run a Rhino Compute server that processes an uploaded DXF file. The Appserver is running in a docker on my mac and the computer server is running in a VM of windows 11.
Right now, my workflow is:
-
Receive a Base64 string.
-
Save it as a temp
.dxffile. -
Load the objects into a Headless Doc.
The problem is that I need to output these objects to the native Group Content component in Grasshopper. When I try to pass the objects from the script, they don’t seem to preserve the layer information in a way the component can read, or I get a “Data conversion failed from Goo to Model Content” error.
I’ve tried File3dm.Read (fails to read the temp file on Mac so I’m not sure if it will work deployed in a container) and doc.Write3dm (not supported on Mac headless), so I’m stuck on how to get valid ModelObjects that the Group component will accept.
I will need to eventually expand this process to work with a few more file types (dwg, svg, 3dm), but for now my focus is DXF.