]> git.mxchange.org Git - flightgear.git/blobdiff - utils/fgviewer/fgviewer.cxx
commradio: improvements for atis speech
[flightgear.git] / utils / fgviewer / fgviewer.cxx
index f8cbdaccc1c3ed705e92e4272e2efdf47a201a22..e0ebcf250539cb0a2eb32d0b0d01c8ed5ffdd4c3 100644 (file)
@@ -179,7 +179,7 @@ main(int argc, char** argv)
     // FIXME Ok, replace this by querying the root of the property tree
     sgUserDataInit(props.get());
     SGSceneFeatures::instance()->setTextureCompression(SGSceneFeatures::DoNotUseCompression);
-    SGMaterialLib* ml = new SGMaterialLib;
+    SGMaterialLibPtr ml = new SGMaterialLib;
     SGPath mpath(fg_root);
     mpath.append("Materials/default/materials.xml");
     try {
@@ -188,6 +188,7 @@ main(int argc, char** argv)
         SG_LOG(SG_GENERAL, SG_ALERT, "Problems loading FlightGear materials.\n"
                << "Probably FG_ROOT is not properly set.");
     }
+    ml->refreshActiveMaterials();
     simgear::SGModelLib::init(fg_root, props);
 
     // Set up the reader/writer options