Enable Direct3D Debug Layer in Windows Phone

You can create Direct3D windows phone app using XAML+Direct3D template, but it has some cons. The most annoying cons is inability to enable Direct3D Debug Layer as the runtime create Direct3D device internally.

Actually with a little trick we can enable the debug layer using visual studio debugger.

  1. Create new breakpoint at d3d11!D3D11CreateDevice
  2. Start your program
  3. After the breakpoint triggered, change the R3 register value to (0x02 or 00000002 )

Now you can view some direct3D messages in output window, you can find some explanation about Direct3D debug layer’s messages here and here.

Leave a comment