#include <simgear/props/props.hxx>
#include <simgear/scene/model/modellib.hxx>
#include <simgear/scene/util/SGNodeMasks.hxx>
+#include <simgear/math/SGMath.hxx>
#include "panelnode.hxx"
-
#include "model_panel.hxx"
-SG_USING_STD(vector);
+using std::vector;
using namespace simgear;
fgLoad3DModelPanel(const string &path, SGPropertyNode *prop_root)
{
osg::Node* node = SGModelLib::loadModel(path, prop_root, load_panel);
- node->setNodeMask(~SG_NODEMASK_TERRAIN_BIT);
+ if (node)
+ node->setNodeMask(~SG_NODEMASK_TERRAIN_BIT);
return node;
}