|On this page|
RenderMan for Houdini
RenderMan provides its own bridge product called "RenderMan for Houdini". Please follow this link for more information: setting up "RenderMan for Houdini".
Earlier versions of Houdini shipped with dedicated RenderMan nodes and SOHO scripts. With the release of the "RenderMan for Houdini" bridge product, these nodes have been deprecated and hidden in
$HFS/houdini/OPlegacyRMan (included in
OPcustomize script). The following information is presented for legacy setups only.
Rendering with RenderMan is done in Houdini thru a RenderMan render output driver node. It generates a RIB stream and pipes it to the
prman executable specified in the Command parameter. It is also possible to save a
.rib file to disk, by turning on the toggle next to the Disk File parameter.
Under the hood, the output driver node runs SOHO scripts, taking into consideration the RenderMan version specifiedc in the Render Target parameter. The scripts inspect the scene and write out a corresponding RIB, compiling any VOP shaders such as RSL Material, if necessary.
Setting up RenderMan
In order for Houdini to be able to find all the necessary RenderMan tools, first you will need to set a few environment variables:
RMANTREEis set to the installed version of RenderMan, for example:
ensure the search path includes the
binsubdirectory of RenderMan, for example:
HOUDINI_DEFAULT_RIB_RENDERERto the desired version, for example:
After setting up these three environment variables, Houdini should be able to use RenderMan.
Choosing a renderer
Each RIB target renderer has its own executable, way of compiling shaders, attributes, options, and features. Much of this is handled by Houdini behind the scenes. However, as a big head start, you can give Houdini a hint as to which render you are using by setting the environment variable
HOUDINI_DEFAULT_RIB_RENDERER to the render target you want to use. The list of renderers can be inferred by looking at the
$HH/RIBtargets and also at
$HH/soho directory and scanning the files. The current renderers include
Houdini uses this variable in several places. In the
hrmanshader script (a wrapper around the shader compiler), the variable controls which compiler program to call. It also controls which properties appear on the RIB output driver.
Set the default RIB renderer
# set up for prman21.0 export HOUDINI_DEFAULT_RIB_RENDERER=prman21.0
Setting up the display driver
RenderMan version 20.2 and up ships with a Houdini display driver, so there is no need for any additional setup, beyond specifying
houdini in the ROP node’s Display Device parameter. Once this is done, the RIB renderer will render directly to MPlay.
It is also possible to reconfigure RenderMan to remap
framebuffer device to Houdini display driver, so that all framebuffer rendering goes to MPlay as well. This can be done in
rendermn.ini with this line:
Customizing the View: RenderMan menu
Overriding the shader path
Houdini will set the path to the default path each renderer expects. You can override the shader path in two ways:
Set the path by adding the rendering parameter to the output driver (preferred method).
Set the environment variable
If you customize the path, you should include
$HFS/ri_shaders in the path for light shaders. If you don’t customize the path, Houdini will look for directories named
ri_shaders in the
For RIS shader plugins there is a
HOUDINI_RI_RIXPLUGINPATH environment variable. But you don’t need to include
$HFS/ri_shaders in your customization, since Houdini does not look for directories named
ri_shaders because Houdini does not ship with any custom RIS shader plugins. Thus the implicit default of
$RMANTREE/lib/RIS usually suffices.
Customizing object parameters
If you are using RenderMan as a primary renderer, you may not want to see all of the mantra parameters in your geometry objects. You can customize the geometry object to create objects with RenderManparameters instead.
Customize object parameters
Once you save the parameters as permanent default parameters, they will be applied to all new objects. (You can do the same with the light and camera objects, though lights should work fairly well out-of-the-box in Houdini).
You can improve shading quality by adding the Shading Interpolation parameter.
You can use VOPs to create RSL shaders, or you can import other shaders that you have written. Importing is done by creating Houdini Digital Assets that correspond to the written shaders.
To import shaders, run a Python script which parse the output of
sdrinfo (Pixie), etc. Houdini ships with 2 scripts:
slo2otl.py to convert prman shaders.
The scripts are reliant on being able to parse information about shader parameters, but should be fairly easy to customize for an unsupported renderer. The script tries to implicitly guess the HDA table type and is geared for RIS shaders which are VOPs, so light and displacement .slo files implicitly yeld a VOP HDA. You can force the HDA SHOP with the -t command-line switch.
slo2otl.py -t Shop -l myshaders.hda *.slo
This will create an HDA which can be loaded into Houdini. All of the recognized shaders will exist as SHOP nodes.
Windows requires you to run hython in order to run Python.
hython sdl2otl.py -l myrmanshaders.otl *.sdl
Hython will not find the
sdl2otl.py script unless
$HB is included in the Python path.
Building RSL shaders using VOPs
In addition to importing external
.slo shaders described above,
Houdini allows to build shaders using VOP networks
such as RSL Material.
You can assign RSL Material to objects by setting the Material parameter, or to individual primitives using the Material SOP, as described in the shading documentation.
RIS Rendering Mode