PolyMeilex / Neothesia

Flashy Synthesia Like Software For Linux,Windows and MacOs
GNU General Public License v3.0
983 stars 62 forks source link

Neothesia can't start on Windows 7 #31

Closed GunGunGun closed 4 months ago

GunGunGun commented 1 year ago

I run neothesia.exe and the program opens for 0.5s then close immidiately, this is my log:


D:\PortableApp\Synthesia>neothesia.exe
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: AdapterRequest', src\lib.rs:73:61
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

D:\PortableApp\Synthesia>set RUST_BACKTRACE=1

D:\PortableApp\Synthesia>neothesia.exe
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: AdapterRequest', src\lib.rs:73:61
stack backtrace:
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.

D:\PortableApp\Synthesia>neothesia.exe
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: AdapterRequest', src\lib.rs:73:61
stack backtrace:
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.

D:\PortableApp\Synthesia>neothesia.exe
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: AdapterRequest', src\lib.rs:73:61
stack backtrace:
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.

D:\PortableApp\Synthesia>neothesia.exe
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: AdapterRequest', src\lib.rs:73:61
stack backtrace:
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.

D:\PortableApp\Synthesia>neothesia.exe
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: AdapterRequest', src\lib.rs:73:61
stack backtrace:
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.

D:\PortableApp\Synthesia>neothesia.exe
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: AdapterRequest', src\lib.rs:73:61
stack backtrace:
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.

D:\PortableApp\Synthesia>neothesia.exe
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: AdapterRequest', src\lib.rs:73:61
stack backtrace:
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.

D:\PortableApp\Synthesia>neothesia.exe -h
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: AdapterRequest', src\lib.rs:73:61
stack backtrace:
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.

D:\PortableApp\Synthesia>neothesia.exe /?
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: AdapterRequest', src\lib.rs:73:61
stack backtrace:
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.

D:\PortableApp\Synthesia>neothesia.exe --help
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: AdapterRequest', src\lib.rs:73:61
stack backtrace:
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.

D:\PortableApp\Synthesia>neothesia.exe -help
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: AdapterRequest', src\lib.rs:73:61
stack backtrace:
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.

D:\PortableApp\Synthesia>set RUST_BACKTRACE=full

D:\PortableApp\Synthesia>neothesia.exe -help
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: AdapterRequest', src\lib.rs:73:61
stack backtrace:
   0:        0x140461d9f - <unknown>
   1:        0x14047aefa - <unknown>
   2:        0x14045e9e9 - <unknown>
   3:        0x1404645bb - <unknown>
   4:        0x14046423b - <unknown>
   5:        0x140464b69 - <unknown>
   6:        0x140464a6d - <unknown>
   7:        0x140462727 - <unknown>
   8:        0x140464749 - <unknown>
   9:        0x1404a7ee5 - <unknown>
  10:        0x1404a7ff3 - <unknown>
  11:        0x13fea31fd - <unknown>
  12:        0x13fe8a7db - <unknown>
  13:        0x13fe59ea6 - <unknown>
  14:        0x13fe5bcfc - <unknown>
  15:        0x1404571b1 - <unknown>
  16:        0x13fe8acf7 - <unknown>
  17:        0x140482d50 - <unknown>
  18:         0x76b259cd - BaseThreadInitThunk
  19:         0x76d8383d - RtlUserThreadStart

D:\PortableApp\Synthesia>neothesia.exe
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: AdapterRequest', src\lib.rs:73:61
stack backtrace:
   0:        0x13f8e1d9f - <unknown>
   1:        0x13f8faefa - <unknown>
   2:        0x13f8de9e9 - <unknown>
   3:        0x13f8e45bb - <unknown>
   4:        0x13f8e423b - <unknown>
   5:        0x13f8e4b69 - <unknown>
   6:        0x13f8e4a6d - <unknown>
   7:        0x13f8e2727 - <unknown>
   8:        0x13f8e4749 - <unknown>
   9:        0x13f927ee5 - <unknown>
  10:        0x13f927ff3 - <unknown>
  11:        0x13f3231fd - <unknown>
  12:        0x13f30a7db - <unknown>
  13:        0x13f2d9ea6 - <unknown>
  14:        0x13f2dbcfc - <unknown>
  15:        0x13f8d71b1 - <unknown>
  16:        0x13f30acf7 - <unknown>
  17:        0x13f902d50 - <unknown>
  18:         0x76b259cd - BaseThreadInitThunk
  19:         0x76d8383d - RtlUserThreadStart

D:\PortableApp\Synthesia>
PolyMeilex commented 1 year ago

wgpu (graphics api used by Neothesia) fails to initialize DX12 (Win 10 addition), and it's DX11 backend is still in WIP/TODO, so the next fallback is probably Vulkan but that fails as well for some reason (most likely your GPU driver does not support it?)

