Table Of Contents
Introduction
Redshift Proxies allow you to place previously exported Redshift Proxy Files (.rs) files in your scenes without actually loading the geometry until it is actually needed at render time. You can think of a Redshift Proxy as an actual Redshift scene all on its own, they can even contain other Redshift Proxies.
Using Redshift Proxies in your scene is a 2 step process. First you export a Redshift Proxy File, then you import and place a Redshift Proxy in your scene and associate it with the exported file.
Using proxies has several advantages over in-scene objects, namely:
- Proxies are loaded by Redshift on demand and will therefore only use resources when they are needed (when a ray intersects the proxy's bounding box).
- Proxies have almost no time cost during scene translation. Extracting large amounts of geometry can be slow and using proxies means you pay that cost only once, when you first export the Redshift Proxy File.
- Proxies are stored in an optimized format on disk so that the renderer can immediately use the data after loading from disk without additional processing or memory overhead.
- Support for object types including animated and deforming meshes, hair, strands, instances, volume containers, lights and any materials/shaders applied to these objects.
The main disadvantages of using proxies:
- Making edits to the proxy can be more time consuming than if the original data is part of the scene (as it requires making changes in another file and re-exporting the Redshift Proxy File)
- After export Redshift Proxy geometry cannot be deformed or otherwise modified aside from adjusting tessellation settings. For example, you cannot animate components inside a proxy after export, but you can animate the position, rotation and scale of the proxy as a whole rigid object.
- Animated proxies can be heavyweight because they are per-frame caches.
Redshift Proxies provide the option to use either the materials embedded in the Redshift Proxy File, or to replace those materials with materials from the scene where the proxy is placed.
Redshift Proxy Files are DCC-independent, so for example you can export a Redshift Proxy File from Maya and import it as a proxy in Houdini, or vice-versa.
There are currently some important limitations in sharing Redshift Proxy Files between DCCs:
- The embedded shaders in a Redshift Proxy File from one DCC may not be available in another DCC. For example a Redshift Proxy File containing a Softimage Lambert material will not render correctly when placed as a proxy in Maya.
- Certain light types native to a particular DCC may cause errors when rendered in another DCC.
To avoid this issue, we recommend always using one of the From Scene material modes when sharing Redshift Proxy Files between DCCs until we resolve this limitation.
Important Considerations
When working with Redshift Proxies, it is helpful to keep the following things in mind:
- You cannot retrieve the original Maya, 3ds Max or Softimage mesh from a Redshift Proxy File, so it is advisable to keep the original source data that was used to export the Redshift Proxy.
- When placing multiple copies of a Redshift Proxy in a scene, it is much more efficient for memory and performance to create a single Redshift Proxy and then create multiple instances of this proxy and place them as desired.
The data exported with your Redshift Proxy is determined by your Render Settings at the time of export, by default Redshift will try to discard as much unnecessary data as possible to achieve the most efficient file size.
UVs, Vertex Color, & Other Per-Vertex Attributes
When exporting a set of objects as a Redshift Proxy File, only the vertex attributes used by the currently assigned shaders are included in the exported data. This is an important optimization to prevent file bloat. When a proxy file will be used as-is, without overriding materials, this is not an issue. However, when using proxy material overrides, this can cause unexpected behavior if the overriding material requires vertex data that was stripped at export time because it was unused. So if you need certain attributes for your proxies at any point down the line, make sure that a shader attached to your proxy object is making use of those attributes. For example, if you have a sphere with a spherical texture projection and an untextured simple material assigned, the texture projection will be stripped at proxy file export time because it is not used by the currently assigned material. If this proxy is then placed in another scene and the material is overridden by a material that does use UVs, it will render incorrectly due to the missing UVs.
Motion Blur
In order for Redshift Proxies to render with Motion Blur you must make sure that motion blur is enabled in your Render Settings at the time of export.
Motion blur can be disabled on proxies after export but individual motion blur settings like frame duration cannot be changed after the fact, you must re-export your proxy if you wish to change its motion blur settings.
Instancing & Tessellation
If you are planning on instancing your Redshift Proxies please keep in mind that you can only use fixed tessellation.
Adaptive tessellation cannot be used when instancing in Redshift.
Creating & Exporting Proxies
There are three different nodes used to export Redshift Proxy files from Houdini though the export process is the same between them all, some have different functions and export options:
-
Redshift ROP node: Usually used to export full proxy scene files to be rendered in the farms. Can also be used to export only selected objects.
-
Redshift Proxy Output ROP node: Used to export proxy objects from the render context.
-
Redshift Proxy Output SOP node: Used to export proxy objects directly from objects. The proxy sop is added inside the OBJ nodes like any modeling operation, so it exports the modeling SOP linked to its input. It only can export one object.
In order to export Redshift Proxies from the Redshift ROP node in Houdini you must enable the "Export.rs Proxy File" option in the Redshift ROP under the Archive section as pictured below:
Turning on RS Proxy Export in Redshift ROP node
Once enabled you start the actual export process by clicking the "Render to Disk" button as pictured below:
Exporting a RS Proxy
Export Parameters
"Redshift ROP" Proxy Export Options
"Redshift Proxy Output" ROP Export Options
"Redshift Proxy Output" SOP Export Options
Archive
Export .rs Proxy File
Enables the export function of Redshift Proxy Files from "Redshift ROP" when the "Render to Disk" button is pressed.
Only applicable to the "Redshift ROP" output node.
Filename
This path specifies the location and name of the proxy output file. Proxies must be output with the ".rs" file type.
In order to export a proxy file sequence be sure to include the "$F" frame token in your file name as depicted in the images above.
Create Intermediate Directories
When enabled Houdini will automatically add all the paths needed to save the file if they are not available.
Export Only Selected Objects
Exports only the selected objects as a Redshift Proxy file.
Only applicable to the "Redshift ROP" output node.
Discard the Not Used Attributes
When enabled Redshift will try to discard as much unused and unnecessary data as possible to achieve the most efficient file size.
Export Connectivity Data
Enabling this option is only necessary if you need to apply tessellation & displacement to the proxy after you’ve placed it in a scene and the original mesh does not have tessellation or displacement applied. Enabling this option increases the size of the proxy file, so it should only be used if necessary.
Polygon Connectivity Data will be exported automatically for any objects that already make use of tessellation & displacement.
Compress File
This option enables file compression to reduce file size for exported Redshift Proxies. In some cases, the compression can reduce the file size by 50% or more.
In general compression will lead to slower export and load times.
However, if a bottleneck in your pipeline is slow data transfer performance like a slow storage drive or network then enabling file compression could lead to a performance improvement due to the smaller file sizes. If you have a fast network and fast storage drive like an SSD then performance might be slower due to the processing time needed to decompress the proxy files. These are the sorts of things to consider when determining whether to enable or disable compression.
Skip Existing Files
When enabled this option will skip pre-existing Redshift Proxies files that are detected with the same name.
Ignore OBJ Level Transformations
When enabled the proxy object is exported in local space, ignoring any transformations available at object level (translations, rotations, etc). When disabled the proxy is exported after all the object level transformations in world space.
When enabled, any objects exported will lose their object level transformations which makes this option most useful for exporting single frames or mesh level animations.
Using Proxies
To place a Redshift Proxy in your Houdini scene you must create a Redshift Proxy object.
You can do this easily by going to the Redshift toolbar and select "Proxy" as pictured below:
Creating a Redshift Proxy object
Proxy Object Parameters
Redshift Proxy Object
Enable Proxy File
This option enables or disables the proxy file, when disabled the proxy file will not be displayed or render.
Proxy Filename
This field specifies the Redshift Proxy File that will be rendered in place of the proxy object. You can navigate to and select the proxy file by using the folder icon to the right of this field.
Display Mode
These options determine how the proxy will be displayed in the viewport.
- None: Completely hides the proxy from the viewport but the proxy will still render.
- Bounding Box: Displays a simple axis-aligned bounding box encompassing all the objects in the associated file.
- Mesh: Uses the geometry data directly from the file.
- Points: Uses a point cloud to display the geometry data.
|
|
|
|
|
| None | Bounding Box | Mesh | Points |
Display Percentage
This option controls the percentage of the geometry data to display in the viewport when Display Mode is set to Preview Mesh.
When Display Mode is set to Preview Mesh, the full resolution geometry contained in the Redshift Proxy File is used by default. For proxy files containing a lot of geometry, this can negatively impact the viewport rendering performance in. For very geometrically dense proxies, we recommend leaving Display Mode to Bounding Box, using a Linked Mesh, or setting Display Percentage to a low value when using Preview Mesh.
|
|
|
|
|
Display Percentage: 1.0 Display Mode: Mesh |
0.5 | 0.1 |
Display Lines
This option toggles the display of Houdini curve primitives that are present in a Redshift Proxy File. This can be helpful to speed up viewport performance when your proxy contains many curves but you still want to be able to preview your proxy mesh in the viewport.
Animated Preview
When using an animated proxy file sequence this option controls whether the proxy in the viewport is allowed to update or not. When disabled, the proxy will remain static in the viewport but it will still update at render time. When enabled, the animated proxy will update in the viewport.
Proxy Materials
These options control how materials are handled for this proxy and allows from materials within the proxy file to be overridden with materials defined in the current scene. See the section Overriding Proxies for additional details.
- From Proxy: Redshift renders the proxy object using the materials embedded in the proxy file, without overriding them.
- From OBJ Node: The plugin tries to find materials used inside the same OBJ proxy placeholder node. If the OBJ node only has one material defined at OBJ level, it is used to override all the proxy materials.
- Full Override: This option enables the “Full Override Material” parameter, where you can set any material available in the scene to fully override all the proxy materials with it.
- List Override: This is the most flexible option to override proxy materials. When selected you can add materials to the “Material Override List” parameter to set the scene material that is going to be used to override each proxy material. The proxy materials are available in the override list proxy material drop-down menu.
- From Scene Materials: In this case, the plugin is going to replace the proxy materials if it finds a material with the same path/name available in the scene.
Full Override Material
This is where you specify the material in your scene to override every material inside your scene when the Proxy Materials option is set to "Full Override."
Material Override List
This is where you control which materials are overridden in your proxy and with which new materials in your scene when the Proxy Materials option is set to "List Override."
On the left you can click the
button to add new slots until you have enough to override as many materials as you need. After that you can choose the proxy material to replace with the "Replace Material" drop down menu on the left side. In the image below this is the "material_in_proxy." Then you set which scene material will override it with the "With" section on the right side, in the image below this is the "material_in_scene." There are also two empty override slots depicted below.
Material Override List
Overrides
These checkboxes control whether the corresponding attributes of the objects inside the proxy file should be overridden by the same attributes of the proxy placeholder object. For example, if you want to assign an Object ID of 5 to the contents of a proxy file, you would set the Object ID of the placeholder object to 5 and enable the Object ID override.
- Object ID
- Visibility & Matte
- Tessellation & Displacement
- Trace Sets
- User Data
External Proxy References / How To Transfer Proxies
Given that Redshift proxies can contain anything in a Redshift scene, this means that they can externally reference image files (such as EXR, PNG, etc), volume grids (like OpenVDB) and even other proxy files!
These external file references are stored in Redshift proxies both as absolute paths and as relative paths. Let's look at that with an example.
Let's say that a proxy file
proxy.rs is exported in folder
C:\MyProxies and it contains a shader that references texture
mytexture.png which is under
C:\MyProxies\Textures
The folder structre would look like this
|
- [MyProxies]
|
--- proxy.rs
|
--- [Textures]
|
---- mytexture.png
Within the proxy.rs file, the reference to mytexture.png will be saved both as:
- An absolute path filename, i.e
C:\MyProxies\Textures\mytexture.png - A relative path, i.e
.\Textures\mytexture.png
Redshift contains file paths both as absolute and relative in order to facilitate the "transporting" of proxy files and their external references.
To explain with an example: let's say that the above proxy and texture (and their folder structure) were to be copy/pasted on folder
C:\MyOtherProxies and the original
C:\MyProxies folder was deleted.
The absolute path would no longer work because there's no
C:\MyProxies\Textures\mytexture.png file anymore! (we deleted the folder!)
But the relative path would still work! Because, relative to
C:\MyOtherProxies\proxy.rs there would still be a
.\Textures\mytexture.png path.
Now let's consider a proxy file that references a texture folder on a completely different drive! For example:
[C:]
|
- [MyProxies]
|
--- proxy.rs
[D:]
|
- [Textures]
|
---- mytexture.png
Unfortunately, in such a case it's no longer possible to construct a relative path because path
C:\MyProxies\proxy.rs and path D:\Textures\mytexture.png have no common "root"
So, using this folder layout, if the textures were to be moved to a new drive (say, E:\), then the proxy would no longer be able to find them.
In such cases, we recommend using Redshift's path override environment variables
If your texture folder used to be D:\Textures and now it's E:\Textures, you can use the REDSHIFT_PATHOVERRIDE_FILE or REDSHIFT_PATHOVERRIDE_STRING to tell Redshift to turn E:\Textures.
The online documentation page explains how to do that with an example.
If you don't know what external references a proxy might contain, you can use redshiftCmdLine's -printdependencies switch (followed by the proxy's filename) to list these.