mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-05-11 21:52:40 +00:00
Ubershaders: Support per-pixel lighting
This commit is contained in:
parent
c8f31656cb
commit
e968c191ff
12 changed files with 311 additions and 303 deletions
Source/Core/VideoCommon
|
@ -219,21 +219,14 @@ u32 VideoConfig::GetShaderPrecompilerThreads() const
|
|||
return GetNumAutoShaderCompilerThreads();
|
||||
}
|
||||
|
||||
bool VideoConfig::CanUseUberShaders() const
|
||||
{
|
||||
// Ubershaders are currently incompatible with per-pixel lighting.
|
||||
return !bEnablePixelLighting;
|
||||
}
|
||||
|
||||
bool VideoConfig::CanPrecompileUberShaders() const
|
||||
{
|
||||
// We don't want to precompile ubershaders if they're never going to be used.
|
||||
return bPrecompileUberShaders && (bBackgroundShaderCompiling || bDisableSpecializedShaders) &&
|
||||
CanUseUberShaders();
|
||||
return bPrecompileUberShaders && (bBackgroundShaderCompiling || bDisableSpecializedShaders);
|
||||
}
|
||||
|
||||
bool VideoConfig::CanBackgroundCompileShaders() const
|
||||
{
|
||||
// We require precompiled ubershaders to background compile shaders.
|
||||
return bBackgroundShaderCompiling && bPrecompileUberShaders && CanUseUberShaders();
|
||||
return bBackgroundShaderCompiling && bPrecompileUberShaders;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue