Re: Modify buffers

New Message Reply Date view Thread view Subject view Author view

Mario Veraart (rioj7++at++fel.tno.nl)
Thu, 2 Apr 1998 14:06:38 +0200 (MET DST)


Wilfried Zeise wrote:
>
> Hi Alejandro:
>
> First you have to select the color buffer source for the pixels with
> glReadBuffer (GL_FRONT_LEFT, GL_FRONT_BACK, etc.).
>
> With glReadPixels you can read the buffer values, with glDrawPixels you can
> draw new values and with glCopyPixels you can copy a pixel rectangle to
> another position.
>
> The pixel formats you can use are e.g.:
>
> - GL_RGB for the rgb values
> - GL_RGBA for the rgba values
> - GL_STENCIL_INDEX for the stencil buffer
> - GL_DEPTH_COMPONENT for the depth buffer
> etc.
>
> Hope this helps.
>
> Wilfried
>
> Wilfried Zeise
> University of Wuppertal
>
> >Hi,
> >
> > Does anyone know how to modify the buffers (frame, z, stencil, etc) of
> >a Performer channel/window. I want to do some post draw processing to the
> frame
> >buffer using OpenGL and I don't know how to access the buffers.
> >
> >--
> >------------------------------------------------------------------------
> >Alejandro Saez
> >Software Engineer
> >Silicon Chile S.A.
> > Avda. Andres Bello 2777, Of. 602
> >E-mail: asaez++at++silicon.cl Providencia
> >Phone: +56 (2) 203 3371 Ext. 105 Santiago
> >Fax: +56 (2) 203 3370 Chile

If you only want to draw some extra things like a HUD, you don;t have
to read and write the buffer. After pfDraw() you just set up the
required OpenGL state and viewing settings and draw what you want.
Be sure to restore the state as found after pfDraw(), because
performer might be counting on certain settings.

Mario
=======================================================================
List Archives, FAQ, FTP: http://www.sgi.com/Technology/Performer/
            Submissions: info-performer++at++sgi.com
        Admin. requests: info-performer-request++at++sgi.com


New Message Reply Date view Thread view Subject view Author view

This archive was generated by hypermail 2.0b2 on Mon Aug 10 1998 - 17:57:11 PDT

This message has been cleansed for anti-spam protection. Replace '++at++' in any mail addresses with the '@' symbol.