smoke - prman-pixar/RenderManForBlender GitHub Wiki
#Rendering Smoke and/or Flame effects#
PRMan has the ability to render Blender smoke/fire simulations. The workflow is similar to rendering smoke in Cycles.
- Create and bake your smoke simulation. Please note that if you do not bake the simulation (by pressing the 'bake' button in the smoke sim panel) you will not be able to export it.
Note: You can use the 'adaptive domain' option with the smoke sim for PRMan, but the 'smoke high resolution' options do not work and can crash the exporter. - Select the smoke domain in Blender and apply a PxrVolume shader to it.
- In the node editor, add in a PxrPrimVar node and type in 'density' in the 'name' box. Leave the type dropdown as 'float'.
- Connect the grey float output of the primvar node to the density float input of the PxrVolume shader.
This is all that is needed for a basic render of the smoke in PRMan.
#Modifying the Smoke Simulation Data#
In some cases you may want to alter the output of the smoke sim (making it more dense or hard edged, for instance). In this case you can tweak the output of the primvar node, but it is important to understand the different data formats that are being used and how to convert between them.
The smoke simulation density is being output by the primvar node as a single floating point number. All of the nodes that you could use to modify the smoke data (PxrMix, PxrBlend, PxrHSV, PxrGamma) expect an RGB color input. If you were to hook the float output of the primvar directly into the RGB input of, say a PxrBlend node, the render would not work. Unlike the Cycles engine, PRMan nodes do not automatically convert between data formats at node inputs if they are incorrect. You must first convert the floating point number into a RGB value, modify it, and then convert it back to floating point before plugging it into the PxrVolume node. Here's an example workflow:
- Run the smoke simulation, bake it, and add in the PxrPrimVar node to access the density data. Connect the 'float' output into the 'input' of a PxrFloat3 node. This will convert the float data into an RGB value. Next connect the 'RGB' output of the Float3 node to the top value of a PxrBlend node. Select 'multiply' for the function and enter an RGB value of 3,3,3 in the second color swatch. This will essentially multiply the smoke data (making it three times as dense). Connect the 'rgb' output of the blend node into the input of a PxrFloat node. Select 'luminosity' as the conversion method. This will convert the RGB input data back into a single float number. Connect the 'output' of the float node into the 'density float' input of the PxrVolume shader. Now render and notice that your smoke is much denser than before.
#Coming Soon: Fire!#