[Addon] Rendering Single Image on multiple PC

Hello Everyone,

this is an addon i have written after watching a Tutorial from Kent Trammell at cgcookie.com.
http://cgcookie.com/blender/2014/07/31/rendering-single-frame-faster-multiple-computers/

I post it here again, so people can download the .py file here directly.

I only got a single windows machine here right now, so i dont know if everything works on the other operating systems. You can paste the code into the Blender Texteditor and save it as a .py file. Then you can put it into your Blender addon directory.
After Enabling it, you can go to the Properties->RenderPanel->Output. There should be an additional filepath + a checkbox. Here is what they do:

Filepath: Directory where the Rendernodes automatically save the Rendered Images after hitting F12/pressing Render (Note: A subfolder with the name of the Blendfile is generated)
Autosave: Turns the Autosave of the Images on or off - The Images get the samples written in their Filename automatically(if you got slower and faster Rendernodes that you want to finish at the same time) - The Seed while rendering depends on how much Files are already in the targetdirectory.

After finishing Rendering you can open another Blenderfile and go to Compositing. In the Tool-Panel(left side of the screen after pressing T) their is a new Panel called “Merge Images”:

Images: The Directory the images that you want to merge are loaded from.
Target: Currently this one has no usage, but i plan on automatically adding the generated Nodegroup in the Compositor, let them generate and save the combined Image, then disabling the Nodegroup and use the saved Image instead for better performance during compositing.
SampleWeighting: If you turn this off, you can combine Images together that where rendered without this addon(without the samples in their filename)
Merge: This Button loads all the Images of the specified Filepath and combines them into a single Nodegroup with an Image Output, which you can find in the compositornodes.

This is how i thought one would use the addon:

  1. Model/Texture etc. your scene, specify the filepath and check Autosave, then Render from as many nodes you want
  2. Open another Blenderfile, this is where you do your compositing - In the Compositing Nodetree there is a new Panel called Merge Images. There are 2 Paths you can choose
    In the Compositor click Add->Group->MergedImages. The output of the group is the combined hopefully noisefree Image.

Things that are still to do for the addon:

  1. Currently you need to specify the Samples for each node manually - Maybe I can implement something that automatically assigns a number of Samples to your Rendernodes based on the time your main Workstation needs to complete the scene.
  2. Button to clear out the Folder with the images - Right now if you Render your Scene again these Images are just added to the existing ones in the Subfolder(could be an advantage, as you can basically split your Rendertimes as it is now - but not with progressive Refinement at the moment i think).
  3. Let the Rendernodes start their work when you Hit F12 at your workstation.
  4. Right now it doesnt work with multiple Renderlayers(simple noisereduction for example on individual layers could be simply done on all machines if necessary)
    I am pretty sure there are a ton of bugs at the moment - i will try to fix em when i got the time. Feel free to point out any problems or stuff that could be improved in the script as i am not very expierienced with python.

With best regards

granite_skull

RenderSingleFrameOnMultipleMachines.2.zip (2.28 KB)

Great Thanks Granite_Skull,

Congrats!
Spirou4D

Ok, i fixed the problem with the placeholders that were not written before rendering(resulting in all machines using the same seed).

Right now the script generates an Image named Placeholder(or use the existing one) - the disadvantage is that this Image shows up in the Imagebrowser in Blender(I will probably switch to writing a file with os open).

Does anyone know how to receive the samples while/at the end of progressive refinement Rendering?

I just updated the addon - the Placeholders don´t show up in the Blender Imagebrowser anymore.

The Generate Nodegoup Button + SampleWeighting Checkbox is now moved to their own Panel in the Compositor called “Merge Images”. There are also two new directorys you can specify - Images and Target. Images is the directory where the Images are in you want to combine.
Target currently has no usage, but i plan on automatically adding the generated Nodegroup in the Compositor, let them generate and save the combined Image, then disabling the Nodegroup and use the saved Image instead for better performance during compositing.