//
// Copyright (C) 2000 Curtis L. Olson - curt@flightgear.org
//
-// This program is free software; you can redistribute it and/or
-// modify it under the terms of the GNU General Public License as
-// published by the Free Software Foundation; either version 2 of the
-// License, or (at your option) any later version.
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Library General Public
+// License as published by the Free Software Foundation; either
+// version 2 of the License, or (at your option) any later version.
//
-// This program is distributed in the hope that it will be useful, but
-// WITHOUT ANY WARRANTY; without even the implied warranty of
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-// General Public License for more details.
+// Library General Public License for more details.
//
-// You should have received a copy of the GNU General Public License
-// along with this program; if not, write to the Free Software
-// Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+// You should have received a copy of the GNU Library General Public
+// License along with this library; if not, write to the
+// Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+// Boston, MA 02111-1307, USA.
//
// $Id$
#ifndef _SG_CLOUD_HXX_
#define _SG_CLOUD_HXX_
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
+#include <simgear/compiler.h>
#include <plib/ssg.h>
-#include <simgear/misc/fgpath.hxx>
+#include STL_STRING
+SG_USING_STD(string);
+
+
+#define SG_MAX_CLOUD_TYPES 4 // change this if we add/remove cloud
+ // types en the enum below
+
+enum SGCloudType {
+ SG_CLOUD_OVERCAST = 0,
+ SG_CLOUD_MOSTLY_CLOUDY,
+ SG_CLOUD_MOSTLY_SUNNY,
+ SG_CLOUD_CIRRUS
+};
class SGCloudLayer {
+private:
+
ssgRoot *layer_root;
ssgTransform *layer_transform;
ssgSimpleState *layer_state;
~SGCloudLayer( void );
// build the cloud object
- void build( FGPath path, double size, double asl, double thickness,
- double transition );
+ void build( double size, double asl, double thickness,
+ double transition, ssgSimpleState *state );
// repaint the cloud colors based on current value of sun_angle,
// sky, and fog colors. This updates the color arrays for
};
+// make an ssgSimpleState for a cloud layer given the named texture
+ssgSimpleState *SGCloudMakeState( const string &path );
+
+
#endif // _SG_CLOUD_HXX_