mirror of
https://github.com/cemu-project/Cemu.git
synced 2025-07-07 15:31:18 +12:00
emulate unsupported shadow sampler types
This commit is contained in:
parent
f9f6260580
commit
5d07d115a6
3 changed files with 55 additions and 17 deletions
|
@ -1,7 +1,8 @@
|
|||
#pragma once
|
||||
|
||||
#include "Common/precompiled.h"
|
||||
#include "HW/Latte/Core/LatteConst.h"
|
||||
#include "Cafe/HW/Latte/Renderer/Metal/MetalCommon.h"
|
||||
|
||||
namespace LatteDecompiler
|
||||
{
|
||||
static void _emitUniformVariables(LatteDecompilerShaderContext* decompilerContext)
|
||||
|
@ -442,7 +443,8 @@ namespace LatteDecompiler
|
|||
|
||||
src->add(", ");
|
||||
|
||||
if (shaderContext->shader->textureUsesDepthCompare[i])
|
||||
// Only 2D and 2D array textures can be used with comparison samplers
|
||||
if (shaderContext->shader->textureUsesDepthCompare[i] && IsValidDepthTextureType(shaderContext->shader->textureUnitDim[i]))
|
||||
src->add("depth");
|
||||
else
|
||||
src->add("texture");
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue