Save multiple polysurface to individual obj file with batch script?

Hi! I have multiple buildings in one file, and I’d like to export them into individual files, each containing one building. Is that feasible in Rhinoscript?

Many thanks!

Sure, just script the Export command, which exports selected objects.

– Dale

well… I got 500 individual polysurface (export to 500 .obj file) and I don’t want to do it mannually…

Write a script (either RhinoScript or Python) that follows this algorithm:

  1. Select the objects you want to export. Keep a list of the objects.
  2. Unselect all objects in the document
  3. For each object in your list:
    3.1. Select the object
    3.2. Script the _-Export command (you’ll need to cook up a file name)
    3.3. Unselect the object
  4. Done

– Dale

1 Like

Thank you for the clear pipeline!