RustAudio / baseview

low-level window system interface for audio plugin UIs
Apache License 2.0
267 stars 57 forks source link

Handling window creation failures #122

Open robbert-vdh opened 2 years ago

robbert-vdh commented 2 years ago

I feel like open_parented()/open_as_if_parented()/open_blocking() should return a Result<WindowHandle/()>. Right now there's no way to handle window creation failures, and baseview will just panic if anything goes wrong. That's especially important when creating OpenGL contexts. If baseview would return an error, you would be able to try a couple different settings until you find something that works on the current system.