[isaacsim.core.rendering_manager] Isaac Sim Core Rendering Manager#

Version: 0.4.2

Overview#

The isaacsim.core.rendering_manager extension provides centralized control over rendering operations and viewport management within Isaac Sim. This extension offers programmatic APIs for executing rendering steps, managing rendering timing, and controlling viewport configurations including camera settings and window management.

Key Components#

RenderingManager#

RenderingManager provides core rendering control and timing management. The class handles synchronous and asynchronous rendering operations, allowing applications to trigger frame updates without advancing simulation or physics systems.

The set_dt method configures the application’s coherent dt across the run loop, timeline (targetFramerate and timeCodesPerSecond), and Isaac loop runner’s manual-mode step size. It does not modify the physics scene’s timeStepsPerSecond; for that, pair the call with SimulationManager.setup_simulation at the same dt.

from isaacsim.core.rendering_manager import RenderingManager
from isaacsim.core.simulation_manager import SimulationManager

# Coherent 120 Hz setup (loop, timeline, and physics aligned)
SimulationManager.setup_simulation(dt=1 / 120.0)
RenderingManager.set_dt(1 / 120.0)

# Trigger a single render frame
RenderingManager.render()

Event System#

The callback registration system enables applications to subscribe to rendering events. The RenderingEvent enum defines available event types, with NEW_FRAME being the primary event for frame-based operations. Callbacks can be registered with specific execution order to ensure proper sequencing of dependent operations.

from isaacsim.core.rendering_manager import RenderingEvent, RenderingManager

def frame_callback(event, *args, **kwargs):
    print(f"Frame rendered: {event}")

# Register callback for new frame events
callback_id = RenderingManager.register_callback(
    RenderingEvent.NEW_FRAME,
    callback=frame_callback,
    order=10
)

ViewportManager#

ViewportManager provides comprehensive viewport and camera control capabilities. The manager handles viewport window creation, camera assignment, resolution management, and viewport synchronization operations.

Camera management supports both built-in Omniverse Kit cameras (Perspective, Top, Front, Right views) and custom USD Camera prims. The system maintains proper camera-to-viewport associations and handles camera view transformations.

from isaacsim.core.rendering_manager import ViewportManager

# Create a custom viewport window
window = ViewportManager.create_viewport_window(
    title="Custom View",
    resolution=(1920, 1080),
    camera="/OmniverseKit_Top"
)

# Set camera view to look at specific target
ViewportManager.set_camera_view(
    camera=ViewportManager.get_camera(),
    eye=[5.0, 5.0, 5.0],
    target=[0.0, 0.0, 0.0]
)

Viewport Synchronization#

The viewport waiting system ensures proper frame readiness before operations. Both synchronous and asynchronous waiting methods allow applications to coordinate with viewport rendering cycles, preventing race conditions when capturing frames or performing viewport-dependent operations.

# Wait for viewport to be ready for capture
ready, frames_waited = ViewportManager.wait_for_viewport(max_frames=60)
if ready:
    # Perform viewport-dependent operations
    pass

Functionality#

Resolution and Display Control#

ViewportManager handles dynamic resolution changes for both individual viewports and render products. The system supports programmatic resolution updates while maintaining proper aspect ratios and render target configurations.

Multi-Viewport Management#

The extension supports creating and managing multiple viewport windows simultaneously. Viewport windows can be filtered, destroyed, and configured independently, enabling complex multi-view applications and debugging scenarios.

USD Integration#

Deep integration with USD render products and camera prims enables seamless interaction with the USD stage pipeline. The system automatically handles USD prim relationships and maintains proper render product configurations.

Enable Extension#

The extension can be enabled (if not already) in one of the following ways:

Define the next entry as an application argument from a terminal.

APP_SCRIPT.(sh|bat) --enable isaacsim.core.rendering_manager

Define the next entry under [dependencies] in an experience (.kit) file or an extension configuration (extension.toml) file.

[dependencies]
"isaacsim.core.rendering_manager" = {}

Open the Window > Extensions menu in a running application instance and search for isaacsim.core.rendering_manager. Then, toggle the enable control button if it is not already active.

Python API#

RenderingEvent

Rendering event types.

RenderingManager

Core class that provides APIs for controlling rendering.

ViewportManager

Core class that provides APIs for managing viewports.


class RenderingEvent(
value,
names=<not given>,
*values,
module=None,
qualname=None,
type=None,
start=1,
boundary=None,
)#

Rendering event types.

NEW_FRAME = 'isaacsim.rendering.new_frame'#

Event triggered when a new frame is rendered.

class RenderingManager#

Bases: object

Core class that provides APIs for controlling rendering.

classmethod deregister_all_callbacks() None#

Deregister all callbacks registered via register_callback().

Example:

>>> from isaacsim.core.rendering_manager import RenderingManager
>>>
>>> RenderingManager.deregister_all_callbacks()
classmethod deregister_callback(uid: int) None#

Deregister a callback registered via register_callback().

Parameters:

uid – The unique identifier of the callback to deregister. If the unique identifier does not exist or has already been deregistered, a warning is logged and the method does nothing.

Example:

>>> from isaacsim.core.rendering_manager import RenderingManager
>>>
>>> # deregister the callback with the unique identifier 0
>>> RenderingManager.deregister_callback(0)
classmethod get_dt() float#

Get the application’s currently-configured dt.

Reads from one of two sources, in priority order:

  1. If /app/runLoops/main/rateLimitEnabled is true, returns 1 / /app/runLoops/main/rateLimitFrequency.

  2. Otherwise, if the Isaac loop runner is in manual mode, returns its manual_step_size.

  3. As a final fallback, returns 1 / /app/runLoops/main/rateLimitFrequency even though the rate-limit isn’t enabled (the value may not actually be in effect).

Note that this returns the loop / timeline dt, not the physics scene’s physics_dt; for that use isaacsim.core.simulation_manager.PhysicsScene.get_dt().

Returns:

Application dt in seconds.

Example:

>>> from isaacsim.core.rendering_manager import RenderingManager
>>>
>>> RenderingManager.get_dt()
0.0166666...
classmethod register_callback(
event: RenderingEvent,
*,
callback: callable,
order: int = 0,
) int#

Register/subscribe a callback to be triggered when a specific rendering event occurs.

Parameters:
  • event – The rendering event to subscribe to.

  • callback – The callback function.

  • order – The subscription order. Callbacks registered within the same order will be triggered in the order they were registered.

Returns:

The unique identifier of the callback subscription.

Raises:
  • ValueError – If the rendering event is not supported.

  • RuntimeError – If unable to register the callback.

Example:

>>> from isaacsim.core.rendering_manager import RenderingEvent, RenderingManager
>>>
>>> def callback(event, *args, **kwargs):
...     print(event)
...
>>> # subscribe to the NEW_FRAME event
>>> callback_id = RenderingManager.register_callback(RenderingEvent.NEW_FRAME, callback=callback)
>>> callback_id
0
>>> # perform a rendering step in order to trigger the callback and print the event
>>> RenderingManager.render()  
<carb.eventdispatcher._eventdispatcher.Event object at 0x...>
>>>
>>> # deregister all callbacks
>>> RenderingManager.deregister_all_callbacks()
classmethod render() None#

Render the stage.

This method performs an app update without stepping the simulation or physics.

Example:

>>> from isaacsim.core.rendering_manager import RenderingManager
>>>
>>> RenderingManager.render()
async classmethod render_async() None#

Render the stage.

This method is the asynchronous version of render().

classmethod set_dt(dt: float) None#

Set the application’s coherent dt across the run loop, timeline, and loop runner.

Sets the following, in order:

  1. If ``/app/runLoops/main/rateLimitEnabled`` is already true, writes /app/runLoops/main/rateLimitFrequency = 1/dt and calls timeline.set_target_framerate(1/dt). If rate-limit is not already enabled, this step is skipped and the app continues to run unthrottled - this method does not enable rate-limiting on its own.

  2. Writes stage.SetTimeCodesPerSecond(1/dt) to the root layer and timeline.set_time_codes_per_second(1/dt). This is the value the timeline uses as its per-tick dt whenever /app/player/useFixedTimeStepping is true (the default in the full Isaac Sim GUI).

  3. Calls loop_runner.set_manual_step_size(dt) and loop_runner.set_manual_mode(True) on the Isaac loop runner, so the loop dispatches a fixed dt instead of the wall-clock measured value (relevant when useFixedTimeStepping is false, e.g. standalone Python). If the Isaac loop runner is not available, falls back to enabling the carb rate-limit (rateLimitEnabled = True) and writing rateLimitFrequency / timeline.set_target_framerate regardless of the prior rateLimitEnabled value.

  4. Writes the Fabric default simulation-period numerator/denominator carb settings from dt. These are read by Fabric SimStageWithHistory instances created after this call; existing histories are not updated.

This does not modify the physics scene’s timeStepsPerSecond attribute - use isaacsim.core.simulation_manager.SimulationManager.setup_simulation() for that. For real-time playback at a chosen rate, call both APIs with the same dt.

Parameters:

