pymel.core.system.ogs¶
- ogs(*args, **kwargs)¶
OGS is one of the viewport renderers. As there is a lot of effort involved in migrating functionality it will evolve over several releases. As it evolves it is prudent to provide safeguards to get the database back to a known state. That is the function of this command, similar to how ‘dgdirty’ is used to restore state to the dependency graph.
Flags:
Long Name / Short Name Argument Types Properties deviceInformation / di bool If used then output the current device information. disposeReleasableTextures / drt bool Clear up all the releasable file textures in GPU memory that are not required for rendering. dumpTexture / dt unicode If used then dump GPU texture memory usage info (in MB), must be used with FLAG gpuMemoryUsed. The final info detail is specified by the string parameter. Current available values are: full, total. enableHardwareInstancing / hwi bool Enables/disables new gpu instancing of instanceable render items in OGS. fragmentEditor / fe unicode If used then launch the fragment editor UI. fragmentXML / xml unicode Get the fragment XML associated with a shading node. gpuMemoryUsed / gpu bool If used then output the estimated amount of GPU memory in use (in MB). isLegacyViewportEnabled / lve bool To query if the legacy viewport is enabled. isWinRemoteSession / irs bool Query if this is a remote session. pause / p bool Toggle pausing VP2 display update rebakeTextures / rbt bool If used then re-bake all baked textures for OGS. regenerateUVTilePreview / rup unicode If used then regenerate all UV tiles preview textures for OGS. reloadTextures / rlt bool If used then reload all textures for OGS. reset / r bool If used then reset the entire OGS database for all viewports using it. In query mode the number of viewports that would be affected is returned but the reset is not actually done. If no viewport is using OGS then OGS will stop listening to DG changes. shaderSource / ss unicode Get the shader source for the specified material. toggleTexturePaging / ttp bool If used then toggle the default OGS Texture paging mechanism. traceRenderPipeline / trp bool Enable debug tracing of the renderer pipeline. Flag can have multiple arguments, passed either as a tuple or a list. Derived from mel command maya.cmds.ogs
Example:
import pymel.core as pm // Reset the database for all panels running the OGS renderer. // Returns the number of panels affected. pm.ogs( reset=True ) // Result: [modelPanel1] //