Part of the Khronos Group
OpenGL.org

The Industry's Foundation for High Performance Graphics

from games to virtual reality, mobile phones to supercomputers

Results 1 to 7 of 7

Thread: GL_COMPILE_AND_EXECUTE / GL_COMPILE

  1. #1
    Advanced Member Frequent Contributor
    Join Date
    Feb 2000
    Location
    France
    Posts
    880

    GL_COMPILE_AND_EXECUTE / GL_COMPILE

    Hi there !

    I am still running a Dual Pentium III 600Mhz 512Mb under WinNT4.0 SP6a with an ELSA Erazor X2 (GeForce DDR) and the latest leaked nVidia Drivers 5.13 for NT.

    I discovered something very amazing this afternoon : I usually use display lists this way :

    1) If the list has to be built :
    glNewList(xx,GL_COMPILE_AND_EXECUTE);
    RENDER_EVERYTHING();
    glEndList();
    2) If it has been built :
    glCallList(xx);

    For some reason, I changed one of my programs today to :
    1) If the list has to be built :
    glNewList(xx,GL_COMPILE);
    RENDER_EVERYTHING();
    glEndList();
    2) Always :
    glCallList(xx);

    Some remarks :

    1 - The cycle COMPILATION THEN EXECUTION is much much MUCH faster than the cycle COMPILATION/EXECUTION at the same time.
    2 - More remarkable, the display list created seems more efficient... I mean, I get better fps now than before on the same model ! (gain 5-15 fps according to the model !). This would mean that the compilation is not the same in the two cases...

    Well, if some of you want to try that (actually I was perhaps the only one using my previous method, but who knows !)....
    Then, if someone can explain me...
    Actually, it can make sense that COMPILE THEN EXECUTE is faster than COMPILE/EXECUTE AT THE SAME TIME. But I can't find an explanation for the "better" list created !

    See ya.

    Eric

  2. #2
    Intern Newbie
    Join Date
    Mar 2000
    Location
    UK
    Posts
    36

    Re: GL_COMPILE_AND_EXECUTE / GL_COMPILE

    Interesting.

    Are you absoloutely sure that you weren't rebuilding the display list each frame, or something like that?

    I'll check this out myself, and get back to you on it....

  3. #3
    Advanced Member Frequent Contributor
    Join Date
    Feb 2000
    Location
    France
    Posts
    880

    Re: GL_COMPILE_AND_EXECUTE / GL_COMPILE

    Yes, I am absolutely sure !

    I kept the old source and added a message each time glNewList was added and I can tell that it was not each frame !

    Anyway, the time that was needed for rebuilding the display list was something like 3-5 seconds (depending on the model) with my previous method so I would have noticed if it was rebuilt each frame. And what is amazing is that now the whole cycle is hardly noticeable !!!

    Well, I do not know if it is due to the new drivers 5.13 or to GeForce (DDR) or to whatever but any of you who is using the same method than the one I was using should try the second one ! I hope you'll gain as much as me....

    Eric

  4. #4
    Member Regular Contributor
    Join Date
    Feb 2000
    Location
    milano, italy
    Posts
    282

    Re: GL_COMPILE_AND_EXECUTE / GL_COMPILE

    yes, i noticed the same behaviour on the TNT.
    ...i was testing specular maps, so i took the time to test straight, VA, DL, DL w/exe...

    on the tnt, the DL w/exe, was very very slow.

    Dolo/\/\ightY
    Dolo/\/\ightY

  5. #5
    Junior Member Newbie
    Join Date
    Apr 2000
    Posts
    1

    Re: GL_COMPILE_AND_EXECUTE / GL_COMPILE

    It's nice to see someone else has this problem!

    When I use COMPILE_AND_EXECUTE the compiled list is actually slower than not using display lists at all!
    (from 20fps without display lists to 3fps with COMPILE_AND_EXECUTE display lists!)

    Seems this must be with NVIDIA's drivers.
    (I have a Geforce with 5.something drivers)

  6. #6
    Intern Newbie
    Join Date
    Mar 2000
    Location
    UK
    Posts
    36

    Re: GL_COMPILE_AND_EXECUTE / GL_COMPILE

    I just made an alteration to a project that I've been working on for a long time, changing the display list method as suggested above.

    I really can't believe the speed difference that it makes!!

    Thanks guys.

    Incidentally, is there any good reason for having a compile and execute display list, over a compile display list? It doesn's make any sense that SGI would put in a redundant feature like this.

  7. #7
    Advanced Member Frequent Contributor cass's Avatar
    Join Date
    Feb 2000
    Location
    Austin, TX, USA
    Posts
    913

    Re: GL_COMPILE_AND_EXECUTE / GL_COMPILE

    This is interesting, for sure. I have seen what is done in the mesa code, and I would expect the display list generated by COMPILE_AND_EXECTUTE to have identical performance to COMPILE after the first build. Perhaps an optimization path is used in the COMPILE case? I always use COMPILE then call the list, so I've never noticed.

    Cass
    Cass Everitt -- cass@xyzw.us

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •