Skip to content

Commit

Permalink
Make sure Fullscreen VS is also created in capturing program
Browse files Browse the repository at this point in the history
* This shader is necessary for the MSAA-to-array copying functionality
  used, and without it we bind a NULL vertex shader and can end up with
  driver crashes.
  • Loading branch information
baldurk committed Mar 2, 2015
1 parent 731a7f3 commit e2f7afc
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions renderdoc/driver/d3d11/d3d11_debug.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -766,13 +766,15 @@ bool D3D11DebugManager::InitDebugRendering()
m_DebugRender.FloatCopyArrayToMSPS = MakePShader(multisamplehlsl.c_str(), "RENDERDOC_FloatCopyArrayToMS", "ps_5_0");
m_DebugRender.DepthCopyMSToArrayPS = MakePShader(multisamplehlsl.c_str(), "RENDERDOC_DepthCopyMSToArray", "ps_5_0");
m_DebugRender.DepthCopyArrayToMSPS = MakePShader(multisamplehlsl.c_str(), "RENDERDOC_DepthCopyArrayToMS", "ps_5_0");

string displayhlsl = GetEmbeddedResource(debugcbuffers_h);
displayhlsl += GetEmbeddedResource(debugcommon_hlsl);
displayhlsl += GetEmbeddedResource(debugdisplay_hlsl);

m_DebugRender.FullscreenVS = MakeVShader(displayhlsl.c_str(), "RENDERDOC_FullscreenVS", "vs_4_0");

if(RenderDoc::Inst().IsReplayApp())
{
string displayhlsl = GetEmbeddedResource(debugcbuffers_h);
displayhlsl += GetEmbeddedResource(debugcommon_hlsl);
displayhlsl += GetEmbeddedResource(debugdisplay_hlsl);

D3D11_INPUT_ELEMENT_DESC inputDesc;

inputDesc.SemanticName = "POSITION";
Expand Down Expand Up @@ -821,7 +823,6 @@ bool D3D11DebugManager::InitDebugRendering()
memcpy(m_DebugRender.MeshHomogVSBytecode, &bytecode[0], bytecode.size());

m_DebugRender.WireframePS = MakePShader(displayhlsl.c_str(), "RENDERDOC_WireframePS", "ps_4_0");
m_DebugRender.FullscreenVS = MakeVShader(displayhlsl.c_str(), "RENDERDOC_FullscreenVS", "vs_4_0");
m_DebugRender.OverlayPS = MakePShader(displayhlsl.c_str(), "RENDERDOC_OverlayPS", "ps_4_0");
m_DebugRender.CheckerboardPS = MakePShader(displayhlsl.c_str(), "RENDERDOC_CheckerboardPS", "ps_4_0");

Expand Down

0 comments on commit e2f7afc

Please sign in to comment.