mirror of
https://github.com/baldurk/renderdoc.git
synced 2026-07-19 05:57:09 +00:00
Always point sample depth textures on display
This commit is contained in:
@@ -91,4 +91,5 @@ BINDING(0) uniform FontUniforms
|
||||
#define TEXDISPLAY_TYPEMASK 0x7
|
||||
#define TEXDISPLAY_UINT_TEX 0x8
|
||||
#define TEXDISPLAY_SINT_TEX 0x10
|
||||
#define TEXDISPLAY_DEPTH_TEX 0x20
|
||||
|
||||
|
||||
@@ -268,6 +268,7 @@ void main(void)
|
||||
{
|
||||
bool uintTex = (OutputDisplayFormat & TEXDISPLAY_UINT_TEX) != 0;
|
||||
bool sintTex = (OutputDisplayFormat & TEXDISPLAY_SINT_TEX) != 0;
|
||||
bool depthTex = (OutputDisplayFormat & TEXDISPLAY_DEPTH_TEX) != 0;
|
||||
|
||||
vec4 col;
|
||||
uvec4 ucol;
|
||||
@@ -287,7 +288,7 @@ void main(void)
|
||||
}
|
||||
else
|
||||
{
|
||||
col = SampleTextureFloat4(scr / Scale, OutputDisplayFormat & TEXDISPLAY_TYPEMASK, FlipY == 0, (Scale < 1.0 && MipLevel == 0.0), int(MipLevel), Slice);
|
||||
col = SampleTextureFloat4(scr / Scale, OutputDisplayFormat & TEXDISPLAY_TYPEMASK, FlipY == 0, (Scale < 1.0 && MipLevel == 0.0 && !depthTex), int(MipLevel), Slice);
|
||||
}
|
||||
|
||||
if(RawOutput != 0)
|
||||
|
||||
@@ -388,6 +388,9 @@ bool GLReplay::RenderTexture(TextureDisplay cfg)
|
||||
|
||||
ubo->OutputDisplayFormat = resType;
|
||||
|
||||
if(dsTexMode != eGL_NONE)
|
||||
ubo->OutputDisplayFormat |= TEXDISPLAY_DEPTH_TEX;
|
||||
|
||||
ubo->RawOutput = cfg.rawoutput ? 1 : 0;
|
||||
|
||||
ubo->TextureResolutionPS.x = float(tex_x);
|
||||
|
||||
Reference in New Issue
Block a user