open3d.t.io.RealSenseSensor#

class open3d.t.io.RealSenseSensor#

RealSense camera discovery, configuration, streaming and recording

__init__(self: open3d.cpu.pybind.t.io.RealSenseSensor) None#

Initialize with default settings.

capture_frame(self, wait=True, align_depth_to_color=True)#

Acquire the next synchronized RGBD frameset from the camera.

Parameters:
  • wait (bool, optional, default=True) – If true wait for the next frame set, else return immediately with an empty RGBDImage if it is not yet available.

  • align_depth_to_color (bool, optional, default=True) – Enable aligning WFOV depth image to the color image in visualizer.

Returns:

open3d.t.geometry.RGBDImage

static enumerate_devices() List[open3d.cpu.pybind.t.io.RealSenseValidConfigs]#

Query all connected RealSense cameras for their capabilities.

get_filename(self: open3d.cpu.pybind.t.io.RealSenseSensor) str#

Get filename being written.

get_metadata(self: open3d.cpu.pybind.t.io.RealSenseSensor) open3d.cpu.pybind.t.io.RGBDVideoMetadata#

Get metadata of the RealSense video capture.

get_timestamp(self: open3d.cpu.pybind.t.io.RealSenseSensor) int#

Get current timestamp (in us)

init_sensor(*args, **kwargs)#

Overloaded function.

  1. init_sensor(self, sensor_config=<open3d.cpu.pybind.t.io.RealSenseSensorConfig object at 0x7f915d8cc270>, sensor_index=0, filename=’’)

    Configure sensor with custom settings. If this is skipped, default settings will be used. You can enable recording to a bag file by specifying a filename.

Parameters:
  • sensor_config (open3d.io.RGBDSensorConfig, optional, default=<open3d.cpu.pybind.t.io.RealSenseSensorConfig object at 0x7f915d8cc270>) – Camera configuration, such as resolution and framerate. A serial number can be entered here to connect to a specific camera.

  • sensor_index (int, optional, default=0) – Connect to a camera at this position in the enumeration of RealSense cameras that are currently connected. Use enumerate_devices() or list_devices() to obtain a list of connected cameras. This is ignored if sensor_config contains a serial entry.

  • filename (str, optional, default='') – Save frames to a bag file

Returns:

bool

  1. init_sensor(self, sensor_config=<open3d.cpu.pybind.t.io.RealSenseSensorConfig object at 0x7f9145ca4ff0>, sensor_index=0, filename=’’)

    Configure sensor with custom settings. If this is skipped, default settings will be used. You can enable recording to a bag file by specifying a filename.

Parameters:
  • sensor_config (open3d.t.io.RealSenseSensorConfig, optional, default=<open3d.cpu.pybind.t.io.RealSenseSensorConfig object at 0x7f9145ca4ff0>) – Camera configuration, such as resolution and framerate. A serial number can be entered here to connect to a specific camera.

  • sensor_index (int, optional, default=0) – Connect to a camera at this position in the enumeration of RealSense cameras that are currently connected. Use enumerate_devices() or list_devices() to obtain a list of connected cameras. This is ignored if sensor_config contains a serial entry.

  • filename (str, optional, default='') – Save frames to a bag file

Returns:

bool

static list_devices() bool#

List all RealSense cameras connected to the system along with their capabilities. Use this listing to select an appropriate configuration for a camera

pause_record(self: open3d.cpu.pybind.t.io.RealSenseSensor) None#

Pause recording to the bag file. Note: If this is called immediately after start_capture, the bag file may have an incorrect end time.

resume_record(self: open3d.cpu.pybind.t.io.RealSenseSensor) None#

Resume recording to the bag file. The file will contain discontinuous segments.

start_capture(self, start_record=False)#

Start capturing synchronized depth and color frames.

Parameters:

start_record (bool, optional, default=False) – Start recording to the specified bag file as well.

Returns:

bool

stop_capture(self: open3d.cpu.pybind.t.io.RealSenseSensor) None#

Stop capturing frames.