godotengine / godot

Godot Engine – Multi-platform 2D and 3D game engine
https://godotengine.org
MIT License
91.17k stars 21.2k forks source link

Godot 4 - Linux start error #40299

Closed nonunknown closed 4 years ago

nonunknown commented 4 years ago

Godot version: 4.0 nightly build from @Calinou

OS/device including version: Ubuntu 20.04

Installed Drivers

vulkan-utils/focal,focal,now 1.2.131.1+dfsg1-1 all [installed]
  transitional package
vulkan-tools/focal,now 1.2.131.1+dfsg1-1 amd64 [installed,automatic]
  Miscellaneous Vulkan utilities
mesa-vulkan-drivers/focal-updates,now 20.0.8-0ubuntu1~20.04.1 amd64 [installed]
  Mesa Vulkan graphics drivers
libvulkan1/focal,now 1.2.131.2-1 amd64 [installed]
  Vulkan loader library
libvkd3d1/focal,now 1.1-4 amd64 [installed,automatic]
  Direct3D 12 to Vulkan translation - library

Issue description:

root@nonunknown-AHV:/home/nonunknown/Desktop/godot# ./godot4
Godot Engine v4.0.dev.calinou.d0cea291d - https://godotengine.org
ERROR: Cant find layer: VK_LAYER_KHRONOS_validation
   at: _check_layers (drivers/vulkan/vulkan_context.cpp:157)
ERROR: Cant find layer: VK_LAYER_LUNARG_standard_validation
   at: _check_layers (drivers/vulkan/vulkan_context.cpp:157)
ERROR: Cant find layer: VK_LAYER_GOOGLE_threading
   at: _check_layers (drivers/vulkan/vulkan_context.cpp:157)
ERROR: Condition "err" is true. Returning: ERR_CANT_CREATE
   at: _create_physical_device (drivers/vulkan/vulkan_context.cpp:349)
handle_crash: Program crashed with signal 11
Dumping the backtrace. Please include this when reporting the bug on https://github.com/godotengine/godot/issues
[1] /lib/x86_64-linux-gnu/libc.so.6(+0x46210) [0x7fb3a5535210] (??:0)
[2] ./godot4() [0x2a9a8b1] (??:?)
[3] ./godot4(vkDestroyFence+0x20) [0x2a9e6ed] (??:?)
[4] VulkanContext::~VulkanContext() (??:?)
[5] VulkanContextX11::~VulkanContextX11() (??:?)
[6] void memdelete<VulkanContextX11>(VulkanContextX11*) (??:?)
[7] DisplayServerX11::DisplayServerX11(String const&, DisplayServer::WindowMode, unsigned int, Vector2i const&, Error&) (??:?)
[8] DisplayServerX11::create_func(String const&, DisplayServer::WindowMode, unsigned int, Vector2i const&, Error&) (??:?)
[9] DisplayServer::create(int, String const&, DisplayServer::WindowMode, unsigned int, Vector2i const&, Error&) (??:?)
[10] Main::setup2(unsigned long) (??:?)
[11] Main::setup(char const*, int, char**, bool) (??:?)
[12] ./godot4(main+0xe1) [0x19e6403] (??:?)
[13] /lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0xf3) [0x7fb3a55160b3] (??:0)
[14] ./godot4(_start+0x29) [0x19e6279] (??:?)
-- END OF BACKTRACE --
Aborted (core dumped)

Steps to reproduce: Just execute

Minimal reproduction project: N/A

akien-mga commented 4 years ago

Can you run any Vulkan application?

Calinou commented 4 years ago

This is completely unrelated to the issue itself, but TIL GitHub lets you write bold in code blocks if you use a <b> tag within a <pre> tag (don't use triple backticks for the code block):

image

I learn something new every day. :no_mouth:

Juankz commented 4 years ago

I've seen this error, you need to install vulkan-validation-layers. And reboot

nonunknown commented 4 years ago

@Juankz vulkan-validation-layers this package doesnt exist. Also I tried LunarXchange sdk and when I run vkvia I get: VIA_ERROR: Vulkan failed to find a compatible driver. maybe my potato laptop doesnt support vulkan.

unrelated @Calinou I just got copy as HTML from terminal ;D

akien-mga commented 4 years ago

vulkan-validation-layers this package doesnt exist.

Fuzzy search is your friend :) On Ubuntu it's https://launchpad.net/ubuntu/+source/vulkan-validationlayers

But that only solves the first 3 errors (should be info messages really), the last one is the main issue: your GPU doesn't support Vulkan with the currently installed driver. What GPU is it?

nonunknown commented 4 years ago

Intel Graphics 3000 HD Intel(R) Core(TM) i3-2310M CPU @ 2.10GHz

akien-mga commented 4 years ago

Mesa on Linux provides Vulkan support for Intel Gen 8+: https://en.wikipedia.org/wiki/Mesa_(computer_graphics)#Table_of_Rendering_APIs

Intel Graphics HD 3000 is Gen 6, Sandy Bridge, so you're out of luck.

Not better on Windows as Intel provides Vulkan dirvers for Gen 9+ only: https://www.intel.com/content/www/us/en/support/articles/000005524/graphics.html

akien-mga commented 4 years ago

BTW, it would be great if you can test the next nightly builds (tomorrow probably) to confirm that #40354 works (it won't make Godot work for you, but it should show an error instead of crashing).

nonunknown commented 4 years ago

@akien-mga The test you told me to do:

Screenshot from 2020-07-15 13-36-24

Calinou commented 4 years ago

Speaking of which, the error message should be modified to specify which Vulkan version is required (1.0, 1.1, 1.2, …).