mirror of
https://github.com/hrydgard/ppsspp.git
synced 2024-11-23 05:19:56 +00:00
ShaderId: Safer way to check for backend.
This commit is contained in:
parent
946d4b6251
commit
f4b0cddda3
@ -392,7 +392,7 @@ void ComputeFragmentShaderID(FShaderID *id_out, const ComputedPipelineState &pip
|
||||
id.SetBit(FS_BIT_COLOR_WRITEMASK, colorWriteMask);
|
||||
|
||||
// All framebuffers are array textures in Vulkan now.
|
||||
if (gstate_c.textureIsArray && g_Config.iGPUBackend == (int)GPUBackend::VULKAN) {
|
||||
if (gstate_c.textureIsArray && gstate_c.Use(GPU_USE_FRAMEBUFFER_ARRAYS)) {
|
||||
id.SetBit(FS_BIT_SAMPLE_ARRAY_TEXTURE);
|
||||
}
|
||||
|
||||
|
@ -491,7 +491,7 @@ enum {
|
||||
GPU_USE_DEPTH_TEXTURE = FLAG_BIT(16),
|
||||
GPU_USE_ACCURATE_DEPTH = FLAG_BIT(17),
|
||||
GPU_USE_GS_CULLING = FLAG_BIT(18), // Geometry shader
|
||||
// Bit 19 free.
|
||||
GPU_USE_FRAMEBUFFER_ARRAYS = FLAG_BIT(19),
|
||||
GPU_USE_FRAMEBUFFER_FETCH = FLAG_BIT(20),
|
||||
GPU_SCALE_DEPTH_FROM_24BIT_TO_16BIT = FLAG_BIT(21),
|
||||
GPU_ROUND_FRAGMENT_DEPTH_TO_16BIT = FLAG_BIT(22),
|
||||
|
@ -290,6 +290,7 @@ u32 GPU_Vulkan::CheckGPUFeatures() const {
|
||||
features &= ~GPU_USE_LIGHT_UBERSHADER;
|
||||
}
|
||||
|
||||
features |= GPU_USE_FRAMEBUFFER_ARRAYS;
|
||||
return CheckGPUFeaturesLate(features);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user