Distributed Rendering
Distributed rendering, as the name suggests, means distributing the rendering work among multiple computers. This allows you to scale up performance beyond what a single machine can offer.
We already covered the basics in the Introduction sections V-Ray Server and Distributed Rendering. Please read them first, as we will be expanding upon this here.
The VRayRenderer.resetHosts method
Along with addHosts/removeHosts methods, the VRayRenderer
class also implements a resetHosts method. It has the same signature as addHosts: it takes IP:port pairs as string delimited by ',' or ';'. It drops all hosts from the current list and sets the new list for use. If the list is empty this just disconnects all hosts.
The inProcess flag
This is a VRayRenderer
property. By default it is set to true. When set to false, the process in which the renderer is created won't be used for rendering. Only distributed rendering will be used. The server can still be on the same machine in another process. If no hosts are added, rendering doesn't start at all.
Performance and Scalability Considerations
Overhead from enabling DR
By default distributed rendering is disabled when creating a VRayRenderer. This saves some memory that is otherwise used to transfer scene changes to the DR hosts. Set DREnabled=true
to be able to add DR hosts before or after starting rendering.
Progressive vs buckets
Currently distributed progressive rendering does not scale up as well as bucket rendering. You can safely add dozens of hosts with buckets, but in progressive (both Production and Interactive mode) gains start to diminish after only a few. This depends on scene settings and the network, of course. Progressive rendering is more often used in the scene development stage where resolutions are not so high, so this is less of a problem. Final frame rendering of huge resolutions and/or multiple animation frames is well suited for DR. In the latter case it is often best to assign each render machine to one animation frame.