Settings
- class omni.graph.core.Settings(VERSION: str = '/persistent/omnigraph/settingsVersion', UPDATE_MESH_TO_HYDRA: str = '/persistent/omnigraph/updateMeshPointsToHydra', PLAY_COMPUTE_GRAPH: str = '/app/player/playComputegraph', OPTIMIZE_GENERATED_PYTHON: str = '/persistent/omnigraph/generator/pyOptimize', ENABLE_PATH_CHANGED_CALLBACK: str = '/persistent/omnigraph/enablePathChangedCallback', DEPRECATIONS_ARE_ERRORS: str = '/persistent/omnigraph/deprecationsAreErrors')
Bases:
object
Class that packages up all of the OmniGraph settings handling into a common location. The settings themselves are handled through the Carbonite settings ABI, this just provides a nicer and more focused interface. Values here should also be reflected in the C++ OmniGraphSettings class.
Methods
__init__
([VERSION, UPDATE_MESH_TO_HYDRA, ...])Return the generator settings object corresponding to the current carb settings
temporary
(setting_name[, setting_value])Generator to temporarily use a new setting value
Attributes
Control whether or not similar graph should be merged together as instances in order to allow vectorized compute
Modify deprecation paths to raise errors or exceptions instead of logging warnings.
Disable all processing of info-only notices by OG.
Enable the deprecated Node.pathChangedCallback.
Optimize the Python code being output by the node generator
Evaluate OmniGraph when the Kit 'Play' button is pressed
Update mesh points directly to Hydra
Version number of these settings
- __init__(VERSION: str = '/persistent/omnigraph/settingsVersion', UPDATE_MESH_TO_HYDRA: str = '/persistent/omnigraph/updateMeshPointsToHydra', PLAY_COMPUTE_GRAPH: str = '/app/player/playComputegraph', OPTIMIZE_GENERATED_PYTHON: str = '/persistent/omnigraph/generator/pyOptimize', ENABLE_PATH_CHANGED_CALLBACK: str = '/persistent/omnigraph/enablePathChangedCallback', DEPRECATIONS_ARE_ERRORS: str = '/persistent/omnigraph/deprecationsAreErrors') None
- static generator_settings() Settings
Return the generator settings object corresponding to the current carb settings
- Returns
Current settings object used by the code generator
- Return type
omni.graph.tools.Settings
- static temporary(setting_name: Union[str, List[Tuple[str, Any]], Dict[str, Any]], setting_value: Any = None)
Generator to temporarily use a new setting value
- Parameters
setting_name – A string containing the path to the setting (e.g. “/persistent/omnigraph/deprecationsAreErrors”) or a list of tuples containing setting name and value pairs.
setting_value – New value for the setting. ‘None’ is not a valid setting value and will generate a warning. Ignored if ‘setting_name’ is a list.
If a setting does not yet exist it will be created at context entry and removed at context exit.
Examples
with og.Settings.temporary(og.Settings.AUTO_INSTANCING_ENABLED, True): do_something_with_auto_instancing() with og.Settings.temporary([("/MySettings/debug", True), (og.Settings.DEPRECATIONS_ARE_ERRORS, False)]): do_something_with_deprecations_as_errors_disabled()
- AUTO_INSTANCING_ENABLED = '/persistent/omnigraph/autoInstancingEnabled'
Control whether or not similar graph should be merged together as instances in order to allow vectorized compute
- DEPRECATIONS_ARE_ERRORS: str = '/persistent/omnigraph/deprecationsAreErrors'
Modify deprecation paths to raise errors or exceptions instead of logging warnings.
- DISABLE_INFO_NOTICE_HANDLING_IN_PLAYBACK = '/persistent/omnigraph/disableInfoNoticeHandlingInPlayback'
Disable all processing of info-only notices by OG. This is an optimization for applications which do not require any triggering of OG via USD (value_changed and path_changed callbacks, lazy-graph etc
- ENABLE_PATH_CHANGED_CALLBACK: str = '/persistent/omnigraph/enablePathChangedCallback'
Enable the deprecated Node.pathChangedCallback. This will affect performance.
- OPTIMIZE_GENERATED_PYTHON: str = '/persistent/omnigraph/generator/pyOptimize'
Optimize the Python code being output by the node generator
- PLAY_COMPUTE_GRAPH: str = '/app/player/playComputegraph'
Evaluate OmniGraph when the Kit ‘Play’ button is pressed
- UPDATE_MESH_TO_HYDRA: str = '/persistent/omnigraph/updateMeshPointsToHydra'
Update mesh points directly to Hydra
- VERSION: str = '/persistent/omnigraph/settingsVersion'
Version number of these settings