On Wed, 2009-07-01 at 10:35 -0700, Jesse Barnes wrote:
> On Wed, 01 Jul 2009 11:53:14 -0400
> Owen Taylor <otay...@redhat.com> wrote:
> 
> > There's a more subtle reason why you want to actually glFinish()
> > rather than glFlush() - if your rendering takes long enough so that
> > you can't keep up with the refresh rate:
> > 
> > - Do a bunch of rendering
> > - glFlush
> > - Wait for vblank
> > - glXSwapBuffers
> >  
> > Will cause the glXSwapBuffers to happen in the middle of a frame,
> > while
> > 
> > - Do a bunch of rendering
> > - glFinish
> > - Wait for vblank
> > - glXSwapBuffers
> > 
> > Will cause it to properly happen at the *second* vblank.
> 
> Of course glXSwapBuffers *should* just do the right thing and not tear
> by default (this happens with current radeon & intel drivers afaik).
> So I'd discourage people from using SGI_video_sync for tear-avoidance
> in general.  If you get tearing with glXSwapBuffers, file a bug.

Note that eliminating tearing only goes half the way to smooth
animation. Apps also need to be able to synchronize to the refresh, or
at least to the rendering frame rate. It seems like with DRI2 right now
we've mostly traded in the latter for the former. This may be
exacerbated with the intel driver because it doesn't seem to have any
explicit frame throttling any more, which can cause quite horrible
judder / stuttering (especially since the recent change to the
DRM_I915_GEM_THROTTLE ioctl behaviour).


-- 
Earthling Michel Dänzer           |                http://www.vmware.com
Libre software enthusiast         |          Debian, X and DRI developer

------------------------------------------------------------------------------
_______________________________________________
Mesa3d-dev mailing list
Mesa3d-dev@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mesa3d-dev

Reply via email to