Thread Control
Thread Control
Setting Thread Count
Currently there are four ways to set the number of render threads in RfK, in order of precedence:
- The preferences interactiveRenderThreadsOverride and interactiveRenderThreads3D (equivalent to the use of the "--threads3d" command line parameter in batch mode). If you want to definitively set the number of render threads this will be the place to do it.
- The attribute renderSettings.renderThreads (via AttributeSet, it is not exposed in RenderSettings)
- PrmanGlobalSettings: commandArguments.numThreadModeProcs
- PrmanGlobalSettings: options.limits.threads. This translates literally to RIB: Option "limits" "int threads" [N]
The first three will trigger a "-t:#" addition to the command line arguments for prman which, by RenderMan definition, will override any thread specification in the RIB.
Special Values
If a value of 0 (zero) is given to prman via either the "-t" command line or the "threads" option then all CPUs will be utilized for rendering. If a negative value (-N) is specified then prman will use all but N CPUs for rendering.