Skip to content

Commit

Permalink
Disable time_diff_keeper for playback devices.
Browse files Browse the repository at this point in the history
  • Loading branch information
doronhi committed May 15, 2019
1 parent 8391341 commit d7f964b
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 5 deletions.
5 changes: 4 additions & 1 deletion src/ds5/ds5-device.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -618,7 +618,10 @@ namespace librealsense
});
notification_thread.detach();
}
_tf_keeper->start();
if (dynamic_cast<const platform::playback_backend*>(&(ctx->get_backend())) == nullptr)
_tf_keeper->start();
else
LOG_WARNING("playback_backend - global time_keeper unavailable.");
}

notification ds5_notification_decoder::decode(int value)
Expand Down
5 changes: 4 additions & 1 deletion src/l500/l500-device.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,10 @@ namespace librealsense
register_info(RS2_CAMERA_INFO_DEBUG_OP_CODE, std::to_string(static_cast<int>(fw_cmd::GLD)));
register_info(RS2_CAMERA_INFO_PHYSICAL_PORT, group.uvc_devices.front().device_path);
register_info(RS2_CAMERA_INFO_PRODUCT_ID, pid_hex_str);
_tf_keeper->start();
if (dynamic_cast<const platform::playback_backend*>(&(ctx->get_backend())) == nullptr)
_tf_keeper->start();
else
LOG_WARNING("playback_backend - global time_keeper unavailable.");
}

std::shared_ptr<uvc_sensor> l500_device::create_depth_device(std::shared_ptr<context> ctx,
Expand Down
3 changes: 0 additions & 3 deletions unit-tests/unit-tests-common.h
Original file line number Diff line number Diff line change
Expand Up @@ -213,9 +213,6 @@ inline void disable_sensitive_options_for(rs2::sensor& sen)
REQUIRE_NOTHROW(range = sen.get_option_range(RS2_OPTION_EXPOSURE)); // TODO: fails sometimes with "Element Not Found!"
REQUIRE_NOTHROW(sen.set_option(RS2_OPTION_EXPOSURE, range.def));
}

if (sen.supports(RS2_OPTION_GLOBAL_TIME_ENABLED))
REQUIRE_NOTHROW(sen.set_option(RS2_OPTION_GLOBAL_TIME_ENABLED, 0));
}

inline void disable_sensitive_options_for(rs2::device& dev)
Expand Down

0 comments on commit d7f964b

Please sign in to comment.