GunGunGun commented 1 year ago

wgpu (graphics api used by Neothesia) fails to initialize DX12 (Win 10 addition), and it's DX11 backend is still in WIP/TODO, so the next fallback is probably Vulkan but that fails as well for some reason (most likely your GPU driver does not support it?)

Yes, my driver doesn't support Vulkan, but it could run Piano from Above and Synthesia just fine.

commandblock2 commented 1 year ago

It also happens with RV620/M82 [Mobility Radeon HD 3450/3470] (Ancient card around 2010) on manjaro probably using opensource radeon driver. Totally newbie to graphics, but why do we need to support different backends? I though with wgpu we can use backend agnostic code, is there some features that we are using that are currently not covered by wgpu? or is there anything more complicated going on?

    ~/Neothesia    master    RUST_BACKTRACE=full ./target/release/neothesia                ✔  52s  
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: DeviceRequest(RequestDeviceError)', src/main.rs:234:91
stack backtrace:
   0:     0x5560a87600c0 - std::backtrace_rs::backtrace::libunwind::trace::hb9d4ab162544b2dc
                               at /rustc/90743e7298aca107ddaa0c202a4d3604e29bfeb6/library/std/src/../../backtrace/src/backtrace/libunwind.rs:93:5
   1:     0x5560a87600c0 - std::backtrace_rs::backtrace::trace_unsynchronized::hfb2460e71f117410
                               at /rustc/90743e7298aca107ddaa0c202a4d3604e29bfeb6/library/std/src/../../backtrace/src/backtrace/mod.rs:66:5
   2:     0x5560a87600c0 - std::sys_common::backtrace::_print_fmt::h590b28d5011bb59c
                               at /rustc/90743e7298aca107ddaa0c202a4d3604e29bfeb6/library/std/src/sys_common/backtrace.rs:65:5
   3:     0x5560a87600c0 - <std::sys_common::backtrace::_print::DisplayBacktrace as core::fmt::Display>::fmt::h014c1a2f1c251e02
                               at /rustc/90743e7298aca107ddaa0c202a4d3604e29bfeb6/library/std/src/sys_common/backtrace.rs:44:22
   4:     0x5560a87827de - core::fmt::write::h05a61a757499c813
                               at /rustc/90743e7298aca107ddaa0c202a4d3604e29bfeb6/library/core/src/fmt/mod.rs:1209:17
   5:     0x5560a875d245 - std::io::Write::write_fmt::h51649d971bd272da
                               at /rustc/90743e7298aca107ddaa0c202a4d3604e29bfeb6/library/std/src/io/mod.rs:1682:15
   6:     0x5560a875fe85 - std::sys_common::backtrace::_print::hf24f2e23f9f53ea0
                               at /rustc/90743e7298aca107ddaa0c202a4d3604e29bfeb6/library/std/src/sys_common/backtrace.rs:47:5
   7:     0x5560a875fe85 - std::sys_common::backtrace::print::h7d93659208dac6ec
                               at /rustc/90743e7298aca107ddaa0c202a4d3604e29bfeb6/library/std/src/sys_common/backtrace.rs:34:9
   8:     0x5560a876173f - std::panicking::default_hook::{{closure}}::h09ebca33416689de
                               at /rustc/90743e7298aca107ddaa0c202a4d3604e29bfeb6/library/std/src/panicking.rs:267:22
   9:     0x5560a876147a - std::panicking::default_hook::h765ecbbc01460791
                               at /rustc/90743e7298aca107ddaa0c202a4d3604e29bfeb6/library/std/src/panicking.rs:286:9
  10:     0x5560a8761e38 - std::panicking::rust_panic_with_hook::h7a788c0dbfbe500c
                               at /rustc/90743e7298aca107ddaa0c202a4d3604e29bfeb6/library/std/src/panicking.rs:688:13
  11:     0x5560a8761bd7 - std::panicking::begin_panic_handler::{{closure}}::h10c0bd693c8329f8
                               at /rustc/90743e7298aca107ddaa0c202a4d3604e29bfeb6/library/std/src/panicking.rs:579:13
  12:     0x5560a876056c - std::sys_common::backtrace::__rust_end_short_backtrace::h0dfae764c220091d
                               at /rustc/90743e7298aca107ddaa0c202a4d3604e29bfeb6/library/std/src/sys_common/backtrace.rs:137:18
  13:     0x5560a87618f2 - rust_begin_unwind
                               at /rustc/90743e7298aca107ddaa0c202a4d3604e29bfeb6/library/std/src/panicking.rs:575:5
  14:     0x5560a7fed123 - core::panicking::panic_fmt::h609caf9d102b7e38
                               at /rustc/90743e7298aca107ddaa0c202a4d3604e29bfeb6/library/core/src/panicking.rs:65:14
  15:     0x5560a7fed3e3 - core::result::unwrap_failed::hd540fe6b13a2834e
                               at /rustc/90743e7298aca107ddaa0c202a4d3604e29bfeb6/library/core/src/result.rs:1791:5
  16:     0x5560a804ff8e - neothesia::main::h2ea72fce09c840a1
  17:     0x5560a80428e3 - std::sys_common::backtrace::__rust_begin_short_backtrace::h86c0eea56669ec56
  18:     0x5560a80428f9 - std::rt::lang_start::{{closure}}::h3545d26d9bdcf60b
  19:     0x5560a8757d5b - core::ops::function::impls::<impl core::ops::function::FnOnce<A> for &F>::call_once::hdaf7228e581d5b92
                               at /rustc/90743e7298aca107ddaa0c202a4d3604e29bfeb6/library/core/src/ops/function.rs:286:13
  20:     0x5560a8757d5b - std::panicking::try::do_call::ha44593fcf25461cd
                               at /rustc/90743e7298aca107ddaa0c202a4d3604e29bfeb6/library/std/src/panicking.rs:483:40
  21:     0x5560a8757d5b - std::panicking::try::hb842e1c63025973e
                               at /rustc/90743e7298aca107ddaa0c202a4d3604e29bfeb6/library/std/src/panicking.rs:447:19
  22:     0x5560a8757d5b - std::panic::catch_unwind::hc6f5bfa4ae24c9df
                               at /rustc/90743e7298aca107ddaa0c202a4d3604e29bfeb6/library/std/src/panic.rs:137:14
  23:     0x5560a8757d5b - std::rt::lang_start_internal::{{closure}}::h2ca008097fbec8a5
                               at /rustc/90743e7298aca107ddaa0c202a4d3604e29bfeb6/library/std/src/rt.rs:148:48
  24:     0x5560a8757d5b - std::panicking::try::do_call::h44dc1c25acbbd94a
                               at /rustc/90743e7298aca107ddaa0c202a4d3604e29bfeb6/library/std/src/panicking.rs:483:40
  25:     0x5560a8757d5b - std::panicking::try::h07aeb67e414a5f18
                               at /rustc/90743e7298aca107ddaa0c202a4d3604e29bfeb6/library/std/src/panicking.rs:447:19
  26:     0x5560a8757d5b - std::panic::catch_unwind::h72da57663254be20
                               at /rustc/90743e7298aca107ddaa0c202a4d3604e29bfeb6/library/std/src/panic.rs:137:14
  27:     0x5560a8757d5b - std::rt::lang_start_internal::h6571a4b5f4cfd159
                               at /rustc/90743e7298aca107ddaa0c202a4d3604e29bfeb6/library/std/src/rt.rs:148:20
  28:     0x5560a80506f5 - main
  29:     0x7f00b90e8290 - <unknown>
  30:     0x7f00b90e834a - __libc_start_main
  31:     0x5560a7fed575 - _start
  32:                0x0 - <unknown>
