Overture  Version 25
GUIInit.h
Go to the documentation of this file.
1 #ifndef GUI_INIT_H
2 #define GUI_INIT_H
3 
4 #include <string>
5 #include "kk_Array.hh"
6 
7 #define aString std::string
8 
9 
10 #ifndef NO_APP
11 
12 #include "OvertureTypes.h"
16 // class realMappedGridFunction;
17 #ifdef OV_USE_DOUBLE
18 #define realMappedGridFunction doubleMappedGridFunction
19 #define realGridCollectionFunction doubleGridCollectionFunction
20 #else
21 #define realMappedGridFunction floatMappedGridFunction
22 #define realGridCollectionFunction floatGridCollectionFunction
23 #endif
24 
28 
29 class MappingParameters;
31 class ListOfMappingRC;
32 #endif
33 
34 #include "GUITypes.h"
35 
36 class GraphicsParameters;
38 
39 class Overture
40 {
41  public:
42  static int start(int argc, char *argv[]);
43  static int finish();
44 
45  enum AbortEnum
46  {
49  };
50  static AbortEnum getAbortOption();
51  static void setAbortOption( AbortEnum action );
52  static void abort();
53  static void abort(const aString & message);
54 
55 #ifndef NO_APP
56  static floatSerialArray & nullFloatArray();
57  static doubleSerialArray & nullDoubleArray();
58  static intSerialArray & nullIntArray();
59 #else
60  static KK::Array<float> & nullFloatArray();
61  static KK::Array<double> & nullDoubleArray();
62  static KK::Array<int> & nullIntArray();
63 #endif
64  static RealArray & nullRealArray();
65 
66 #ifndef NO_APP
71 
73 
78 
83 
85 #endif
86 
89 
91  getGraphicsInterface(const aString & windowTitle="Your Slogan Here", const bool initialize=true,
92  int argc=0, char *argv[]=NULL);
93  static void
95 
96 #ifndef NO_APP
98  static void setMappingList(ListOfMappingRC *list);
99 #endif
100 
101  protected:
103 
104 #ifndef NO_APP
106 #endif
107 
109 
110  private:
111 
112 #ifndef NO_APP
113  static floatSerialArray *pNullFloatArray;
114  static doubleSerialArray *pNullDoubleArray;
115  static intSerialArray *pNullIntArray;
116 #else
117  static KK::Array<float> *pNullFloatArray;
118  static KK::Array<double> *pNullDoubleArray;
119  static KK::Array<int> *pNullIntArray;
120 #endif
121  static RealArray *pNullRealArray;
122 
123 #ifndef NO_APP
124  static floatDistributedArray *pNullFloatDistributedArray;
125  static doubleDistributedArray *pNullDoubleDistributedArray;
126  static RealDistributedArray *pNullRealDistributedArray;
127  static IntegerDistributedArray *pNullIntegerDistributedArray;
128 
129 #endif
130 
131 #ifndef NO_APP
132  static MappingParameters *pNullMappingParameters;
133 #endif
134 
135 #ifndef NO_APP
136  static floatMappedGridFunction *pNullFloatMappedGridFunction;
137  static doubleMappedGridFunction *pNullDoubleMappedGridFunction;
138  static intMappedGridFunction *pNullIntMappedGridFunction;
139  static realMappedGridFunction *pNullRealMappedGridFunction;
140 
141  static floatGridCollectionFunction *pNullFloatGridCollectionFunction;
142  static doubleGridCollectionFunction *pNullDoubleGridCollectionFunction;
143  static intGridCollectionFunction *pNullIntGridCollectionFunction;
144  static realGridCollectionFunction *pNullRealGridCollectionFunction;
145 
146  static BoundaryConditionParameters *pDefaultBoundaryConditionParameters;
147 #endif
148 
149  static GraphicsParameters *pDefaultGraphicsParameters; // used for default arguments
150  static GraphicsParameters *pCurrentGraphicsParameters;
151 
152 };
153 
154 #ifndef NO_APP
155 #undef realMappedGridFunction
156 #undef realGridCollectionFunction
157 #endif
158 
159 
160 #endif