Hi,

A 60ms draw time is high, and may be high simply because the OpenGL
fifo is full and stalling draw dispatch, or could be that you could
requires a round trip from CPU to GPU.  I wouldn't have though having
lots of Camera in itself would be the cause of the slow draw times.

W.r.t multipass, using of multiple Camera is probably the way, but one
thing osg::Camera possibly doesn't yet support is sharing of FBO's, I
say possibly because I haven't tried to implement this type of
rendering myself yet, and osg::Camera is setup with the assumption
that each camera will create and manage its own FBO.  One might be
able to assign an already created FBO and share between multiple
Cameras, but I can't say for sure as I haven't tried it in code yet...

Robert.

On Sun, Feb 3, 2008 at 11:32 PM,  <[EMAIL PROTECTED]> wrote:
> Hi all,
>
>  I have a problem in which I have to do multipass rendering. When I say
>  multipass, it's in fact rendering to a texture which is the input for the
>  next rendering, etc... and that about a hundreds time... I could explain
>  why, but only if necessary, but let's say that no there is no better way
>  than doing a cascaded rendering with that amount of steps, and in fact,
>  that's sphecifically why I'm doing it on GPU...
>
>  Moving on to OSG related problem, it seems to me that every time you want
>  to render to a texture you have to add a Camera node. I've heard that you
>  could maybe do a little bit better, by having only one Camera node, but
>  several paths leading to it with differents statesets. But in my case, I
>  can't have only one camera, and several statesets, because each time, I
>  have to change
>  the fbo to render to, that can only be done by adding a new camera, with a
>  different texture to render to ...
>
>  So my question is, is there a better way to do this kind of multipass
>  rendering, than adding a camera for each step ? (better in the sense of
>  less costly ...)
>  I'm asking this because when I look at the stats, drawing takes about 60 ms,
>  and gpu time is 80ms. I expected the value for the gpu, because for each
>  camera, there is a fragment shader associated. But I didn't expect the
>  draw time to be so high, and I really think that is because of the way I'm
>  doing it (too many nodes maybe ... :( )
>
>  Thank you all
>  _______________________________________________
>  osg-users mailing list
>  osg-users@lists.openscenegraph.org
>  http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>
_______________________________________________
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to