It's time to add to our billet small code to display a blank window on the screen. For starters try to apply header file Precompiled.h. To create a window we need the following classes ATL: CWindowImpl, CWindow and CWinTraits, which are described in the header file atlwin.h. For convenience, create a data structure DesktopWindow (in fact it is the window class). Also override the macro to verify critical resource use functions (ATLVERIFY).
Now, add the code in a class of our window. We use a macro to the ad window and set its card messages and write functions for minimum functionality.
So, to choose the scope of activities to which we begin: drawing, modeling or programming. And I choose ... programming. Everything else, maybe I did not even touch on in this study.
You can select any engine ready and start writing scripts for him, as well as delve into the study of its source code to make the necessary changes for the needs of the game. But until we get down to the study of one of the DirectX APIs, and it will Direct2D.
Direct2D has a simple structure and a good start for the first acquaintance with DirectX and Direct3D general in particular. First we need to skim c Component Object Model (COM), which is closely linked with DirectX and ATL, which we use as our primary object structure of the main window.