[PATCH 3/4] compositor: unify sprite and primary handling a bit

Jesse Barnes jbarnes at virtuousgeek.org
Tue Jan 17 10:25:33 PST 2012


On Mon, 16 Jan 2012 22:09:11 -0500
Kristian Høgsberg <krh at bitplanet.net> wrote:
> > +       if (queued_sprite) {
> > +               drmVBlank vbl = {
> > +                       .request.type = DRM_VBLANK_RELATIVE | DRM_VBLANK_EVENT,
> > +                       .request.sequence = 1,
> > +               };
> > +
> > +               vbl.request.signal = (unsigned long)output;
> > +               ret = drmWaitVBlank(c->drm.fd, &vbl);
> > +               if (ret) {
> > +                       fprintf(stderr, "vblank event request failed: %d: %s\n",
> > +                               ret, strerror(errno));
> > +               }
> > +       }
> > +
> 
> Can't you just use the pageflip callback for this too?

I think so, but I haven't tested to see if we'll sometimes be off by
one with a flip complete vs a vblank event (one might come in before
the other).  And the setplane call is really vblank sync'd, independent
of when/how the flip was scheduled.

We really need an atomic mode set don't we?

-- 
Jesse Barnes, Intel Open Source Technology Center
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 836 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/wayland-devel/attachments/20120117/cd56dd19/attachment.pgp>


More information about the wayland-devel mailing list