-
Notifications
You must be signed in to change notification settings - Fork 926
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[local] Don't panic if no adapters are found #368
Comments
Unless I misunderstand, this is fixed by 41132a3? |
@antonok-edm this only fixed a part of the problem in |
I tried implementating an fix for /// Retrieves an [`Adapter`] which matches the given options.
///
/// Some options are "soft", so treated as non-mandatory. Others are "hard".
///
/// If no adapters are found that suffice all the "hard" options, `None` is returned.
pub fn request(options: &wgn::RequestAdapterOptions) -> Option<Self> {
wgn::request_adapter(/* &*wgn::hub::GLOBAL (private to wgpu-rs) */, &options, &[]).map(|id| Adapter { id })
} The problem is that there is no way to access the global wgpu instance. |
We need to modify |
I was just taking a look to see if I could fix this since it's marked with |
Yes, sorry, looks like this was fixed at some point recently. wgpu/wgpu-core/src/instance.rs Line 291 in d453235
|
It would be nicer not to panic in
wgpu_instance_request_adapters
.I don't think it should be a blocker for 0.4, but a nice little thing to have.
The text was updated successfully, but these errors were encountered: