[revert] Resolving conflicting changes

This commit is contained in:
CamilleLaVey 2025-11-26 10:48:01 -04:00
parent b50ace27ee
commit 58b2a8a810
2 changed files with 6 additions and 12 deletions

View file

@ -544,19 +544,10 @@ Id EmitImageFetch(EmitContext& ctx, IR::Inst* inst, const IR::Value& index, Id c
// This image is multisampled, lod must be implicit // This image is multisampled, lod must be implicit
lod = Id{}; lod = Id{};
} }
const bool is_integer_fetch = info.type == TextureType::Buffer
? false
: ctx.textures.at(info.descriptor_index).is_integer;
const ImageOperands operands(lod, ms); const ImageOperands operands(lod, ms);
const Id image = TextureImage(ctx, info, index); return Emit(&EmitContext::OpImageSparseFetch, &EmitContext::OpImageFetch, ctx, inst,
const Id result_type = is_integer_fetch ? ctx.U32[4] : ctx.F32[4]; ctx.F32[4], TextureImage(ctx, info, index), coords, operands.MaskOptional(),
const Id sample = operands.Span());
Emit(&EmitContext::OpImageSparseFetch, &EmitContext::OpImageFetch, ctx, inst, result_type,
image, coords, operands.MaskOptional(), operands.Span());
if (!is_integer_fetch) {
return sample;
}
return ctx.OpBitcast(ctx.F32[4], sample);
} }
Id EmitImageQueryDimensions(EmitContext& ctx, IR::Inst* inst, const IR::Value& index, Id lod, Id EmitImageQueryDimensions(EmitContext& ctx, IR::Inst* inst, const IR::Value& index, Id lod,

View file

@ -1,3 +1,6 @@
// SPDX-FileCopyrightText: Copyright 2025 Eden Emulator Project
// SPDX-License-Identifier: GPL-3.0-or-later
// SPDX-FileCopyrightText: Copyright 2019 yuzu Emulator Project // SPDX-FileCopyrightText: Copyright 2019 yuzu Emulator Project
// SPDX-License-Identifier: GPL-3.0-or-later // SPDX-License-Identifier: GPL-3.0-or-later