|
uvc_error_t | uvc_init (uvc_context_t **pctx, struct libusb_context *usb_ctx) |
| Initializes the UVC context.
|
|
void | uvc_exit (uvc_context_t *ctx) |
| Closes the UVC context, shutting down any active cameras.
|
|
Setup routines used to construct UVC access contexts
◆ uvc_init()
uvc_error_t uvc_init |
( |
uvc_context_t ** | pctx, |
|
|
struct libusb_context * | usb_ctx ) |
Initializes the UVC context.
- Note
- If you provide your own USB context, you must handle libusb event processing using a function such as libusb_handle_events.
- Parameters
-
[out] | pctx | The location where the context reference should be stored. |
[in] | usb_ctx | Optional USB context to use |
- Returns
- Error opening context or UVC_SUCCESS
◆ uvc_exit()
void uvc_exit |
( |
uvc_context_t * | ctx | ) |
|
Closes the UVC context, shutting down any active cameras.
- Note
- This function invalides any existing references to the context's cameras.
If no USB context was provided to uvc_init, the UVC-specific USB context will be destroyed.
- Parameters
-
ctx | UVC context to shut down |