mirror of
https://gitlab.freedesktop.org/monado/monado.git
synced 2025-01-01 12:46:12 +00:00
drivers: Improve word choice/clarity
This commit is contained in:
parent
93a2391767
commit
6706180cd8
|
@ -334,7 +334,6 @@ depthai_do_one_frame(struct depthai_fs *depthai)
|
|||
auto nano = std::chrono::duration_cast<std::chrono::duration<int64_t, std::nano>>(duration);
|
||||
uint64_t timestamp_ns = nano.count();
|
||||
|
||||
// Sanity check.
|
||||
if (num >= ARRAY_SIZE(depthai->sink)) {
|
||||
DEPTHAI_ERROR(depthai, "Instance number too large! (%u)", num);
|
||||
return;
|
||||
|
|
|
@ -155,7 +155,7 @@ hdk_device_update(struct hdk_device *hd)
|
|||
|
||||
// HDMI status only valid in reports version 3.
|
||||
// Expecting either version 1 (100Hz) or 3 (400Hz):
|
||||
// https://github.com/OSVR/OSVR-HDK-MCU-Firmware/blob/master/Source%20code/Embedded/src/DeviceDrivers/BNO070_using_hostif.c#L511
|
||||
// https://github.com/OSVR/OSVR-HDK-MCU-Firmware/blob/main/Source%20code/Embedded/src/DeviceDrivers/BNO070_using_hostif.c#L511
|
||||
|
||||
// Next byte is sequence number, ignore
|
||||
buf++;
|
||||
|
@ -191,7 +191,7 @@ hdk_device_update(struct hdk_device *hd)
|
|||
|
||||
// This is in the "world" coordinate system.
|
||||
|
||||
// Note that we must "rotate" this velocity by the first transform above
|
||||
// Note that we must "rotate" this velocity by the first transform from earlier
|
||||
// (90 about x), hence putting it in a pure quat.
|
||||
struct xrt_quat ang_vel_quat;
|
||||
ang_vel_quat.x = fromFixedPoint<6, 9>(hdk_get_le_int16(buf));
|
||||
|
|
|
@ -376,7 +376,7 @@ hydra_system_enter_motion_control(struct hydra_system *hs, timepoint_ns now)
|
|||
|
||||
os_hid_set_feature(hs->command_hid, HYDRA_REPORT_START_MOTION, sizeof(HYDRA_REPORT_START_MOTION));
|
||||
|
||||
// Doing a dummy get-feature now.
|
||||
// Doing a throwaway get-feature now.
|
||||
uint8_t buf[91] = {0};
|
||||
os_hid_get_feature(hs->command_hid, 0, buf, sizeof(buf));
|
||||
|
||||
|
@ -594,7 +594,7 @@ hydra_found(struct xrt_prober *xp,
|
|||
struct hydra_system *hs = U_TYPED_CALLOC(struct hydra_system);
|
||||
hs->base.type = XRT_TRACKING_TYPE_HYDRA;
|
||||
snprintf(hs->base.name, XRT_TRACKING_NAME_LEN, "%s", "Razer Hydra magnetic tracking");
|
||||
// Dummy transform from local space to base.
|
||||
// Arbitrary static transform from local space to base.
|
||||
hs->base.offset.position.y = 1.0f;
|
||||
hs->base.offset.position.z = -0.25f;
|
||||
hs->base.offset.orientation.w = 1.0f;
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
|
||||
using namespace ILLIXR;
|
||||
|
||||
/// Dummy plugin class for an instance during phonebook registration
|
||||
/// Simulated plugin class for an instance during phonebook registration
|
||||
class illixr_plugin : public plugin
|
||||
{
|
||||
public:
|
||||
|
|
|
@ -182,7 +182,7 @@ OpticalSystem::SolveDisplayUVToRenderUV(const Vector2 &inputUV, Vector2 const &i
|
|||
Vector3 rayDir;
|
||||
|
||||
// we can do all three calls below to RenderUVToDisplayUV at the
|
||||
// same time via SIMD or better yet we can vectorize across all
|
||||
// same time using SIMD or better yet we can vectorize across all
|
||||
// the uvs if we have a list of them
|
||||
curDisplayUV = RenderUVToDisplayUV(curCameraUV);
|
||||
Vector2 displayUVGradX =
|
||||
|
|
|
@ -202,7 +202,6 @@ ns_vipd_parse(struct ns_hmd *ns)
|
|||
|
||||
try_get_fov(ns, config_json, &temp_data->fov[0], &temp_data->fov[1]);
|
||||
|
||||
// stupid
|
||||
memcpy(&ns->base.hmd->distortion.fov[0], &temp_data->fov[0], sizeof(struct xrt_fov));
|
||||
memcpy(&ns->base.hmd->distortion.fov[1], &temp_data->fov[1], sizeof(struct xrt_fov));
|
||||
|
||||
|
|
|
@ -256,7 +256,7 @@ struct psmv_parsed_calibration_zcm1
|
|||
* vector before subtracting from the gyro 80rpm measures, I get a
|
||||
* better calibration.
|
||||
*
|
||||
* So in order to get the accurate 80rpm measures:
|
||||
* So to get the accurate 80rpm measures:
|
||||
* GyroMeasure80rpm-(GyroBias1*UnknownVector2) or
|
||||
* GyroMeasure80rpm-(GyroBias2*UnknownVector2)
|
||||
*/
|
||||
|
@ -408,7 +408,7 @@ struct psmv_parsed_input
|
|||
//! Accelerometer and gyro scope samples (ZCM2).
|
||||
struct psmv_parsed_sample sample;
|
||||
|
||||
//! Copy of above (ZCM2).
|
||||
//! Copy of preceding (ZCM2).
|
||||
struct psmv_parsed_sample sample_copy;
|
||||
};
|
||||
};
|
||||
|
@ -1005,7 +1005,7 @@ psmv_found(struct xrt_prober *xp,
|
|||
return 0;
|
||||
}
|
||||
|
||||
// Sanity check for device type.
|
||||
// Validate device type.
|
||||
switch (devices[index]->product_id) {
|
||||
case PSMV_PID_ZCM1: break;
|
||||
case PSMV_PID_ZCM2: break;
|
||||
|
|
|
@ -41,7 +41,7 @@
|
|||
|
||||
|
||||
/*!
|
||||
* Stupid convenience macro to print out a pose, only used for debugging
|
||||
* Convenience macro to print out a pose, only used for debugging
|
||||
*/
|
||||
#define print_pose(msg, pose) \
|
||||
U_LOG_E(msg " %f %f %f %f %f %f %f", pose.position.x, pose.position.y, pose.position.z, pose.orientation.x, \
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
* @brief Sample HMD device, use as a starting point to make your own device driver.
|
||||
*
|
||||
*
|
||||
* Based largely on dummy_hmd.c
|
||||
* Based largely on simulated_hmd.c
|
||||
*
|
||||
* @author Jakob Bornecrantz <jakob@collabora.com>
|
||||
* @author Ryan Pavlik <ryan.pavlik@collabora.com>
|
||||
|
|
|
@ -1357,7 +1357,7 @@ survive_device_autoprobe(struct xrt_auto_prober *xap,
|
|||
}
|
||||
|
||||
#ifdef XRT_BUILD_DRIVER_HANDTRACKING
|
||||
// We want to hit this codepath when we find a HMD but no controllers.
|
||||
// We want to enter this codepath when we find a HMD but no controllers.
|
||||
if ((ss->hmd != NULL) && !found_controllers) {
|
||||
struct t_stereo_camera_calibration *cal = NULL;
|
||||
|
||||
|
@ -1376,7 +1376,8 @@ survive_device_autoprobe(struct xrt_auto_prober *xap,
|
|||
out_xdevs[out_idx++] = two_hands[0];
|
||||
out_xdevs[out_idx++] = two_hands[1];
|
||||
}
|
||||
// Don't need it anymore. And it's not even created unless we hit this codepath, which is somewhat hard.
|
||||
// Don't need it anymore. And it's not even created unless we enter this codepath, which is somewhat
|
||||
// hard.
|
||||
t_stereo_camera_calibration_reference(&cal, NULL);
|
||||
}
|
||||
#endif
|
||||
|
|
|
@ -183,7 +183,7 @@ ulv2_process_hand(Leap::Hand hand, xrt_hand_joint_set *joint_set, int hi)
|
|||
ulv2_process_joint(nextJ(ld), fb(ld).basis(), fb(ld).width(), hi, xrtj(LITTLE_TIP));
|
||||
break;
|
||||
// I hear that Sagittarius has a better api, in C even, so hopefully
|
||||
// there'll be less weird boilerplate whenever we get access to that
|
||||
// there'll be less weird boilerplate whenever we get that
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -220,7 +220,7 @@ leap_input_loop(void *ptr_to_xdev)
|
|||
"connected to Leap Motion "
|
||||
"controller. Retrying (%i / %i)",
|
||||
i, num_tries);
|
||||
// This codepath should very rarely get hit as nowadays this gets probed by VID/PID, so you'd
|
||||
// This codepath should very rarely be enter as nowadays this gets probed by VID/PID, so you'd
|
||||
// have to be pretty fast to unplug after it gets probed and before this check.
|
||||
} else {
|
||||
ULV2_INFO(ulv2d,
|
||||
|
|
|
@ -50,7 +50,7 @@ struct v4l2_source_descriptor
|
|||
/*!
|
||||
* Offset from start off frame to start of pixels.
|
||||
*
|
||||
* Aka crop_scanline_bytes_start.
|
||||
* Also known as crop_scanline_bytes_start.
|
||||
*
|
||||
* Special case for ps4 camera
|
||||
*/
|
||||
|
|
|
@ -435,7 +435,7 @@ _handle_sweep_pulse(struct lighthouse_watchman *watchman, uint8_t id, uint32_t t
|
|||
}
|
||||
|
||||
if (frame->sweep_ids & (1 << id)) {
|
||||
LH_WARN("%s: sensor %u hit twice per frame, assuming reflection", watchman->name, id);
|
||||
LH_WARN("%s: sensor %u triggered twice per frame, assuming reflection", watchman->name, id);
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
@ -286,7 +286,8 @@ init_valve_index(struct xrt_prober *xp,
|
|||
out_xdevs[out_idx++] = two_hands[0];
|
||||
out_xdevs[out_idx++] = two_hands[1];
|
||||
}
|
||||
// Don't need it anymore. And it's not even created unless we hit this codepath, which is somewhat hard.
|
||||
// Don't need it anymore. And it's not even created unless we enter this codepath, which is somewhat
|
||||
// hard.
|
||||
t_stereo_camera_calibration_reference(&cal, NULL);
|
||||
}
|
||||
#endif
|
||||
|
|
|
@ -276,7 +276,7 @@ struct vive_headset_lighthouse_v2_pulse_report
|
|||
{
|
||||
uint8_t id;
|
||||
struct vive_headset_lighthouse_v2_pulse pulse[4];
|
||||
/* Seen to be all values in range [0 - 53], related to hit sensor (and
|
||||
/* Seen to be all values in range [0 - 53], related to triggered sensor (and
|
||||
* imu?). */
|
||||
uint8_t unknown1;
|
||||
/* Always 0 */
|
||||
|
|
Loading…
Reference in a new issue