Hi,

So what you get is a z-fighting artefacts which comes
from rendering pixels on the same depth position where
other pixels already exists. Sometimes they are drawn,
sometimes not.

Hence do disable depth reading on other passes which
will force to use the depth values just from the first
pass if you have your depth buffer shared.


Cheers,
Art


--- Jason Ziglar <[EMAIL PROTECTED]> schrieb:

> So I've got multiple projective texturing passes
> working, but I've run 
> into yet another problem. When the additional passes
> happen, they cause 
> flickering, which appears to be from fighting
> between the various 
> cameras projecting onto the scene.
> 
> I've tried using NESTED_RENDER on the cameras,
> increasing the camera 
> values with a static counter, but they still fight.
> How would I go about 
> removing the flicker from the different camera
> passes?
> 
> Thanks in advance,
> 
> 
> Art Tevs wrote:
> > Hi,
> >
> > if you want to have it to be extendable to
> n-passes, then you have to go the way you have
> proposed first. Create n camera's located on the
> same position. The subgraph scene of the camera
> should have your projective shader applied, so that
> if it get rendered then you have projected the
> correct texture on the scene.
> >
> > Afterwards you have to combine them. The easiest
> way would be to use the osgPPU library (use the
> current svn version) where you can specify a shader
> which do combines all the camera views into one
> texture.
> > Of course this is still not a general solution,
> because you need to know how much cameras you have
> when you write your shader. 
> >
> > Maybe the other solution would be to attach the
> same output texture to every camera's frame buffer
> object and use a shader and an adding-blend
> operation to write only the 1/n of the color value 
> to that texture . After all camera passes you will
> get the average value out of it.
> >
> > Cheers,
> > Art
> >
> >
> >
> >
> >
> > ----- Ursprüngliche Mail ----
> > Von: Jason Ziglar <[EMAIL PROTECTED]>
> > An: OpenSceneGraph Users
> <osg-users@lists.openscenegraph.org>
> > Gesendet: Montag, den 5. Mai 2008, 22:42:09 Uhr
> > Betreff: Re: [osg-users] Multiple projective
> texture passes?
> >
> > I don't see any straightforward way to ensure that
> is is extensible to 
> > n-passes using that technique though. My
> understanding is that I can't 
> > have an array of matrices in the shader, so in
> order to add a single 
> > pass I'd have to go and recompile the entire
> program.
> >
> > Is there a technique for having multiple
> transformation matrices without 
> > hard-coding the list of matrices?
> >
> > Thanks in advance,
> >
> >
> > Art Tevs wrote:
> >   
> >> Hi Jason,
> >>
> >> I think, you do not need multiple cameras. If you
> have
> >> the projective matricies of each of the captured
> >> viewcamera, then you can just combine all the
> >> projective textures in one pass. Just pass all
> your
> >> matricies and corresponding textures to the
> shader and
> >> compute the average value.
> >>
> >> If you was able to setup the environment for the
> one
> >> projective textures, then extending it to
> multiple
> >> textures is not a big issue.
> >>
> >> Cheers,
> >> Art
> >>
> >>
> >> --- Jason Ziglar <[EMAIL PROTECTED]> schrieb:
> >>
> >>  
> >>     
> >>> Hi all,
> >>>     I'm trying to write a program which takes
> >>> multiple images and 
> >>> projectively textures a scene with them. The
> images
> >>> are taken at 
> >>> different locations within the scene, and I'd
> like
> >>> to have the scene 
> >>> rendered with the result from projecting all the
> >>> images onto the world 
> >>> geometry.
> >>>
> >>>     I've got a shader and code base which can
> >>> project a single image 
> >>> onto geometry, but I'm not entirely certain how
> to
> >>> extend this to 
> >>> multiple images. Multiple cameras seems like the
> >>> right idea, except that 
> >>> I don't see how to grab the correct transforms
> and
> >>> textures for a given 
> >>> camera and apply them to the scene in order. Any
> >>> suggestions?
> >>>
> >>>
> >>> _______________________________________________
> >>> osg-users mailing list
> >>> osg-users@lists.openscenegraph.org
> >>>
> >>>    
> >>>       
> >>
>
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
> >>  
> >>
> >>
> >>
> >>       Machen Sie Yahoo! zu Ihrer Startseite. Los
> geht's: 
> >> http://de.yahoo.com/set
> >> _______________________________________________
> >> 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
> >
> >
> >
> >       E-Mails jetzt auf Ihrem Handy.
> > www.yahoo.de/go
> > _______________________________________________
> > 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
> 



      Lesen Sie Ihre E-Mails jetzt einfach von unterwegs.
www.yahoo.de/go
_______________________________________________
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to