]> git.mxchange.org Git - simgear.git/blob - simgear/scene/sky/clouds3d/SkySceneLoader.hpp
Clouds3D crashes because there is no Light
[simgear.git] / simgear / scene / sky / clouds3d / SkySceneLoader.hpp
1 //------------------------------------------------------------------------------
2 // File : SkySceneLoader.hpp
3 //------------------------------------------------------------------------------
4 // SkyWorks : Copyright 2002 Mark J. Harris and
5 //                                              The University of North Carolina at Chapel Hill
6 //------------------------------------------------------------------------------
7 // Permission to use, copy, modify, distribute and sell this software and its 
8 // documentation for any purpose is hereby granted without fee, provided that 
9 // the above copyright notice appear in all copies and that both that copyright 
10 // notice and this permission notice appear in supporting documentation. 
11 // Binaries may be compiled with this software without any royalties or 
12 // restrictions. 
13 //
14 // The author(s) and The University of North Carolina at Chapel Hill make no 
15 // representations about the suitability of this software for any purpose. 
16 // It is provided "as is" without express or 
17 // implied warranty.
18 /**
19  * @file SkySceneLoader.hpp
20  * 
21  * Definition of a simple class for loading scenes into SkyWorks.
22  */
23 #ifndef __SKYSCENELOADER_HPP__
24 #define __SKYSCENELOADER_HPP__
25
26 #ifdef HAVE_CONFIG
27 #  include <config.h>
28 #endif
29
30 #include <simgear/compiler.h>
31 #include <simgear/misc/sg_path.hxx>
32 #include <simgear/math/point3d.hxx>
33
34 #include "SkyUtil.hpp"
35
36
37 //------------------------------------------------------------------------------
38 /**
39  * @class SkySceneLoader
40  * @brief A simple scene loader for SkyWorks scenes.
41  * 
42  * Loads a scene using the Load() method, which is passed the filename of a 
43  * file containing a SkyArchive describing the scene. 
44  */
45 class SkySceneLoader
46 {
47 public:
48   SkySceneLoader();
49   ~SkySceneLoader();
50
51   bool Load( unsigned char *data, unsigned int size, double latitude, double longitude );
52   bool Load( SGPath fileroot, double latitude, double longitude );
53   
54   void Set_Cloud_Orig( Point3D *posit );
55   
56   void Update( double *view_pos );
57   
58   void Resize( double w, double h);
59   
60   void Draw( sgMat4 mat );
61   
62 };
63
64 #endif //__SKYSCENELOADER_HPP__