open3d.t.io.RSBagReader

class open3d.t.io.RSBagReader

RealSense Bag file reader.

__init__(*args, **kwargs)

Overloaded function.

  1. __init__(self: open3d.cpu.pybind.t.io.RSBagReader) -> None

  2. __init__(self: open3d.cpu.pybind.t.io.RSBagReader, buffer_size: int = 32) -> None

close(self: open3d.cpu.pybind.t.io.RSBagReader) → None

Close the opened RS bag playback.

static create(filename)

Create RGBD video reader based on filename

Parameters

filename (str) – Path to the RGBD video file.

Returns

open3d.cpu.pybind.t.io.RGBDVideoReader

get_timestamp(self: open3d.cpu.pybind.t.io.RSBagReader) → int

Get current timestamp (in us).

is_eof(self: open3d.cpu.pybind.t.io.RSBagReader) → bool

Check if the RS bag file is all read.

is_opened(self: open3d.cpu.pybind.t.io.RSBagReader) → bool

Check if the RS bag file is opened.

next_frame(self: open3d.cpu.pybind.t.io.RSBagReader) → open3d.cpu.pybind.t.geometry.RGBDImage

Get next frame from the RS bag playback and returns the RGBD object.

open(self, filename)

Open an RS bag playback.

Parameters

filename (str) – Path to the RGBD video file.

Returns

bool

save_frames(self, frame_path, start_time_us=0, end_time_us=18446744073709551615)

Save synchronized and aligned individual frames to subfolders

Parameters
  • frame_path (str) – Frames will be stored in stream subfolders ‘color’ and ‘depth’ here. The intrinsic camera calibration for the color stream will be saved in ‘intrinsic.json’

  • start_time_us (int, optional, default=0) – (default 0) Start saving frames from this time (us)

  • end_time_us (int, optional, default=18446744073709551615) – (default video length) Save frames till this time (us)

Returns

None

seek_timestamp(self, timestamp)

Seek to the timestamp (in us).

Parameters

timestamp (int) – Timestamp in the video (usec).

Returns

bool

property metadata

Get metadata of the RS bag playback.