ghost commented 1 year ago

I can confirm it does not work on Windows XP as well

commandblock2 commented 1 year ago

with RUST_LOG=info RUST_BACKTRACE=1 cargo run it gives following output, it seems the card doesn't support vulkan indeed.

    ~/Neothesia    master ?1     RUST_LOG=info RUST_BACKTRACE=1 cargo run                          ✔ 
    Finished dev [unoptimized + debuginfo] target(s) in 9.07s
     Running `target/debug/neothesia`
[2023-02-01T03:52:11Z INFO  winit::platform_impl::platform::x11::window] Guessed window scale factor: 1.0833333333333333
[2023-02-01T03:52:12Z INFO  wgpu_hal::vulkan::instance] Unable to find extension: VK_EXT_swapchain_colorspace
[2023-02-01T03:52:12Z WARN  wgpu_hal::vulkan::instance] Unable to find layer: VK_LAYER_KHRONOS_validation
[2023-02-01T03:52:12Z INFO  wgpu_hal::vulkan::instance] Instance version: 0x4030eb
[2023-02-01T03:52:12Z INFO  wgpu_hal::vulkan::instance] Enabling debug utils
[2023-02-01T03:52:12Z INFO  wgpu_hal::vulkan::instance] Enabling device properties2
[2023-02-01T03:52:12Z INFO  wgpu_hal::gles::egl] Loading Wayland library to get the current display
[2023-02-01T03:52:12Z INFO  wgpu_hal::gles::egl] Loading X11 library to get the current display
[2023-02-01T03:52:12Z INFO  wgpu_hal::gles::egl] Using X11 platform
[2023-02-01T03:52:12Z INFO  wgpu_hal::gles::egl] Enabling EGL debug output
[2023-02-01T03:52:12Z INFO  wgpu_hal::gles::egl] Display vendor "Mesa Project", version (1, 5)
[2023-02-01T03:52:12Z INFO  wgpu_hal::gles::egl]        EGL surface: +srgb
[2023-02-01T03:52:12Z INFO  wgpu_hal::gles::egl]        Trying native-render
[2023-02-01T03:52:12Z INFO  wgpu_hal::gles::egl]        EGL context: +debug
[2023-02-01T03:52:12Z INFO  wgpu_hal::gles::egl]        EGL context: +robust access EXT
[2023-02-01T03:52:12Z INFO  wgpu_hal::gles::egl]        EGL context: +surfaceless
[2023-02-01T03:52:12Z ERROR wgpu_hal::vulkan::instance] GENERAL [../mesa-22.3.3/src/amd/vulkan/radv_device.c:741 (0x0)]
        Device '/dev/dri/renderD128' is not using the AMDGPU kernel driver: Invalid argument (VK_ERROR_INCOMPATIBLE_DRIVER)
