ViewportOpenGLSceneView#
- class omni.kit.scene_view.opengl.ViewportOpenGLSceneView(viewport_api, *args, **kwargs)#
Bases:
OpenGLSceneViewMethods
__init__(viewport_api, *args, **kwargs)Construct a ViewportOpenGLSceneView instance that will draw the scene with OpenGL clipped against a Viewport's render
create_in_viewport_window(viewport_window, ...)Helper staticmethod to create a ViewportOpenGLSceneView into a ViewportWindow
destroy(self)Removes all the callbacks and circular references.
Attributes
- __init__(viewport_api, *args, **kwargs)#
Construct a ViewportOpenGLSceneView instance that will draw the scene with OpenGL clipped against a Viewport’s render
- Parameters:
viewport_api – ViewportAPI The ViewportAPI to attach the ViewportOpenGLSceneView to
*arg – Additional arguments to pass to OpenGLSceneView constructor
**kwargs – Additional keyword arguments to pass to OpenGLSceneView constructor
- static create_in_viewport_window(
- viewport_window,
- frame_name: str,
- build_fn,
- *args,
- **kwargs,
Helper staticmethod to create a ViewportOpenGLSceneView into a ViewportWindow
- Parameters:
viewport_window – ViewportWindow The ViewportWindow to add the ViewportOpenGLSceneView into
frame_name – str Unique identifier for the parent frame
build_fn – Callable(gl_scene_view: ViewportOpenGLSceneView) Optional callback to use with parent frame’s build_fn
\*args – Additional positional arguments to pass to ViewportOpenGLSceneView constructor
**kwargs – Additional keyword arguments to pass to ViewportOpenGLSceneView constructor
- destroy(self: omni.ui._ui.Widget) None#
Removes all the callbacks and circular references.