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 2008 (or Visual C++ 2008 Express Edition)*.
2.  A knowledge of basic C++ and Win32 programming.
3.  DirectX SDK (August 2009 or later)
4.  A DirectX 10 capable video card and Windows Vista or later.
5.  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 Screenshot

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 No Screenshot

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 able to switch to Fullscreen mode and back.

Lesson 3:  An Overview of the Third Dimension No Screenshot

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 Screenshot

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:  The Rendering Pipeline Screenshot

The rendering pipeline is a powerful sequence of steps that convert a series of coordinates into a beautifully rendered frame.  In this lesson we'll find out how that is done, and write some simple code to get a command of how rendering can be manipulated using HLSL.

Lesson 6:  Manipulating Shaders Screenshot

While what we did in Lesson 5 was cool, it's actually rather limited in terms of what it can do.  The DirectX program couldn't manipulate the effects and make changes to them.  In this lesson we'll learn how to control the effects based on time or conditions in your game.

Lesson 7:  3D Transformation Screenshot

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 8:  Rendering Depth Screenshot

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 9:  Simple Modeling Screenshot

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 10:  Adding Lights Screenshot

In the previous lessons we have worked without lights 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 11:  Adding Textures Screenshot

Before now, we've worked with simple geometry, with no material qualties.  In this last lesson of the Basics tutorial, we will add textures to our geometry to make them look more like real-world objects.