DirectXTutorial.com
The Ultimate DirectX Tutorial
Direct3D Basics
Log In
Prerequisite

Before you can do this tutorial, you will need the following:

1.  Visual Studio 2005 (or Visual C++ 2005 Express Edition)*.
2.  A knowledge of basic C++ and Win32 programming.
3.  DirectX SDK (February 2005 or later)
4.  A burning desire to make games.

* - other versions of C++ compilers will also run DirectX, however, there are some language specific changes you may need to make in each of the demo applications.

Lesson 1:  Getting Started with Direct3D

In this first DirectX lesson we will go over how to build a basic Direct3D application.  We will also cover a couple of theoretical concepts underlying DirectX which are useful to know.  Don't worry, nothing too theoretical.

Lesson 2:  Going Fullscreen

Imagine only being able to play Half-Life 2 or Halo in a 400x400 pixel window.  Kinda lame?  I thought so myself.  In this lesson we will modify our Direct3D program to be in Fullscreen mode.

Lesson 3:  An Overview of the Third Dimension

More important than knowing the code of Direct3D is having a very fundamental understanding of 3D and how it works.  This lesson will go briefly over 3D coordinate systems, how 3D models are constructed, lighting, color and more.  If you already know these things, I recommed you go over this to make sure there isn't anything else you might learn.  Otherwise, you should do this lesson in full.

Lesson 4:  Drawing a Triangle

Triangles do not make the world go round.  They are the world.  Because triangles can be combined to form pretty much any shape known to man, games tend to be made out of triangles.  In this lesson we will learn how to draw a simple triangle and color it.

Lesson 5:  Transforming Vertices

So far, our triangle does nothing.  It sits still, and even if you got it to move, it wasn't in 3D.  You made a boring, flat triangle.  Now let's bring this triangle to life by transforming it into a 3D triangle, rotating it, moving it around, and even scaling it to a different size.

Lesson 6:  Rendering Depth

Now our triangle can rotate, can be resized and can move.  Our camera can zoom, pan, and change direction.  We've got everything set to go.  However, there is one problem that must be solved before we go too far...

Lesson 7:  Simple Modeling

We're getting pretty good with triangles, but triangles by themselves are no fun.  Let's learn how to make simple shapes out of triangles, and transform each shape as a whole.

Lesson 8:  Rendering with Vertex Lighting

In the previous lessons we have turned lighting off for simplicity.  However, no lights in a 3D world makes everything look fake.  Lights add good effects to your game, even if they are as simple as day and night.  This lesson will cover the basics of lighting and show how to make a simple light.

Lesson 9:  More on Lighting

There is more to lighting than a simple Directional Light.  This lesson covers more types of lights you can use.

Lesson 10:  Blending Colors for Special Effects

Sometimes you wish to have objects be see-through.  This includes windows, glass objects, clouds, and much more.  These effects are achieved by blending colors together, the color of what you are drawing and what is in the background.  This lesson will cover how to do simple color blending.