Exporting Background 3D preview as Image In Bulk

Hello, I want to export the background 3D preview images in bulk, but the only option I see at the moment is doing so manually. I have a script that runs in periodic mode and reads excel with hundreds of data to create the brick wall geometry. But now I want to export the 3D preview as image from dynamo. I read on one of the posts that it’s possible to use the import the export as image function in the menu as a node?
If so, how can I do that? Alternatively does anyone know a way to capture screenshot using the python node? Thanks a lot.

Look into Capturefinery from Kean Walmsley, https://www.keanw.com/2019/05/introducing-capturefinery-a-dynamo-package-that-creates-presentation-graphics-for-refinery-studies.html.

Won’t do exactly what you are after as you aren’t going into refinery, but the source code has what you want (I think).

Most of my animations are done via screen2gif which will send a screenshot of each frame that you could save out. Would require keeping the window static but it works.

Maybe consider adding some coloring as well?

Hi Jacob, thanks for your suggestion! I looked into their source code and did find a related function. But I’m strugggling to make a zero-touch node for taking a screenshot in dynamo. If you know a way to do so please advise. Thanks a lot!

Beyond that tool I do not. Note that this is driving the Dynamo API so its not about making a node but about making a new Dynamo run entirely.

you can do this with an extension or with a nodeModel node. (sometimes called a UI node, but you don’t need the UI portion)
check this

here is what happens when you click that menu item:

with an extension you can get the BackgroundPreview and call similar functions yourself.