本来以为再也不会和图形产生任何联系了,现在又开始学习图形相关的内容。
今天开贴为证,好好学习图形学。
The first 4 lines include the header files for each library we are using. The lines look like this:
1 2 3 4 |
|
Next you need to set up all the variables you plan to use in your program. This program will create a blank OpenGL window, so we won't need to set up a lot of variables just yet. The few variables that we do set up are very important, and will be used in just about every OpenGL program you write using this code.
The first line sets up a Rendering Context. Every OpenGL program is linked to a Rendering Context. A Rendering Context is what links OpenGL calls to the Device Context. The OpenGL Rendering Context is defined as hRC. In order for your program to draw to a Window you need to create a Device Context, this is done i