]> git.mxchange.org Git - simgear.git/blob - simgear/scene/tgdb/userdata.hxx
Merge branch 'jmt/ref_ptr-conv'
[simgear.git] / simgear / scene / tgdb / userdata.hxx
1 // userdata.hxx -- two classes for populating ssg user data slots in association
2 //                 with our implimenation of random surface objects.
3 //
4 // Written by David Megginson, started December 2001.
5 //
6 // Copyright (C) 2001 - 2003  Curtis L. Olson  - http://www.flightgear.org/~curt
7 //
8 // This program is free software; you can redistribute it and/or
9 // modify it under the terms of the GNU General Public License as
10 // published by the Free Software Foundation; either version 2 of the
11 // License, or (at your option) any later version.
12 //
13 // This program is distributed in the hope that it will be useful, but
14 // WITHOUT ANY WARRANTY; without even the implied warranty of
15 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
16 // General Public License for more details.
17 //
18 // You should have received a copy of the GNU General Public License
19 // along with this program; if not, write to the Free Software
20 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
21 //
22 // $Id$
23
24
25 #ifndef _SG_USERDATA_HXX
26 #define _SG_USERDATA_HXX
27
28 #include <simgear/compiler.h>
29 #include <simgear/math/sg_random.h>
30
31 #include <osg/Node>
32
33 class SGMatModel;
34 class SGPropertyNode;
35
36 /**
37  * the application must call sgUserDataInit() and specify the
38  * following values (needed by the model loader callback at draw time)
39  * before drawing any scenery.
40  */
41 void sgUserDataInit(SGPropertyNode *p);
42
43 /**
44  * Get a random model.
45  */
46 osg::Node* sgGetRandomModel(SGMatModel *obj, mt seed);
47
48 namespace simgear
49 {
50 /**
51  * Get the property root for the simulation
52  */
53 SGPropertyNode* getPropertyRoot();
54 }
55
56 #endif // _SG_USERDATA_HXX