View Full Version : checking a display list
11-06-2002, 01:24 AM
How can i check if a display list ive created has been properley defined? ie that it is executable by glCallList()?
11-06-2002, 02:46 AM
Ok found how to check the display list, however i cant work out why my display list wont be defined http://www.opengl.org/discussion_boards/ubb/frown.gif
heres part of my code, can anyone see whats wrong?
it fails on the test for if the display list is defined ' glIsList(the_terrain2) '
the_terrain2 = glGenLists(1);
for (int i = -50000; i <= 50000; i+=1000)
for (int j = -50000; j <= 50000; j +=1000)
float height = dted.Height(i+300000, j+200000);
glColor3f(height/300, height/300, height/300);
glVertex3d((double) i, (double) j, height);
std::cout << "Terrain Height for x,y("<< i << "," << j <<") = " << height << endl;
[This message has been edited by neilw (edited 11-06-2002).]
11-06-2002, 04:39 AM
You need to have created an OpenGL context before ANY OpenGL function will work correctly. If you're using glut, that means after glutCreateWindow. If you're using Win32 to create your window that means after wglCreateContext.
Hmmm... I seem to be replying to a lot of posts with this same answer lately. Maybe I should start having a text file with generic responses I can cut/paste from. http://www.opengl.org/discussion_boards/ubb/smile.gif
11-06-2002, 06:13 AM
Hmmm... I seem to be replying to a lot of posts with this same answer lately. Maybe I should start having a text file with generic responses I can cut/paste from.
If you think a text file like this would be handy here, try visiting the "Hardware/Gaming" help section. I used to post there trying to help people, but I was writing the exact same answer 90% of the time. http://www.opengl.org/discussion_boards/ubb/smile.gif
11-06-2002, 06:28 AM
Ha ha ha! Let me guess. Your responses went something like...
"Try downloading the latest drivers for your video card."
11-06-2002, 07:06 AM
Exactly. http://www.opengl.org/discussion_boards/ubb/smile.gif Or, "Don't upgrade from Win98 to WinXP and expect things to work well unless you do a clean install." Hehehe
11-06-2002, 03:01 PM
WinXP? I even don't get Doom and Dosquake to run. glDoom runs too slow on my system, Doom95 and Dosdoom don't run, glQuake crashes (I'm using a glide wrapper) and Winquake is just plain ugly. And the compatibility options of XP have never made a difference. I think, they just chance the GetVersion() reply.
WinXP sucks, but I'm not gonna change back to Win98, which is more compatible, but first it would kill my processor (Win98 doesn't use the HLT processor command and my cooler is dead, for some strange reason =), second most of the new features, that XP provides, aren't contained in 98. Well, I could make my system a bit more compatible by a Windows update, but I'm not gonna accept Micro$oft's new licence (read it carefully!).
11-06-2002, 07:17 PM
Well, XP seems to work ok sometimes, it's the upgrade from 98 without a clean install that seems to really hork things up. I've run some of my demo's on the XP boxes at work.
Now Win2k on the other hand, that is sweetness in all it's glory (at least as good as Windows can get, hehe). Wish my Ultra5 at work had a decent vid card...
Powered by vBulletin® Version 4.2.0 Copyright © 2013 vBulletin Solutions, Inc. All rights reserved.