mirror of
https://github.com/overte-org/overte.git
synced 2025-04-08 07:12:40 +02:00
Use a higher thread priority for Oculus present
This commit is contained in:
parent
825fc1cfa1
commit
9bf4804d3d
3 changed files with 5 additions and 0 deletions
|
@ -165,6 +165,7 @@ public:
|
|||
|
||||
if (newPlugin) {
|
||||
bool hasVsync = true;
|
||||
QThread::setPriority(newPlugin->getPresentPriority());
|
||||
bool wantVsync = newPlugin->wantVsync();
|
||||
_context->makeCurrent();
|
||||
#if defined(Q_OS_WIN)
|
||||
|
|
|
@ -14,6 +14,7 @@
|
|||
#include <memory>
|
||||
#include <queue>
|
||||
|
||||
#include <QtCore/QThread>
|
||||
#include <QtCore/QTimer>
|
||||
#include <QtGui/QImage>
|
||||
|
||||
|
@ -80,6 +81,7 @@ protected:
|
|||
|
||||
void updateCompositeFramebuffer();
|
||||
|
||||
virtual QThread::Priority getPresentPriority() { return QThread::HighPriority; }
|
||||
virtual void compositeLayers();
|
||||
virtual void compositeScene();
|
||||
virtual void compositeOverlay();
|
||||
|
|
|
@ -24,6 +24,8 @@ public:
|
|||
virtual QJsonObject getHardwareStats() const;
|
||||
|
||||
protected:
|
||||
QThread::Priority getPresentPriority() override { return QThread::TimeCriticalPriority; }
|
||||
|
||||
bool internalActivate() override;
|
||||
void hmdPresent() override;
|
||||
bool isHmdMounted() const override;
|
||||
|
|
Loading…
Reference in a new issue