diff options
author | RĂ©mi Verschelde <rverschelde@gmail.com> | 2020-07-14 09:03:25 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-07-14 09:03:25 +0200 |
commit | 28e8347d6cb1e5e8945ba62b9678849046038bb6 (patch) | |
tree | 8e04d15eac7b6d4cba1b55e57452399a31a584de /platform/android | |
parent | 41802d83975a52a4f6c23de0bceaa0e055031ee1 (diff) | |
parent | 996910b62706774792bde4934e23ef5bde37fc32 (diff) |
Merge pull request #40354 from bruvzg/add_vulkan_init_message
Display error popup instead of crashing if Vulkan init failed.
Diffstat (limited to 'platform/android')
-rw-r--r-- | platform/android/display_server_android.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/platform/android/display_server_android.cpp b/platform/android/display_server_android.cpp index 1436d832de..1fb0d7ef60 100644 --- a/platform/android/display_server_android.cpp +++ b/platform/android/display_server_android.cpp @@ -360,7 +360,11 @@ Vector<String> DisplayServerAndroid::get_rendering_drivers_func() { } DisplayServer *DisplayServerAndroid::create_func(const String &p_rendering_driver, DisplayServer::WindowMode p_mode, uint32_t p_flags, const Vector2i &p_resolution, Error &r_error) { - return memnew(DisplayServerAndroid(p_rendering_driver, p_mode, p_flags, p_resolution, r_error)); + DisplayServer *ds = memnew(DisplayServerAndroid(p_rendering_driver, p_mode, p_flags, p_resolution, r_error)); + if (r_error != OK) { + ds->alert("Your video card driver does not support any of the supported Vulkan versions.", "Unable to initialize Video driver"); + } + return ds; } void DisplayServerAndroid::register_android_driver() { |