Results 1 to 2 of 2

Thread: GL + timer queue

  1. #1
    Senior Member Frequent Contributor
    Join Date
    Oct 2009
    Posts
    592

    GL + timer queue

    If my rendering loop looks like this:
    Code :
    {
      issueCommands();
      swapBuffers();
    }
    Where is the best place to process a timer queue (processTimerQueue()), before swapping or after? I am pretty certain that the buffer swapping can block (say for VSync) and hence, the best place might be before the swap? How about the GL commands? Before or after? My guess is after, but I am not certain.

  2. #2
    Senior Member Frequent Contributor
    Join Date
    Oct 2009
    Posts
    592

    Re: GL + timer queue

    Yeah, I think after issueCommands() would be a good place.

    Rationale:
    Timer callbacks can alter textures, VBOs ... and might stall the pipeline, if they were called before issueCommands().

Similar Threads

  1. timer
    By in forum OpenGL: Basic Coding
    Replies: 1
    Last Post: 01-08-2006, 04:55 PM
  2. timer
    By zukko in forum OpenGL: Basic Coding
    Replies: 2
    Last Post: 06-11-2004, 11:00 AM
  3. timer
    By Vlasko in forum OpenGL: Basic Coding
    Replies: 3
    Last Post: 05-25-2003, 11:35 PM
  4. timer
    By PrinceofZ in forum OpenGL: Basic Coding
    Replies: 4
    Last Post: 11-20-2000, 07:46 AM
  5. Timer Please!!!
    By frogger in forum OpenGL: Basic Coding
    Replies: 4
    Last Post: 05-16-2000, 07:34 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