From 9de276fb2f8c2c79f1aeabea377b8b2581e04074 Mon Sep 17 00:00:00 2001 From: Slawomir Cygan Date: Mon, 24 Aug 2020 17:01:15 +0200 Subject: [PATCH] Set dEQP process to be high-dpi aware on Windows On systems with DPI scaling enabled the thread should be high-DPI aware to create windows, that could be used for exlusive full-screen swapchains with application control. Components: Vulkan, Framework VK-GL-CTS Issue: 2558 Affects: dEQP-VK.wsi.win32.full_screen_exclusive.application_controlled Change-Id: Ibfedb804d902ef41eafcb10cde0d3c2d8e281797 --- framework/platform/win32/tcuWin32Platform.cpp | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/framework/platform/win32/tcuWin32Platform.cpp b/framework/platform/win32/tcuWin32Platform.cpp index 0517c60..bd38dbd 100644 --- a/framework/platform/win32/tcuWin32Platform.cpp +++ b/framework/platform/win32/tcuWin32Platform.cpp @@ -38,6 +38,15 @@ Platform::Platform (void) // Set process priority to lower. SetPriorityClass(GetCurrentProcess(), BELOW_NORMAL_PRIORITY_CLASS); + + // Set process to be DPI aware + // This is requried for VK tests that manually enter exclusive mode + // using VK_FULL_SCREEN_EXCLUSIVE_APPLICATION_CONTROLLED_EXT + if (SetProcessDPIAware() == 0) + { + TCU_FAIL("SetProcessDPIAware function failed"); + } + { wgl::ContextFactory* factory = DE_NULL; -- 2.7.4