Flames look nice, but takes lot of time to render them, specially in high resolution and quality.
One way of speeding up rendering is to distribute rendering on various computers.
The main idea is to have a central server onto which one can upload various flames to be rendered. The rendering of these flames is then distributed on various computers which run as render slaves, each rendering one part of the image. When all parts are completed, then either the master or one of the slaves assembles the final image from various parts.
There are two issues related to this:
- flam3 cannot render only one part of the image, although large images can be rendered in stripes to overcome out of memory error. Still, as it is originally, either with stripes or not, flam3-render can render one image only, not part of the image.
- somehow the file location need to be resolved. the render slaves need the information describing what to render (the .flame3 file), and they need to store somewhere the result of their rendering. This means between the server and render slaves we need a shared file system,where/from where both can read/write, or the server need to act also as a file server, allowing slaves to upload render results and download render informations.
For now, I have changed flam3 package to allow partial rendering only.
In order to ease the parameter passing, I have modified the code that now settings can be passed either through environment variables, or through command line arguments. All environment variables can be set from command line using [name]=value format, where [name] is the name of the environment variable. Please note, command line settings have higher priority over their environment counterparts.
Also, couple of new options were added, for rendering only part of the flame:
- –help – display the help
- minstrip=[number] – the minumum strip number to be rendered.
- maxstrip=[number] – the maximum strip to be rendered.
- strip=[number] – the strip to be rendered.
- for all this parameters, you will have to set nstrips value. Also, the value of these parameters should between 0 and nstrips.
- Also, if minstrip and maxstrip is provided, then render is between minstrip inclusive and maxstrip-1 inclusive. (minstrip=0 and maxstrip=1 will render strip 0, minstrip=1 maxstrip=1 will render no strips)
- providing strip=[number] will render only the given strip.
Sources can be downloaded from here: flam3.tar.gz
Next step would be the server and render slaves.