Results 1 to 4 of 4

Thread: Refresh Problem

  1. #1
    Junior Member Newbie
    Join Date
    Mar 2001
    Posts
    21

    Refresh Problem

    Hi,
    I used outline fonts to display text at various locations.

    for example "Text1" at location (30,30)
    "Text2" at location (60,60) and

    i am using glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
    option.

    It took some time to clear the color buffer. So it is looking like flicker on the screen. How i can avoid it?. If i removed the GL_COLOR_BUFFER_BIT it is working fine. But when i am displaying text "text3" at location (30,30), the "text3" is superimposed on the text "text1".

    Thanks,
    Kannan

  2. #2
    Senior Member Regular Contributor
    Join Date
    Dec 1969
    Location
    Munich,Germany
    Posts
    227

    Re: Refresh Problem

    the GlClear call blocks the graphic pipeline untill it is finished you should avoid all drawing calls soon after a glClear, do some calcualtions or other stuff.

    thats the only thing i can say to this topic
    Chris
    yes

  3. #3
    Senior Member OpenGL Guru Relic's Avatar
    Join Date
    Apr 2000
    Posts
    2,450

    Re: Refresh Problem

    You see the flicker because you're working on the front buffer. Select a double buffered pixelformat, render in the backbuffer and do a SwapBuffers().
    By this you don't see the clear and drawing happening on your screen but only the final image.

  4. #4
    Senior Member Regular Contributor
    Join Date
    Dec 1969
    Location
    Munich,Germany
    Posts
    227

    Re: Refresh Problem

    hmm geee I never think of the simple answers
    yes

Similar Threads

  1. problem with refresh rate on multiple viewports
    By El in forum OpenGL: Advanced Coding
    Replies: 3
    Last Post: 01-19-2004, 07:20 AM
  2. Refresh Rate Problem
    By in forum OpenGL: User Software
    Replies: 1
    Last Post: 12-12-2003, 06:48 PM
  3. How to fix refresh rate problem for XP/2000
    By Twilight in forum OpenGL: User Software
    Replies: 0
    Last Post: 09-18-2001, 08:30 AM
  4. Refresh Problem
    By Drew88 in forum OpenGL: User Software
    Replies: 3
    Last Post: 07-02-2001, 02:54 AM
  5. refresh rate problem
    By n3r0nix in forum OpenGL: Basic Coding
    Replies: 2
    Last Post: 04-01-2001, 02:05 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