]> git.mxchange.org Git - flightgear.git/blob - src/Model/model_panel.hxx
- move exception handling from init() and childAdded() to add_model()
[flightgear.git] / src / Model / model_panel.hxx
1 // model.hxx - manage a 3D aircraft model.
2 // Written by David Megginson, started 2002.
3 //
4 // This file is in the Public Domain, and comes with no warranty.
5
6 #ifndef __MODEL_HXX
7 #define __MODEL_HXX 1
8
9 #ifndef __cplusplus
10 # error This library requires C++
11 #endif
12
13 #include <vector>
14
15 SG_USING_STD(vector);
16
17 #include <simgear/math/point3d.hxx>
18 #include <simgear/props/props.hxx>
19
20
21 // Don't pull in the headers, since we don't need them here.
22
23 class SGInterpTable;
24 class FGCondition;
25 class FGLocation;
26
27
28 // Has anyone done anything *really* stupid, like making min and max macros?
29 #ifdef min
30 #undef min
31 #endif
32 #ifdef max
33 #undef max
34 #endif
35
36
37 /**
38  * Load a 3D model with or without XML wrapper.  This version supports
39  * also loading the instrument panel and is wired in with dependencies
40  * on panelnode.hxx, and thus files in src/Cockpit and also GUI/mouse
41  * input code to support the 3d clickable hotspots.
42  *
43  * If the path ends in ".xml", then it will be used as a property-
44  * list wrapper to add animations to the model.
45  *
46  * Subsystems should not normally invoke this function directly;
47  * instead, they should use the SGModelLoader declared in loader.hxx.
48  */
49 osg::Node *fgLoad3DModelPanel( const string& fg_root, const string &path,
50                                SGPropertyNode *prop_root,
51                                double sim_time_sec, const SGPath& livery );
52
53
54 #endif // __MODEL_HXX