This time around, we are going to dig into Chapter 9 of
Frank Luna’s Introduction to 3D Game
Programming with Direct3D 11.0
. We will be implementing the BlendDemo in the next
couple of posts. We will base this demo off our previous example, the Textured
Hills Demo. We will be adding transparency to our water mesh, a fog effect, and a box
with a wire texture, with transparency implemented using pixel shader clipping. We’ll
need to update our shader effect, Basic.fx, to support these additional effects, along with its
C# wrapper class. We’ll also look at additional DirectX blend and rasterizer states,
and build up a static class to manage our these for us, in the same fashion we used for our
InputLayouts and Effects. The full code for this example can be found on GitHub at
https://github.com/ericrrichards/dx11.git, under
the BlendDemo project. Before we can get to the demo code, we need to cover some of the
basics first, however.