Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion ci/common.deps.sh
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ CI_PLATFORM="${1:-DEFAULT}"
if [[ "$CI_PLATFORM" != "WASM" ]];
then
clone_addon https://github.com/ossia/score-addon-ltc
clone_addon https://github.com/ossia/score-addon-ndi
# clone_addon https://github.com/ossia/score-addon-ndi
clone_addon https://github.com/bltzr/score-avnd-granola
clone_addon https://github.com/ossia/score-addon-ultraleap
clone_addon https://github.com/ossia/score-addon-contextfree
Expand Down
16 changes: 16 additions & 0 deletions src/app/Application.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -230,6 +230,17 @@ Application::Application(int& argc, char** argv)
}

m_app = createApplication(appSettings, argc, argv);

#if defined(QT_FEATURE_thread)
#if QT_FEATURE_thread == 1
this->thread()->setPriority(QThread::Priority::TimeCriticalPriority);
QThreadPool::globalInstance()->setMaxThreadCount(2);
QThreadPool::globalInstance()->setThreadPriority(QThread::Priority::HighPriority);
#if QT_VERSION >= QT_VERSION_CHECK(6, 9, 0)
QThreadPool::globalInstance()->setServiceLevel(QThread::QualityOfService::High);
#endif
#endif
#endif
}

Application::Application(
Expand Down Expand Up @@ -445,7 +456,12 @@ void Application::init()

#if defined(QT_FEATURE_thread)
#if QT_FEATURE_thread == 1
this->thread()->setPriority(QThread::Priority::TimeCriticalPriority);
QThreadPool::globalInstance()->setMaxThreadCount(2);
QThreadPool::globalInstance()->setThreadPriority(QThread::Priority::HighPriority);
#if QT_VERSION >= QT_VERSION_CHECK(6, 9, 0)
QThreadPool::globalInstance()->setServiceLevel(QThread::QualityOfService::High);
#endif
#endif
#endif

Expand Down
8 changes: 7 additions & 1 deletion src/app/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -408,7 +408,13 @@ struct increase_timer_precision

// Then maybe we can go a bit lower...
ULONG currentRes{};
NtSetTimerResolution(100, TRUE, &currentRes);
NtSetTimerResolution(7500, TRUE, &currentRes);
if(currentRes <= 8000)
NtSetTimerResolution(5000, TRUE, &currentRes);
if(currentRes <= 6000)
NtSetTimerResolution(2500, TRUE, &currentRes);
if(currentRes <= 3000)
NtSetTimerResolution(1000, TRUE, &currentRes);
#endif
}

Expand Down
2 changes: 2 additions & 0 deletions src/lib/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -237,6 +237,7 @@ set(HEADERS
"${CMAKE_CURRENT_SOURCE_DIR}/score/tools/Unused.hpp"
"${CMAKE_CURRENT_SOURCE_DIR}/score/tools/RecursiveWatch.hpp"
"${CMAKE_CURRENT_SOURCE_DIR}/score/tools/ThreadPool.hpp"
"${CMAKE_CURRENT_SOURCE_DIR}/score/tools/Timers.hpp"
"${CMAKE_CURRENT_SOURCE_DIR}/score/tools/Debug.hpp"
"${CMAKE_CURRENT_SOURCE_DIR}/score/tools/Version.hpp"
"${CMAKE_CURRENT_SOURCE_DIR}/score/tools/exceptions/MissingCommand.hpp"
Expand Down Expand Up @@ -511,6 +512,7 @@ set(SRCS
"${CMAKE_CURRENT_SOURCE_DIR}/score/widgets/SpinBoxes.cpp"

"${CMAKE_CURRENT_SOURCE_DIR}/score/tools/ListNetworkAddresses.cpp"
"${CMAKE_CURRENT_SOURCE_DIR}/score/tools/Timers.cpp"

"${CMAKE_CURRENT_SOURCE_DIR}/core/application/SafeQApplication.cpp"
"${CMAKE_CURRENT_SOURCE_DIR}/core/application/ApplicationInterface.cpp"
Expand Down
12 changes: 11 additions & 1 deletion src/lib/score/gfx/Vulkan.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,16 @@
#if defined(QT_FEATURE_vulkan) && QT_CONFIG(vulkan) && __has_include(<vulkan/vulkan.h>)
#include <QVulkanInstance>

#if __has_include(<QtGui/private/qrhi_p.h>)
#include <QtGui/private/qrhi_p.h>
#endif

#if __has_include(<rhi/qrhi_platform.h>)
#include <rhi/qrhi_platform.h>
#elif __has_include(<private/qrhivulkan_p.h>)
#include <private/qrhivulkan_p.h>
#endif

#include <mutex>
namespace score::gfx
{
Expand All @@ -27,7 +37,7 @@ QVulkanInstance* staticVulkanInstance(bool create)
#endif

QByteArrayList exts;
exts << "VK_KHR_get_physical_device_properties2";
exts << QRhiVulkanInitParams::preferredInstanceExtensions();

if(auto v = instance.supportedApiVersion(); v >= QVersionNumber(1, 1))
{
Expand Down
Loading
Loading