Ipotrick / Daxa

Daxa is a convenient, simple and modern gpu abstraction built on vulkan
MIT License
381 stars 28 forks source link

Device Creation #80

Closed Ipotrick closed 3 months ago

Ipotrick commented 7 months ago

Device creation has problems:

My idea would be to remove the device selector in device creation. Instead make it a free function that takes a physical device list from the daxa instance.

It might also be nice if device creation wouldnt fail when a feature is not present and instead make it the user responsibility to check if a created device can actually do what is asked of it. This might be misleading but also more convenient to program.

Ipotrick commented 7 months ago

A scenario i had encountered was mesh shading support. Many times the features used are a hard requirement and then the current daxa device creation is fine. But when one wants to have a fallback path (for example a for mesh shading) then its hard/impossible to do that with current daxa device creation.

Ipotrick commented 7 months ago

There is also the point that some devices dont support daxa at all. In that case we should emit a good error message, collecting all the features/properties missing for that device.

loopunit commented 7 months ago

I also have the need to create a device based on its id (no other way to associate a device with a specific desktop on windows), which I've gone ahead and added here since it was a blocker when I was evaluating this lib.

Ipotrick commented 7 months ago

Thanks for pointing that out @loopunit. I will take that into consideration for the new device selection.

Ipotrick commented 3 months ago

Device creation is redone in 3.1