Main Page
Related Pages
Modules
Namespaces
Classes
Files
File List
File Members
src
winusb
request-winusb.cpp
Go to the documentation of this file.
1
// License: Apache 2.0. See LICENSE file in root directory.
2
// Copyright(c) 2019 Intel Corporation. All Rights Reserved.
3
4
#include "
request-winusb.h
"
5
#include "
endpoint-winusb.h
"
6
#include "
device-winusb.h
"
7
8
namespace
librealsense
9
{
10
namespace
platform
11
{
12
usb_request_winusb::usb_request_winusb
(
rs_usb_device
device
,
rs_usb_endpoint
endpoint)
13
{
14
_endpoint
= endpoint;
15
_overlapped
= std::make_shared<OVERLAPPED>();
16
_safe_handle
= std::make_shared<safe_handle>(CreateEvent(
nullptr
,
false
,
false
,
nullptr
));
17
_overlapped
->hEvent = _safe_handle->GetHandle();
18
_client_data
=
this
;
19
}
20
21
usb_request_winusb::~usb_request_winusb
()
22
{
23
24
}
25
26
int
usb_request_winusb::get_actual_length
()
const
27
{
28
return
_overlapped
->InternalHigh;
// _request->actual_length;
29
}
30
31
void
usb_request_winusb::set_native_buffer_length
(
int
length
)
32
{
33
34
}
35
36
int
usb_request_winusb::get_native_buffer_length
()
37
{
38
return
_buffer
.size();
39
}
40
41
void
usb_request_winusb::set_native_buffer
(
uint8_t
*
buffer
)
42
{
43
44
}
45
46
uint8_t
*
usb_request_winusb::get_native_buffer
()
const
47
{
48
return
NULL
;
49
}
50
51
void
*
usb_request_winusb::get_native_request
()
const
52
{
53
return
_overlapped
.get();
54
}
55
}
56
}
librealsense::platform::usb_request_winusb::get_native_buffer
virtual uint8_t * get_native_buffer() const override
Definition:
request-winusb.cpp:46
librealsense::platform::usb_request_winusb::_overlapped
std::shared_ptr< OVERLAPPED > _overlapped
Definition:
request-winusb.h:61
librealsense::platform::usb_request_base::_buffer
std::vector< uint8_t > _buffer
Definition:
usb-request.h:63
librealsense::platform::usb_request_winusb::~usb_request_winusb
virtual ~usb_request_winusb()
Definition:
request-winusb.cpp:21
librealsense::platform::usb_request_winusb::set_native_buffer
virtual void set_native_buffer(uint8_t *buffer) override
Definition:
request-winusb.cpp:41
endpoint-winusb.h
librealsense::platform::usb_request_winusb::usb_request_winusb
usb_request_winusb(rs_usb_device device, rs_usb_endpoint endpoint)
Definition:
request-winusb.cpp:12
uint8_t
unsigned char uint8_t
Definition:
stdint.h:78
librealsense::platform::usb_request_winusb::set_native_buffer_length
virtual void set_native_buffer_length(int length) override
Definition:
request-winusb.cpp:31
librealsense::platform::usb_request_winusb::get_native_buffer_length
virtual int get_native_buffer_length() override
Definition:
request-winusb.cpp:36
librealsense::platform::buffer
Definition:
backend-v4l2.h:120
librealsense
Definition:
calibration-model.h:6
librealsense::platform::usb_request_base::_client_data
void * _client_data
Definition:
usb-request.h:60
device-winusb.h
librealsense::platform::rs_usb_endpoint
std::shared_ptr< usb_endpoint > rs_usb_endpoint
Definition:
usb-endpoint.h:24
librealsense::platform::usb_request_winusb::get_native_request
virtual void * get_native_request() const override
Definition:
request-winusb.cpp:51
librealsense::platform::usb_request_base::_endpoint
rs_usb_endpoint _endpoint
Definition:
usb-request.h:62
request-winusb.h
librealsense::platform::usb_request_winusb::_safe_handle
std::shared_ptr< safe_handle > _safe_handle
Definition:
request-winusb.h:62
NULL
#define NULL
Definition:
tinycthread.c:47
length
GLenum GLuint GLenum GLsizei length
Definition:
glad/glad/glad.h:136
librealsense::device
Definition:
device.h:43
librealsense::platform::rs_usb_device
std::shared_ptr< usb_device > rs_usb_device
Definition:
usb-device.h:29
librealsense::platform::usb_request_winusb::get_actual_length
virtual int get_actual_length() const override
Definition:
request-winusb.cpp:26
librealsense2
Author(s): Sergey Dorodnicov
, Doron Hirshberg
, Mark Horn
, Reagan Lopez
, Itay Carpis
autogenerated on Mon May 3 2021 02:47:40