Sign in to follow this  
Abbid

OpenGL OpenGl dont work :(

Recommended Posts

ok, dont flame me for asking this, i got 5 mins till lecture starts so i dont have time to search. i have got visual studio 6.0. i know how to code using opengl and c++. i made a simple program that displays just a white triangle but it doesn't work. i know the code is correct, but i may be missing some header or something. dont know what it is. anyone have any idea??

Share this post


Link to post
Share on other sites
Quote:
Original post by Sneftel
You've got a problem on line 17.

You've got it all wrong! It's a general protection fault caused by a misconfigred USB MP3 stick [grin]

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
Today, while driving home, my car suddendly stopped in the middle of the highway.

I have no idea why it did this. Please tell me what the problem is. Please be detailed, so I can tell the repair shop men exactly what they have to fix.

kthxbye.

Share this post


Link to post
Share on other sites
Quote:

ok, dont flame me for asking this, i got 5 mins till lecture starts so i dont have time to search.

I can google alot of things in 5 minutes. Why can't you?

Quote:

i made a simple program that displays just a white triangle but it doesn't work. i know the code is correct, but i may be missing some header or something. dont know what it is.


Oh teh nos! The code is correct and it doesnt work? You're absolutely correct, opengl doesnt work! hundreds of thousands of people are using stuff that doesnt work. Thats a tragedy.


Quote:

anyone have any idea??


Yeah. RTFM.




Dont ask questions like this, esp without showing any code or describing what it does do. And posting that you have 5 minutes till your lecture isn't going to make us desire to help you any faster.

Share this post


Link to post
Share on other sites
Quote:
Original post by Foxostro
Quote:

I can google alot of things in 5 minutes. Why can't you?


56k


unless youre using google image search, 56k isnt a significant problem. I used to be on slowass dialup (33.6) and google was still certainly usable, and with 5min you can still google alot :-)

besides, if hes 5 minutes from lecture hes most likely on campus using broadband.

Share this post


Link to post
Share on other sites
LOL, ok, i think i shot my self in the foot.

Right, heres my scenario.

my uni is part of an academic alliance with microsoft and that alliance basically meeans that we can download microsoft program of them for free to use as part of our course.

anyway, i downloaded Microsoft Visual Studio so i could code my project at home.

i guess what i wanted to ask (but never really did) was that should i already have the opengl libraries on my computer????
Two freind have already said that i should, one said it comes with windows, the other said it comes with GFX card drivers (both of which i have).

Now, about the code. I coded a simple program that displays a simple white triangle one the screen. Now, this code ran in Uni but when i run it at home it gives me an error at the following line :

#include <GL/glut.h>

now, obviously, its telling me that i dont have the GLUT libraries. what i want to know from u guys is, should i already have these libraries?? if i should, then how do i get them to work, and if i dont, then where can i get the libraries from and how will i use them??

P.S, thats probably the most stupid question to you guys, since your all experienced in this fields, but remember, you were all beginners once :)

Share this post


Link to post
Share on other sites
Cant be detailed, got a lecture in -2 minutes

shouldnt #include <GL/glut.h> be #include "gl/glut.h"??

Never done OpenGL before, just a thought:)

EDIT: Ignore that just looked on Nehe it says....

#include <windows.h> // Header File For Windows
#include <gl\gl.h> // Header File For The OpenGL32 Library
#include <gl\glu.h> // Header File For The GLu32 Library
#include <gl\glaux.h> // Header File For The GLaux Library

Share this post


Link to post
Share on other sites
The OpenGL-headers come with Visual studio, but GLUT is not part of OpenGL, it's a 3rd party helper-library for OpenGL. So you need to download that. It can be found here.

Good luck.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this