Moved osg::Impostor to osgSim::Impostor, as Impostor isn't a core feature.

This commit is contained in:
Robert Osfield
2005-05-01 19:48:49 +00:00
parent 7de1265059
commit 03232ec667
41 changed files with 702 additions and 845 deletions

View File

@@ -5,7 +5,7 @@ CXXFILES =\
TestManipulator.cpp\
osgimpostor.cpp\
LIBS += -losgProducer -lProducer -losgText -losgGA -losgDB -losgUtil -losg $(GL_LIBS) $(X_LIBS) $(OTHER_LIBS)
LIBS += -losgProducer -lProducer -losgText -losgSim -losgGA -losgDB -losgUtil -losg $(GL_LIBS) $(X_LIBS) $(OTHER_LIBS)
INSTFILES = \
$(CXXFILES)\

View File

@@ -4,7 +4,7 @@ include $(TOPDIR)/Make/makedefs
CXXFILES =\
osgimpostor.cpp\
LIBS += -losgProducer -lProducer -losgDB -losgText -losgUtil -losg $(GL_LIBS) $(X_LIBS) $(OTHER_LIBS)
LIBS += -losgProducer -lProducer -losgSim -losgDB -losgText -losgUtil -losg $(GL_LIBS) $(X_LIBS) $(OTHER_LIBS)
EXEC = osgimpostor

View File

@@ -1,11 +1,11 @@
#include <osg/Geometry>
#include <osg/Impostor>
#include <osg/Material>
#include <osg/MatrixTransform>
#include <osg/Quat>
#include <osg/Geode>
#include <osgUtil/InsertImpostorsVisitor>
#include <osgSim/Impostor>
#include <osgSim/InsertImpostorsVisitor>
#include <osgDB/ReadFile>
@@ -196,7 +196,7 @@ void LayoutAsGrid()
if (UseImpostor)
{
osg::Impostor * impostor = new osg::Impostor();
osgSim::Impostor * impostor = new osgSim::Impostor();
impostor->setImpostorThreshold(static_cast<float> (Threshold));
impostor->addChild(groups[i]);
impostor->setRange(0, 0.0f, 1e7f);
@@ -258,7 +258,7 @@ int main( int argc, char **argv )
osg::Node* model = osgDB::readNodeFiles(arguments);
if (model)
{
// the osgUtil::InsertImpostorsVisitor used lower down to insert impostors
// the osgSim::InsertImpostorsVisitor used lower down to insert impostors
// only operators on subclass of Group's, if the model top node is not
// a group then it won't be able to insert an impostor. We therefore
// manually insert an impostor above the model.
@@ -268,7 +268,7 @@ int main( int argc, char **argv )
if (bs.valid())
{
osg::Impostor* impostor = new osg::Impostor;
osgSim::Impostor* impostor = new osgSim::Impostor;
// standard LOD settings
impostor->addChild(model);
@@ -295,7 +295,7 @@ int main( int argc, char **argv )
// now insert impostors in the model using the InsertImpostorsVisitor.
osgUtil::InsertImpostorsVisitor ov;
osgSim::InsertImpostorsVisitor ov;
// traverse the model and collect all osg::Group's and osg::LOD's.
// however, don't traverse the rootnode since we want to keep it as

View File

@@ -12,6 +12,7 @@
#include <osg/CullFace>
#include <osg/TexMat>
#include <osg/TexGen>
#include <osg/TexEnv>
#include <osg/TexEnvCombine>
#include <osg/TextureCubeMap>
#include <osg/VertexProgram>

View File

@@ -9,6 +9,7 @@
#include <osg/ClipNode>
#include <osg/AlphaFunc>
#include <osg/TexGenNode>
#include <osg/TexEnv>
#include <osg/TexEnvCombine>
#include <osg/Material>
#include <osg/Endian>