0
\$\begingroup\$

I'm working on my own (much tinier) version of Monogame. Right now I've been able to draw triangles to the screen with custom shaders using Direct3D 11. The problem is that I can't get it to be as perfomant as Monogame. I did some graphics debugging and noticed something :

enter image description here

enter image description here

The above picture is my implementation and the other is Monogame. For some reason the pixel shader, vertex shader and constant buffers are assigned at every draw call. I don't understand why this is happening since in my code I only ever set those parameter once an then draw a buffer containing 2 triangles 1000 times (as a performance test).

\$\endgroup\$
-1
\$\begingroup\$

It turns out that the lack of performance was due to the lack of depth buffer.

\$\endgroup\$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.