Hi, An advanced way to do that is to combine layered rendering with a geometry shader and geometry instancing to generate the slices. OSG SVN has support to let the geometry shader choose the right layer via the gl_Layer variable.
-Fred ----- "Mahendra G.R" <mahen...@mahendragr.com> a écrit : > Hello Robert, > > Ok, will do that. I'm pretty new to ALL these things. > > > On Fri, Oct 1, 2010 at 3:38 PM, Robert Osfield < > robert.osfi...@gmail.com > wrote: > > > Hi Mahendra, > > Hows about looking at the osg::Camera API, it should become obvious > how one sets a specific face of texture cube map or a 3d texture when > doing render to texture. Learning how to investigate how to solve > your own problems by looking at the API and examples will really speed > your progress. > > Robert. > > On Fri, Oct 1, 2010 at 2:32 PM, Mahendra G.R < mahen...@mahendragr.com > > wrote: > > Hello, > > > > Sorry guys, i have a problem agian. What i'm trying to do is render > into a > > 3D texture and i have a problem here, as far as i know, what i'm > doing now > > is render into a 2D texture (using a FBO). I saw some samples in > opengl > > where they actually loop through all the slices in Z direction and > produce a > > 3D texture. how should i do this in osg?. Sorry if my questions are > stupid > > > > > > Thanks, > > Best regards > > > > On Fri, Oct 1, 2010 at 2:47 PM, Mahendra G.R < > mahen...@mahendragr.com > > > wrote: > >> > >> Hello Robert, > >> > >> Thanks, i figured it out. > >> > >> On Fri, Oct 1, 2010 at 2:42 PM, Robert Osfield < > robert.osfi...@gmail.com > > >> wrote: > >>> > >>> HI Mahendra > >>> > >>> On Fri, Oct 1, 2010 at 1:30 PM, Mahendra G.R < > mahen...@mahendragr.com > > >>> wrote: > >>> > Thanks or ur reply, how should i read back the data from the > texture, > >>> > can i > >>> > attach an image to the camera(or texture?) and read data from > that > >>> > image?, > >>> > is it possible and how. > >>> > >>> See osgprerender example, in particular the code path that is used > when > >>> you run: > >>> > >>> osgprerender --image > >>> > >>> Robert. > >>> _______________________________________________ > >>> osg-users mailing list > >>> osg-users@lists.openscenegraph.org > >>> > http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org > >> > >> > >> > >> -- > >> http://www.mahendragr.com > > > > > > > > -- > > http://www.mahendragr.com > > > > _______________________________________________ > > 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 > > > > -- > http://www.mahendragr.com > > _______________________________________________ > 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