View Single Post
Old 07-03-2005, 10:19 AM   #4 (permalink)
fp_unit
mike
 
Join Date: Jan 2005
Location: Ottawa, ON
Posts: 79
fp_unit is on a distinguished road
I managed to get it working pretty easily in Visual Studio .NET 2003 (your code you listed). I didnt change one thing and it compiled my first try, here's how I did it:

* File->New Project->Visual C++ Application->Win32 Application [ gave project a name ]
* File->Add New Item->C++ Source File [ named "main.cpp" ]
* Pasted Code
* Project->$(Project Name) Properties->Linker->Input->Additional Dependencies->opengl32.lib glu32.lib
* Build->Build Project
* Debug->Start without Debugging

Worked perfectly, no compile errors. I took a screenshot but I have no way to upload it, in case your wondering its a small red triangle on a black background, pretty simple OpenGL stuff.

EDIT: Screenshot, enjoy
http://munro.humber.ca/~dwnm0041/opengl-app.JPG

Try again in Dev-C++, create a new project (C++), Windows Application (not console), add new file (c++), copy/paste code into file, save, set linker options (you should only need opengl32.lib and glu32.lib) then compile. I would guess that somewhere along the lines of setting up your project you chose "C application" or "Console Application" or something like that. Keep trying, OpenGL is fun
fp_unit is offline   Reply With Quote