Render full-screen gradient or texture
- by Filip Skakun
What's the simplest way to fill the background of the screen with a gradient or a texture in Direct3D 10/11?
I'm building a Windows 8 metro app in which the camera never moves and I render some content in D3D, but I need to fill the background with something else than a solid color. Do I need to figure out the size and position of a rectangle and position it in 3D space or can I have some simpler solution?
I don't care about depth at all, I don't use any depth buffer since all my content is sorted back to front, so I could just start by drawing to the background.