diff options
| author | 2021-07-31 03:04:08 -0300 | |
|---|---|---|
| committer | 2021-11-16 22:11:29 +0100 | |
| commit | cfeb161c7ebf93bf6ac39e430fc998dc13abfc66 (patch) | |
| tree | e77411856862dbe91ef7edb475d19e64ff1db18b /src/shader_recompiler/backend/glasm/emit_glasm_image.cpp | |
| parent | gl_rasterizer: Properly scale viewports and scissors (diff) | |
| download | yuzu-cfeb161c7ebf93bf6ac39e430fc998dc13abfc66.tar.gz yuzu-cfeb161c7ebf93bf6ac39e430fc998dc13abfc66.tar.xz yuzu-cfeb161c7ebf93bf6ac39e430fc998dc13abfc66.zip | |
glsl/glasm: Pass and use scaling parameters in shaders
Diffstat (limited to 'src/shader_recompiler/backend/glasm/emit_glasm_image.cpp')
| -rw-r--r-- | src/shader_recompiler/backend/glasm/emit_glasm_image.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/shader_recompiler/backend/glasm/emit_glasm_image.cpp b/src/shader_recompiler/backend/glasm/emit_glasm_image.cpp index 583ed3cf2..05e88cd97 100644 --- a/src/shader_recompiler/backend/glasm/emit_glasm_image.cpp +++ b/src/shader_recompiler/backend/glasm/emit_glasm_image.cpp | |||
| @@ -612,8 +612,9 @@ void EmitIsTextureScaled(EmitContext& ctx, IR::Inst& inst, const IR::Value& inde | |||
| 612 | if (!index.IsImmediate()) { | 612 | if (!index.IsImmediate()) { |
| 613 | throw NotImplementedException("Non-constant texture rescaling"); | 613 | throw NotImplementedException("Non-constant texture rescaling"); |
| 614 | } | 614 | } |
| 615 | UNIMPLEMENTED(); | 615 | ctx.Add("AND.U RC.x,scaling[0].x,{};" |
| 616 | ctx.Add("MOV.S {}.x,-1;", inst); | 616 | "SNE.S {},RC.x,0;", |
| 617 | 1u << index.U32(), ctx.reg_alloc.Define(inst)); | ||
| 617 | } | 618 | } |
| 618 | 619 | ||
| 619 | void EmitImageAtomicIAdd32(EmitContext& ctx, IR::Inst& inst, const IR::Value& index, Register coord, | 620 | void EmitImageAtomicIAdd32(EmitContext& ctx, IR::Inst& inst, const IR::Value& index, Register coord, |