I have created a series of geometry (with colors) in Dynamo. My goal is to save pictures of these.
Since it is not possible, based on my knowledge, to export a series of dynamo backgrounds automatically, I was trying to loop through the geometry designs from a python script.
For each design I try to:
- Convert geometry to element in Revit
- Override color in view (not standard)
- Save images
- Delete the geometry (and start again)
For step 1, I tried to export sat and re-import them, but I didn’t manage to color them (through OverrideGraphicSettings(), ogs.SetSurfaceForegroundPatternColor() ogs.SetSurfaceForegroundPatternVisible() ) because the sat file has no Surface to color. Then I thought about using Family, but I cannot find anything in Revit API to CREATE a family from geometry.
For step 2, as mentioned before, I use view.SetElementOverrides() because i need to put color in a different 3D view (not current view). I believe this can work.
For step 3 I use doc.ExportImage(). This can work as well.
Nothing to say about step 4.
In order for this plan to work, I need to solve step 1. Do you have any suggestions on solving step 1?
I would also appreciate your opinion on making this entire workflow more efficient.
Please note, OOTB node are not an option for me because this is a small part of a bigger workflow developed in python.
Thanks in advance!