summaryrefslogtreecommitdiffstats
path: root/src/shader_recompiler/backend/glsl/emit_glsl_image.cpp
diff options
context:
space:
mode:
authorReinUsesLisp <reinuseslisp@airmail.cc>2021-07-31 08:04:08 +0200
committerFernando Sahmkow <fsahmkow27@gmail.com>2021-11-16 22:11:29 +0100
commitcfeb161c7ebf93bf6ac39e430fc998dc13abfc66 (patch)
treee77411856862dbe91ef7edb475d19e64ff1db18b /src/shader_recompiler/backend/glsl/emit_glsl_image.cpp
parentgl_rasterizer: Properly scale viewports and scissors (diff)
downloadyuzu-cfeb161c7ebf93bf6ac39e430fc998dc13abfc66.tar
yuzu-cfeb161c7ebf93bf6ac39e430fc998dc13abfc66.tar.gz
yuzu-cfeb161c7ebf93bf6ac39e430fc998dc13abfc66.tar.bz2
yuzu-cfeb161c7ebf93bf6ac39e430fc998dc13abfc66.tar.lz
yuzu-cfeb161c7ebf93bf6ac39e430fc998dc13abfc66.tar.xz
yuzu-cfeb161c7ebf93bf6ac39e430fc998dc13abfc66.tar.zst
yuzu-cfeb161c7ebf93bf6ac39e430fc998dc13abfc66.zip
Diffstat (limited to '')
-rw-r--r--src/shader_recompiler/backend/glsl/emit_glsl_image.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/shader_recompiler/backend/glsl/emit_glsl_image.cpp b/src/shader_recompiler/backend/glsl/emit_glsl_image.cpp
index 099e0160b..82b6f0d77 100644
--- a/src/shader_recompiler/backend/glsl/emit_glsl_image.cpp
+++ b/src/shader_recompiler/backend/glsl/emit_glsl_image.cpp
@@ -616,8 +616,8 @@ void EmitIsTextureScaled(EmitContext& ctx, IR::Inst& inst, const IR::Value& inde
if (!index.IsImmediate()) {
throw NotImplementedException("Non-constant texture rescaling");
}
- UNIMPLEMENTED();
- ctx.AddU1("{}=true;", inst);
+ const u32 image_index{index.U32()};
+ ctx.AddU1("{}=(ftou(scaling.x)&{})!=0;", inst, 1u << image_index);
}
void EmitBindlessImageSampleImplicitLod(EmitContext&) {