mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-01-25 15:31:17 +01:00
TexCache: rewrite level calculation
This commit is contained in:
parent
d95e5e2b6f
commit
744b1c1624
@ -75,7 +75,6 @@ void InitBackendInfo()
|
|||||||
}
|
}
|
||||||
|
|
||||||
g_Config.backend_info.APIType = API_D3D;
|
g_Config.backend_info.APIType = API_D3D;
|
||||||
g_Config.backend_info.bUseMinimalMipCount = true;
|
|
||||||
g_Config.backend_info.bSupportsExclusiveFullscreen = true;
|
g_Config.backend_info.bSupportsExclusiveFullscreen = true;
|
||||||
g_Config.backend_info.bSupportsDualSourceBlend = true;
|
g_Config.backend_info.bSupportsDualSourceBlend = true;
|
||||||
g_Config.backend_info.bSupportsPrimitiveRestart = true;
|
g_Config.backend_info.bSupportsPrimitiveRestart = true;
|
||||||
|
@ -133,7 +133,6 @@ static void GetShaders(std::vector<std::string> &shaders)
|
|||||||
static void InitBackendInfo()
|
static void InitBackendInfo()
|
||||||
{
|
{
|
||||||
g_Config.backend_info.APIType = API_OPENGL;
|
g_Config.backend_info.APIType = API_OPENGL;
|
||||||
g_Config.backend_info.bUseMinimalMipCount = false;
|
|
||||||
g_Config.backend_info.bSupportsExclusiveFullscreen = false;
|
g_Config.backend_info.bSupportsExclusiveFullscreen = false;
|
||||||
//g_Config.backend_info.bSupportsDualSourceBlend = true; // is gpu dependent and must be set in renderer
|
//g_Config.backend_info.bSupportsDualSourceBlend = true; // is gpu dependent and must be set in renderer
|
||||||
//g_Config.backend_info.bSupportsEarlyZ = true; // is gpu dependent and must be set in renderer
|
//g_Config.backend_info.bSupportsEarlyZ = true; // is gpu dependent and must be set in renderer
|
||||||
|
@ -358,10 +358,9 @@ TextureCache::TCacheEntryBase* TextureCache::Load(const u32 stage)
|
|||||||
tex_hash ^= tlut_hash;
|
tex_hash ^= tlut_hash;
|
||||||
}
|
}
|
||||||
|
|
||||||
// D3D doesn't like when the specified mipmap count would require more than one 1x1-sized LOD in the mipmap chain
|
// GPUs don't like when the specified mipmap count would require more than one 1x1-sized LOD in the mipmap chain
|
||||||
// e.g. 64x64 with 7 LODs would have the mipmap chain 64x64,32x32,16x16,8x8,4x4,2x2,1x1,1x1, so we limit the mipmap count to 6 there
|
// e.g. 64x64 with 7 LODs would have the mipmap chain 64x64,32x32,16x16,8x8,4x4,2x2,1x1,0x0, so we limit the mipmap count to 6 there
|
||||||
while (g_ActiveConfig.backend_info.bUseMinimalMipCount && std::max(width, height) >> (tex_levels - 1) == 0)
|
tex_levels = std::min<u32>(IntLog2(std::max(width, height)) + 1, tex_levels);
|
||||||
--tex_levels;
|
|
||||||
|
|
||||||
TCacheEntryBase *entry = textures[texID];
|
TCacheEntryBase *entry = textures[texID];
|
||||||
if (entry)
|
if (entry)
|
||||||
|
@ -36,7 +36,6 @@ VideoConfig::VideoConfig()
|
|||||||
|
|
||||||
// disable all features by default
|
// disable all features by default
|
||||||
backend_info.APIType = API_NONE;
|
backend_info.APIType = API_NONE;
|
||||||
backend_info.bUseMinimalMipCount = false;
|
|
||||||
backend_info.bSupportsExclusiveFullscreen = false;
|
backend_info.bSupportsExclusiveFullscreen = false;
|
||||||
|
|
||||||
// Game-specific stereoscopy settings
|
// Game-specific stereoscopy settings
|
||||||
|
@ -146,7 +146,6 @@ struct VideoConfig final
|
|||||||
std::vector<std::string> AAModes;
|
std::vector<std::string> AAModes;
|
||||||
std::vector<std::string> PPShaders; // post-processing shaders
|
std::vector<std::string> PPShaders; // post-processing shaders
|
||||||
|
|
||||||
bool bUseMinimalMipCount;
|
|
||||||
bool bSupportsExclusiveFullscreen;
|
bool bSupportsExclusiveFullscreen;
|
||||||
bool bSupportsDualSourceBlend;
|
bool bSupportsDualSourceBlend;
|
||||||
bool bSupportsPrimitiveRestart;
|
bool bSupportsPrimitiveRestart;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user