From 49e0cc046e284f9fda19f83e25564a6a7110df63 Mon Sep 17 00:00:00 2001 From: Simon Ser Date: Tue, 2 Feb 2021 11:56:51 +0100 Subject: [PATCH] Move Vulkan init into main Some Wayland server setup will need Vulkan initialized. --- src/main.cpp | 6 ++++++ src/steamcompmgr.cpp | 6 ------ 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/main.cpp b/src/main.cpp index ce8ba22..9bbb3a6 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -179,6 +179,12 @@ int main(int argc, char **argv) return 1; } + if ( vulkan_init() != True ) + { + fprintf( stderr, "Failed to initialize Vulkan\n" ); + return 1; + } + // Prevent our clients from connecting to the parent compositor unsetenv("WAYLAND_DISPLAY"); diff --git a/src/steamcompmgr.cpp b/src/steamcompmgr.cpp index e738ac4..333dae3 100644 --- a/src/steamcompmgr.cpp +++ b/src/steamcompmgr.cpp @@ -2866,12 +2866,6 @@ steamcompmgr_main (int argc, char **argv) allDamage = None; clipChanged = True; - if ( vulkan_init() != True ) - { - fprintf (stderr, "Failed to initialize Vulkan device!\n"); - exit( 1 ); - } - vblank_init(); currentOutputWidth = g_nOutputWidth;