Monado OpenXR Runtime
|
North Star HMD code. More...
#include "math/m_mathinclude.h"
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <assert.h>
#include "os/os_time.h"
#include "ns_hmd.h"
#include "util/u_var.h"
#include "util/u_debug.h"
#include "util/u_device.h"
#include "util/u_time.h"
#include "math/m_space.h"
Macros | |
#define | NS_TRACE(d, ...) U_LOG_XDEV_IFL_T(&d->base, d->log_level, __VA_ARGS__) |
#define | NS_DEBUG(d, ...) U_LOG_XDEV_IFL_D(&d->base, d->log_level, __VA_ARGS__) |
#define | NS_INFO(d, ...) U_LOG_XDEV_IFL_I(&d->base, d->log_level, __VA_ARGS__) |
#define | NS_WARN(d, ...) U_LOG_XDEV_IFL_W(&d->base, d->log_level, __VA_ARGS__) |
#define | NS_ERROR(d, ...) U_LOG_XDEV_IFL_E(&d->base, d->log_level, __VA_ARGS__) |
Functions | |
static float | try_get_ipd (struct ns_hmd *ns, const struct cJSON *json) |
static void | try_get_fov (struct ns_hmd *ns, const struct cJSON *json, struct xrt_fov *out_left_fov, struct xrt_fov *out_right_fov) |
bool | ns_p2d_parse (struct ns_hmd *ns, const cJSON *json) |
static void | ns_3d_fov_calculate (struct xrt_quat projection, struct xrt_fov *out_fov) |
static bool | ns_3d_eye_parse (struct ns_hmd *ns, struct ns_3d_eye *eye, const struct cJSON *eye_data) |
bool | ns_3d_parse (struct ns_hmd *ns, const cJSON *json) |
bool | ns_mt_parse (struct ns_hmd *ns, const cJSON *json) |
static bool | ns_optical_config_parse (struct ns_hmd *ns) |
static void | ns_hmd_destroy (struct xrt_device *xdev) |
static xrt_result_t | ns_hmd_get_tracked_pose (struct xrt_device *xdev, enum xrt_input_name name, int64_t at_timestamp_ns, struct xrt_space_relation *out_relation) |
static void | ns_hmd_get_view_poses (struct xrt_device *xdev, const struct xrt_vec3 *default_eye_relation, int64_t at_timestamp_ns, uint32_t view_count, struct xrt_space_relation *out_head_relation, struct xrt_fov *out_fovs, struct xrt_pose *out_poses) |
bool | ns_mesh_calc (struct xrt_device *xdev, uint32_t view, float u, float v, struct xrt_uv_triplet *result) |
struct xrt_device * | ns_hmd_create (const cJSON *config_json) |
Creates a North Star HMD. More... | |
North Star HMD code.