Part of the Khronos Group
OpenGL.org

The Industry's Foundation for High Performance Graphics

from games to virtual reality, mobile phones to supercomputers

Results 1 to 4 of 4

Thread: Attach back buffer to FBO

  1. #1
    Intern Newbie
    Join Date
    Nov 2008
    Posts
    33

    Attach back buffer to FBO

    I see that with OpenGL 3.0, one can draw to multiple render targets of different resolutions. I need to draw to the back buffer and also to a half-resolution other target, where the latter is used for simple color-coded picking, and I want to draw simultaneously to save on having to transform vertices twice. But how do I attach the back buffer as a render target to an FBO?

    From NVIDIA's OpenGL 3.0 driver page: "Now allows rendering to a FBO with mixed-size attachments"

    But if I do say
    GLenum bufs[] = {GL_BACK, GL_AUX0};
    glDrawBuffers(2, bufs)
    how do I set the resolution for GL_AUX0?

  2. #2
    Intern Newbie
    Join Date
    Nov 2008
    Posts
    33

    Re: Attach back buffer to FBO

    Hello?

  3. #3
    Junior Member Regular Contributor
    Join Date
    Aug 2003
    Location
    Toronto, Canada
    Posts
    155

    Re: Attach back buffer to FBO

    You should read the spec for FBOs closer I think. They let you draw to renderbuffers and textures, not the main window's buffers.

  4. #4
    Senior Member OpenGL Pro
    Join Date
    Sep 2004
    Location
    Prombaatu
    Posts
    1,401

    Re: Attach back buffer to FBO

    And fyi AUX buffers are deprecated in OpenGL 3.0...

Posting Permissions

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