mirror of
https://gitlab.freedesktop.org/monado/monado.git
synced 2024-12-28 18:46:18 +00:00
t/c/builder_lighthouse: Fail more clearly when cameras aren't available
This commit is contained in:
parent
4c55364d95
commit
0f40a4be8f
|
@ -638,8 +638,21 @@ lighthouse_open_system(struct xrt_builder *xb,
|
|||
lhs.vive_tstatus.hand_enabled = false;
|
||||
}
|
||||
|
||||
|
||||
|
||||
bool success = true;
|
||||
|
||||
if (hmd_config == NULL) {
|
||||
// This should NEVER happen, but we're not writing Rust.
|
||||
U_LOG_E("Didn't get a vive config? Not creating visual trackers.");
|
||||
goto end;
|
||||
}
|
||||
if (!hmd_config->cameras.valid) {
|
||||
U_LOG_I(
|
||||
"HMD didn't have cameras or didn't have a valid camera calibration. Not creating visual trackers.");
|
||||
goto end;
|
||||
}
|
||||
|
||||
struct xrt_slam_sinks sinks = {0};
|
||||
struct xrt_device *hand_devices[2] = {NULL};
|
||||
success = setup_visual_trackers(usysd, xp, hmd_config, &sinks, hand_devices);
|
||||
|
|
Loading…
Reference in a new issue