Open ghost opened 5 years ago
Thanks for the report! Hopefully, someone with Windows10 can take a look at it shortly. In the meantime, you could help (unless you want to look at it yourself?) by setting RUST_BACKTRACE=1
and providing us with the stack trace.
@kvark Finally I figured out it's a environment variable.
Hm, this error looks to be within the wio
dependency of gfx, but it compiled alright... :v
Does your gpu support dx12?
@msiglreith According to
Yes. I do also've the D3D12.dll in System32.
Thanks, it's actually on of the very first calls CreateDXGIFactory2
failing.
quad
also crash?The next step would probably be then to isolate the call by removing the prior debug_assertion
part and remove the dxgi1_3::DXGI_CREATE_FACTORY_DEBUG` flag.
Difficult to debug as I'm unable to reproduce it.
@msiglreith
quad
and it has also crashed the same way, with the same wio
panic!quad
using --release
, and the same panic occurred. Same call stack.x86_64-pc-windows-gnu
) to build gfx
since VS is kinda expensive for my current internet.The next step would probably be then to isolate the call by removing the prior debug_assertion part and remove the dxgi1_3::DXGI_CREATE_FACTORY_DEBUG` flag.
So I've to fork wio
to change dxgi1_3
. I'm not sure if this will be very portable, since I'd have to change Cargo.toml in the gfx clone.
@hydroper thanks for testing to so far
I'm using MinGW (x86_64-pc-windows-gnu) to build gfx since VS is kinda expensive for my current internet.
Actually I'm not sure if MinGW supports dx12 so far. Not sure if someone has tested it so far.
I'll basically have to fork wio to change dxgi1_3, right?
It just crashes in wio as we pass a nullptr. You could clone gfx repository and change the lines mentioned. The wio dependency can stay as is.
@msiglreith Yeah, it was quite easy to change the lines. I stripped lines 673..682
let hr = unsafe {
dxgi1_3::CreateDXGIFactory2(
dxgi1_3::DXGI_CREATE_FACTORY_DEBUG,
&dxgi1_4::IDXGIFactory4::uuidof(),
&mut dxgi_factory as *mut *mut _ as *mut *mut _)
};
if !winerror::SUCCEEDED(hr) {
error!("Failed on dxgi factory creation: {:?}", hr);
}
Then saved and ran cargo run --bin compute --features dx12 1 2 3 4
on examples
and still got the same result.
Actually I'm not sure if MinGW supports dx12 so far. Not sure if someone has tested it so far.
That means MinGW could be incompatible with DXGI/wio
. Well... I should sacrifice my internet for VS the 3rd time...
Mmm, i'm using win10 and windows-gnu stable. Currently these programs runs fine using dx12 on my machine, and I can see the gfx-rs logo in the quad example.
@crlf0710 For me they ran compilling with MSVC++, but not with MinGW (stable-windows-gnu
). Oh, and it's one of the latest MinGW distros...
Short info header:
Error (with backtrace)