diff --git a/iOS/Info.plist b/iOS/Info.plist
index fe8a976..685071e 100644
--- a/iOS/Info.plist
+++ b/iOS/Info.plist
@@ -9,15 +9,17 @@
CFBundleExecutable
Vulkan Caps Viewer
CFBundleIconName
- vulkanCapsViewer.png
+ AppIcon
CFBundleIdentifier
$(PRODUCT_BUNDLE_IDENTIFIER)
+ CFBundleInfoDictionaryVersion
+ 6.0
CFBundleName
Vulkan Caps Viewer
CFBundlePackageType
APPL
CFBundleShortVersionString
- 1.0
+ 1.17
CFBundleSignature
????
CFBundleSupportedPlatforms
@@ -45,7 +47,7 @@
LSRequiresIPhoneOS
MinimumOSVersion
- 12.0
+ 15.0
NOTE
Ported to iOS by LunarG
UIDeviceFamily
diff --git a/settingsDialog.cpp b/settingsDialog.cpp
index 727a07a..75cc25f 100644
--- a/settingsDialog.cpp
+++ b/settingsDialog.cpp
@@ -69,8 +69,8 @@ settingsDialog::settingsDialog(Settings appSet)
formLayout->addRow(tr("Use proxy settings for upload"), createCheckBox("checkBoxUseProxy"));
QDialogButtonBox *buttonBox = new QDialogButtonBox(QDialogButtonBox::Ok | QDialogButtonBox::Cancel);
- connect(buttonBox, SIGNAL(accepted()), this, SLOT(slotAccept()));
- connect(buttonBox, SIGNAL(rejected()), this, SLOT(slotCancel()));
+ connect(buttonBox, SIGNAL(accepted()), this, SLOT(slotAccept()), Qt::QueuedConnection);
+ connect(buttonBox, SIGNAL(rejected()), this, SLOT(slotCancel()), Qt::QueuedConnection);
formLayout->addWidget(buttonBox);
diff --git a/submitDialog.cpp b/submitDialog.cpp
index 4f8d5a7..eeda042 100644
--- a/submitDialog.cpp
+++ b/submitDialog.cpp
@@ -29,6 +29,7 @@
#include
#include
#include
+#include
SubmitDialog::SubmitDialog(QString submitter, QString caption)
{
@@ -57,13 +58,13 @@ SubmitDialog::SubmitDialog(QString submitter, QString caption)
formLayout->addRow("Comment:", editComment);
QDialogButtonBox *buttonBox = new QDialogButtonBox(QDialogButtonBox::Ok | QDialogButtonBox::Cancel);
- connect(buttonBox, SIGNAL(accepted()), this, SLOT(slotAccept()));
- connect(buttonBox, SIGNAL(rejected()), this, SLOT(slotCancel()));
+ connect(buttonBox, SIGNAL(accepted()), this, SLOT(slotAccept()), Qt::QueuedConnection);
+ connect(buttonBox, SIGNAL(rejected()), this, SLOT(slotCancel()), Qt::QueuedConnection);
formLayout->addWidget(buttonBox);
setLayout(formLayout);
- setWindowTitle(caption);
+ setWindowTitle(caption);
}
diff --git a/vulkancapsviewer.cpp b/vulkancapsviewer.cpp
index ac51ad4..9ac39a5 100644
--- a/vulkancapsviewer.cpp
+++ b/vulkancapsviewer.cpp
@@ -71,9 +71,13 @@
#include
#endif
+#ifdef __APPLE__
+#include
+
#ifdef VK_USE_PLATFORM_IOS_MVK
extern "C" const char *getWorkingFolderForiOS(void);
#endif
+#endif
using std::to_string;
@@ -152,15 +156,15 @@ VulkanCapsViewer::VulkanCapsViewer(QWidget *parent)
ui.setupUi(this);
setWindowTitle("Vulkan Hardware Capability Viewer " + version);
// Connect slots
- connect(ui.comboBoxGPU, SIGNAL(currentIndexChanged(int)), this, SLOT(slotComboBoxGPUIndexChanged(int)));
- connect(ui.toolButtonUpload, SIGNAL(pressed()), this, SLOT(slotUploadReport()));
- connect(ui.toolButtonSave, SIGNAL(pressed()), this, SLOT(slotSaveReport()));
- connect(ui.toolButtonOnlineDevice, SIGNAL(pressed()), this, SLOT(slotDisplayOnlineReport()));
- connect(ui.toolButtonOnlineDataBase, SIGNAL(pressed()), this, SLOT(slotBrowseDatabase()));
- connect(ui.toolButtonAbout, SIGNAL(pressed()), this, SLOT(slotAbout()));
- connect(ui.toolButtonExit, SIGNAL(pressed()), this, SLOT(slotClose()));
- connect(ui.toolButtonSettings, SIGNAL(pressed()), this, SLOT(slotSettings()));
- connect(ui.comboBox, SIGNAL(currentIndexChanged(int)), this, SLOT(slotComboTabChanged(int)));
+ connect(ui.comboBoxGPU, SIGNAL(currentIndexChanged(int)), this, SLOT(slotComboBoxGPUIndexChanged(int)), Qt::QueuedConnection);
+ connect(ui.toolButtonUpload, SIGNAL(pressed()), this, SLOT(slotUploadReport()), Qt::QueuedConnection);
+ connect(ui.toolButtonSave, SIGNAL(pressed()), this, SLOT(slotSaveReport()), Qt::QueuedConnection);
+ connect(ui.toolButtonOnlineDevice, SIGNAL(pressed()), this, SLOT(slotDisplayOnlineReport()), Qt::QueuedConnection);
+ connect(ui.toolButtonOnlineDataBase, SIGNAL(pressed()), this, SLOT(slotBrowseDatabase()), Qt::QueuedConnection);
+ connect(ui.toolButtonAbout, SIGNAL(pressed()), this, SLOT(slotAbout()), Qt::QueuedConnection);
+ connect(ui.toolButtonExit, SIGNAL(pressed()), this, SLOT(slotClose()), Qt::QueuedConnection);
+ connect(ui.toolButtonSettings, SIGNAL(pressed()), this, SLOT(slotSettings()), Qt::QueuedConnection);
+ connect(ui.comboBox, SIGNAL(currentIndexChanged(int)), this, SLOT(slotComboTabChanged(int)), Qt::QueuedConnection);
qApp->setStyle(QStyleFactory::create("Fusion"));
boldFont.setBold(true);
@@ -601,13 +605,14 @@ bool VulkanCapsViewer::initVulkan()
#if defined(VK_USE_PLATFORM_XCB_KHR)
VK_KHR_XCB_SURFACE_EXTENSION_NAME,
#endif
-#if defined(VK_USE_PLATFORM_MACOS_MVK)
- VK_MVK_MACOS_SURFACE_EXTENSION_NAME,
-#endif
-
-#if defined(VK_USE_PLATFORM_IOS_MVK)
- VK_MVK_IOS_SURFACE_EXTENSION_NAME,
-#endif
+
+//#if defined(VK_USE_PLATFORM_MACOS_MVK)
+// VK_MVK_MACOS_SURFACE_EXTENSION_NAME,
+//#endif
+//
+//#if defined(VK_USE_PLATFORM_IOS_MVK)
+// VK_MVK_IOS_SURFACE_EXTENSION_NAME,
+//#endif
};
std::vector enabledExtensions = {};
@@ -620,6 +625,10 @@ bool VulkanCapsViewer::initVulkan()
if (availableExtensionCount != 0) {
enabledExtensions.push_back(VK_KHR_SURFACE_EXTENSION_NAME);
}
+
+#if __APPLE__
+ enabledExtensions.push_back("VK_EXT_metal_surface");
+#endif
std::vector surfaceExtensionsAvailable = {};
@@ -659,7 +668,7 @@ bool VulkanCapsViewer::initVulkan()
}
}
-#if defined(VK_USE_PLATFORM_MACOS_MVK) && (VK_HEADER_VERSION >= 216)
+#if defined(__APPLE__) && (VK_HEADER_VERSION >= 216)
instanceCreateInfo.flags = VK_INSTANCE_CREATE_ENUMERATE_PORTABILITY_BIT_KHR;
enabledExtensions.push_back(VK_KHR_PORTABILITY_ENUMERATION_EXTENSION_NAME);
enabledExtensions.push_back(VK_KHR_GET_PHYSICAL_DEVICE_PROPERTIES_2_EXTENSION_NAME);
@@ -785,25 +794,16 @@ bool VulkanCapsViewer::initVulkan()
}
#endif
-#if defined(VK_USE_PLATFORM_MACOS_MVK)
- if (surface_extension == VK_MVK_MACOS_SURFACE_EXTENSION_NAME) {
- VkMacOSSurfaceCreateInfoMVK surfaceCreateInfo = {};
- surfaceCreateInfo.sType = VK_STRUCTURE_TYPE_MACOS_SURFACE_CREATE_INFO_MVK;
- pMetalSurrogate = new QVukanSurrogate();
- surfaceCreateInfo.pView = (void*)pMetalSurrogate->winId();
- surfaceResult = vkCreateMacOSSurfaceMVK(vulkanContext.instance, &surfaceCreateInfo, nullptr, &vulkanContext.surface);
- }
+// This works for deskop and iOS devices
+#if __APPLE__
+ VkMetalSurfaceCreateInfoEXT info = {};
+ info.sType = VK_STRUCTURE_TYPE_METAL_SURFACE_CREATE_INFO_EXT;
+ info.pNext = nullptr;
+ info.pLayer = (void*)pMetalSurrogate->winId();
+ info.flags = 0;
+ vkCreateMetalSurfaceEXT(vulkanContext.instance, &info, nullptr, &vulkanContext.surface);
#endif
-#if defined(VK_USE_PLATFORM_IOS_MVK)
- if (surface_extension == VK_MVK_IOS_SURFACE_EXTENSION_NAME) {
- VkIOSSurfaceCreateInfoMVK surfaceCreateInfo = {};
- surfaceCreateInfo.sType = VK_STRUCTURE_TYPE_MACOS_SURFACE_CREATE_INFO_MVK;
- pMetalSurrogate = new QVukanSurrogate();
- surfaceCreateInfo.pView = (void*)pMetalSurrogate->winId();
- surfaceResult = vkCreateIOSSurfaceMVK(vulkanContext.instance, &surfaceCreateInfo, nullptr, &vulkanContext.surface);
- }
-#endif
if (surfaceResult == VK_SUCCESS) {
vulkanContext.surfaceExtension = surface_extension;
break;