C# Script to Export to Colored Layers from Grasshopper without Baking

They look like the same thing to me?

I see no reason for the extreme verbosity of trace / error messages. In this case, I hadn’t yet changed the ‘Directory’ text panel so expected to see the fail message you added but I don’t see it?

Command: _-Grasshopper
Grasshopper option ( Window Document Solver Banner ): _Document
Grasshopper Document ( Open Save SaveAs Close CloseAll ): _Open
Grasshopper file ( Browse ): “C:\Users\josep\Downloads\Export Without Baking.gh”
Connected as an Analog Input - Ready to Export
Increase value to Export - keep at Maximum until export is completed
Grasshopper option ( Window Document Solver Banner ): _Enter
Grasshopper option ( Window Document Solver Banner )
Connected as an Analog Input - Ready to Export
Increase value to Export - keep at Maximum until export is completed
Connected as an Analog Input - Ready to Export
Increase value to Export - keep at Maximum until export is completed
Connected as an Analog Input - Ready to Export
Increase value to Export - keep at Maximum until export is completed
Connected as an Analog Input - Ready to Export
Increase value to Export - keep at Maximum until export is completed
Connected as an Analog Input - Ready to Export
Increase value to Export - keep at Maximum until export is completed
Connected as an Analog Input - Ready to Export
Increase value to Export - keep at Maximum until export is completed
Connected as an Analog Input - Ready to Export
Increase value to Export - keep at Maximum until export is completed
Connected as an Analog Input - Ready to Export
Increase value to Export - keep at Maximum until export is completed
Connected as an Analog Input - Already Active
Set Input to Minimum to Reset

When I changed the directory to one that exists and tried again, it fails. I see this message:

Connected as an Analog Input - Already Active

So I quite Rhino, restarted your GH file, changed the directory and tried again. It failed again with no clue as to why? I’m ready to give up now. :frowning:

The analog trigger sounded like a clever work-around yesterday but in fact is a PITA to use. UGH! There must be a better way using a single button. A few years ago I cobbled together a bake to layer component that uses a single button to trigger multiple copies of the component and it works well:

Some comments on the GH prior to your C#:

  • I see no reason for the Brep Join prior to ArrBox. It’s only effect is to convert curves to surfaces which can be accomplished by a Srf param.

  • I see no reason for nine Flatten components when the same goal can be accomplished with three Entwine components.

  • The ‘Extension’ Value List should be a dropdown instead of a cycle.

  • I hate relays.

Export Without Baking_2023Aug21a.gh (19.2 KB)

I’m not sure yet how I would use this, if it worked, but it’s broken.

1 Like