3 #include <osg/MatrixTransform>
5 #include <osg/Geometry>
6 #include <osgUtil/UpdateVisitor>
7 #include <osg/Texture2D>
11 #include <osgUtil/TransformCallback>
12 #include <osgUtil/RenderStage>
13 #include <osgUtil/SmoothingVisitor>
14 #include <osgUtil/CullVisitor>
17 using namespace vrecko;
26 _subgraph(subgraph) {}
28 virtual void operator()(osg::Node*
node, osg::NodeVisitor* nv)
31 if (_subgraph.valid()) _subgraph->accept(*nv);
47 _localState(new osg::StateSet),
54 _localState(new osg::StateSet),
58 virtual void operator()(osg::Node*
node, osg::NodeVisitor* nv)
61 osgUtil::CullVisitor* cullVisitor =
dynamic_cast<osgUtil::CullVisitor*
>(nv);
62 if (cullVisitor && (_texture.valid()|| _image.valid()) && _subgraph.valid()) {
63 doPreRender(*node,*cullVisitor);
76 void doPreRender(osg::Node&
node, osgUtil::CullVisitor& cv);
97 void preInitialize(
void);