It is often desirable and convenient to save some configuration of Nviz for use in other applications. For example, each session of Nviz might require the same set of maps or other attributes. To allow persistence between sessions, Nviz provides tools for saving and loading the current "state" of the system. These tools are accessed using the Load State and Save State options under the File menu.
Save State records the current status of Nviz, including all current maps, color settings, camera viewpoint, and so on into a user designated file. This state file may then be reloaded at a later time and will restore the state of Nviz. Load State queries the user for a state file to load and modifies the state of Nviz according to the state file. Note that Load State does not erase the current state of Nviz when loading a new state. Instead, the current state is augmented according to the contents of the state file. Since this can sometimes cause unexpected results, it is best to either restart Nviz or manually reset the state of Nviz before loading a state file.
State files are particularly useful when creating scripts for animation (see scripting below). In particular, a predefined Nviz state can be loaded automatically into a script by turning on scripting and performing the activity of loading the new state.