From e0012811aefc8bb3e1b9217daf25cc1902390155 Mon Sep 17 00:00:00 2001 From: Gregory Hainaut Date: Tue, 12 May 2015 12:36:34 +0200 Subject: [PATCH] gsdx-debug: more debug info in gl trace --- plugins/GSdx/GSDeviceOGL.cpp | 4 +++- plugins/GSdx/GSRendererOGL.cpp | 5 ++++- plugins/GSdx/GSTextureFXOGL.cpp | 4 ++++ 3 files changed, 11 insertions(+), 2 deletions(-) diff --git a/plugins/GSdx/GSDeviceOGL.cpp b/plugins/GSdx/GSDeviceOGL.cpp index 735d199b20..4c2c746c57 100644 --- a/plugins/GSdx/GSDeviceOGL.cpp +++ b/plugins/GSdx/GSDeviceOGL.cpp @@ -718,7 +718,9 @@ void GSDeviceOGL::StretchRect(GSTexture* st, const GSVector4& sr, GSTexture* dt, return; } - GL_PUSH("StretchRect"); + GL_PUSH(format("StretchRect from %d to %d", + static_cast(st)->GetID(), + static_cast(dt)->GetID()).c_str()); // ************************************ // Init diff --git a/plugins/GSdx/GSRendererOGL.cpp b/plugins/GSdx/GSRendererOGL.cpp index f54cdb1160..77e6b998ce 100644 --- a/plugins/GSdx/GSRendererOGL.cpp +++ b/plugins/GSdx/GSRendererOGL.cpp @@ -211,7 +211,10 @@ void GSRendererOGL::SendDraw(bool require_barrier) void GSRendererOGL::DrawPrims(GSTexture* rt, GSTexture* ds, GSTextureCache::Source* tex) { - GL_PUSH(format("GL Draw in (%d/%d)", static_cast(rt)->GetID(), static_cast(ds)->GetID()).c_str()); + GL_PUSH(format("GL Draw from %d in %d (Depth %d)", + tex && tex->m_texture ? static_cast(tex->m_texture)->GetID() : 0, + static_cast(rt)->GetID(), + static_cast(ds)->GetID()).c_str()); GSDrawingEnvironment& env = m_env; GSDrawingContext* context = m_context; diff --git a/plugins/GSdx/GSTextureFXOGL.cpp b/plugins/GSdx/GSTextureFXOGL.cpp index b83df69c78..66cc5a6d48 100644 --- a/plugins/GSdx/GSTextureFXOGL.cpp +++ b/plugins/GSdx/GSTextureFXOGL.cpp @@ -29,6 +29,8 @@ static const uint32 g_gs_cb_index = 22; void GSDeviceOGL::CreateTextureFX() { + GL_PUSH("CreateTextureFX"); + m_vs_cb = new GSUniformBufferOGL(g_vs_cb_index, sizeof(VSConstantBuffer)); m_ps_cb = new GSUniformBufferOGL(g_ps_cb_index, sizeof(PSConstantBuffer)); @@ -67,6 +69,8 @@ void GSDeviceOGL::CreateTextureFX() // Help to debug FS in apitrace m_apitrace = CompilePS(PSSelector()); + + GL_POP(); } GSDepthStencilOGL* GSDeviceOGL::CreateDepthStencil(OMDepthStencilSelector dssel)