Page 2 of 2 FirstFirst 12
Results 11 to 16 of 16

Thread: EGL double buffering

  1. #11
    Senior Member
    Join Date
    May 2006
    Posts
    353

    Re: Example of double buffered pbuffer

    Quote Originally Posted by mustaf
    Hi,

    So, is there any implementation where we have double buffered pbuffer?I have some question regarding the double buffered pbuffer

    1>Can we specify which buffer of pbuffer is used for writing to pbuffer and which for reading from pbuffer?
    2>Who takes care of the synchronization issue i.e. whether simultaneously reading and writing is possible.
    3>Do i need to explicitly call eglswapbuffers on pbuffer to transfer the content from back buffer to front buffer?
    Even if there were an implementation that used double buffered pbuffers for whatever reason (though I can't think of any right now), that would be completely hidden. It would behave as if single-buffered.

    What is the effect if i call eglswapbuffers on single buffered pbuffer?My opinion is it is a NOP, but just want to confirm.I have verified in the rasteroid (Hybrid) exmaple that it is a NOP.
    EGL spec, section 3.9.1: "If surface is a single-buffered window, pixmap, or pbuffer surface, eglSwapBuffers has no effect."

    In case of single buffered pbuffer, how is the synchronization happen i.e. we are not reading and writing to/from pbuffer simultaneously.
    The same way it happens for window surfaces: a read operation from the surface causes a flush of all rendering commands to that surface. I.e. it will block until all rendering has been completed.
    Georg Kolling, Imagination Technologies
    Please ask questions specific to PowerVR hardware or SDKs on the PowerVR Insider Forum
    DevTech@imgtec.com | http://www.powervrinsider.com

  2. #12
    Junior Member
    Join Date
    Aug 2007
    Location
    INDIA
    Posts
    29

    Re: Example of double buffered pbuffer

    Quote Originally Posted by Xmas
    Even if there were an implementation that used double buffered pbuffers for whatever reason (though I can't think of any right now), that would be completely hidden. It would behave as if single-buffered.
    Somewhere, i read over the net(i dont exactly remember where) that when we need two pbuffers for texturing or whatever purpose, it is better to use a double buffered pbuffer in stead of two pbuffer so that context switching will be reduced and as a result, performance will be enhanced.

    So, i was thinking there might be some usefulness of double buffered pbuffer.Do you have any idea on this?

  3. #13
    Senior Member
    Join Date
    May 2006
    Posts
    353

    Re: Example of double buffered pbuffer

    Quote Originally Posted by mustaf
    Somewhere, i read over the net(i dont exactly remember where) that when we need two pbuffers for texturing or whatever purpose, it is better to use a double buffered pbuffer in stead of two pbuffer so that context switching will be reduced and as a result, performance will be enhanced.
    Then whoever wrote that is wrong. There are no double-buffered pbuffers.
    Georg Kolling, Imagination Technologies
    Please ask questions specific to PowerVR hardware or SDKs on the PowerVR Insider Forum
    DevTech@imgtec.com | http://www.powervrinsider.com

  4. #14
    Junior Member
    Join Date
    Aug 2011
    Posts
    1

    Re: EGL double buffering

    Hi,

    I'm having problems understanding how double buffering works in OpenGL ES and on the iPhone. I suspect it it is supported implictly, but it would help my understanding if I knew how to enable and disable it. Its fairly obvious how it works on traditional openGL - we draw to a back buffer, swap it (just a pointer swap) with the front buffer and draw the front buffer (the old back buffer).

  5. #15

    Re: EGL double buffering

    As far as I know, there is no way to specify that you want to work in single buffer mode.

  6. #16
    Senior Member
    Join Date
    May 2008
    Posts
    104

    Re: EGL double buffering

    When you create your egl window surface you can pass an attribute list. You can set EGL_RENDER_BUFFER to EGL_BACK_BUFFER for a double buffered window or you can set it to EGL_SINGLE_BUFFER for a single buffered window. Some windowing systems, will even let you have X number of buffers for EGL_BACK_BUFFER, by setting the buffer count on the native window.

Page 2 of 2 FirstFirst 12

Similar Threads

  1. Single-Buffering with EGL
    By SSNTails in forum Cross API and window system integration
    Replies: 1
    Last Post: 04-19-2007, 06:22 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
  •