Monado OpenXR Runtime
Data Structures | Macros | Typedefs | Enumerations | Functions
xrt_prober.h File Reference

Common interface to probe for devices. More...

#include "xrt/xrt_device.h"
Include dependency graph for xrt_prober.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  xrt_prober_entry
 Entry for a single device. More...
 
struct  xrt_prober_entry_lists
 Main root of all of the probing device. More...
 
struct  xrt_prober_device
 A probed device, may or may not be opened. More...
 
struct  xrt_prober
 The main prober that probes and manages found but not opened HMD devices that are connected to the system. More...
 
struct  xrt_auto_prober
 A simple prober to probe for a HMD device connected to the system. More...
 

Macros

#define XRT_MAX_DEVICES_PER_PROBE   16
 The maximum number of devices that a single "found" function called by the prober can create per-call. More...
 

Typedefs

typedef struct cJSON cJSON
 
typedef struct xrt_auto_prober *(* xrt_auto_prober_creator) ()
 Function for creating a auto prober. More...
 
typedef void(* xrt_prober_list_video_cb) (struct xrt_prober *xp, struct xrt_prober_device *pdev, const char *product, const char *manufacturer, const char *serial, void *ptr)
 Callback for listing video devices. More...
 

Enumerations

enum  xrt_bus_type { XRT_BUS_TYPE_UNKNOWN, XRT_BUS_TYPE_USB, XRT_BUS_TYPE_BLUETOOTH }
 Bus type of a device. More...
 
enum  xrt_prober_string { XRT_PROBER_STRING_MANUFACTURER, XRT_PROBER_STRING_PRODUCT, XRT_PROBER_STRING_SERIAL_NUMBER }
 String descriptor types. More...
 

Functions

const char * xrt_prober_string_to_string (enum xrt_prober_string t)
 
const char * xrt_bus_type_to_string (enum xrt_bus_type t)
 
int xrt_prober_create (struct xrt_prober **out_xp)
 Call this function to create the xrt_prober. More...
 
int xrt_prober_create_with_lists (struct xrt_prober **out_xp, struct xrt_prober_entry_lists *list)
 Used by the target binary to create the prober with a list of drivers. More...
 
bool xrt_prober_match_string (struct xrt_prober *xp, struct xrt_prober_device *dev, enum xrt_prober_string type, const char *to_match)
 

Detailed Description

Common interface to probe for devices.

Author
Jakob Bornecrantz jakob.nosp@m.@col.nosp@m.labor.nosp@m.a.co.nosp@m.m

Typedef Documentation

◆ cJSON

typedef struct cJSON cJSON

Enumeration Type Documentation

◆ xrt_bus_type

Bus type of a device.

Enumerator
XRT_BUS_TYPE_UNKNOWN 
XRT_BUS_TYPE_USB 
XRT_BUS_TYPE_BLUETOOTH 

◆ xrt_prober_string

String descriptor types.

Enumerator
XRT_PROBER_STRING_MANUFACTURER 
XRT_PROBER_STRING_PRODUCT 
XRT_PROBER_STRING_SERIAL_NUMBER 

Function Documentation

◆ xrt_bus_type_to_string()

const char* xrt_bus_type_to_string ( enum xrt_bus_type  t)

◆ xrt_prober_match_string()

bool xrt_prober_match_string ( struct xrt_prober xp,
struct xrt_prober_device dev,
enum xrt_prober_string  type,
const char *  to_match 
)

References len.

◆ xrt_prober_string_to_string()

const char* xrt_prober_string_to_string ( enum xrt_prober_string  t)