You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
At the moment our format check is basically just a static bitflag comparison and the formats are hardcoded into each bootstrap. This is okay but it's not ideal for a few reasons:
When Shader Model 7 comes out for D3D12 we can't just assume SPIR-V is available, we have to check the feature level first
On macOS Metal is technically always available but the device family may not meet SDL's needs
At least one NDA platform only supports a specific shader format when an on-disk shader cache is present
So we need to beef this up a bit and make it a whole bootstrap function, where drivers are given a chance to check for minimum support in addition to checking if the backend recognizes a specific format. For example, we should move this check from CreateDevice to CheckSupport:
As a band-aid to the Mac problem we can maybe check for basic hardware support in PrepareDriver, but that's not quite the same as driver format support.
At the moment our format check is basically just a static bitflag comparison and the formats are hardcoded into each bootstrap. This is okay but it's not ideal for a few reasons:
So we need to beef this up a bit and make it a whole bootstrap function, where drivers are given a chance to check for minimum support in addition to checking if the backend recognizes a specific format. For example, we should move this check from CreateDevice to CheckSupport:
https://github.com/libsdl-org/SDL/blob/main/src/gpu/metal/SDL_gpu_metal.m#L4472-L4488
The text was updated successfully, but these errors were encountered: