]> git.mxchange.org Git - simgear.git/commitdiff
two warning fixes
authorTorsten Dreyer <Torsten@t3r.de>
Thu, 12 Aug 2010 09:42:04 +0000 (11:42 +0200)
committerTorsten Dreyer <Torsten@t3r.de>
Thu, 12 Aug 2010 09:42:04 +0000 (11:42 +0200)
simgear/scene/util/StateAttributeFactory.cxx
simgear/structure/SGSharedPtr.hxx

index 76124da06b1b1e8df83ca8f024928d979f91ff38..25a0a57622860f841105ebd9985de3613682c220 100644 (file)
@@ -39,7 +39,7 @@ StateAttributeFactory::StateAttributeFactory()
 {
     _standardAlphaFunc = new AlphaFunc;
     _standardAlphaFunc->setFunction(osg::AlphaFunc::GREATER);
-    _standardAlphaFunc->setReferenceValue(0.01);
+    _standardAlphaFunc->setReferenceValue(0.01f);
     _standardAlphaFunc->setDataVariance(Object::STATIC);
     _smooth = new ShadeModel;
     _smooth->setMode(ShadeModel::SMOOTH);
index f321b12dc4a3e4578b14276d2e5f74dfded32b2c..98b72f22c902a37dfd43c07b2f8418a36687ebbe 100644 (file)
@@ -88,7 +88,7 @@ public:
   { return T::count(_ptr); }
 
   bool valid(void) const
-  { return _ptr; }
+  { return _ptr != NULL; }
 
   void clear()
   { put(); }