Graphics and Simulations Manual
Note for users of C++ Express Edition
Good On-Line Tutorial: http://www.lighthouse3d.com/tutorials/glut-tutorial/
|
OpenGL Part 1: Using GLUT |
|||||
|
OpenGL Part 2: Using Win32 |
|||||
| 3. Why Windows? |
12. glTranslate () |
15. Line Thickness | |||
|
OpenGL PowerPoint Summaries |
|||||
|
7. Blending and Fog |
9. Bitmaps, Fonts |
11. MilkShape |
|||
|
8. Display Lists |
10. Texture Maping |
12. DirectX |
|||
|
MilkShape3D |
|||||
|
DirectX |
|||||
Videos
http://xoax.net/comp/cpp/opengl/index.php
http://www.videotutorialsrock.com/
Notes for use of C++ Express Edition
Step 1: Open C++ Console Applications and create a new project
Step 2: Link to the OpenGL libraries
¢
Under the Project menu select Project Properties (Alt+F7) at the
bottom.
¢
Select Configuration Properties → Linker → Input
from the navigation panel on the left.
¢ Select All Configurations from the Configuration drop-down box at the top of the dialog.
This ensures you are changing the settings for both the
Debug and Release
¢
Type “opengl32.lib glu32.lib” in Additional Dependencies and click
OK.
Step 3: Insert and run the following code
#include
"stdafx.h"
#include
<GL/glut.h>
void
mydisplay()
{
glClear(GL_COLOR_BUFFER_BIT);
glBegin(GL_POLYGON);
glVertex2f(-0.5, -0.5);
glVertex2f(-0.5, 0.5);
glVertex2f(0.5, 0.5);
glVertex2f(0.5, -0.5);
glEnd();
glFlush();
}
int
main(int argc,
char** argv)
{
glutCreateWindow("Simple");
glutDisplayFunc(mydisplay);
glutMainLoop();
}
Output
