[Mesa-dev] GBM Surface
krh at bitplanet.net
Tue Mar 27 12:11:17 PDT 2012
On Tue, Mar 27, 2012 at 3:08 PM, Kristian Høgsberg <krh at bitplanet.net> wrote:
> Here's a patch series from Ander to implement a new gbm feature: gbm
> surface. The gbm library is useful for allocating surface for scanout
> and rendering, but the application needs to create EGLImages for the
> gbm bos and then renderbuffers and then render using an FBO. On top
> of that, we have to rely on the (awkward) surfaceless extension to
> make it all work. So gbm surface gives us a few things:
> 1) Independent from KMS. The API could be a lot simpler if we just
> could say "EGL surface on this KMS crtc", we didn't want to tie it
> to KMS for a few reasons: we need to be able to pageflip to gbm bos
> from different sources (wayland clients); without the kms
> integration we can do headless EGL; gbm is usable with OpenWF as
> well; and finally, we may be able to implement the wayland egl
> backend in terms of gbm surface, which will greatly simplify that.
> 2) Go through eglSwapBuffers as a end-of-frame indicator. This is
> mainly to cover our back on architectures that require explicit
> synchronization between multiple queues, or for deferred rendering
> architectures that relies on eglSwapBuffers to trigger the actual
> 3) Let the EGL implementation manage number of buffers (double or
> triple buffer decision etc)
> 4) Provide a native window type for EGL on GBM. We avoid the
> surfaceless extension.
> 5) Reduce boilerplate code for applications using GBM, EGL and KMS.
> Here's how the eglkms.c example looks converted to gbm surface.
Ooops, wrong link, try this one:
More information about the mesa-dev