dt – Application dt in seconds (e.g. 1.0 / 60 for 60 Hz).

Raises:

ValueError – If dt is not positive.

Example:

>>> from isaacsim.core.rendering_manager import RenderingManager
>>>
>>> RenderingManager.set_dt(1 / 120.0)  # 120 Hz
kit_loop = <module 'omni.kit.loop.bindings._loop' from '/_build/linux-x86_64/release/exts/omni.kit.loop-isaac/omni/kit/loop/bindings/_loop.cpython-312-x86_64-linux-gnu.so'>#
class ViewportManager#

Bases: object

Core class that provides APIs for managing viewports.

classmethod create_viewport_window(
*,
camera: str | Usd.Prim | UsdGeom.Camera = '/OmniverseKit_Persp',
title: str | None = None,
resolution: tuple[int, int] = (1280, 720),
) ViewportWindow#

Create a viewport window.

Parameters:
  • camera – The camera to use for the viewport. If not provided, the default (perspective) camera is used.

  • title – The viewport window title (name). If not provided, a default title is generated.

  • resolution – The viewport window resolution: (width, height).

Returns:

The viewport window (as a proxy).

Example:

>>> from isaacsim.core.rendering_manager import ViewportManager
>>> import isaacsim.core.experimental.utils.stage as stage_utils
>>>
>>> # create a viewport window with the default camera and resolution
>>> window = ViewportManager.create_viewport_window()
>>> window.title
'Viewport 1'
>>> window.viewport_api.camera_path
Sdf.Path('/OmniverseKit_Persp')
>>>
>>> # create a viewport window with a custom camera and resolution
>>> camera = stage_utils.define_prim("/Camera", "Camera")
>>> window = ViewportManager.create_viewport_window(
...     camera=camera,
...     resolution=(640, 480),
...     title="Custom Viewport",
... )
>>> window.title
'Custom Viewport'
>>> window.viewport_api.camera_path
Sdf.Path('/Camera')
>>> window.viewport_api.resolution
(640, 480)
classmethod destroy_viewport_windows(
*,
include: list[str] | None = None,
exclude: list[str] | None = None,
) list[str]#

Destroy viewport windows.

Parameters:
  • include – Viewport window titles (names) to destroy. If not provided, all viewport windows will be destroyed. Regular expressions are supported.

  • exclude – Viewport window titles (names) to exclude from destruction. Excluded names take precedence over included names. Regular expressions are supported.

Returns:

List of destroyed viewport window titles (names).

Example:

>>> from isaacsim.core.rendering_manager import ViewportManager
>>>
>>> # given the following viewport windows: "Viewport", "Viewport 1", and "Custom Viewport",
>>> # destroy all viewport windows except the default one: "Viewport"
>>> ViewportManager.destroy_viewport_windows(exclude=["Viewport"])
['Viewport 1', 'Custom Viewport']
classmethod get_camera(
render_product_or_viewport: str | Usd.Prim | UsdRender.Product | 'ViewportAPI' | None = None,
) UsdGeom.Camera#

Get a render product or viewport’s camera.

Parameters:

render_product_or_viewport – The render product or viewport to get the camera from. If not provided, the active viewport is used.

Returns:

USD Camera prim.

Raises:
  • ValueError – Invalid render product or viewport.

  • ValueError – No camera prim target found for a given render product.

Example:

>>> from isaacsim.core.rendering_manager import ViewportManager
>>>
>>> # get the camera of the active viewport
>>> ViewportManager.get_camera()
UsdGeom.Camera(Usd.Prim(</OmniverseKit_Persp>))
classmethod get_render_product(
render_product_or_viewport: str | Usd.Prim | UsdRender.Product | 'ViewportAPI' | None = None,
) UsdRender.Product | None#

Get an USD RenderProduct prim that describes an artifact produced by a render.

Supported sources are:

Source

Return value

Unspecified (default)

The active viewport’s render product

ViewportAPI instance

The given viewport’s render product

UsdRender.Product prim instance

The given prim instance

USD RenderProduct prim path

The UsdRender.Product prim at the given path

Viewport window title (name)

The given viewport window’s render product

Parameters:

render_product_or_viewport – The render product or viewport to get the USD RenderProduct prim from. If not provided, the active viewport is used.

Returns:

USD RenderProduct prim, or None if no render product is found.

Example:

