[GPU] Ensure force_special_view checks swizzle signs before using signed

This was causing unnecessary logspam in Blue Dragon due to
incorrectly trying to request signed when the fetch constants are
unsigned
This commit is contained in:
Herman S.
2026-01-17 22:41:48 +09:00
parent 0c8d1b763f
commit 125b4c8c05
2 changed files with 9 additions and 3 deletions

View File

@@ -708,8 +708,11 @@ uint32_t D3D12TextureCache::GetActiveTextureBindlessSRVIndex(
if (force_special_view) {
// Determine which texture object to use
// Respect swizzled_signs from fetch constant, not just shader request
Texture* texture = nullptr;
if (host_shader_binding.is_signed) {
bool use_signed = host_shader_binding.is_signed &&
texture_util::IsAnySignSigned(binding->swizzled_signs);
if (use_signed) {
texture = IsSignedVersionSeparateForFormat(binding->key)
? binding->texture_signed
: binding->texture;

View File

@@ -616,8 +616,11 @@ VkImageView VulkanTextureCache::GetActiveBindingOrNullImageView(
if (force_special_view) {
// Get the appropriate texture for signed/unsigned.
// Respect swizzled_signs from fetch constant, not just shader request.
Texture* texture = nullptr;
if (is_signed && IsSignedVersionSeparateForFormat(binding->key)) {
bool use_signed =
is_signed && texture_util::IsAnySignSigned(binding->swizzled_signs);
if (use_signed && IsSignedVersionSeparateForFormat(binding->key)) {
texture = binding->texture_signed;
} else {
texture = binding->texture;
@@ -625,7 +628,7 @@ VkImageView VulkanTextureCache::GetActiveBindingOrNullImageView(
if (texture) {
image_view =
static_cast<VulkanTexture*>(texture)->GetOrCreate3DAs2DImageView(
is_signed, binding->host_swizzle);
use_signed, binding->host_swizzle);
}
} else {
const VulkanTextureBinding& vulkan_binding =