[2023-02-01T03:52:12Z ERROR wgpu_hal::vulkan::instance]         objects: (type: INSTANCE, hndl: 0x55c0a8c95710, name: ?)
[2023-02-01T03:52:12Z ERROR wgpu_hal::vulkan::instance] GENERAL [Loader Message (0x0)]
        setup_loader_term_phys_devs:  Failed to detect any valid GPUs in the current config
[2023-02-01T03:52:12Z ERROR wgpu_hal::vulkan::instance]         objects: (type: INSTANCE, hndl: 0x55c0a8bbc080, name: ?)
[2023-02-01T03:52:12Z ERROR wgpu_hal::vulkan::instance] enumerate_adapters: Initialization of an object has failed
[2023-02-01T03:52:12Z INFO  wgpu_hal::gles::egl] Max label length: 256
[2023-02-01T03:52:12Z INFO  wgpu_hal::gles::egl] Enabling GLES debug output
[2023-02-01T03:52:12Z INFO  wgpu_hal::gles::adapter] Vendor: X.Org
[2023-02-01T03:52:12Z INFO  wgpu_hal::gles::adapter] Renderer: AMD RV620 (DRM 2.50.0 / 6.1.7-1-MANJARO, LLVM 15.0.7)
[2023-02-01T03:52:12Z INFO  wgpu_hal::gles::adapter] Version: OpenGL ES 3.0 Mesa 22.3.3
[2023-02-01T03:52:12Z INFO  wgpu_hal::gles::adapter] SL version: OpenGL ES GLSL ES 3.00
[2023-02-01T03:52:12Z INFO  wgpu_core::instance] Adapter Gl AdapterInfo { name: "AMD RV620 (DRM 2.50.0 / 6.1.7-1-MANJARO, LLVM 15.0.7)", vendor: 0, device: 0, device_type: Other, driver: "", driver_info: "", backend: Gl }
[2023-02-01T03:52:12Z ERROR wgpu::backend::direct] Error in Adapter::request_device: Limit 'max_compute_workgroups_per_dimension' value 65535 is better than allowed 0
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: DeviceRequest(RequestDeviceError)', src/main.rs:234:91
stack backtrace:
   0: rust_begin_unwind
             at /rustc/90743e7298aca107ddaa0c202a4d3604e29bfeb6/library/std/src/panicking.rs:575:5
   1: core::panicking::panic_fmt
             at /rustc/90743e7298aca107ddaa0c202a4d3604e29bfeb6/library/core/src/panicking.rs:65:14
   2: core::result::unwrap_failed
             at /rustc/90743e7298aca107ddaa0c202a4d3604e29bfeb6/library/core/src/result.rs:1791:5
   3: core::result::Result<T,E>::unwrap
             at /rustc/90743e7298aca107ddaa0c202a4d3604e29bfeb6/library/core/src/result.rs:1113:23
   4: neothesia::init
             at ./src/main.rs:234:9
   5: neothesia::main
             at ./src/main.rs:170:41
   6: core::ops::function::FnOnce::call_once
             at /rustc/90743e7298aca107ddaa0c202a4d3604e29bfeb6/library/core/src/ops/function.rs:251:5
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.
[2023-02-01T03:52:16Z INFO  wgpu_core::hub] Dropping Global
PolyMeilex commented 1 year ago

@commandblock2 wgpu does not require backend specific code, but sometimes it simply can't bypass stuff like hardware simply missing some functionality, in case of windows it's DX11 backend is still WIP. In your case it looks more promising it successfully fallbacked from Vulkan to OpenGL (cause it looks like your card is "modern" enough to support GLES 3) but it failed on the hardware init stage (lack of compute units), thankfully Neothesia does not use them atm, so I disabled those all together.

Here is a test build with that disabled: https://github.com/PolyMeilex/Neothesia/actions/runs/4063496299 Binaries are at the bottom of the page, would be nice if you could test that