Open AlbertoGP opened 1 year ago
This is probably caused due to the somewhat large limits that forma is currently asking for. We can definitely do better here. Could you please run wgpu-info and provide the two values that we're asking for?
Hi, thanks for taking the time to look into this.
Max Texture Dimension 2d: 16384
Max Storage Buffer Binding Size: 536870912
@AlbertoGP can you please try changing line 72 in gpu/renderer/mod.rs
from this:
max_storage_buffer_binding_size: 1 << 30,
to this:
max_storage_buffer_binding_size: 1 << 29,
And running again?
I tried a few values all the way down to 1<<20
and it still fails in the same way.
Now, I did put a eprintln!()
in front of those lines (let desc = …
) and it does not come out on the console, it looks like those lines do not get run.
I was trying with the cpu
device, but I tried again with l
and with h
just in case: I get the same error message, but at a different location inside demo/src/runner.rs
, like 257 this time which makes sense because it’s inside impl GpuRunner
instead of impl CpuRunner
.
CPU: cargo run --release -- cpu spaceship
GPU: cargo run --release -- l spaceship
, cargo run --release -- h spaceship
(same result for both)
any update? I have this error as well and don't know what to do
The way to troubleshoot this is to compare the difference in how the DeviceDescriptor
is configured for the skybox example shared by @AlbertoGP (wgpu$ cargo run --release --example skybox
) and what forma is using. I haven't been able to find time to look at it in detail (maybe I'll take a look at it later today) but if one of you guys @AlbertoGP @vixalien can try on your own that would be really helpful. Take a look at Code in wgpu skybox example's DeviceDescriptor
in these files: https://github.com/gfx-rs/wgpu/blob/master/wgpu/examples/framework.rs#L223 and https://github.com/gfx-rs/wgpu/blob/master/wgpu/examples/skybox/main.rs
I don't really understand rust so unless you provide really specific instructions, I don't think I may be of good use
@AlbertoGP, could you please test the hello compute and hello triangle example in wgpu? https://github.com/gfx-rs/wgpu/tree/master/wgpu/examples
Sure, here is the result:
$ cargo run --release --example hello-compute 1 4 3 295
Finished release [optimized] target(s) in 0.19s
Running `target/release/examples/hello-compute 1 4 3 295`
[2022-12-20T18:40:06Z ERROR wgpu_hal::vulkan::instance] enumerate_adapters: Initialization of an object has failed
Steps: [0, 2, 7, 55]
$ cargo run --release --example hello-triangle
Compiling wgpu v0.14.0 (/tmp/ramdisk/wgpu/wgpu)
Finished release [optimized] target(s) in 6.53s
Running `target/release/examples/hello-triangle`
[2022-12-20T18:38:04Z ERROR wgpu_hal::vulkan::instance] enumerate_adapters: Initialization of an object has failed
Both seem to work fine: hello-compute
gives the same result as reported in wgpu/examples/hello-compute/README.md
, and hello-triangle
shows the red isosceles triangle over green background that adapts when you resize the window.
I was also looking at: https://github.com/gfx-rs/wgpu/issues/2123
In their case, they had some issues with getting the display. If you have the time, could you please run our example in the debugger to see exactly why wgpu fails to return an adapter?
Maybe running vulkaninfo
will also bring up some issues with your setup.
Well, vulkaninfo
does not run because Vulkan does not work on this graphic card (Radeon 7990): it did work on this very system before with an AMD GPU of the Polaris class: that card stopped working and was replaced by this one, without adding or removing any packages.
Is there some way of getting a (probably slow) render just using the CPU?
Sure, here is the result:
$ cargo run --release --example hello-compute 1 4 3 295 Finished release [optimized] target(s) in 0.19s Running `target/release/examples/hello-compute 1 4 3 295` [2022-12-20T18:40:06Z ERROR wgpu_hal::vulkan::instance] enumerate_adapters: Initialization of an object has failed Steps: [0, 2, 7, 55]
$ cargo run --release --example hello-triangle Compiling wgpu v0.14.0 (/tmp/ramdisk/wgpu/wgpu) Finished release [optimized] target(s) in 6.53s Running `target/release/examples/hello-triangle` [2022-12-20T18:38:04Z ERROR wgpu_hal::vulkan::instance] enumerate_adapters: Initialization of an object has failed
Both seem to work fine:
hello-compute
gives the same result as reported inwgpu/examples/hello-compute/README.md
, andhello-triangle
shows the red isosceles triangle over green background that adapts when you resize the window.
works for me too
update: it works for me, after I git pull
ed
Hi, just testing it on Linux ppc64le (IBM PowerPC 64-bit Little-Endian) with an old graphics card and I get this error message, which has probably more to do with wgpu-rs but might be useful to have as reference:
The backtrace is not informative, just says that this happened inside
main()
and the rest is boilerplate, but I’ll add it if you request it.I’ve just tried
wgpu-rs
in case the problem was there, and the examples run although with an error message:This and other examples run, although
examples/hello
does not:I was surprised because I thought that using the
cpu
device the graphic card would not matter.