mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-23 14:19:46 -06:00
Use custom isnan implementation to avoid HLSL optimizer issues
This adjusts the NaN replacement logic introduced in #9928 to work around the HLSL compiler optimizing away calls to isnan, which caused that functionality to not work with ubershaders on D3D11 and D3D12 (it did work with specialized shaders, despite a warning being logged for both; that warning is also now gone). Note that the `D3DCOMPILE_IEEE_STRICTNESS` flag did not solve this issue, despite the warning suggesting that it might. Suggested by @kayru and @jamiehayes.
This commit is contained in:
@ -176,6 +176,8 @@ union ShaderHostConfig
|
||||
std::string GetDiskShaderCacheFileName(APIType api_type, const char* type, bool include_gameid,
|
||||
bool include_host_config, bool include_api = true);
|
||||
|
||||
void WriteIsNanHeader(ShaderCode& out, APIType api_type);
|
||||
|
||||
void GenerateVSOutputMembers(ShaderCode& object, APIType api_type, u32 texgens,
|
||||
const ShaderHostConfig& host_config, std::string_view qualifier);
|
||||
|
||||
|
Reference in New Issue
Block a user