Increase point sprite size for runway lights

This commit is contained in:
Frederic Bouvier 2012-01-31 23:40:19 +01:00
parent a276e7e379
commit 78645169bf
2 changed files with 9 additions and 9 deletions

View File

@ -756,7 +756,7 @@ SGLoadBTG(const std::string& path, const simgear::SGReaderWriterOptions* options
if (!tileGeometryBin.vasiLights.empty()) { if (!tileGeometryBin.vasiLights.empty()) {
EffectGeode* vasiGeode = new EffectGeode; EffectGeode* vasiGeode = new EffectGeode;
Effect* vasiEffect Effect* vasiEffect
= getLightEffect(24, osg::Vec3(1, 0.0001, 0.000001), 1, 24, true); = getLightEffect(48, osg::Vec3(1, 0.0001, 0.000001), 1, 48, true);
vasiGeode->setEffect(vasiEffect); vasiGeode->setEffect(vasiEffect);
SGVec4f red(1, 0, 0, 1); SGVec4f red(1, 0, 0, 1);
SGMaterial* mat = 0; SGMaterial* mat = 0;
@ -782,9 +782,8 @@ SGLoadBTG(const std::string& path, const simgear::SGReaderWriterOptions* options
if (tileGeometryBin.runwayLights.getNumLights() > 0 if (tileGeometryBin.runwayLights.getNumLights() > 0
|| !tileGeometryBin.rabitLights.empty() || !tileGeometryBin.rabitLights.empty()
|| !tileGeometryBin.reilLights.empty() || !tileGeometryBin.reilLights.empty()
|| !tileGeometryBin.odalLights.empty() || !tileGeometryBin.odalLights.empty())
|| tileGeometryBin.taxiLights.getNumLights() > 0) runwayEffect = getLightEffect(32, osg::Vec3(1, 0.001, 0.0002), 2, 32, true);
runwayEffect = getLightEffect(16, osg::Vec3(1, 0.001, 0.0002), 1, 16, true);
if (tileGeometryBin.runwayLights.getNumLights() > 0 if (tileGeometryBin.runwayLights.getNumLights() > 0
|| !tileGeometryBin.rabitLights.empty() || !tileGeometryBin.rabitLights.empty()
|| !tileGeometryBin.reilLights.empty() || !tileGeometryBin.reilLights.empty()
@ -817,11 +816,12 @@ SGLoadBTG(const std::string& path, const simgear::SGReaderWriterOptions* options
} }
if (tileGeometryBin.taxiLights.getNumLights() > 0) { if (tileGeometryBin.taxiLights.getNumLights() > 0) {
Effect* taxiEffect = getLightEffect(16, osg::Vec3(1, 0.001, 0.0002), 1, 16, true);
osg::Group* taxiLights = new osg::Group; osg::Group* taxiLights = new osg::Group;
taxiLights->setStateSet(lightManager->getTaxiLightStateSet()); taxiLights->setStateSet(lightManager->getTaxiLightStateSet());
taxiLights->setNodeMask(RUNWAYLIGHTS_BIT); taxiLights->setNodeMask(RUNWAYLIGHTS_BIT);
EffectGeode* geode = new EffectGeode; EffectGeode* geode = new EffectGeode;
geode->setEffect(runwayEffect); geode->setEffect(taxiEffect);
geode->addDrawable(SGLightFactory::getLights(tileGeometryBin.taxiLights)); geode->addDrawable(SGLightFactory::getLights(tileGeometryBin.taxiLights));
taxiLights->addChild(geode); taxiLights->addChild(geode);
lightGroup->addChild(taxiLights); lightGroup->addChild(taxiLights);

View File

@ -478,8 +478,8 @@ SGLightFactory::getSequenced(const SGDirectionalLightBin& lights)
float flashTime = 2e-2 + 5e-3*sg_random(); float flashTime = 2e-2 + 5e-3*sg_random();
osg::Sequence* sequence = new osg::Sequence; osg::Sequence* sequence = new osg::Sequence;
sequence->setDefaultTime(flashTime); sequence->setDefaultTime(flashTime);
Effect* effect = getLightEffect(10.0f, osg::Vec3(1.0, 0.0001, 0.00000001), Effect* effect = getLightEffect(40.0f, osg::Vec3(1.0, 0.0001, 0.00000001),
6.0f, 10.0f, true); 10.0f, 40.0f, true);
for (int i = lights.getNumLights() - 1; 0 <= i; --i) { for (int i = lights.getNumLights() - 1; 0 <= i; --i) {
EffectGeode* egeode = new EffectGeode; EffectGeode* egeode = new EffectGeode;
egeode->setEffect(effect); egeode->setEffect(effect);
@ -505,8 +505,8 @@ SGLightFactory::getOdal(const SGLightBin& lights)
float flashTime = 2e-2 + 5e-3*sg_random(); float flashTime = 2e-2 + 5e-3*sg_random();
osg::Sequence* sequence = new osg::Sequence; osg::Sequence* sequence = new osg::Sequence;
sequence->setDefaultTime(flashTime); sequence->setDefaultTime(flashTime);
Effect* effect = getLightEffect(10.0f, osg::Vec3(1.0, 0.0001, 0.00000001), Effect* effect = getLightEffect(40.0f, osg::Vec3(1.0, 0.0001, 0.00000001),
6.0, 10.0, false); 10.0, 40.0, false);
// centerline lights // centerline lights
for (int i = lights.getNumLights() - 1; 2 <= i; --i) { for (int i = lights.getNumLights() - 1; 2 <= i; --i) {
EffectGeode* egeode = new EffectGeode; EffectGeode* egeode = new EffectGeode;