summaryrefslogtreecommitdiffhomepage
path: root/tracker-kinect-face
diff options
context:
space:
mode:
Diffstat (limited to 'tracker-kinect-face')
-rw-r--r--tracker-kinect-face/CMakeLists.txt14
-rw-r--r--tracker-kinect-face/camera_kinect_ir.cpp8
-rw-r--r--tracker-kinect-face/kinect_face_settings.h1
-rw-r--r--tracker-kinect-face/kinect_face_tracker.cpp4
-rw-r--r--tracker-kinect-face/kinect_face_tracker.h1
-rw-r--r--tracker-kinect-face/lang/zh_CN.ts2
6 files changed, 17 insertions, 13 deletions
diff --git a/tracker-kinect-face/CMakeLists.txt b/tracker-kinect-face/CMakeLists.txt
index 7ab62df2..d205a764 100644
--- a/tracker-kinect-face/CMakeLists.txt
+++ b/tracker-kinect-face/CMakeLists.txt
@@ -30,16 +30,16 @@ if (WIN32 AND opentrack-intel)
target_link_libraries(${self} opentrack-video)
# Install Kinect Face DLL
- install(FILES "${SDK_KINECT20}/Redist/Face/${kinect-arch-dir}/Kinect20.Face.dll" DESTINATION "${opentrack-hier-pfx}" PERMISSIONS ${opentrack-perms-exec})
+ install(FILES "${SDK_KINECT20}/Redist/Face/${kinect-arch-dir}/Kinect20.Face.dll" DESTINATION "${opentrack-libexec}" PERMISSIONS ${opentrack-perms-exec})
# Install Kinect Face Database
- install(DIRECTORY "${SDK_KINECT20}/Redist/Face/${kinect-arch-dir}/NuiDatabase" DESTINATION "${opentrack-hier-pfx}")
+ install(DIRECTORY "${SDK_KINECT20}/Redist/Face/${kinect-arch-dir}/NuiDatabase" DESTINATION "${opentrack-libexec}")
set(redist-dir "${CMAKE_SOURCE_DIR}/redist/${kinect-arch-dir}")
- install(
- FILES "${redist-dir}/msvcp110.dll" "${redist-dir}/msvcr110.dll"
- DESTINATION "${opentrack-hier-pfx}"
- PERMISSIONS ${opentrack-perms-exec}
- )
+ #install(
+ # FILES "${redist-dir}/msvcp110.dll" "${redist-dir}/msvcr110.dll"
+ # DESTINATION "${opentrack-libexec}"
+ # PERMISSIONS ${opentrack-perms-exec}
+ #)
# Optional OpenCV support
# Needed for Point Tracker to support Kinect V2 IR Sensor
diff --git a/tracker-kinect-face/camera_kinect_ir.cpp b/tracker-kinect-face/camera_kinect_ir.cpp
index 81357a6d..3a33fd14 100644
--- a/tracker-kinect-face/camera_kinect_ir.cpp
+++ b/tracker-kinect-face/camera_kinect_ir.cpp
@@ -48,7 +48,12 @@ namespace Kinect {
std::vector<QString> CamerasProvider::camera_names() const
{
- if (camera_name_to_index("Kinect V2 Video Sensor") != -1)
+ auto list = get_camera_names();
+ auto it = std::find_if(list.cbegin(), list.cend(), [](const auto& x) {
+ const auto& [name, idx] = x;
+ return name.startsWith("Kinect V2 Video Sensor [");
+ });
+ if (it != list.cend())
{
// We found Kinect V2 Video Sensor therefore we have a kinect V2 connected.
// Publish our Kinect V2 IR Sensor implementation then.
@@ -232,6 +237,7 @@ namespace Kinect {
// Release previous frame if any
SafeRelease(iInfraredFrame);
+ Sleep(34); // FIXME
HRESULT hr = iInfraredFrameReader->AcquireLatestFrame(&iInfraredFrame);
if (SUCCEEDED(hr))
diff --git a/tracker-kinect-face/kinect_face_settings.h b/tracker-kinect-face/kinect_face_settings.h
index 40af1eb7..2c5cc55f 100644
--- a/tracker-kinect-face/kinect_face_settings.h
+++ b/tracker-kinect-face/kinect_face_settings.h
@@ -8,7 +8,6 @@
#pragma once
#include "ui_kinect_face_settings.h"
-#include "compat/macros.hpp"
#include "api/plugin-api.hpp"
class KinectFaceSettings : public ITrackerDialog
diff --git a/tracker-kinect-face/kinect_face_tracker.cpp b/tracker-kinect-face/kinect_face_tracker.cpp
index e7b77133..4bab2eef 100644
--- a/tracker-kinect-face/kinect_face_tracker.cpp
+++ b/tracker-kinect-face/kinect_face_tracker.cpp
@@ -136,8 +136,8 @@ module_status KinectFaceTracker::start_tracker(QFrame* aFrame)
iVideoWidget = std::make_unique<video_widget>(aFrame);
iLayout = std::make_unique<QHBoxLayout>(aFrame);
iLayout->setContentsMargins(0, 0, 0, 0);
- iLayout->addWidget(iVideoWidget.get());
- aFrame->setLayout(iLayout.get());
+ iLayout->addWidget(&*iVideoWidget);
+ aFrame->setLayout(&*iLayout);
//video_widget->resize(video_frame->width(), video_frame->height());
aFrame->show();
diff --git a/tracker-kinect-face/kinect_face_tracker.h b/tracker-kinect-face/kinect_face_tracker.h
index 8070c519..83b58d71 100644
--- a/tracker-kinect-face/kinect_face_tracker.h
+++ b/tracker-kinect-face/kinect_face_tracker.h
@@ -12,7 +12,6 @@
#include "api/plugin-api.hpp"
#include "compat/timer.hpp"
-#include "compat/macros.hpp"
#include "video/video-widget.hpp"
// Kinect Header files
diff --git a/tracker-kinect-face/lang/zh_CN.ts b/tracker-kinect-face/lang/zh_CN.ts
index de0e4f95..1e1b55d1 100644
--- a/tracker-kinect-face/lang/zh_CN.ts
+++ b/tracker-kinect-face/lang/zh_CN.ts
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE TS>
-<TS version="2.1">
+<TS version="2.1" language="zh_CN">
<context>
<name>KinectFaceMetadata</name>
<message>