feat(windows): usbip-win runbook ([~]) + clean-room Kinect10.dll NUI shim (x86+x64 export-verified) (wave 9; todo 14 done, 12/13 blocked)
This commit is contained in:
1 parent
3eb8c07e4c
commit
9b5a0255e2
30 files changed
+3007
-12
No files matched your search
@@ -0,0 +1,550 @@
|
||||
#include "sensor.h"
|
||||
|
||||
#include <algorithm>
|
||||
#include <cstdlib>
|
||||
#include <cstring>
|
||||
#include <string>
|
||||
|
||||
namespace nui_shim {
|
||||
namespace {
|
||||
|
||||
constexpr wchar_t kDefaultMappingName[] = L"kinect_virtual_frames";
|
||||
constexpr DWORD kPlayerIndexMask = 0x7u;
|
||||
|
||||
VirtualKinectSensor* g_sensor = nullptr;
|
||||
CRITICAL_SECTION g_sensor_lock;
|
||||
INIT_ONCE g_sensor_lock_once = INIT_ONCE_STATIC_INIT;
|
||||
|
||||
BOOL CALLBACK InitSensorLock(PINIT_ONCE, PVOID, PVOID*) {
|
||||
InitializeCriticalSection(&g_sensor_lock);
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
CRITICAL_SECTION& SensorLock() {
|
||||
InitOnceExecuteOnce(&g_sensor_lock_once, InitSensorLock, nullptr, nullptr);
|
||||
return g_sensor_lock;
|
||||
}
|
||||
|
||||
std::wstring MappingName() {
|
||||
wchar_t buffer[256];
|
||||
DWORD n = GetEnvironmentVariableW(L"KINECT_SHIM_SHM", buffer, 256);
|
||||
if (n > 0 && n < 256) {
|
||||
return std::wstring(buffer, n);
|
||||
}
|
||||
return std::wstring(kDefaultMappingName);
|
||||
}
|
||||
|
||||
std::vector<uint16_t> ResizeDepthNearest(const std::vector<uint16_t>& src,
|
||||
uint32_t sw,
|
||||
uint32_t sh,
|
||||
uint32_t dw,
|
||||
uint32_t dh) {
|
||||
std::vector<uint16_t> out(static_cast<std::size_t>(dw) * dh, 0);
|
||||
if (sw == 0 || sh == 0 || dw == 0 || dh == 0 ||
|
||||
src.size() != static_cast<std::size_t>(sw) * sh) {
|
||||
return out;
|
||||
}
|
||||
for (uint32_t y = 0; y < dh; ++y) {
|
||||
const uint32_t sy = std::min(static_cast<uint32_t>(
|
||||
static_cast<uint64_t>(y) * sh / dh),
|
||||
sh - 1);
|
||||
for (uint32_t x = 0; x < dw; ++x) {
|
||||
const uint32_t sx = std::min(static_cast<uint32_t>(
|
||||
static_cast<uint64_t>(x) * sw / dw),
|
||||
sw - 1);
|
||||
out[static_cast<std::size_t>(y) * dw + x] =
|
||||
src[static_cast<std::size_t>(sy) * sw + sx];
|
||||
}
|
||||
}
|
||||
return out;
|
||||
}
|
||||
|
||||
NUI_SKELETON_POSITION_TRACKING_STATE MapJointState(
|
||||
contract::JointTrackingState s) {
|
||||
switch (s) {
|
||||
case contract::JointTrackingState::TRACKED:
|
||||
return NUI_SKELETON_POSITION_TRACKED;
|
||||
case contract::JointTrackingState::INFERRED:
|
||||
return NUI_SKELETON_POSITION_INFERRED;
|
||||
case contract::JointTrackingState::NOT_TRACKED:
|
||||
return NUI_SKELETON_POSITION_NOT_TRACKED;
|
||||
}
|
||||
return NUI_SKELETON_POSITION_NOT_TRACKED;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
bool resolution_to_size(NUI_IMAGE_RESOLUTION resolution,
|
||||
uint32_t& width,
|
||||
uint32_t& height) {
|
||||
switch (resolution) {
|
||||
case NUI_IMAGE_RESOLUTION_80x60:
|
||||
width = 80;
|
||||
height = 60;
|
||||
return true;
|
||||
case NUI_IMAGE_RESOLUTION_320x240:
|
||||
width = 320;
|
||||
height = 240;
|
||||
return true;
|
||||
case NUI_IMAGE_RESOLUTION_640x480:
|
||||
width = 640;
|
||||
height = 480;
|
||||
return true;
|
||||
case NUI_IMAGE_RESOLUTION_1280x960:
|
||||
width = 1280;
|
||||
height = 960;
|
||||
return true;
|
||||
default:
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
VirtualKinectSensor::VirtualKinectSensor() {
|
||||
InitializeCriticalSection(&lock_);
|
||||
}
|
||||
|
||||
VirtualKinectSensor::~VirtualKinectSensor() {
|
||||
Shutdown();
|
||||
DeleteCriticalSection(&lock_);
|
||||
}
|
||||
|
||||
HRESULT VirtualKinectSensor::Initialize(DWORD dwFlags) {
|
||||
if (initialized_) {
|
||||
return E_NUI_ALREADY_INITIALIZED;
|
||||
}
|
||||
init_flags_ = dwFlags;
|
||||
source_.open(MappingName().c_str());
|
||||
|
||||
stop_event_ = CreateEventW(nullptr, TRUE, FALSE, nullptr);
|
||||
skeleton_ready_event_ = CreateEventW(nullptr, TRUE, FALSE, nullptr);
|
||||
initialized_ = true;
|
||||
|
||||
producer_thread_ =
|
||||
CreateThread(nullptr, 0, &VirtualKinectSensor::ProducerThunk, this, 0,
|
||||
nullptr);
|
||||
if (producer_thread_ == nullptr) {
|
||||
initialized_ = false;
|
||||
return E_FAIL;
|
||||
}
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
void VirtualKinectSensor::Shutdown() {
|
||||
if (!initialized_) {
|
||||
return;
|
||||
}
|
||||
initialized_ = false;
|
||||
if (stop_event_ != nullptr) {
|
||||
SetEvent(stop_event_);
|
||||
}
|
||||
if (producer_thread_ != nullptr) {
|
||||
WaitForSingleObject(producer_thread_, 2000);
|
||||
CloseHandle(producer_thread_);
|
||||
producer_thread_ = nullptr;
|
||||
}
|
||||
|
||||
EnterCriticalSection(&lock_);
|
||||
for (auto& stream : streams_) {
|
||||
for (auto* texture : stream.ring) {
|
||||
if (texture != nullptr) {
|
||||
texture->Release();
|
||||
}
|
||||
}
|
||||
stream = ImageStream{};
|
||||
}
|
||||
skeleton_enabled_ = false;
|
||||
has_skeleton_ = false;
|
||||
LeaveCriticalSection(&lock_);
|
||||
|
||||
source_.close();
|
||||
if (stop_event_ != nullptr) {
|
||||
CloseHandle(stop_event_);
|
||||
stop_event_ = nullptr;
|
||||
}
|
||||
if (skeleton_ready_event_ != nullptr) {
|
||||
CloseHandle(skeleton_ready_event_);
|
||||
skeleton_ready_event_ = nullptr;
|
||||
}
|
||||
}
|
||||
|
||||
DWORD VirtualKinectSensor::InitializationFlags() const { return init_flags_; }
|
||||
|
||||
HRESULT VirtualKinectSensor::Status() const {
|
||||
return initialized_ ? S_OK : E_NUI_DEVICE_NOT_READY;
|
||||
}
|
||||
|
||||
HRESULT VirtualKinectSensor::SkeletonTrackingEnable(HANDLE hNextFrameEvent,
|
||||
DWORD dwFlags) {
|
||||
EnterCriticalSection(&lock_);
|
||||
skeleton_enabled_ = true;
|
||||
skeleton_flags_ = dwFlags;
|
||||
skeleton_app_event_ = hNextFrameEvent;
|
||||
LeaveCriticalSection(&lock_);
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
HRESULT VirtualKinectSensor::SkeletonTrackingDisable() {
|
||||
EnterCriticalSection(&lock_);
|
||||
skeleton_enabled_ = false;
|
||||
skeleton_app_event_ = nullptr;
|
||||
LeaveCriticalSection(&lock_);
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
HRESULT VirtualKinectSensor::SkeletonGetNextFrame(
|
||||
DWORD dwMillisecondsToWait,
|
||||
NUI_SKELETON_FRAME* pSkeletonFrame) {
|
||||
if (pSkeletonFrame == nullptr) {
|
||||
return E_POINTER;
|
||||
}
|
||||
if (!skeleton_enabled_) {
|
||||
return E_NUI_STREAM_NOT_ENABLED;
|
||||
}
|
||||
|
||||
const DWORD wait = WaitForSingleObject(skeleton_ready_event_,
|
||||
dwMillisecondsToWait);
|
||||
if (wait != WAIT_OBJECT_0) {
|
||||
if (skeleton_flags_ &
|
||||
NUI_SKELETON_TRACKING_FLAG_TITLE_SETS_TRACKED_SKELETONS) {
|
||||
return S_FALSE;
|
||||
}
|
||||
return E_NUI_FRAME_NO_DATA;
|
||||
}
|
||||
|
||||
EnterCriticalSection(&lock_);
|
||||
if (!has_skeleton_) {
|
||||
LeaveCriticalSection(&lock_);
|
||||
return E_NUI_FRAME_NO_DATA;
|
||||
}
|
||||
*pSkeletonFrame = latest_skeleton_;
|
||||
last_delivered_skeleton_frame_ = latest_skeleton_.dwFrameNumber;
|
||||
ResetEvent(skeleton_ready_event_);
|
||||
LeaveCriticalSection(&lock_);
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
HRESULT VirtualKinectSensor::ImageStreamOpen(NUI_IMAGE_TYPE eImageType,
|
||||
NUI_IMAGE_RESOLUTION eResolution,
|
||||
DWORD,
|
||||
DWORD dwFrameLimit,
|
||||
HANDLE hNextFrameEvent,
|
||||
HANDLE* phStreamHandle) {
|
||||
if (phStreamHandle == nullptr) {
|
||||
return E_POINTER;
|
||||
}
|
||||
uint32_t width = 0;
|
||||
uint32_t height = 0;
|
||||
if (!resolution_to_size(eResolution, width, height)) {
|
||||
return E_INVALIDARG;
|
||||
}
|
||||
|
||||
uint32_t bpp = 2;
|
||||
switch (eImageType) {
|
||||
case NUI_IMAGE_TYPE_COLOR:
|
||||
case NUI_IMAGE_TYPE_COLOR_YUV:
|
||||
case NUI_IMAGE_TYPE_COLOR_RAW_YUV:
|
||||
bpp = 4;
|
||||
break;
|
||||
case NUI_IMAGE_TYPE_DEPTH_AND_PLAYER_INDEX:
|
||||
case NUI_IMAGE_TYPE_DEPTH:
|
||||
case NUI_IMAGE_TYPE_COLOR_INFRARED:
|
||||
bpp = 2;
|
||||
break;
|
||||
default:
|
||||
return E_INVALIDARG;
|
||||
}
|
||||
|
||||
EnterCriticalSection(&lock_);
|
||||
ImageStream* slot = nullptr;
|
||||
for (auto& stream : streams_) {
|
||||
if (stream.open && stream.type == eImageType) {
|
||||
slot = &stream;
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (slot == nullptr) {
|
||||
for (auto& stream : streams_) {
|
||||
if (!stream.open) {
|
||||
slot = &stream;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (slot == nullptr) {
|
||||
LeaveCriticalSection(&lock_);
|
||||
return E_NUI_DEVICE_NOT_READY;
|
||||
}
|
||||
|
||||
for (auto* texture : slot->ring) {
|
||||
if (texture != nullptr) {
|
||||
texture->Release();
|
||||
}
|
||||
}
|
||||
|
||||
slot->open = true;
|
||||
slot->type = eImageType;
|
||||
slot->resolution = eResolution;
|
||||
slot->width = width;
|
||||
slot->height = height;
|
||||
slot->bytes_per_pixel = bpp;
|
||||
slot->app_event = hNextFrameEvent;
|
||||
slot->ring_size = std::clamp<std::size_t>(
|
||||
dwFrameLimit == 0 ? 2 : dwFrameLimit, 2, 4);
|
||||
slot->ring.assign(slot->ring_size, nullptr);
|
||||
slot->frames.assign(slot->ring_size, NUI_IMAGE_FRAME{});
|
||||
for (std::size_t i = 0; i < slot->ring_size; ++i) {
|
||||
slot->ring[i] = new NuiFrameTexture(width, height, bpp);
|
||||
}
|
||||
slot->write_index = 0;
|
||||
slot->latest_index = 0;
|
||||
slot->has_frame = false;
|
||||
slot->outstanding = false;
|
||||
|
||||
*phStreamHandle = reinterpret_cast<HANDLE>(slot);
|
||||
LeaveCriticalSection(&lock_);
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
ImageStream* VirtualKinectSensor::StreamFromHandle(HANDLE hStream) {
|
||||
for (auto& stream : streams_) {
|
||||
if (stream.open && reinterpret_cast<HANDLE>(&stream) == hStream) {
|
||||
return &stream;
|
||||
}
|
||||
}
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
HRESULT VirtualKinectSensor::ImageStreamGetNextFrame(
|
||||
HANDLE hStream,
|
||||
DWORD dwMillisecondsToWait,
|
||||
const NUI_IMAGE_FRAME** ppcImageFrame) {
|
||||
if (ppcImageFrame == nullptr) {
|
||||
return E_POINTER;
|
||||
}
|
||||
ImageStream* stream = nullptr;
|
||||
HANDLE app_event = nullptr;
|
||||
EnterCriticalSection(&lock_);
|
||||
stream = StreamFromHandle(hStream);
|
||||
if (stream != nullptr) {
|
||||
app_event = stream->app_event;
|
||||
}
|
||||
LeaveCriticalSection(&lock_);
|
||||
if (stream == nullptr) {
|
||||
return E_INVALIDARG;
|
||||
}
|
||||
|
||||
if (app_event != nullptr) {
|
||||
const DWORD wait = WaitForSingleObject(app_event, dwMillisecondsToWait);
|
||||
if (wait != WAIT_OBJECT_0) {
|
||||
return E_NUI_FRAME_NO_DATA;
|
||||
}
|
||||
}
|
||||
|
||||
EnterCriticalSection(&lock_);
|
||||
if (!stream->has_frame) {
|
||||
LeaveCriticalSection(&lock_);
|
||||
return E_NUI_FRAME_NO_DATA;
|
||||
}
|
||||
stream->outstanding = true;
|
||||
*ppcImageFrame = &stream->frames[stream->latest_index];
|
||||
LeaveCriticalSection(&lock_);
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
HRESULT VirtualKinectSensor::ImageStreamReleaseFrame(
|
||||
HANDLE hStream,
|
||||
const NUI_IMAGE_FRAME* pImageFrame) {
|
||||
if (pImageFrame == nullptr) {
|
||||
return E_INVALIDARG;
|
||||
}
|
||||
EnterCriticalSection(&lock_);
|
||||
ImageStream* stream = StreamFromHandle(hStream);
|
||||
if (stream == nullptr) {
|
||||
LeaveCriticalSection(&lock_);
|
||||
return E_INVALIDARG;
|
||||
}
|
||||
if (pImageFrame->pFrameTexture == nullptr) {
|
||||
LeaveCriticalSection(&lock_);
|
||||
return E_NOINTERFACE;
|
||||
}
|
||||
stream->outstanding = false;
|
||||
LeaveCriticalSection(&lock_);
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
void VirtualKinectSensor::BuildSkeletonFrame(const SourceFrame& src) {
|
||||
NUI_SKELETON_FRAME frame{};
|
||||
LARGE_INTEGER ts;
|
||||
ts.QuadPart = src.meta.timestamp_micros / 1000;
|
||||
frame.liTimeStamp = ts;
|
||||
frame.dwFrameNumber = src.meta.frame_number;
|
||||
frame.dwFlags = 0;
|
||||
|
||||
for (auto& data : frame.SkeletonData) {
|
||||
data.eTrackingState = NUI_SKELETON_NOT_TRACKED;
|
||||
data.dwTrackingID = 0;
|
||||
for (auto& state : data.eSkeletonPositionTrackingState) {
|
||||
state = NUI_SKELETON_POSITION_NOT_TRACKED;
|
||||
}
|
||||
}
|
||||
|
||||
if (src.has_player) {
|
||||
NUI_SKELETON_DATA& data = frame.SkeletonData[0];
|
||||
data.eTrackingState = NUI_SKELETON_TRACKED;
|
||||
data.dwTrackingID = src.meta.skeleton.skeleton_tracking_id;
|
||||
data.dwEnrollmentIndex = 0;
|
||||
data.dwUserIndex = 0;
|
||||
data.dwQualityFlags = src.meta.skeleton.quality_flags;
|
||||
const contract::Vector4& hip =
|
||||
src.meta.skeleton.joints[NUI_SKELETON_POSITION_HIP_CENTER].position;
|
||||
data.Position = {hip.x, hip.y, hip.z, hip.w};
|
||||
for (std::size_t j = 0; j < contract::kJointCount; ++j) {
|
||||
const contract::JointData& joint = src.meta.skeleton.joints[j];
|
||||
data.SkeletonPositions[j] = {joint.position.x, joint.position.y,
|
||||
joint.position.z, joint.position.w};
|
||||
data.eSkeletonPositionTrackingState[j] =
|
||||
MapJointState(joint.tracking_state);
|
||||
}
|
||||
}
|
||||
|
||||
latest_skeleton_ = frame;
|
||||
has_skeleton_ = true;
|
||||
}
|
||||
|
||||
void VirtualKinectSensor::FillStreams(const SourceFrame& src) {
|
||||
for (auto& stream : streams_) {
|
||||
if (!stream.open || stream.outstanding) {
|
||||
continue;
|
||||
}
|
||||
const std::size_t next = (stream.has_frame)
|
||||
? (stream.latest_index + 1) % stream.ring_size
|
||||
: stream.write_index;
|
||||
NuiFrameTexture* texture = stream.ring[next];
|
||||
if (texture == nullptr) {
|
||||
continue;
|
||||
}
|
||||
|
||||
if (stream.type == NUI_IMAGE_TYPE_DEPTH_AND_PLAYER_INDEX ||
|
||||
stream.type == NUI_IMAGE_TYPE_DEPTH) {
|
||||
std::vector<uint16_t> depth = ResizeDepthNearest(
|
||||
src.depth_pixels, src.meta.depth.width, src.meta.depth.height,
|
||||
stream.width, stream.height);
|
||||
if (stream.type == NUI_IMAGE_TYPE_DEPTH) {
|
||||
for (auto& pixel : depth) {
|
||||
pixel = static_cast<uint16_t>(pixel & ~kPlayerIndexMask);
|
||||
}
|
||||
}
|
||||
texture->set_bits(reinterpret_cast<const uint8_t*>(depth.data()),
|
||||
depth.size() * sizeof(uint16_t));
|
||||
} else if (stream.type == NUI_IMAGE_TYPE_COLOR_INFRARED) {
|
||||
synth::BgraFrame source_color{
|
||||
{src.meta.color.width, src.meta.color.height},
|
||||
src.meta.color.width * 4u,
|
||||
src.color_pixels};
|
||||
synth::InfraredFrame ir = synth::synthesize_infrared(
|
||||
source_color, {stream.width, stream.height});
|
||||
texture->set_bits(reinterpret_cast<const uint8_t*>(ir.pixels.data()),
|
||||
ir.pixels.size() * sizeof(uint16_t));
|
||||
} else {
|
||||
synth::BgraFrame source_color{
|
||||
{src.meta.color.width, src.meta.color.height},
|
||||
src.meta.color.width * 4u,
|
||||
src.color_pixels};
|
||||
synth::BgraFrame color = synth::passthrough_color(
|
||||
source_color, {stream.width, stream.height});
|
||||
texture->set_bits(color.pixels.data(), color.pixels.size());
|
||||
}
|
||||
|
||||
NUI_IMAGE_FRAME& image = stream.frames[next];
|
||||
LARGE_INTEGER ts;
|
||||
ts.QuadPart = src.meta.timestamp_micros / 1000;
|
||||
image.liTimeStamp = ts;
|
||||
image.dwFrameNumber = src.meta.frame_number;
|
||||
image.eImageType = stream.type;
|
||||
image.eResolution = stream.resolution;
|
||||
image.pFrameTexture = texture;
|
||||
image.dwFrameFlags = 0;
|
||||
image.ViewArea.eDigitalZoom = NUI_IMAGE_DIGITAL_ZOOM_1X;
|
||||
image.ViewArea.lCenterX = 0;
|
||||
image.ViewArea.lCenterY = 0;
|
||||
|
||||
stream.latest_index = next;
|
||||
stream.write_index = (next + 1) % stream.ring_size;
|
||||
stream.has_frame = true;
|
||||
if (stream.app_event != nullptr) {
|
||||
SetEvent(stream.app_event);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void VirtualKinectSensor::ProducerLoop() {
|
||||
LARGE_INTEGER frequency;
|
||||
LARGE_INTEGER start;
|
||||
QueryPerformanceFrequency(&frequency);
|
||||
QueryPerformanceCounter(&start);
|
||||
uint32_t frame_number = 0;
|
||||
|
||||
while (WaitForSingleObject(stop_event_, 0) != WAIT_OBJECT_0) {
|
||||
LARGE_INTEGER now;
|
||||
QueryPerformanceCounter(&now);
|
||||
const int64_t micros =
|
||||
(now.QuadPart - start.QuadPart) * 1000000 / frequency.QuadPart;
|
||||
|
||||
SourceFrame src;
|
||||
const bool got = source_.is_open() && source_.read_latest(src);
|
||||
if (!got) {
|
||||
src = SourceFrame{};
|
||||
src.has_player = false;
|
||||
src.meta.depth.width = 640;
|
||||
src.meta.depth.height = 480;
|
||||
src.meta.color.width = 640;
|
||||
src.meta.color.height = 480;
|
||||
src.depth_pixels.assign(640u * 480u, 0);
|
||||
src.color_pixels.assign(640u * 480u * 4u, 0);
|
||||
}
|
||||
++frame_number;
|
||||
src.meta.frame_number = frame_number;
|
||||
src.meta.timestamp_micros = micros;
|
||||
|
||||
EnterCriticalSection(&lock_);
|
||||
if (skeleton_enabled_) {
|
||||
BuildSkeletonFrame(src);
|
||||
SetEvent(skeleton_ready_event_);
|
||||
if (skeleton_app_event_ != nullptr) {
|
||||
SetEvent(skeleton_app_event_);
|
||||
}
|
||||
}
|
||||
FillStreams(src);
|
||||
LeaveCriticalSection(&lock_);
|
||||
|
||||
WaitForSingleObject(stop_event_, kFramePeriodMs);
|
||||
}
|
||||
}
|
||||
|
||||
DWORD WINAPI VirtualKinectSensor::ProducerThunk(LPVOID param) {
|
||||
static_cast<VirtualKinectSensor*>(param)->ProducerLoop();
|
||||
return 0;
|
||||
}
|
||||
|
||||
VirtualKinectSensor* GlobalSensor() { return g_sensor; }
|
||||
|
||||
VirtualKinectSensor* EnsureGlobalSensor() {
|
||||
EnterCriticalSection(&SensorLock());
|
||||
if (g_sensor == nullptr) {
|
||||
g_sensor = new VirtualKinectSensor();
|
||||
}
|
||||
VirtualKinectSensor* sensor = g_sensor;
|
||||
LeaveCriticalSection(&SensorLock());
|
||||
return sensor;
|
||||
}
|
||||
|
||||
void DestroyGlobalSensor() {
|
||||
EnterCriticalSection(&SensorLock());
|
||||
if (g_sensor != nullptr) {
|
||||
delete g_sensor;
|
||||
g_sensor = nullptr;
|
||||
}
|
||||
LeaveCriticalSection(&SensorLock());
|
||||
}
|
||||
|
||||
}
|
||||
Reference in new issue
Block a user