>>> from isaacsim.core.rendering_manager import ViewportManager
>>>
>>> # get render product from the active viewport
>>> ViewportManager.get_render_product()
UsdRender.Product(Usd.Prim(</Render/OmniverseKit/HydraTextures/omni_kit_widget_viewport_ViewportTexture_0>))
>>>
>>> # get render product from a viewport API
>>> viewport_api = ViewportManager.get_viewport_api()
>>> ViewportManager.get_render_product(viewport_api)
UsdRender.Product(Usd.Prim(</Render/OmniverseKit/HydraTextures/omni_kit_widget_viewport_ViewportTexture_0>))
>>>
>>> # get render product from a USD RenderProduct prim path
>>> path = "/Render/OmniverseKit/HydraTextures/omni_kit_widget_viewport_ViewportTexture_0"
>>> ViewportManager.get_render_product(path)
UsdRender.Product(Usd.Prim(</Render/OmniverseKit/HydraTextures/omni_kit_widget_viewport_ViewportTexture_0>))
>>>
>>> # get render product from a viewport window
>>> ViewportManager.get_render_product("Viewport")
UsdRender.Product(Usd.Prim(</Render/OmniverseKit/HydraTextures/omni_kit_widget_viewport_ViewportTexture_0>))
classmethod get_resolution(
render_product_or_viewport: str | Usd.Prim | UsdRender.Product | 'ViewportAPI' | None = None,
) tuple[int, int]#

Get a render product or viewport’s resolution: width x height.

Parameters:

render_product_or_viewport – The render product or viewport to get the resolution from. If not provided, the active viewport is used. See get_viewport_api() or get_render_product() for supported sources.

Returns:

Resolution as a tuple of width and height.

Example:

>>> from isaacsim.core.rendering_manager import ViewportManager
>>>
>>> ViewportManager.get_resolution()
(1280, 720)
classmethod get_viewport_api(
render_product_or_viewport: str | Usd.Prim | UsdRender.Product | 'ViewportAPI' | None = None,
) 'ViewportAPI' | None#

Get a viewport API (also identified as viewport) instance.

Supported sources are:

Source

Return value

Unspecified (default)

The active viewport window’s viewport API instance

ViewportAPI instance

The given viewport API instance

Viewport window title (name)

The given viewport window’s viewport API instance

Parameters:

render_product_or_viewport – The render product or viewport to get the viewport API from. If not provided, the active viewport window is used.

Returns:

Viewport API instance (as a proxy), or None if no viewport API is found.

Example:

>>> from isaacsim.core.rendering_manager import ViewportManager
>>>
>>> # get viewport API from the active viewport window
>>> ViewportManager.get_viewport_api()
<weakproxy at 0x... to ViewportAPI at 0x...>
>>>
>>> # get viewport API from a viewport window
>>> ViewportManager.get_viewport_api("Viewport")
<weakproxy at 0x... to ViewportAPI at 0x...>
classmethod get_viewport_windows(
*,
include: list[str] | None = None,
exclude: list[str] | None = None,
) list#

Get viewport windows.

Parameters:
  • include – Viewport window titles (names) to get. If not provided, all viewport windows will be included. Regular expressions are supported.

  • exclude – Viewport window titles (names) to exclude from getting. Excluded names take precedence over included names. Regular expressions are supported.

Returns:

List of viewport windows (as proxies).

Example:

>>> from isaacsim.core.rendering_manager import ViewportManager
>>>
>>> # get all viewport windows
>>> windows = ViewportManager.get_viewport_windows()
>>> windows
[<weakproxy at 0x... to ViewportWindow at 0x...>]
>>> windows[0].title
'Viewport'
>>> windows[0].viewport_api.camera_path
Sdf.Path('/OmniverseKit_Persp')
>>> windows[0].viewport_api.resolution
(1280, 720)
classmethod set_camera(
camera: str | Usd.Prim | UsdGeom.Camera,
*,
render_product_or_viewport: str | Usd.Prim | UsdRender.Product | 'ViewportAPI' | None = None,
) None#

Set a render product or viewport’s camera.

Available Omniverse Kit cameras:#

Camera view

USD path (on session layer)

Perspective view

/OmniverseKit_Persp

Top view

/OmniverseKit_Top

Front view

/OmniverseKit_Front

Right view

/OmniverseKit_Right

Parameters:
  • camera – The camera to set.

  • render_product_or_viewport – The render product or viewport to set the camera for. If not provided, the active viewport is used. See get_viewport_api() or get_render_product() for supported sources.

Raises:
  • ValueError – Invalid camera.

  • ValueError – Invalid render product or viewport.

Example:

