Hello
I'm developping quite simple volume rendering technic consisting of several
textured quads aligned according viewpoint. As I havent the time to write a
cool shader for this I have sample my volume according x,y,z and select the
set of quad that fit to the viewpoint..
As quads are parallels, I know that my quads are always render in the same
order (or in reverse order if it's seen from behind) then I would like to
control the order of drawing of the planes'osg::Geometry:
I've tried with some
myDrawable:public Drawable{
bool reverse;
vector<Drawable> planesset;//a set of Quad
void drawimplementation(renderState r){
int end=planeset.size();
if(!reverse)
for(int i=0;i<end;i++)planeset[i].drawimplementation(r);
else
for(int i=end;i<0;i--)planeset[i].drawimplementation(r);
}
};
It works but the texture cannot be attach to a Drawable:(
Then I have read of the possibility to create my own RenderBin in order not
to sort my drawing and just set a reverse flag on a geometry, but How could
I do that?
It seems to be very complicated, is there an other way?
Thanks
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org