The Reference Editor provides two methods for substituting file references within the parent scene. Each method has its advantages and limitations.
The Replace Reference command opens a file browser to replace the current reference with another you select. The group node and/or locator remains the same. Any edits that exist for the file reference at the parent scene level will be applied to the substituted file reference because the reference node is not modified. While this works well in situations where the file reference being substituted has exactly the same node names and DAG hierarchy as the original file reference, it has limited applications. If the node names and DAG hierarchy are not identical, you may encounter errors when Maya tries to apply the reference edits to the substituted reference and data loss could result. Maya doesn’t track the substitutions that occur when using the Replace Reference command and is not recommended when nested file references exist in the referencing hierarchy.
Proxy References allow you to substitute one or more file references by creating a set of possible substitute references (proxies) for a given file reference. A new node is created to keep track of the multiple proxies. Proxy references let you globally substitute many proxy references at a time by selecting the proxy references and reloading them based on their proxy tag. This is advantageous when you quickly need to substitute from a low resolution version of the scene to a high resolution version, and vice versa.
If you want to share animation between proxy references for a particular file reference you must ensure that a state of equivalency exists between the various proxy files for a particular file reference and their parent scene. That is, when you keyframe within the parent scene, you want to ensure that the animation can be applied to the correct nodes regardless of which proxy file is loaded. To achieve this equivalency, the proxy files must be set up as follows:
When rendering a scene that contains file and proxy references, only the currently loaded file and proxy references will render in the image unless you specify otherwise. You must ensure you load any references you want to appear in the rendering prior to rendering. You can switch proxies for the purposes of rendering using Pre Render MEL and Post Render MEL scripts.
For example, a low resolution proxy is currently displayed in the scene and needs to be switched to the high resolution version prior to rendering and then back to the low resolution version after the rendering is complete. By determining the name of the proxy manager in the Reference Editor, you can then determine the names of the related proxy set nodes for each proxy, and then create a simple script for switching between the low and high resolution versions of the proxies before and after rendering.
The following workflow describes one method for switching between proxy references before and after rendering:
//switch to the high res version
proxySwitch treeRN;
//switch to the low res version
proxySwitch treeloRN;
Except where otherwise noted, this work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported License