context-libusb.h
Go to the documentation of this file.
1 // License: Apache 2.0. See LICENSE file in root directory.
2 // Copyright(c) 2015 Intel Corporation. All Rights Reserved.
3 
4 #pragma once
5 
6 #include "usb/usb-types.h"
8 
9 #include <memory>
10 #include "libusb.h"
11 
12 namespace librealsense
13 {
14  namespace platform
15  {
17  {
18  public:
19  usb_context();
20  ~usb_context();
21 
22  libusb_context* get();
23 
24  void start_event_handler();
25  void stop_event_handler();
26 
27  size_t device_count();
28  libusb_device* get_device(uint8_t index);
29 
30  private:
31  std::mutex _mutex;
32  libusb_device **_list;
33  size_t _count;
35  struct libusb_context* _ctx;
37  std::thread _event_handler;
38  };
39  }
40 }
unsigned char uint8_t
Definition: stdint.h:78
GLuint index
libusb_device * get_device(uint8_t index)
struct libusb_context * _ctx


librealsense2
Author(s): LibRealSense ROS Team
autogenerated on Thu Dec 22 2022 03:43:16