Tuesday, July 14, 2009

What should the next step be for game programming in C++?

I've learned the basics of C++ and have made some simple games, such as Tic-Tac-Toe, but I want to learn how to program graphics in the games. I've tried to learn Directx, but all of the books I've read are way too complex like I missed a step in learning game programming. Does anybody have a suggestion or know any other books or tutorials that could help me out?

What should the next step be for game programming in C++?
I'd suggest downloading a copy of the C++ version of Visual Studio Express (it's free) and start writing some windows applications. There are plenty of books on the topic, and a huge amount of free information and demos on the web. Start learning to draw primitive (lines, shapes, images) using GDI pens, brushes etc. Learn how to eliminate flicker by drawing things to a bitmap and then drawing that bitmap on the screen in one go (google "double buffering"). Next try simple animations i.e. moving the objects around on the screen. Finally learn how to read the mouse, keyboard and joystick.





It might sound like a lot to learn, but there's plenty of info on the net to help you, and once you how to do these things you'll be able to develop a huge range of 2D games.





Once you feel ready to take the plunge into 3D I'd suggest downloading the C# version of Visual Studio Express and a copy of XNA. C# is very similar to C++ but much, much easier and faster to develop for. XNA is Microsoft's game development library, it takes care of all the usual headaches of DirectX so that you can concentrate on the game itself. Plus it has plenty of support and examples to help get you started. It'll also allow you to write games for both PC and the XBox 360.
Reply:You might want to consider some university courses. To understand graphics, especially 3D graphics, you need to understand linear algebra and matrices.





When you have a good grasp of the underlying math, the purposes of the functions and data structures will be more clear.

thank you cards

No comments:

Post a Comment