>>> import isaacsim.core.experimental.utils.stage as stage_utils
>>> from isaacsim.core.rendering_manager import ViewportManager
>>>
>>> # set the active viewport's camera to the top view
>>> ViewportManager.set_camera("/OmniverseKit_Top")
>>>
>>> # set the active viewport's camera to a custom camera
>>> camera = stage_utils.define_prim("/Camera", "Camera")
>>> ViewportManager.set_camera(camera)
classmethod set_camera_view(
camera: str | Usd.Prim | UsdGeom.Camera,
*,
eye: list | np.ndarray | wp.array | None = None,
target: list | np.ndarray | wp.array | None = None,
relative_tracking: bool = False,
) None#

Set the camera view.

This method sets the camera view by adjusting its position and orientation, while taking into account the camera’s center of interest (COI) attribute: omni:kit:centerOfInterest, if it exists.

Depending on the forwarded arguments and the existence of the COI attribute, the camera view is adjusted as follows:

COI

eye

target

Behavior

no

no

no

The camera’s view will not change. A warning will be logged.

no

no

yes

The camera remains in place but rotates to face the target.

no

yes

no

The camera teleports to the eye while keeping its orientation.

no

yes

yes

The camera teleports to the eye and rotates to face the target.

yes

no

no

The camera remains in place but rotates to face the COI.

yes

no

yes

The relative_tracking flag determines the behavior:

  • If relative_tracking is False (default), the camera remains in place but rotates to face the target. The COI is updated to the target value.

  • If relative_tracking is True, the camera teleports to face the target, while keeping the same orientation and distance relative to the COI. The COI is updated to the target value.

yes

yes

no

The camera teleports to the eye and rotates to face the COI.

yes

yes

yes

The camera teleports to the eye and rotates to face the target. The COI is updated to the target value.

Parameters:
  • camera – The camera path or instance.

  • eye – The eye position (position of the camera in the world frame).

  • target – The target position (position of the target to look at in the world frame).

  • relative_tracking – Whether to track the target relative to the current camera position.

Raises:

ValueError – The camera is not a valid USD Camera prim.

Example:

>>> from isaacsim.core.rendering_manager import ViewportManager
>>>
>>> # set the active viewport's camera view to look at a target at (1.0, 2.0, 3.0)
>>> camera = ViewportManager.get_camera()
>>> ViewportManager.set_camera_view(camera, target=[1.0, 2.0, 3.0])  
classmethod set_resolution(
resolution: tuple[int, int] | str,
*,
render_product_or_viewport: str | Usd.Prim | UsdRender.Product | 'ViewportAPI' | None = None,
) None#

Set a render product or viewport’s resolution: width x height.

Parameters:
  • resolution – The resolution as a tuple of width and height.

  • render_product_or_viewport – The render product or viewport to set the resolution for. If not provided, the active viewport is used. See get_viewport_api() or get_render_product() for supported sources.

Raises:

ValueError – Invalid render product or viewport.

Example:

>>> from isaacsim.core.rendering_manager import ViewportManager
>>>
>>> # set the active viewport's resolution to (640, 480)
>>> ViewportManager.set_resolution((640, 480))
>>>
>>> # check the resolution
>>> ViewportManager.get_resolution()
(640, 480)
>>> ViewportManager.get_viewport_api().resolution
(640, 480)
classmethod wait_for_viewport(
*,
viewport: str | 'ViewportAPI' | None = None,
max_frames: int = 60,
sleep_time: float = 0.02,
) tuple[bool, int]#

Wait for the viewport to be ready.

Calling this method ensures that a new frame is rendered by the viewport during an app update (or rendering step).

Parameters:
  • viewport – The viewport to wait for. If not provided, the active viewport is used. See get_viewport_api() for supported viewport sources.

  • max_frames – The maximum number of frames to wait for.

  • sleep_time – Time, in seconds, to sleep between frames. Setting a positive value reduces the number of frames required for the viewport to be ready.

Returns:

A tuple containing a boolean indicating whether the viewport is ready and the number of frames waited for.

Example:

>>> from isaacsim.core.rendering_manager import ViewportManager
>>>
>>> ViewportManager.wait_for_viewport()
(True, 0)
async classmethod wait_for_viewport_async(
*,
viewport: str | 'ViewportAPI' | None = None,
max_frames: int = 60,
sleep_time: float = 0.02,
) tuple[bool, int]#

Wait for the viewport to be ready.

This method is the asynchronous version of wait_for_viewport().

Parameters:
  • viewport – The viewport to wait for. If not provided, the active viewport is used. See get_viewport_api() for supported viewport sources.

  • max_frames – The maximum number of frames to wait for.

  • sleep_time – Time, in seconds, to sleep between frames. Setting a positive value reduces the number of frames required for the viewport to be ready.

Returns:

A tuple containing a boolean indicating whether the viewport is ready and the number of frames waited for.