Results 1 to 4 of 4

Thread: Can I only Create a Pbuffer without create a window surface

  1. #1
    Junior Member
    Join Date
    Dec 2011
    Posts
    2

    Can I only Create a Pbuffer without create a window surface

    I want to create a pbuffer surface to draw something but do not want to show it, just want to copy the color buffer to the native memory.
    Creating a Pbuffer Surface can create a window Surface first and bind it to a context, then create a pbuffer surface, just like this

    eglChooseConfig(display,...) //for the window surface
    eglCreateWindowSurface(display,...)
    eglCreateContext(...)
    eglMakeCurrent(display,...)

    eglChooseConfig(display,...) //for the pbuffer surface
    eglCreatePbufferSurface(display,...)

    But I do not want to show anything on screen ,so I do not want to create a window surface .
    If I do this and only create a pbuffer ,it get a error and return EGL_BAD_ALLOC.
    Does it has to create a window surface and bind it to a context first ?

  2. #2
    Junior Member
    Join Date
    Dec 2011
    Posts
    2

    Re: Can I only Create a Pbuffer without create a window sur

    Just like the problem here http://www.imgtec.com/forum/forum_posts.asp?TID=854
    why I have to create a window surface before I am allowed to create a PBuffer surface with the GLES 1.1 sdk.

  3. #3
    Senior Member
    Join Date
    May 2008
    Posts
    100

    Re: Can I only Create a Pbuffer without create a window sur

    The spec doesn't require a window surface to render to a pbuffer surface. Are you making the pbuffer surface current?

  4. #4
    Junior Member
    Join Date
    Feb 2012
    Posts
    1

    Re: Can I only Create a Pbuffer without create a window sur

    Also use attribute EGL_PBUFFER_BIT in your attributes to eglChooseConfig.

Similar Threads

  1. Create and initialize a pbuffer.
    By muratmat in forum OpenGL ES general technical discussions
    Replies: 1
    Last Post: 09-17-2009, 09:18 PM
  2. Create and initialize a pbuffer.
    By muratmat in forum Cross API and window system integration
    Replies: 0
    Last Post: 09-16-2009, 06:31 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •