mirror of
https://github.com/baldurk/renderdoc.git
synced 2026-11-08 06:53:41 +00:00
Use correct context for shader debugging programs
This commit is contained in:
2 files changed
+4
-3
No files matched your search
@@ -349,6 +349,7 @@ public:
|
||||
void SetReplayData(GLWindowingData data);
|
||||
|
||||
void UseReplayContext() { MakeCurrentReplayContext(&m_ReplayCtx); }
|
||||
void UseDebugContext() { MakeCurrentReplayContext(m_DebugCtx); }
|
||||
bool IsReplayContext(void *ctx) { return m_ReplayCtx.ctx == NULL || ctx == m_ReplayCtx.ctx; }
|
||||
bool HasDebugContext() { return m_DebugCtx != NULL; }
|
||||
void FillWithDiscardPattern(DiscardType type, GLuint framebuffer, GLsizei numAttachments,
|
||||
|
||||
@@ -1154,6 +1154,8 @@ public:
|
||||
uniformParams.dynoffset.z = offset.value.s32v[2];
|
||||
}
|
||||
|
||||
m_pDriver->GetReplay()->UseReplayContext();
|
||||
|
||||
GLuint prog = m_pDriver->GetReplay()->MakeShaderDebugSampleProg(config);
|
||||
|
||||
if(prog == 0)
|
||||
@@ -1164,8 +1166,6 @@ public:
|
||||
return false;
|
||||
}
|
||||
|
||||
m_pDriver->GetReplay()->UseReplayContext();
|
||||
|
||||
GLMarkerRegion markerRegion("QueueSampleGather");
|
||||
|
||||
GLRenderState rs;
|
||||
@@ -1288,7 +1288,7 @@ public:
|
||||
|
||||
RDCASSERTEQUAL(params[0].type, VarType::Float);
|
||||
|
||||
m_pDriver->GetReplay()->UseReplayContext();
|
||||
m_pDriver->GetReplay()->UseDebugContext();
|
||||
|
||||
GLMarkerRegion markerRegion("QueueCalculateMathOp");
|
||||
|
||||
|
||||
Reference in new issue
Block a user