PDA

View Full Version : Installation without Glut



Craige
05-28-2008, 10:15 PM
So, I'm new to OpenGL, and not really sure what I'm doing here. What I want to do is install OpenGL without Glut. Reason being, I am learning SDL for use in managing my application where GLUT would normally take control. IE: Window Managing, Events, looping applicaion, etc.

However, I can not seem to find a resource pertaining to installation of OpenGL without GLUT. I do not want the GLUT toolkit; just OpenGL and GLU.

How would I go about this installation on my Windows enviorment with MinGW + Code::Blocks?

Sidebar: Interestingly enough, Code::blocks seems to have the header files for OpenGL, GLU, and GLUT, but not the library files for OpenGL. :\, and thus I get errors when compiling my applications.

ZbuffeR
05-29-2008, 02:10 AM
This has nothing to do with glut.

You must configure your project to use gl/glu libs.
Something like -lgl or -lopengl32 etc.

Craige
05-29-2008, 06:04 AM
This has nothing to do with glut.

You must configure your project to use gl/glu libs.
Something like -lgl or -lopengl32 etc.

Exactly. I don't want to use GLUT, but I don't know how to install JUST openGL/GLU.

Zengar
05-29-2008, 06:32 AM
You don't have to install anything. OpenGL is installed on every Windows/MacOS/Linux box by default.

songho
05-29-2008, 10:34 AM
Craige,
Once you install MinGW, you should already have OpenGL headers/libs under your MinGW folder. They comes along with MinGW packages.

Craige
05-29-2008, 09:47 PM
Craige,
Once you install MinGW, you should already have OpenGL headers/libs under your MinGW folder. They comes along with MinGW packages.


Could I get away with just linking the glu.a library? Or is there actually an OpenGL.a lib?


You don't have to install anything. OpenGL is installed on every Windows/MacOS/Linux box by default.

Yes...The .dll's are present on all modern OS's, but I'm referring to the libraries required to compile an application.

Thank's in advance.

Zengar
05-30-2008, 12:05 AM
I advice you to look through the MinGW libraries folder, there will be something like opengl32.a or similar...

songho
05-30-2008, 10:04 AM
Could I get away with just linking the glu.a library? Or is there actually an OpenGL.a lib?

You should see OpenGL libraries under "YourMinGW/lib" folder:
libopengl32.a : OpenGL lib
libglu32.a : GLU lib

And, the linker parameter for an OpenGL application should include:
-lglu32 -lopengl32 -lwinmm -lgdi32
(You can omit glu32 if you don't use GLU functions in your code.)


Notice that winmm and gdi32 are also needed because you are building a Windows application.

Craige
06-03-2008, 07:29 PM
Oh, I see the library now. Thank you very much. I must have just overlooked it previously.