#include <playback_device.h>
Public Member Functions | |
bool | compress_while_record () const override |
bool | contradicts (const stream_profile_interface *a, const std::vector< stream_profile > &others) const override |
std::shared_ptr< matcher > | create_matcher (const frame_holder &frame) const override |
bool | extend_to (rs2_extension extension_type, void **ext) override |
std::shared_ptr< context > | get_context () const override |
rs2_playback_status | get_current_status () const |
platform::backend_device_group | get_device_data () const override |
uint64_t | get_duration () const |
std::pair< uint32_t, rs2_extrinsics > | get_extrinsics (const stream_interface &stream) const override |
const std::string & | get_file_name () const |
uint64_t | get_position () const |
std::vector< tagged_profile > | get_profiles_tags () const override |
sensor_interface & | get_sensor (size_t i) override |
const sensor_interface & | get_sensor (size_t i) const override |
size_t | get_sensors_count () const override |
void | hardware_reset () override |
bool | is_real_time () const |
bool | is_valid () const override |
void | pause () |
playback_device (std::shared_ptr< context > context, std::shared_ptr< device_serializer::reader > serializer) | |
void | resume () |
void | seek_to_time (std::chrono::nanoseconds time) |
void | set_frame_rate (double rate) |
void | set_real_time (bool real_time) |
void | stop () |
void | tag_profiles (stream_profiles profiles) const override |
virtual | ~playback_device () |
Public Member Functions inherited from librealsense::device_interface | |
virtual | ~device_interface ()=default |
Public Member Functions inherited from librealsense::info_interface | |
virtual | ~info_interface ()=default |
Public Member Functions inherited from librealsense::recordable< info_interface > | |
virtual | ~recordable ()=default |
Public Member Functions inherited from librealsense::extendable_interface | |
virtual | ~extendable_interface ()=default |
Public Member Functions inherited from librealsense::info_container | |
void | create_snapshot (std::shared_ptr< info_interface > &snapshot) const override |
void | enable_recording (std::function< void(const info_interface &)> record_action) override |
const std::string & | get_info (rs2_camera_info info) const override |
void | register_info (rs2_camera_info info, const std::string &val) |
bool | supports_info (rs2_camera_info info) const override |
void | update (std::shared_ptr< extension_snapshot > ext) override |
void | update_info (rs2_camera_info info, const std::string &val) |
Public Member Functions inherited from librealsense::extension_snapshot | |
virtual | ~extension_snapshot ()=default |
Static Public Member Functions | |
static bool | try_extend_snapshot (std::shared_ptr< extension_snapshot > &e, rs2_extension extension_type, void **ext) |
Public Attributes | |
signal< playback_device, rs2_playback_status > | playback_status_changed |
Private Member Functions | |
rs2_extrinsics | calc_extrinsic (const rs2_extrinsics &from, const rs2_extrinsics &to) |
device_serializer::nanoseconds | calc_sleep_time (device_serializer::nanoseconds timestamp) |
void | catch_up () |
std::map< uint32_t, std::shared_ptr< playback_sensor > > | create_playback_sensors (const device_serializer::device_snapshot &device_description) |
template<typename T > | |
void | do_loop (T op) |
std::shared_ptr< stream_profile_interface > | get_stream (const std::map< unsigned, std::shared_ptr< playback_sensor >> &sensors_map, device_serializer::stream_identifier stream_id) |
bool | prefetch_done () |
void | register_device_info (const device_serializer::device_snapshot &device_description) |
void | register_extrinsics (const device_serializer::device_snapshot &device_description) |
void | start () |
void | stop_internal () |
void | try_looping () |
void | update_extensions (const device_serializer::device_snapshot &device_description) |
void | update_time_base (device_serializer::nanoseconds base_timestamp) |
Private Attributes | |
std::map< uint32_t, std::shared_ptr< playback_sensor > > | m_active_sensors |
std::chrono::high_resolution_clock::time_point | m_base_sys_time |
device_serializer::nanoseconds | m_base_timestamp |
std::shared_ptr< context > | m_context |
device_serializer::device_snapshot | m_device_description |
std::vector< std::shared_ptr< lazy< rs2_extrinsics > > > | m_extrinsics_fetchers |
std::map< int, std::pair< uint32_t, rs2_extrinsics > > | m_extrinsics_map |
std::atomic_bool | m_is_paused |
std::atomic_bool | m_is_started |
device_serializer::nanoseconds | m_last_published_timestamp |
std::mutex | m_last_published_timestamp_mutex |
device_serializer::nanoseconds | m_prev_timestamp |
lazy< std::shared_ptr< dispatcher > > | m_read_thread |
std::shared_ptr< device_serializer::reader > | m_reader |
std::atomic_bool | m_real_time |
std::atomic< double > | m_sample_rate |
std::map< uint32_t, std::shared_ptr< playback_sensor > > | m_sensors |
Definition at line 17 of file playback_device.h.
playback_device::playback_device | ( | std::shared_ptr< context > | context, |
std::shared_ptr< device_serializer::reader > | serializer | ||
) |
Definition at line 14 of file playback_device.cpp.
|
virtual |
Definition at line 145 of file playback_device.cpp.
|
private |
Definition at line 139 of file playback_device.cpp.
|
private |
Definition at line 373 of file playback_device.cpp.
|
private |
Definition at line 628 of file playback_device.cpp.
|
inlineoverridevirtual |
Implements librealsense::device_interface.
Definition at line 58 of file playback_device.h.
|
inlineoverridevirtual |
Implements librealsense::device_interface.
Definition at line 59 of file playback_device.h.
|
overridevirtual |
Implements librealsense::device_interface.
Definition at line 195 of file playback_device.cpp.
|
private |
Definition at line 48 of file playback_device.cpp.
|
private |
Definition at line 463 of file playback_device.cpp.
|
overridevirtual |
Implements librealsense::extendable_interface.
Definition at line 189 of file playback_device.cpp.
|
overridevirtual |
Implements librealsense::device_interface.
Definition at line 163 of file playback_device.cpp.
rs2_playback_status playback_device::get_current_status | ( | ) | const |
Definition at line 262 of file playback_device.cpp.
|
overridevirtual |
Implements librealsense::device_interface.
Definition at line 351 of file playback_device.cpp.
uint64_t playback_device::get_duration | ( | ) | const |
Definition at line 269 of file playback_device.cpp.
|
overridevirtual |
Implements librealsense::device_interface.
Definition at line 356 of file playback_device.cpp.
const std::string & playback_device::get_file_name | ( | ) | const |
Definition at line 619 of file playback_device.cpp.
uint64_t playback_device::get_position | ( | ) | const |
Definition at line 624 of file playback_device.cpp.
|
inlineoverridevirtual |
Implements librealsense::device_interface.
Definition at line 51 of file playback_device.h.
|
overridevirtual |
Implements librealsense::device_interface.
Definition at line 168 of file playback_device.cpp.
|
overridevirtual |
Implements librealsense::device_interface.
Definition at line 178 of file playback_device.cpp.
|
overridevirtual |
Implements librealsense::device_interface.
Definition at line 173 of file playback_device.cpp.
|
private |
Definition at line 121 of file playback_device.cpp.
|
overridevirtual |
Implements librealsense::device_interface.
Definition at line 184 of file playback_device.cpp.
bool playback_device::is_real_time | ( | ) | const |
Definition at line 346 of file playback_device.cpp.
|
overridevirtual |
Implements librealsense::device_interface.
Definition at line 361 of file playback_device.cpp.
void playback_device::pause | ( | ) |
Definition at line 274 of file playback_device.cpp.
|
private |
Definition at line 512 of file playback_device.cpp.
|
private |
Definition at line 634 of file playback_device.cpp.
|
private |
Definition at line 658 of file playback_device.cpp.
void playback_device::resume | ( | ) |
Definition at line 311 of file playback_device.cpp.
void playback_device::seek_to_time | ( | std::chrono::nanoseconds | time | ) |
Definition at line 218 of file playback_device.cpp.
void playback_device::set_frame_rate | ( | double | rate | ) |
Definition at line 203 of file playback_device.cpp.
void playback_device::set_real_time | ( | bool | real_time | ) |
Definition at line 340 of file playback_device.cpp.
|
private |
Definition at line 406 of file playback_device.cpp.
void playback_device::stop | ( | ) |
Definition at line 426 of file playback_device.cpp.
|
private |
Definition at line 443 of file playback_device.cpp.
|
inlineoverridevirtual |
Implements librealsense::device_interface.
Definition at line 52 of file playback_device.h.
|
static |
Definition at line 686 of file playback_device.cpp.
|
private |
Definition at line 522 of file playback_device.cpp.
|
private |
Definition at line 714 of file playback_device.cpp.
|
private |
Definition at line 366 of file playback_device.cpp.
|
private |
Definition at line 87 of file playback_device.h.
|
private |
Definition at line 84 of file playback_device.h.
|
private |
Definition at line 85 of file playback_device.h.
|
private |
Definition at line 79 of file playback_device.h.
|
private |
Definition at line 81 of file playback_device.h.
|
private |
Definition at line 91 of file playback_device.h.
|
private |
Definition at line 92 of file playback_device.h.
|
private |
Definition at line 83 of file playback_device.h.
|
private |
Definition at line 82 of file playback_device.h.
|
private |
Definition at line 93 of file playback_device.h.
|
private |
Definition at line 94 of file playback_device.h.
|
private |
Definition at line 90 of file playback_device.h.
|
private |
Definition at line 78 of file playback_device.h.
|
private |
Definition at line 80 of file playback_device.h.
|
private |
Definition at line 89 of file playback_device.h.
|
private |
Definition at line 88 of file playback_device.h.
|
private |
Definition at line 86 of file playback_device.h.
signal<playback_device, rs2_playback_status> librealsense::playback_device::playback_status_changed |
Definition at line 45 of file playback_device.h.