4#include <QGuiApplication>
5#include <QVulkanFunctions>
6#include <QVulkanInstance>
19 int main(
int argc,
char **argv)
41 inst.setLayers({
"VK_LAYER_KHRONOS_validation" });
43 bool ok = inst.create();
48 if (!inst.layers().contains(
"VK_LAYER_KHRONOS_validation")) {
59 if (inst.supportedLayers().contains(
"VK_LAYER_KHRONOS_validation")) {
62 bool ok = inst.create();
88 uint32_t devCount = 0;
89 f->vkEnumeratePhysicalDevices(inst->vkInstance(), &devCount,
nullptr);
109 bool m_initialized =
false;
117 if (!inst.create()) {
static int exec()
Enters the main event loop and waits until exit() is called, then returns the value that was set to e...
The QExposeEvent class contains event parameters for expose events. \inmodule QtGui.
The QVulkanFunctions class provides cross-platform access to the instance level core Vulkan 1....
The QVulkanInstance class represents a native Vulkan instance, enabling Vulkan rendering onto a QSurf...
virtual bool event(QEvent *) override
Override this to handle any event (ev) sent to the window.
bool event(QEvent *e)
Override this to handle any event (ev) sent to the window.
void exposeEvent(QExposeEvent *)
The expose event (ev) is sent by the window system when a window moves between the un-exposed and exp...
QApplication app(argc, argv)
[0]
void setVulkanInstance(QVulkanInstance *instance)