Use Frame Number to Drive Seed In a Random Effector and Dome Light Color
-
I have a plan to create 100 variations of a simple abstract art image. Five Cloners and a few mesh objects. I'd like to automate this as much as possible. I thought that rendering 100 frames (as though this were an animation) and for each frame change the color of the background (a Dome Light), the color of the objects, and the arrangement of the objects (via Random Effectors for the Cloners).
Can anyone think of a possible workflow for this? I can write Xpresso or Python (preferably Python) easily.
Thanks,
Greg -
Hi Greg,
Here are two options. The top (object manager) light object uses an XPresso setup. It converts the RGB value into an HSL and randomizes the Hue value here. Then puts it back to RGB. You can set up the L and S channels, then change the "42" I added to the $1 to different integer numbers for the other channels. CMD dragging a node copies it.
The Random Effector in the second example Modifies the Clone while the Cloner is set to Blend. I introduced a few more child objects to get a random variety. Otherwise, it often feels like it focuses more on the center. Please note that I have set the Min/Max of the random Effector to 0-100%
Please note that for perfect processing, the left side has a sortable list; the top to the bottom is the flow of information, if not forced otherwise by the nodes.Please check this page out: Perhaps some useful formula content for XPresso
https://help.maxon.net/c4d/2023/en-us/Default.htm#html/6194.html?TocPath=Appendix%257C_____2About Python, I keep this strictly (!) out of this forum; if there is any question, use the Developer Café; you find the link on the Support page at maxon.net
I have discussed this internally a while ago, and handling Python here would require checking any code submitted repeatedly to see if anything would have changed after a while. So, there is no Python here. Sorry, but this is the only manageable way to keep it safe here.
So, no code here, thank you.All the best
-
@Dr-Sassi Using your deeply knowledgeable examples I was able to modify the scene to do exactly what I need. Using a Dome Light instead of an Area Light; the only slight issue was finding the right Color input for the DL (there seem to be many Color inputs :)).
I used Time and Multiple nodes to create a unique integer per frame and input that into the Seed of a Random Effector to achieve my goal.
I have attached the modified file.
Thanks again, as always!
Greg
-
Hi Greg, thank you very much for the reply and the lovely feedback.
Yes, XPresso can sometimes expose a lot of parameters. Perhaps that helps:
Drag the Object into the XPresso Editor.
With the Object active, drag the parameters from the Attribute Manager to the blue square of the Node, and let go of the "mouse". The wanted Parameter should be established as input. If you need an output, drag the Parameter from the Attribute Manager on the red square of the Node.Example use: Output can be helpful to explore how a Pulldown menu was coded. Like in the Random Effector, you have more options. See image. This helps to know about "hidden" parameters.
Each of the entries is coded with an Integer number. So you can change the entry via XPresso.
Thanks for the feedback file. Yes, that looks stable. If there was a question and I missed it, let me know.
As a side note, the Take System might be a great addition to the sequencing of image output.
Enjoy your project
-