summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--gui/main-window.ui24
-rw-r--r--gui/new_file_dialog.h3
-rw-r--r--gui/options-dialog.cpp1
-rw-r--r--gui/options-dialog.ui18
-rw-r--r--tracker-hatire/ftnoir_tracker_hat.cpp4
-rw-r--r--tracker-rift-025/ftnoir_tracker_rift_025.cpp25
-rw-r--r--tracker-rift-025/ftnoir_tracker_rift_025.h6
-rw-r--r--tracker-rift-042/ftnoir_tracker_rift_042.cpp12
-rw-r--r--tracker-rift-042/ftnoir_tracker_rift_042.h6
-rw-r--r--tracker-rift-080/ftnoir_tracker_rift_080.cpp10
-rw-r--r--tracker-rift-080/ftnoir_tracker_rift_080.h6
-rw-r--r--tracker-rift-140/impl.cpp12
-rw-r--r--tracker-rift-140/rift-140.hpp6
-rw-r--r--tracker-rs/ftnoir_tracker_rs.cpp13
-rw-r--r--tracker-steamvr/steamvr.cpp9
15 files changed, 93 insertions, 62 deletions
diff --git a/gui/main-window.ui b/gui/main-window.ui
index 8bf78efd..33ee99d3 100644
--- a/gui/main-window.ui
+++ b/gui/main-window.ui
@@ -342,7 +342,7 @@
<enum>QFrame::Raised</enum>
</property>
<property name="text">
- <string>TZ</string>
+ <string>Z</string>
</property>
</widget>
</item>
@@ -358,7 +358,7 @@
<enum>QFrame::Raised</enum>
</property>
<property name="text">
- <string>pitch</string>
+ <string>Pitch</string>
</property>
</widget>
</item>
@@ -411,7 +411,7 @@
<enum>QFrame::Raised</enum>
</property>
<property name="text">
- <string>TY</string>
+ <string>Y</string>
</property>
</widget>
</item>
@@ -427,7 +427,7 @@
<enum>QFrame::Raised</enum>
</property>
<property name="text">
- <string>TX</string>
+ <string>X</string>
</property>
</widget>
</item>
@@ -474,7 +474,7 @@
<enum>QFrame::Raised</enum>
</property>
<property name="text">
- <string>roll</string>
+ <string>Roll</string>
</property>
</widget>
</item>
@@ -490,7 +490,7 @@
<enum>QFrame::Raised</enum>
</property>
<property name="text">
- <string>yaw</string>
+ <string>Yaw</string>
</property>
</widget>
</item>
@@ -704,7 +704,7 @@
<enum>QFrame::Raised</enum>
</property>
<property name="text">
- <string>TX</string>
+ <string>X</string>
</property>
</widget>
</item>
@@ -726,7 +726,7 @@
<enum>QFrame::Raised</enum>
</property>
<property name="text">
- <string>TY</string>
+ <string>Y</string>
</property>
</widget>
</item>
@@ -767,7 +767,7 @@
<enum>QFrame::Raised</enum>
</property>
<property name="text">
- <string>pitch</string>
+ <string>Pitch</string>
</property>
</widget>
</item>
@@ -783,7 +783,7 @@
<enum>QFrame::Raised</enum>
</property>
<property name="text">
- <string>roll</string>
+ <string>Roll</string>
</property>
</widget>
</item>
@@ -799,7 +799,7 @@
<enum>QFrame::Raised</enum>
</property>
<property name="text">
- <string>yaw</string>
+ <string>Yaw</string>
</property>
</widget>
</item>
@@ -821,7 +821,7 @@
<enum>QFrame::Raised</enum>
</property>
<property name="text">
- <string>TZ</string>
+ <string>Z</string>
</property>
</widget>
</item>
diff --git a/gui/new_file_dialog.h b/gui/new_file_dialog.h
index 6ba3ede3..cd5ca528 100644
--- a/gui/new_file_dialog.h
+++ b/gui/new_file_dialog.h
@@ -39,7 +39,8 @@ private slots:
if (text == "" || text == ".ini" || QFile(options::group::ini_directory() + "/" + text).exists())
{
QMessageBox::warning(this,
- "File exists", "This file already exists. Pick another name.",
+ tr("File exists"),
+ tr("This file already exists. Pick another name."),
QMessageBox::Ok, QMessageBox::NoButton);
return;
}
diff --git a/gui/options-dialog.cpp b/gui/options-dialog.cpp
index a0d26b8a..8cf67e6d 100644
--- a/gui/options-dialog.cpp
+++ b/gui/options-dialog.cpp
@@ -142,6 +142,7 @@ void OptionsDialog::bind_key(key_opts& kopts, QLabel* label)
d.setLayout(&l);
d.setFixedSize(QSize(500, 300));
d.setWindowFlags(Qt::Dialog);
+ setWindowFlags(Qt::MSWindowsFixedSizeDialogHint | windowFlags());
d.setWindowModality(Qt::ApplicationModal);
connect(&k,
&KeyboardListener::key_pressed,
diff --git a/gui/options-dialog.ui b/gui/options-dialog.ui
index 471bd712..f23dd63f 100644
--- a/gui/options-dialog.ui
+++ b/gui/options-dialog.ui
@@ -6,10 +6,16 @@
<rect>
<x>0</x>
<y>0</y>
- <width>525</width>
- <height>603</height>
+ <width>450</width>
+ <height>599</height>
</rect>
</property>
+ <property name="minimumSize">
+ <size>
+ <width>450</width>
+ <height>0</height>
+ </size>
+ </property>
<property name="windowTitle">
<string>Options</string>
</property>
@@ -465,6 +471,12 @@
</item>
<item row="5" column="0">
<widget class="QLabel" name="label_17">
+ <property name="minimumSize">
+ <size>
+ <width>300</width>
+ <height>0</height>
+ </size>
+ </property>
<property name="text">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;Specify an angle to rotate position tracking. It lets the tracker avoid moving on the X and Y axes when zooming, since camera isn't mounted perfectly in front of the model, but above or below.&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
@@ -865,7 +877,7 @@
<item>
<widget class="QGroupBox" name="groupBox_">
<property name="sizePolicy">
- <sizepolicy hsizetype="Minimum" vsizetype="Maximum">
+ <sizepolicy hsizetype="Preferred" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
diff --git a/tracker-hatire/ftnoir_tracker_hat.cpp b/tracker-hatire/ftnoir_tracker_hat.cpp
index 421a0e26..e8da968f 100644
--- a/tracker-hatire/ftnoir_tracker_hat.cpp
+++ b/tracker-hatire/ftnoir_tracker_hat.cpp
@@ -56,10 +56,10 @@ void hatire::start_tracker(QFrame*)
case result_ok:
break;
case result_error:
- QMessageBox::warning(0,"Error", ret.error, QMessageBox::Ok,QMessageBox::NoButton);
+ QMessageBox::warning(0, tr("Error"), ret.error, QMessageBox::Ok,QMessageBox::NoButton);
break;
case result_open_error:
- QMessageBox::warning(0,"Error", "Unable to open ComPort: " + ret.error, QMessageBox::Ok,QMessageBox::NoButton);
+ QMessageBox::warning(0, tr("Error"), tr("Unable to open ComPort: %1").arg(ret.error), QMessageBox::Ok,QMessageBox::NoButton);
break;
}
diff --git a/tracker-rift-025/ftnoir_tracker_rift_025.cpp b/tracker-rift-025/ftnoir_tracker_rift_025.cpp
index 7c0b2a55..5109385e 100644
--- a/tracker-rift-025/ftnoir_tracker_rift_025.cpp
+++ b/tracker-rift-025/ftnoir_tracker_rift_025.cpp
@@ -8,7 +8,7 @@
using namespace OVR;
-Rift_Tracker::Rift_Tracker()
+rift_tracker_025::rift_tracker_025()
{
pManager = NULL;
pSensor = NULL;
@@ -16,7 +16,7 @@ Rift_Tracker::Rift_Tracker()
old_yaw = 0;
}
-Rift_Tracker::~Rift_Tracker()
+rift_tracker_025::~rift_tracker_025()
{
if (pSensor)
pSensor->Release();
@@ -27,7 +27,7 @@ Rift_Tracker::~Rift_Tracker()
System::Destroy();
}
-void Rift_Tracker::start_tracker(QFrame*)
+void rift_tracker_025::start_tracker(QFrame*)
{
System::Init(Log::ConfigureDefaultLog(LogMask_All));
pManager = DeviceManager::Create();
@@ -46,23 +46,32 @@ void Rift_Tracker::start_tracker(QFrame*)
}
else
{
- QMessageBox::warning(0,"Error", "Unable to create Rift sensor",QMessageBox::Ok,QMessageBox::NoButton);
+ QMessageBox::warning(nullptr,
+ QCoreApplication::translate("rift_tracker_025", "Error"),
+ QCoreApplication::translate("rift_tracker_025", "Unable to create Rift sensor"),
+ QMessageBox::Ok,QMessageBox::NoButton);
}
}
else
{
- QMessageBox::warning(0,"Error", "Unable to enumerate Rift tracker",QMessageBox::Ok,QMessageBox::NoButton);
+ QMessageBox::warning(nullptr,
+ QCoreApplication::translate("rift_tracker_025", "Error"),
+ QCoreApplication::translate("rift_tracker_025", "Unable to enumerate Rift tracker"),
+ QMessageBox::Ok,QMessageBox::NoButton);
}
}
else
{
- QMessageBox::warning(0,"Error", "Unable to start Rift tracker",QMessageBox::Ok,QMessageBox::NoButton);
+ QMessageBox::warning(nullptr,
+ QCoreApplication::translate("rift_tracker_025", "Error"),
+ QCoreApplication::translate("rift_tracker_025", "Unable to start Rift tracker"),
+ QMessageBox::Ok,QMessageBox::NoButton);
}
}
-void Rift_Tracker::data(double *data)
+void rift_tracker_025::data(double *data)
{
if (pSFusion != NULL && pSensor != NULL)
{
@@ -100,4 +109,4 @@ void Rift_Tracker::data(double *data)
}
}
-OPENTRACK_DECLARE_TRACKER(Rift_Tracker, dialog_rift_025, rift_025Dll)
+OPENTRACK_DECLARE_TRACKER(rift_tracker_025, dialog_rift_025, rift_025Dll)
diff --git a/tracker-rift-025/ftnoir_tracker_rift_025.h b/tracker-rift-025/ftnoir_tracker_rift_025.h
index 96331fd2..b65d3e56 100644
--- a/tracker-rift-025/ftnoir_tracker_rift_025.h
+++ b/tracker-rift-025/ftnoir_tracker_rift_025.h
@@ -21,11 +21,11 @@ struct settings : opts {
{}
};
-class Rift_Tracker : public ITracker
+class rift_tracker_025 : public ITracker
{
public:
- Rift_Tracker();
- virtual ~Rift_Tracker() override;
+ rift_tracker_025();
+ virtual ~rift_tracker_025() override;
void start_tracker(QFrame *) override;
void data(double *data) override;
private:
diff --git a/tracker-rift-042/ftnoir_tracker_rift_042.cpp b/tracker-rift-042/ftnoir_tracker_rift_042.cpp
index af8a386f..6c5d6f60 100644
--- a/tracker-rift-042/ftnoir_tracker_rift_042.cpp
+++ b/tracker-rift-042/ftnoir_tracker_rift_042.cpp
@@ -12,17 +12,17 @@
using namespace OVR;
-Rift_Tracker::Rift_Tracker() : old_yaw(0), hmd(nullptr)
+rift_tracker_042::rift_tracker_042() : old_yaw(0), hmd(nullptr)
{
}
-Rift_Tracker::~Rift_Tracker()
+rift_tracker_042::~rift_tracker_042()
{
ovrHmd_Destroy(hmd);
ovr_Shutdown();
}
-void Rift_Tracker::start_tracker(QFrame*)
+void rift_tracker_042::start_tracker(QFrame*)
{
ovr_Initialize();
hmd = ovrHmd_Create(0);
@@ -34,14 +34,14 @@ void Rift_Tracker::start_tracker(QFrame*)
{
QMessageBox::warning(nullptr,
"Error",
- QStringLiteral("Unable to start Rift tracker: %1").arg(ovrHmd_GetLastError(nullptr)),
+ QCoreApplication::translate("rift_tracker_042", "Unable to start Rift tracker: %1").arg(ovrHmd_GetLastError(nullptr)),
QMessageBox::Ok,
QMessageBox::NoButton);
}
}
-void Rift_Tracker::data(double *data)
+void rift_tracker_042::data(double *data)
{
if (hmd)
{
@@ -87,4 +87,4 @@ void Rift_Tracker::data(double *data)
}
}
-OPENTRACK_DECLARE_TRACKER(Rift_Tracker, dialog_rift_042, rift_042Dll)
+OPENTRACK_DECLARE_TRACKER(rift_tracker_042, dialog_rift_042, rift_042Dll)
diff --git a/tracker-rift-042/ftnoir_tracker_rift_042.h b/tracker-rift-042/ftnoir_tracker_rift_042.h
index ed802da0..82081085 100644
--- a/tracker-rift-042/ftnoir_tracker_rift_042.h
+++ b/tracker-rift-042/ftnoir_tracker_rift_042.h
@@ -21,11 +21,11 @@ struct settings : opts {
{}
};
-class Rift_Tracker : public ITracker
+class rift_tracker_042 : public ITracker
{
public:
- Rift_Tracker();
- virtual ~Rift_Tracker() override;
+ rift_tracker_042();
+ virtual ~rift_tracker_042() override;
void start_tracker(QFrame *) override;
void data(double *data) override;
private:
diff --git a/tracker-rift-080/ftnoir_tracker_rift_080.cpp b/tracker-rift-080/ftnoir_tracker_rift_080.cpp
index 35a268f2..9ca1206a 100644
--- a/tracker-rift-080/ftnoir_tracker_rift_080.cpp
+++ b/tracker-rift-080/ftnoir_tracker_rift_080.cpp
@@ -10,18 +10,18 @@
using namespace OVR;
-Rift_Tracker::Rift_Tracker() : old_yaw(0), hmd(nullptr)
+rift_tracker_080::rift_tracker_080() : old_yaw(0), hmd(nullptr)
{
}
-Rift_Tracker::~Rift_Tracker()
+rift_tracker_080::~rift_tracker_080()
{
if (hmd)
ovr_Destroy(hmd);
ovr_Shutdown();
}
-void Rift_Tracker::start_tracker(QFrame*)
+void rift_tracker_080::start_tracker(QFrame*)
{
ovrResult code;
ovrGraphicsLuid luid = {{0}};
@@ -55,7 +55,7 @@ error:
QMessageBox::NoButton);
}
-void Rift_Tracker::data(double *data)
+void rift_tracker_080::data(double *data)
{
if (hmd)
{
@@ -100,4 +100,4 @@ void Rift_Tracker::data(double *data)
}
}
-OPENTRACK_DECLARE_TRACKER(Rift_Tracker, dialog_rift_080, rift_080Dll)
+OPENTRACK_DECLARE_TRACKER(rift_tracker_080, dialog_rift_080, rift_080Dll)
diff --git a/tracker-rift-080/ftnoir_tracker_rift_080.h b/tracker-rift-080/ftnoir_tracker_rift_080.h
index 7868b2a2..e5ad9c3a 100644
--- a/tracker-rift-080/ftnoir_tracker_rift_080.h
+++ b/tracker-rift-080/ftnoir_tracker_rift_080.h
@@ -20,11 +20,11 @@ struct settings : opts {
{}
};
-class Rift_Tracker : public ITracker
+class rift_tracker_080 : public ITracker
{
public:
- Rift_Tracker();
- ~Rift_Tracker() override;
+ rift_tracker_080();
+ ~rift_tracker_080() override;
void start_tracker(QFrame *) override;
void data(double *data) override;
private:
diff --git a/tracker-rift-140/impl.cpp b/tracker-rift-140/impl.cpp
index 67d5bb47..48aaa10a 100644
--- a/tracker-rift-140/impl.cpp
+++ b/tracker-rift-140/impl.cpp
@@ -8,11 +8,11 @@
using namespace OVR;
-Rift_Tracker::Rift_Tracker() : old_yaw(0), hmd(nullptr)
+rift_tracker_140::rift_tracker_140() : old_yaw(0), hmd(nullptr)
{
}
-Rift_Tracker::~Rift_Tracker()
+rift_tracker_140::~rift_tracker_140()
{
if (hmd)
{
@@ -21,7 +21,7 @@ Rift_Tracker::~Rift_Tracker()
}
}
-void Rift_Tracker::start_tracker(QFrame*)
+void rift_tracker_140::start_tracker(QFrame*)
{
if (OVR_FAILURE(ovr_Initialize(nullptr)))
goto error;
@@ -44,12 +44,12 @@ error:
QMessageBox::warning(nullptr,
"Error",
- QStringLiteral("Unable to start Rift tracker: %1").arg(strerror),
+ QCoreApplication::translate("rift_tracker_140", "Unable to start Rift tracker: %1").arg(strerror),
QMessageBox::Ok,
QMessageBox::NoButton);
}
-void Rift_Tracker::data(double *data)
+void rift_tracker_140::data(double *data)
{
if (hmd)
{
@@ -94,4 +94,4 @@ void Rift_Tracker::data(double *data)
}
}
-OPENTRACK_DECLARE_TRACKER(Rift_Tracker, dialog_rift_140, rift_140Dll)
+OPENTRACK_DECLARE_TRACKER(rift_tracker_140, dialog_rift_140, rift_140Dll)
diff --git a/tracker-rift-140/rift-140.hpp b/tracker-rift-140/rift-140.hpp
index 23ec6fb3..47eb7cd2 100644
--- a/tracker-rift-140/rift-140.hpp
+++ b/tracker-rift-140/rift-140.hpp
@@ -20,11 +20,11 @@ struct settings : opts {
{}
};
-class Rift_Tracker : public ITracker
+class rift_tracker_140 : public ITracker
{
public:
- Rift_Tracker();
- ~Rift_Tracker() override;
+ rift_tracker_140();
+ ~rift_tracker_140() override;
void start_tracker(QFrame *) override;
void data(double *data) override;
private:
diff --git a/tracker-rs/ftnoir_tracker_rs.cpp b/tracker-rs/ftnoir_tracker_rs.cpp
index 6eae0693..d2c77f12 100644
--- a/tracker-rs/ftnoir_tracker_rs.cpp
+++ b/tracker-rs/ftnoir_tracker_rs.cpp
@@ -87,7 +87,10 @@ bool RSTracker::startSdkInstallationProcess()
bool pStarted = QProcess::startDetached(contrib_path + "intel_rs_sdk_runtime_websetup_10.0.26.0396.exe --finstall=core,face3d --fnone=all");
if(!pStarted){
- QMessageBox::warning(0, "Intel® RealSense™ Runtime Installation", "Installation process failed to start.", QMessageBox::Ok);
+ QMessageBox::warning(nullptr,
+ tr("Intel® RealSense™ Runtime Installation"),
+ tr("Installation process failed to start."),
+ QMessageBox::Ok);
}
return pStarted;
}
@@ -100,19 +103,19 @@ void RSTracker::showRealSenseErrorMessageBox(int exitCode)
switch(exitCode){
case -101: //The implementation got an invalid handle from the RealSense SDK session/modules
- msgBox.setInformativeText("Couldn't initialize RealSense tracking. Please make sure SDK Runtime 2016 R2 is installed.");
+ msgBox.setInformativeText(tr("Couldn't initialize RealSense tracking. Please make sure SDK Runtime 2016 R2 is installed."));
break;
case -301: //RealSense SDK runtime execution aborted.
- msgBox.setInformativeText("Tracking stopped after the RealSense SDK Runtime execution has aborted.");
+ msgBox.setInformativeText(tr("Tracking stopped after the RealSense SDK Runtime execution has aborted."));
break;
case -601: //RealSense Camera stream configuration has changed.
- msgBox.setInformativeText("Tracking stopped after another program changed camera streams configuration.");
+ msgBox.setInformativeText(tr("Tracking stopped after another program changed camera streams configuration."));
break;
default:
msgBox.setInformativeText("Status code: " + QString::number(exitCode) + ".\n\nNote that you need the latest camera drivers and the SDK runtime 2016 R2 to be installed.");
}
- QPushButton* triggerSdkInstallation = msgBox.addButton("Install Runtime", QMessageBox::ActionRole);
+ QPushButton* triggerSdkInstallation = msgBox.addButton(tr("Install Runtime"), QMessageBox::ActionRole);
msgBox.addButton(QMessageBox::Ok);
msgBox.exec();
diff --git a/tracker-steamvr/steamvr.cpp b/tracker-steamvr/steamvr.cpp
index 9c357a7a..101f9e50 100644
--- a/tracker-steamvr/steamvr.cpp
+++ b/tracker-steamvr/steamvr.cpp
@@ -54,7 +54,9 @@ void steamvr::start_tracker(QFrame*)
if (!vr)
{
- QMessageBox::warning(nullptr, "Valve SteamVR init error", strerror(e), QMessageBox::Close, QMessageBox::NoButton);
+ QMessageBox::warning(nullptr,
+ QCoreApplication::translate("steamvr", "Valve SteamVR init error"), strerror(e),
+ QMessageBox::Close, QMessageBox::NoButton);
return;
}
@@ -69,7 +71,10 @@ void steamvr::start_tracker(QFrame*)
if (!ok)
{
- QMessageBox::warning(nullptr, "Valve SteamVR init warning", "No HMD connected", QMessageBox::Close, QMessageBox::NoButton);
+ QMessageBox::warning(nullptr,
+ QCoreApplication::translate("steamvr", "Valve SteamVR init warning"),
+ QCoreApplication::translate("steamvr", "No HMD connected"),
+ QMessageBox::Close, QMessageBox::NoButton);
return;
}
}