RE: [info-performer] Subload pfTexture across multiple pipes

Date view Thread view Subject view Author view

From: Dick Rous (dick++at++sgi.com)
Date: 10/30/2003 04:32:57


The fastest way to establish off-screen rendering is to have a managed area
on one pipe that consists of the sum of the visible channel and the
off-screen (rear view mirror) channel.
This can be done with ircombine.
Then, with pfChanViewport you can specify the area of the visible channel
and assign the remainder to the mirror channel, both in the same
pfPipeWindow.
This approach is preferable, because it overcomes the need for 2
pfPipeWindows on the same hardware pipe, and therefore avoid expensive
context switches.
(Total draw time is t_chan1 + t_chan2, while with separate pfPipeWindows it
is t_chan1 + t_chan2 + t_ctxsw, where on IR, t_ctxsw easily can be the
larger
amount).

- Dick.

> -----Original Message-----
> From: Volodymyr Kindratenko [mailto:kindr++at++ncsa.uiuc.edu]
> Sent: Thursday, 30 October, 2003 01:24
> To: 'Dorosky, Christopher G'; 'Dick Rous'
> Cc: info-performer++at++sgi.com
> Subject: RE: [info-performer] Subload pfTexture across multiple pipes
>
>
> Chris:
>
> Thanks for the explanation, it helps.
>
> Well, I came up with a different solution. I render the
> mirror image in a
> separate pfPipeWindow and copy it from the screen buffer to
> the texture's
> image memory via glReadPixels. This is done in the
> pfPipeWindow's channel
> draw callback. This works as long as pfPipeWindow is visible
> on the screen.
> Setting pfPipeWindow type to PFPWIN_TYPE_PBUFFER results in
> not calling the
> pfPipeWindow's channel draw callback, so, no texture is
> rendered. How can I
> render to an off-screen buffer?
>
> Volodymyr
>
> > -----Original Message-----
> > From: Dorosky, Christopher G
> [mailto:christopher.g.dorosky++at++lmco.com]
> > Sent: Wednesday, October 29, 2003 4:27 PM
> > To: Volodymyr Kindratenko; Dick Rous
> > Cc: info-performer++at++sgi.com
> > Subject: RE: [info-performer] Subload pfTexture across
> multiple pipes
> >
> >
> > You have to subload them on each pipe.
> > No way around it, unless you want to take the frame hit and
> > have Performer call the tex->load() implicitly.
> >
> > Pipe 0 CANNOT share it's texture memory with Pipe 1.
> > Channel 0 CAN (and does) share it's texture memory with
> > channel 1, IF Channel 0&1 are on the same pipe.
> >
> > That saying was misleading. pfTexture's can have different
> > images in different pipes. Both must be directly subloaded,
> > even if they are the same.
> >
> > Think of the texture beign texture for a tank. One pipe could
> > be visual, the other IR. Possibly the same pfTexture, but
> > different image data.
> >
> > Chris
> >
> > -----Original Message-----
> > From: owner-info-performer++at++performer.engr.sgi.com
> > [mailto:owner-info-performer++at++performer.engr.sgi.com]On Behalf
> > Of Volodymyr Kindratenko
> > Sent: Wednesday, October 29, 2003 10:20 AM
> > To: 'Dick Rous'
> > Cc: info-performer++at++sgi.com
> > Subject: RE: [info-performer] Subload pfTexture across
> multiple pipes
> >
> >
> > Dick:
> >
> > Actually, it does not, and why should it be? Ideally I want
> > the texture image to be rendered only once on a separate pipe
> > and then be distributed to the remaining pipes (4-IR SGI
> > connected to a 3-wall CAVE). At the moment, the texture
> > rendering channel is attached to one of the 3 pipes used to
> > render the CAVE imagery. And sure enough, this pipe has the
> > right texture. How can I grab this texture and distribute it
> > to the remaining channels?
> >
> > Chapter 9. Graphics State from the OpenGL Performer
> Programmer's Guide
> > says:
> > "... pfSubloadTex() and pfSubloadTexLevel() can also be used
> > in the drawing process to do an immediate load of texture
> > memory managed by the given pfTexture and these routines
> > allow you to specify all loading parameters (source, origin,
> > size, etc.). THIS IS USEFUL FOR LOADING DIFFERENT IMAGES FOR
> > THE SAME pfTexture IN DIFFERENT GRAPHICS PIPELINES. ..." And
> > I need just the opposite, loading the same image in different
> > graphics pipelines.
> >
> > Volodymyr
> >
> > > -----Original Message-----
> > > From: Dick Rous [mailto:dick++at++sgi.com]
> > > Sent: Wednesday, October 29, 2003 4:48 AM
> > > To: 'Volodymyr Kindratenko'; info-performer++at++sgi.com
> > > Subject: RE: [info-performer] Subload pfTexture across
> > multiple pipes
> > >
> > >
> > > Have you checked if the subload code in the draw callback is
> > > executed for each pipe?
> > >
> > > - Dick.
> > >
> > > > -----Original Message-----
> > > > From: Volodymyr Kindratenko [mailto:kindr++at++ncsa.uiuc.edu]
> > > > Sent: Wednesday, 29 October, 2003 01:08
> > > > To: info-performer++at++sgi.com
> > > > Subject: [info-performer] Subload pfTexture across
> multiple pipes
> > > >
> > > >
> > > >
> > > > Hello:
> > > >
> > > > I need to build a rear view mirror for a driver
> > > > simulator. To do
> > > > this, I define a separate channel for rendering rear view
> > > > mirror image and
> > > > in that channel's draw callback I subload the relevant
> > > > portion of the frame
> > > > buffer to the appropriate pfTexture. This works just fine on
> > > > a single pipe
> > > > system. How can I share this texture across multiple pipes
> > > > (CAVE)? In the
> > > > CAVE I see that the correct image is applied to a portion of
> > > > the mirror
> > > > polygon residing on the front wall (I use the front wall's
> > > > pipe rendering
> > > > the rear view channel), and nothing is applied to the portion
> > > > of the polygon
> > > > residing for example on the left wall. Basically, the
> > > > texture image is not
> > > > shared between the pipes. Please help!
> > > >
> > > > Volodymyr Kindratenko
> > > > NCSA, UIUC
> > > >
> > > >
> > > > --------------------------------------------------------------
> > > > ---------
> > > > List Archives, Info, FAQ:
> > http://www.sgi.com/software/performer/
> > > > Open
> > Development Project: http://oss.sgi.com/projects/performer/
> > > > Submissions: info-performer++at++sgi.com
> > > > Admin. requests: info-performer-request++at++sgi.com
> > > > --------------------------------------------------------------
> > > > ---------
> > > >
> > >
> >
> >
> > --------------------------------------------------------------
> > ---------
> > List Archives, Info, FAQ: http://www.sgi.com/software/performer/
> > Open Development Project: http://oss.sgi.com/projects/performer/
> > Submissions: info-performer++at++sgi.com
> > Admin. requests: info-performer-request++at++sgi.com
> > --------------------------------------------------------------
> > ---------
> >
>


Date view Thread view Subject view Author view

This archive was generated by hypermail 2b29 : Thu Oct 30 2003 - 04:33:06 PST