Results 1 to 8 of 8

Thread: checking a display list

  1. #1
    Junior Member Newbie
    Join Date
    Oct 2002
    Posts
    16

    checking a display list

    How can i check if a display list ive created has been properley defined? ie that it is executable by glCallList()?

  2. #2
    Junior Member Newbie
    Join Date
    Oct 2002
    Posts
    16

    Re: checking a display list

    Ok found how to check the display list, however i cant work out why my display list wont be defined

    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) '


    GLuint the_terrain2;

    void main_func()
    {
    the_terrain2 = glGenLists(1);
    glNewList(the_terrain2, GL_COMPILE);
    terrain();
    glEndList();

    if (!glIsList(the_terrain2))
    assert(0);
    ...
    }

    void terrain(void)
    {

    glPointSize(4.0);
    glBegin(GL_POINTS);
    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;
    }
    }
    glEnd();
    }

    [This message has been edited by neilw (edited 11-06-2002).]

  3. #3
    Senior Member OpenGL Pro
    Join Date
    Oct 2000
    Location
    Fargo, ND
    Posts
    1,753

    Re: checking a display list

    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.
    Deiussum
    Software Engineer and OpenGL enthusiast

  4. #4
    Senior Member Regular Contributor
    Join Date
    Apr 2001
    Location
    Fort Collins, Colorado
    Posts
    446

    Re: checking a display list

    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.

  5. #5
    Senior Member OpenGL Pro
    Join Date
    Oct 2000
    Location
    Fargo, ND
    Posts
    1,753

    Re: checking a display list

    Ha ha ha! Let me guess. Your responses went something like...

    "Try downloading the latest drivers for your video card."
    Deiussum
    Software Engineer and OpenGL enthusiast

  6. #6
    Senior Member Regular Contributor
    Join Date
    Apr 2001
    Location
    Fort Collins, Colorado
    Posts
    446

    Re: checking a display list

    Exactly. Or, "Don't upgrade from Win98 to WinXP and expect things to work well unless you do a clean install." Hehehe

  7. #7
    Member Newbie
    Join Date
    Nov 2002
    Location
    Germany
    Posts
    48

    Re: checking a display list

    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!).
    Knowledge is Power

  8. #8
    Senior Member Regular Contributor
    Join Date
    Apr 2001
    Location
    Fort Collins, Colorado
    Posts
    446

    Re: checking a display list

    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...

Similar Threads

  1. Display List, VBO, or ?
    By chrisjon in forum OpenGL: Advanced Coding
    Replies: 11
    Last Post: 08-01-2010, 09:35 AM
  2. display list
    By jay0001 in forum OpenGL: Basic Coding
    Replies: 2
    Last Post: 03-12-2007, 08:48 AM
  3. Display list corruption when list created in shared library
    By Michael Wouters in forum OpenGL: Advanced Coding
    Replies: 2
    Last Post: 09-16-2005, 10:55 PM
  4. "WHAT IS IN A DISPLAY LIST ?"
    By SurGL in forum OpenGL: Basic Coding
    Replies: 3
    Last Post: 11-18-2001, 11:51 PM
  5. Display list to display models...Should I use them?
    By in forum OpenGL: Basic Coding
    Replies: 1
    Last Post: 11-27-2000, 12:49 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Proudly hosted by Digital Ocean