Remove unused SGMakeRunwaySign function.

This commit is contained in:
Christian Schmitt
2012-05-03 16:35:47 +02:00
parent cc37713a66
commit 0bdeaeb4e2
3 changed files with 0 additions and 31 deletions

View File

@@ -261,9 +261,6 @@ ReaderWriterSTG::readStgFile(const std::string& absoluteFileName,
} else if ( token == "OBJECT_SIGN" ) {
node = SGMakeSign(staticOptions->getMaterialLib(), name);
} else if ( token == "OBJECT_RUNWAY_SIGN" ) {
node = SGMakeRunwaySign(staticOptions->getMaterialLib(), name);
} else {
SG_LOG( SG_TERRAIN, SG_ALERT, absoluteFileName
<< ": Unknown token '" << token << "'" );

View File

@@ -41,7 +41,6 @@
#include "apt_signs.hxx"
#define SIGN "OBJECT_SIGN: "
#define RWY "OBJECT_RUNWAY_SIGN: "
using std::vector;
using namespace simgear;
@@ -368,26 +367,3 @@ SGMakeSign(SGMaterialLib *matlib, const string& content)
return object;
}
osg::Node*
SGMakeRunwaySign(SGMaterialLib *matlib, const string& name)
{
// for demo purposes we assume each element (letter) is 1x1 meter.
// Sign is placed 0.25 meters above the ground
float width = name.length() / 3.0;
osg::Vec3 corner(-width, 0, 0.25f);
osg::Vec3 widthVec(2*width + 1, 0, 0);
osg::Vec3 heightVec(0, 0, 1);
osg::Geometry* geometry;
geometry = osg::createTexturedQuadGeometry(corner, widthVec, heightVec);
EffectGeode* geode = new EffectGeode;
geode->setName(name);
geode->addDrawable(geometry);
SGMaterial *mat = matlib->find(name);
if (mat)
geode->setEffect(mat->get_effect());
return geode;
}

View File

@@ -45,8 +45,4 @@ using std::string;
osg::Node* SGMakeSign( SGMaterialLib *matlib, const string& content );
// Generate a runway sign
osg::Node* SGMakeRunwaySign( SGMaterialLib *matlib, const string& name );
#endif // _SG_APT_SIGNS_HXX