Visual c++ 6.0 and glut?

I just wonderd if Visual C++ 6.0 can use glut? If it works How do I do it?

#include <GL\glut.h>
It’s that simple.

Sure i have done that … =) but it was an other problem i saw … gahs… i picked up a Demo about bumpmapping and now i saw it was made with a main(…), and if i whant to compile it I must reprogram a lot i think … or is there an easy way to do it?

Sure i can use an other compilator but i dont have one =)

Hi lepra,

I don’t know if I get your point but you need to configure your VC++6.0 to compile GLUT.
Check these 3 files:
x:\windows\system\glut32.dll
x:.…\VC\lib\glu32.lib
x:.…\VC\include\GL\Glut.h

If you can’t find one of these files go to: http://reality.sgi.com/opengl/glut3/glut3.html

It’s important to say that I create a project as a Win32 Console Application (MFC is disabled) when I am working with GLUT.

I hope this info can be useful.

Don’t forget to add glut32.lib to your libraries, otherwise you’ll get errors when linking.

Antonio www.fatech.com/tech

Both GLUT & GLUI work well with VC6.

Another way to import the glut32.dll calls
besides using Project Settings… Link… is to add the following into your #includes

#pragma comment(lib,“glut32.lib”)

You typically don’t have to do this since it’s already in glut32.h
I prefer the latter (and so did the folks who wrote glut32 for Win32) since I can encapsulate the lib calls right in the editor and I see what’s going on in the code. (just as with #include)

Good Luck

PS
Take a look at GLUI: a GUI built with GLUT in mind.

[This message has been edited by iss (edited 10-22-2000).]

Thanx you guys realy help me with that…
i didnt know i could still do Dos programs in VC++ 6.0 … but now i have a question to “ISS” … with that command for including librarys is it exaktly what the VC do in the linker or do the library get in the *.xe file (Do the *.exe file get larger i mean)?

Where can I find GLUI?

Antonio

Originally posted by Antonio:
[b]Where can I find GLUI?

Antonio[/b]

You will find it at http://www.cs.unc.edu/~rademach/glui/

hi,
Im trying to get GLUT working in V c++ 6.0

I’ve added the GLUT lib and include directory in option
I’ve added glut32.lib in project -> settings -> link tab ->

And i get this error:
--------------------Configuration: lesson6 - Win32 Debug--------------------
Linking…
LIBCD.lib(wincrt0.obj) : error LNK2001: unresolved external symbol _WinMain@16
Debug/lesson6.exe : fatal error LNK1120: 1 unresolved externals
Error executing link.exe.

lesson6.exe - 2 error(s), 0 warning(s)

could some help me??? please

Originally posted by BeatHam:
[b]hi,
Im trying to get GLUT working in V c++ 6.0

I’ve added the GLUT lib and include directory in option
I’ve added glut32.lib in project -> settings -> link tab ->

And i get this error:[/b]

This error you get then you not have choosen Console application i think. Try to make a new workspace with console App and add the librarys like before

You can still have a win32 app and avoid writing the WinMian function.

Select project->settings from the main menu;
Select the “Link” tab from the dialog box;
Select “Output” from the “Category” combo box;
In the “Entry-point symbol” textbox type “mainCRTStartup”

Antonio www.fatech.com/tech