Debian Codegraph @

yorick/ygyoto.h

raw symbols SCIP
1 /*
2 Copyright 2011-2015 Thibaut Paumard
3
4 This file is part of Gyoto.
5
6 Gyoto is free software: you can redistribute it and/or modify
7 it under the terms of the GNU General Public License as published by
8 the Free Software Foundation, either version 3 of the License, or
9 (at your option) any later version.
10
11 Gyoto is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 GNU General Public License for more details.
15
16 You should have received a copy of the GNU General Public License
17 along with Gyoto. If not, see <http://www.gnu.org/licenses/>.
18 */
19
20 #ifndef __YGYOTO_H
21 #define __YGYOTO_Hcxx . . $ `yorick/ygyoto.h:21:9`!
22
23 #include "GyotoConfig.h"cxx . . $ `<file>/include/GyotoConfig.h`/
24 #include "GyotoMetric.h"cxx . . $ `<file>/include/GyotoMetric.h`/
25 #include "GyotoAstrobj.h"cxx . . $ `<file>/include/GyotoAstrobj.h`/
26 #include "GyotoThinDisk.h"cxx . . $ `<file>/include/GyotoThinDisk.h`/
27 #include "GyotoSpectrum.h"cxx . . $ `<file>/include/GyotoSpectrum.h`/
28 #include "GyotoScreen.h"cxx . . $ `<file>/include/GyotoScreen.h`/
29 #include "GyotoPhoton.h"cxx . . $ `<file>/include/GyotoPhoton.h`/
30 #include "GyotoScenery.h"cxx . . $ `<file>/include/GyotoScenery.h`/
31 #include "GyotoScreen.h"cxx . . $ `<file>/include/GyotoScreen.h`/
32
33 #include <cstring>
34 #include <sstream>
35
36 #define YGYOTO_TYPE_LENcxx . . $ `yorick/ygyoto.h:36:9`! 21
37 #define YGYOTO_STD_CATCHcxx . . $ `yorick/ygyoto.h:37:9`! catch(Gyoto::Error e) \
38 { y_error(e.get_message().c_str()); }
39 #define YGYOTO_MAX_REGISTEREDcxx . . $ `yorick/ygyoto.h:39:9`! 20
40
41 typedef void
42 ygyoto_Metric_eval_worker_tcxx . . $ ygyoto_Metric_eval_worker_t#(Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Metriccxx . . $ Gyoto/Metric/::Genericcxx . . $ Gyoto/Metric/Generic#>*, int);
43 typedef void
44 ygyoto_Astrobj_eval_worker_tcxx . . $ ygyoto_Astrobj_eval_worker_t#(Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Astrobjcxx . . $ Gyoto/Astrobj/::Genericcxx . . $ Gyoto/Astrobj/Generic#>*, int);
45 typedef void
46 ygyoto_Spectrum_eval_worker_tcxx . . $ ygyoto_Spectrum_eval_worker_t#(Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Spectrumcxx . . $ Gyoto/Spectrum/::Genericcxx . . $ Gyoto/Spectrum/Generic#>*,\
47 int);
48 typedef void
49 ygyoto_Spectrometer_eval_worker_tcxx . . $ ygyoto_Spectrometer_eval_worker_t#(Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Spectrometercxx . . $ Gyoto/Spectrometer/::Genericcxx . . $ Gyoto/Spectrometer/Generic#>*, int);
50
51 #ifndef YGYOTO_LOCAL_SUPPLIERcxx . . $ `<built-in>:483:9`!
52 /*
53 To push or get a Gyoto Object or to check if iarg is a Gyoto object
54 of a given type, use the following wrappers around the YAPI
55 functions ypush_obj() and yget_obj(). yarg_OBJTYPE return 1 if iarg
56 is an object of that type.
57 */
58 Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Metriccxx . . $ Gyoto/Metric/::Genericcxx . . $ Gyoto/Metric/Generic#> *yget_Metriccxx . . $ yget_Metric(e5690a8f47731463).(int iarg);
59 Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Metriccxx . . $ Gyoto/Metric/::Genericcxx . . $ Gyoto/Metric/Generic#> *ypush_Metriccxx . . $ ypush_Metric(1dfd13db9a5569df).();
60 int yarg_Metriccxx . . $ yarg_Metric(7864480464b09eea).(int iarg);
61 Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Astrobjcxx . . $ Gyoto/Astrobj/::Genericcxx . . $ Gyoto/Astrobj/Generic#>* yget_Astrobjcxx . . $ yget_Astrobj(d2be61062be173).(int iarg);
62 Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Astrobjcxx . . $ Gyoto/Astrobj/::Genericcxx . . $ Gyoto/Astrobj/Generic#>* ypush_Astrobjcxx . . $ ypush_Astrobj(c13d5eff93d584c6).();
63 int yarg_Astrobjcxx . . $ yarg_Astrobj(7864480464b09eea).(int iarg);
64 Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Screencxx . . $ Gyoto/Screen#>* yget_Screencxx . . $ yget_Screen(9ed86900cf73e562).(int iarg);
65 Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Screencxx . . $ Gyoto/Screen#>* ypush_Screencxx . . $ ypush_Screen(6e5ad460b2e29fc9).();
66 int yarg_Screencxx . . $ yarg_Screen(7864480464b09eea).(int iarg);
67 Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Photoncxx . . $ Gyoto/Photon#>* yget_Photoncxx . . $ yget_Photon(702f0940269bd1d).(int iarg);
68 Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Photoncxx . . $ Gyoto/Photon#>* ypush_Photoncxx . . $ ypush_Photon(7eead4ac53495a82).();
69 int yarg_Photoncxx . . $ yarg_Photon(7864480464b09eea).(int iarg) ;
70 Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Scenerycxx . . $ Gyoto/Scenery#>* yget_Scenerycxx . . $ yget_Scenery(c16583ded4f0f347).(int iarg);
71 Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Scenerycxx . . $ Gyoto/Scenery#>* ypush_Scenerycxx . . $ ypush_Scenery(7bab1e0dd488a68e).();
72 int yarg_Scenerycxx . . $ yarg_Scenery(7864480464b09eea).(int iarg);
73 Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Screencxx . . $ Gyoto/Screen#>* yget_Screencxx . . $ yget_Screen(9ed86900cf73e562).(int iarg);
74 Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Screencxx . . $ Gyoto/Screen#>* ypush_Screencxx . . $ ypush_Screen(6e5ad460b2e29fc9).();
75 int yarg_Screencxx . . $ yarg_Screen(7864480464b09eea).(int iarg);
76 Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Spectrumcxx . . $ Gyoto/Spectrum/::Genericcxx . . $ Gyoto/Spectrum/Generic#>* yget_Spectrumcxx . . $ yget_Spectrum(1e4bdddec7725367).(int iarg);
77 Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Spectrumcxx . . $ Gyoto/Spectrum/::Genericcxx . . $ Gyoto/Spectrum/Generic#>* ypush_Spectrumcxx . . $ ypush_Spectrum(5e470b652426fafa).();
78 int yarg_Spectrumcxx . . $ yarg_Spectrum(7864480464b09eea).(int iarg);
79 Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Spectrometercxx . . $ Gyoto/Spectrometer/::Genericcxx . . $ Gyoto/Spectrometer/Generic#>* yget_Spectrometercxx . . $ yget_Spectrometer(eccbd62bd980ad3).(int iarg);
80 Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Spectrometercxx . . $ Gyoto/Spectrometer/::Genericcxx . . $ Gyoto/Spectrometer/Generic#>* ypush_Spectrometercxx . . $ ypush_Spectrometer(46525728b1b93369).();
81 int yarg_Spectrometercxx . . $ yarg_Spectrometer(7864480464b09eea).(int iarg);
82 void ypush_propertycxx . . $ ypush_property(5ae4f9c57baf463d).(Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::SmartPointeecxx . . $ Gyoto/SmartPointee#>,
83 Gyotocxx . . $ Gyoto/::Propertycxx . . $ Gyoto/Property# const&, stdcxx . . $ std/::stringcxx . . $ std/string#, stdcxx . . $ std/::stringcxx . . $ std/string#);
84 void yget_propertycxx . . $ yget_property(fed7bdf14b1732e8).(Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::SmartPointeecxx . . $ Gyoto/SmartPointee#>,
85 Gyotocxx . . $ Gyoto/::Propertycxx . . $ Gyoto/Property# const&, int, stdcxx . . $ std/::stringcxx . . $ std/string#, stdcxx . . $ std/::stringcxx . . $ std/string#);
86
87 /*
88 You can register your own on_eval worker. It will be called when a
89 Metric object GG_OBJ of your specific kind is called as
90 gg_obj(arguments). (Resp. Astrobj.) In your own routins, you can
91 also call the generic eval (and you certainly should, it's the one
92 that processes the generic keywords below). The generic Metric on
93 eval must be called at the end of your specific on eval because it
94 will try to return the metric coefficients if no other outpur value
95 has been pushed.
96 */
97 void ygyoto_Metric_registercxx . . $ ygyoto_Metric_register(58f3e85fe3544e93).(char const * const kind, ygyoto_Metric_eval_worker_tcxx . . $ ygyoto_Metric_eval_worker_t#* on_eval);
98 void ygyoto_Metric_generic_evalcxx . . $ ygyoto_Metric_generic_eval(3a49bfe9aeadf44).(Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Metriccxx . . $ Gyoto/Metric/::Genericcxx . . $ Gyoto/Metric/Generic#>*,
99 int *kiargs, int *piargs, int *rvset,
100 int *paUsed, char * unit);
101
102
103 void ygyoto_Astrobj_registercxx . . $ ygyoto_Astrobj_register(e36727a6f8dbcb89).(char const * const kind, ygyoto_Astrobj_eval_worker_tcxx . . $ ygyoto_Astrobj_eval_worker_t#* on_eval);
104 void ygyoto_Astrobj_generic_evalcxx . . $ ygyoto_Astrobj_generic_eval(45f3a75624ffceb5).(Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Astrobjcxx . . $ Gyoto/Astrobj/::Genericcxx . . $ Gyoto/Astrobj/Generic#>*,
105 int *kiargs, int *piargs, int *rvset,
106 int *paUsed, char * unit);
107 void ygyoto_ThinDisk_generic_evalcxx . . $ ygyoto_ThinDisk_generic_eval(45f3a75624ffceb5).(Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Astrobjcxx . . $ Gyoto/Astrobj/::Genericcxx . . $ Gyoto/Astrobj/Generic#>*,
108 int *kiargs, int *piargs, int *rvset,
109 int *paUsed, char * unit);
110
111
112 void ygyoto_Spectrum_registercxx . . $ ygyoto_Spectrum_register(f8a2046c80a52872).(char const * const kind,
113 ygyoto_Spectrum_eval_worker_tcxx . . $ ygyoto_Spectrum_eval_worker_t#*on_eval);
114 void ygyoto_Spectrum_generic_evalcxx . . $ ygyoto_Spectrum_generic_eval(6d26c281c2ac10e6).
115 (Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Spectrumcxx . . $ Gyoto/Spectrum/::Genericcxx . . $ Gyoto/Spectrum/Generic#> *,
116 int *kiargs, int *piargs, int *rvset, int *paUsed, char *unit);
117
118 void ygyoto_Spectrometer_registercxx . . $ ygyoto_Spectrometer_register(6037abe983da89c1).(char const * const kind,
119 ygyoto_Spectrometer_eval_worker_tcxx . . $ ygyoto_Spectrometer_eval_worker_t#*on_eval);
120 void ygyoto_Spectrometer_generic_evalcxx . . $ ygyoto_Spectrometer_generic_eval(78db89b517826fb).
121 (Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Spectrometercxx . . $ Gyoto/Spectrometer/::Genericcxx . . $ Gyoto/Spectrometer/Generic#> *,
122 int *kiargs, int *piargs, int *rvset, int *paUsed, char * unit);
123
124
125 #endif
126
127 /*
128 The generic on_eval will process these keywords. You need to have
129 initiated the kiargs table. You should call the generic on_eval
130 after processing your SET keywords and before processing your GET
131 keywords. rvset and paUsed are input _and_ output. *rvset == 1 if a
132 return value (ypush_*) is already defined, *rvset == 0 if
133 not. Likewise, *paUsed means that (at least) one positional argument
134 has already been used. Attempting to set the return value twice or
135 to use a positional argument twice is to be considered an error
136 condition.
137 */
138 // Keywords processed by ygyoto_Metric_generic_eval
139 #define YGYOTO_METRIC_GENERIC_KWcxx . . $ `yorick/ygyoto.h:139:9`! "prime2tdot", \
140 "nullifycoord", "kind", "coordkind", "setparameter", "scalarprod", \
141 "mass", "deltamin", "deltamax", "keplerian", \
142 "unitlength", "circularvelocity", \
143 "christoffel", "xmlwrite", "clone", "help"
144 // Number of those keywords
145 #define YGYOTO_METRIC_GENERIC_KW_Ncxx . . $ `yorick/ygyoto.h:145:9`! 16
146
147 // Keywords processed by ygyoto_Astrobj_generic_eval
148 #define YGYOTO_ASTROBJ_GENERIC_KWcxx . . $ `yorick/ygyoto.h:148:9`! "metric", "rmax", "opticallythin", \
149 "xmlwrite", "kind", "setparameter", "clone", "help"
150 // number of those keywords
151 #define YGYOTO_ASTROBJ_GENERIC_KW_Ncxx . . $ `yorick/ygyoto.h:151:9`! 8
152
153 // Keywords processed by ygyoto_ThinDisk_generic_eval
154 #define YGYOTO_THINDISK_GENERIC_KWcxx . . $ `yorick/ygyoto.h:154:9`! \
155 "innerradius", "outerradius", "thickness", "dir", \
156 YGYOTO_ASTROBJ_GENERIC_KWcxx . . $ `yorick/ygyoto.h:148:9`!
157 // number of those keywords
158 #define YGYOTO_THINDISK_GENERIC_KW_Ncxx . . $ `yorick/ygyoto.h:158:9`! 4+YGYOTO_ASTROBJ_GENERIC_KW_Ncxx . . $ `yorick/ygyoto.h:151:9`!
159
160 // maximum number of keywords accepted by a base Astrobj class
161 #define YGYOTO_ASTROBJ_BASE_MAX_KW_Ncxx . . $ `yorick/ygyoto.h:161:9`! YGYOTO_THINDISK_GENERIC_KW_N
162
163 // Keywords processed by ygyoto_Spectrum_generic_eval
164 #define YGYOTO_SPECTRUM_GENERIC_KWcxx . . $ `yorick/ygyoto.h:164:9`! \
165 "xmlwrite", "kind", "setparameter", "clone", "help", "integrate"
166 // number of those keywords
167 #define YGYOTO_SPECTRUM_GENERIC_KW_Ncxx . . $ `yorick/ygyoto.h:167:9`! 6
168
169 // Keywords processed by ygyoto_Spectrometer_generic_eval
170 #define YGYOTO_SPECTROMETER_GENERIC_KWcxx . . $ `yorick/ygyoto.h:170:9`! \
171 "kind", "xmlwrite", "clone", "help", "nsamples", \
172 "setparameter", "channels", "midpoints", "widths"
173 // number of those keywords
174 #define YGYOTO_SPECTROMETER_GENERIC_KW_Ncxx . . $ `yorick/ygyoto.h:174:9`! 9
175
176 /*
177
178 The following are neat for writing workers. The worker needs to
179 abide by my unwritten coding style. Assume MyKind is a subclass of
180 MyBase. MyBase is one of Metric, Astrobj, Spectrum, Spectrometer.
181
182 void ygyoto_MyKind_eval(SmartPointer<Astrobj::Generic>* OBJ_, int argc) {
183 // Define keywords
184 static char const * knames[]={
185 "unit",
186 "keyword1", "keyword2", ..., "keywordN",
187 YGYOTO_MYBASE_GENERIC_KW,
188 0
189 };
190
191 // Parse arguments
192 YGYOTO_WORKER_INIT(MyBase, MyKind, knames, YGYOTO_MYBASE_GENERIC_KW_N+N+1);
193
194 // Read unit keyword
195 YGYOTO_WORKER_SET_UNIT;
196
197 // process individual keywords
198 YGYOTO_WORKER_GETSET_DOUBLE_UNIT(Keyword1);
199 ...
200 YGYOTO_WORKER_GETSET...(KeywordN);
201
202 // Call generic worker
203 YGYOTO_WORKER_CALL_GENERIC(MyBase);
204 }
205 */
206
207 #define YGYOTO_STR1cxx . . $ `yorick/ygyoto.h:207:9`!(X) #X
208 #define YGYOTO_STRcxx . . $ `yorick/ygyoto.h:208:9`!(X) YGYOTO_STR1(X)
209 #define YGYOTO_CAT1cxx . . $ `yorick/ygyoto.h:209:9`!(X, Y) X##Y
210 #define YGYOTO_CATcxx . . $ `yorick/ygyoto.h:210:9`!(X, Y) YGYOTO_CAT1cxx . . $ `yorick/ygyoto.h:209:9`!(X,Y)
211
212 #ifdef GYOTO_USE_XERCEScxx . . $ `include/GyotoConfig.h:161:9`!
213 # define YGYOTO_CONSTRUCTOR_INIT2_XMLcxx . . $ `yorick/ygyoto.h:213:10`!(BASENAME, GETTER) \
214 char * fname = ygets_q(argc-1); \
215 OBJcxx . . $ `yorick/gyoto_Photon.C:28:9`! = ypush_##BASENAME(); \
216 GYOTO_DEBUG_EXPRcxx . . $ `include/GyotoDefs.h:280:9`!(OBJcxx . . $ `yorick/gyoto_SpectroUniform.C:94:9`!); \
217 * OBJcxx . . $ `yorick/gyoto_SpectroUniform.C:94:9`! = Gyoto::Factory(fname).GETTER(); \
218 GYOTO_DEBUGcxx . . $ `include/GyotoDefs.h:341:9`! << "Swapping object for filename\n"; \
219 yarg_swap(0, argc); \
220 GYOTO_DEBUGcxx . . $ `include/GyotoDefs.h:341:9`! << "Dropping filename from stack\n"; \
221 yarg_drop(1); \
222 GYOTO_DEBUGcxx . . $ `include/GyotoDefs.h:341:9`! << "Dropped filename from stack\n"; \
223 --argc;
224 #else
225 # define YGYOTO_CONSTRUCTOR_INIT2_XML(BASENAME, GETTER) \
226 y_error("this gyoto was built without XML support");
227 #endif
228
229
230 #define YGYOTO_CONSTRUCTOR_INIT2cxx . . $ `yorick/ygyoto.h:230:9`!(BASENAME, BASECLASS, DERIVEDCLASS, GETTER)\
231 Gyoto::SmartPointer<BASECLASS> *OBJcxx . . $ `yorick/gyoto_Photon.C:28:9`! = NULLcxx . . $ `/usr/lib/gcc/x86_64-linux-gnu/15/include/stddef.h:416:9`!; \
232 if (yarg_##BASENAME(argc-1)) { \
233 OBJcxx . . $ `yorick/gyoto_SpectroUniform.C:94:9`! = yget_##BASENAME(--argc); \
234 GYOTO_DEBUG_EXPRcxx . . $ `include/GyotoDefs.h:280:9`!(OBJcxx . . $ `yorick/gyoto_SpectroUniform.C:94:9`!); \
235 } else if (yarg_string(argc-1)) { \
236 YGYOTO_CONSTRUCTOR_INIT2_XMLcxx . . $ `yorick/ygyoto.h:213:10`!(BASENAME, GETTER); \
237 } else { \
238 OBJcxx . . $ `yorick/gyoto_Photon.C:28:9`! = ypush_##BASENAME(); \
239 GYOTO_DEBUG_EXPRcxx . . $ `include/GyotoDefs.h:280:9`!(OBJcxx . . $ `yorick/gyoto_Photon.C:28:9`!); \
240 *OBJcxx . . $ `yorick/gyoto_SpectroUniform.C:94:9`! = new DERIVEDCLASS(); \
241 GYOTO_DEBUGcxx . . $ `include/GyotoDefs.h:341:9`! << "object created" << endl; \
242 for (int arg=0; arg<argc; ++arg) \
243 yarg_swap(arg, arg+1); \
244 } \
245 if (argc==1 && yarg_nil(0)) { \
246 yarg_drop(1); \
247 --argc; \
248 }
249 #define YGYOTO_CONSTRUCTOR_INIT1cxx . . $ `yorick/ygyoto.h:249:9`!(BASENAME, BASECLASS, DERIVEDCLASS) \
250 YGYOTO_CONSTRUCTOR_INIT2(BASENAME, BASECLASS, DERIVEDCLASS, get##BASENAME)
251 #define YGYOTO_CONSTRUCTOR_INITcxx . . $ `yorick/ygyoto.h:251:9`!(BASE, KIND) \
252 YGYOTO_CONSTRUCTOR_INIT1(BASE, Gyoto::BASE::Generic, Gyoto::BASE::KIND)
253
254 #define YGYOTO_WORKER_INITcxx . . $ `yorick/ygyoto.h:254:9`!(BASE, KIND, KNAMES, NKW) \
255 YGYOTO_WORKER_INIT1cxx . . $ `yorick/ygyoto.h:256:9`!(BASE, Gyoto::BASE::KIND, KNAMES, NKW)
256 #define YGYOTO_WORKER_INIT1cxx . . $ `yorick/ygyoto.h:256:9`!(BASE, CLASS, KNAMES, NKW) \
257 int rvset[1]={0}, paUsed[1]={0}; \
258 *ypush_##BASE()=*YGYOTO_CATcxx . . $ `yorick/ygyoto.h:210:9`!(OBJcxx . . $ `yorick/gyoto_Photon.C:28:9`!, _); \
259 { \
260 long kidx; \
261 Gyoto::Property const * prop; \
262 std::string pname="", unit=""; \
263 bool unit_found, prop_pushed=false; \
264 ++argc; \
265 while ( ( argc > 0 ) && \
266 ( (kidx=yarg_key(argc-1)) >=0 ) && \
267 ( (prop=(*YGYOTO_CATcxx . . $ `yorick/ygyoto.h:210:9`!(OBJcxx . . $ `yorick/gyoto_SpectroUniform.C:32:9`!, _)) \
268 ->property(pname=yfind_name(kidx)))) ) { \
269 if ( (kidx=yarg_key(argc-3)) >=0 && \
270 !strcmp(yfind_name(kidx),"unit") ) { \
271 unit=ygets_q(argc-4); \
272 unit_found=true; \
273 } else { \
274 unit_found=false; \
275 unit=""; \
276 } \
277 if (yarg_nil(argc-2)) { \
278 if (prop_pushed) y_error("Can push only one return value"); \
279 prop_pushed=true; \
280 yarg_drop(1); \
281 ypush_propertycxx . . $ `yorick/ygyoto.h:609:9`!(*YGYOTO_CATcxx . . $ `yorick/ygyoto.h:210:9`!(OBJcxx . . $ `yorick/stdplug/gyoto_Disk3D.C:33:9`!, _), *prop, pname, unit); \
282 } \
283 else yget_propertycxx . . $ `yorick/ygyoto.h:607:9`!(*YGYOTO_CATcxx . . $ `yorick/ygyoto.h:210:9`!(OBJcxx . . $ `yorick/gyoto_Photon.C:28:9`!, _), *prop, argc-2, pname, unit); \
284 argc -= unit_found?4:2; \
285 } \
286 if (prop_pushed) ++*rvset; \
287 --argc; \
288 } \
289 Gyoto::SmartPointer<CLASS> *OBJcxx . . $ `yorick/gyoto_SpectroUniform.C:32:9`! = \
290 (Gyoto::SmartPointer<CLASS> *)YGYOTO_CATcxx . . $ `yorick/ygyoto.h:210:9`!(OBJcxx . . $ `yorick/stdplug/gyoto_Disk3D.C:33:9`!, _); \
291 static long kglobs[NKW+1]; \
292 int kiargs[NKW]; \
293 int piargs[]={-1,-1,-1,-1,-1}; \
294 yarg_kw_init(const_cast<char**>(KNAMES), kglobs, kiargs); \
295 int iarg=argc, parg=0; \
296 while (iarg>=1) { \
297 iarg = yarg_kw(iarg, kglobs, kiargs); \
298 if (iarg>=1) { \
299 if (parg<5) piargs[parg++]=iarg--; \
300 else y_error( #CLASS " worker takes at most 5 positional arguments"); \
301 } \
302 } \
303 GYOTO_DEBUG_ARRAYcxx . . $ `include/GyotoDefs.h:313:9`!(piargs, 5); \
304 GYOTO_DEBUG_ARRAYcxx . . $ `include/GyotoDefs.h:313:9`!(kiargs, NKW); \
305 int k=-1; \
306 char const * rmsg="Cannot set return value more than once"; \
307 char const * pmsg="Cannot use positional argument more than once"; \
308 char * unit=NULLcxx . . $ `/usr/lib/gcc/x86_64-linux-gnu/15/include/stddef.h:416:9`!; \
309 /* make sure we use the variables at least once */ \
310 if (OBJcxx . . $ `yorick/gyoto_SpectroUniform.C:32:9`! && rmsg && pmsg && unit && k && *paUsed) {}
311
312
313 #define YGYOTO_WORKER_GETSET_VECTORcxx . . $ `yorick/ygyoto.h:313:9`!(MEMBER, N) \
314 if ((iarg=kiargs[++k])>=0) { \
315 iarg+=*rvset; \
316 if (yarg_nil(iarg)) { \
317 if ((*rvset)++) y_error(rmsg); \
318 long dims[] = {1,N}; \
319 double * coord=ypush_d(dims); \
320 (*OBJ)-> get##MEMBER (coord); \
321 } else { \
322 long ntot; \
323 double * pos = ygeta_d(iarg, &ntot, NULL); \
324 if (ntot<N) y_error("POS must have at least " #N " elements"); \
325 (*OBJ) -> set##MEMBER (pos); \
326 } \
327 }
328
329 #define YGYOTO_WORKER_GETSET4cxx . . $ `yorick/ygyoto.h:329:9`!(MEMBER) \
330 YGYOTO_WORKER_GETSET_VECTOR(MEMBER, 4)
331
332 #define YGYOTO_WORKER_GETSET_DOUBLE_UNITcxx . . $ `yorick/ygyoto.h:332:9`!(MEMBER) \
333 if ((iarg=kiargs[++k])>=0) { \
334 iarg+=*rvset; \
335 if (yarg_nil(iarg)) { \
336 if ((*rvset)++) y_error("Only one return value possible"); \
337 ypush_double((*OBJ) -> get##MEMBER (unit?unit:"")); \
338 } else \
339 (*OBJ) -> set##MEMBER (ygets_d(iarg), unit?unit:""); \
340 }
341
342 #define YGYOTO_WORKER_GETSET_DOUBLE2_UNITcxx . . $ `yorick/ygyoto.h:342:9`!(MEMBER) \
343 if ((iarg=kiargs[++k])>=0) { \
344 iarg+=*rvset; \
345 if (yarg_nil(iarg)) { \
346 if ((*rvset)++) y_error("Only one return value possible"); \
347 ypush_double((*OBJcxx . . $ `yorick/gyoto_Photon.C:28:9`!) -> MEMBER (unit?unit:"")); \
348 } else \
349 (*OBJcxx . . $ `yorick/gyoto_Photon.C:28:9`!) -> MEMBER (ygets_d(iarg), unit?unit:""); \
350 }
351
352 #define YGYOTO_WORKER_GETSET_DOUBLEcxx . . $ `yorick/ygyoto.h:352:9`!(MEMBER) \
353 if ((iarg=kiargs[++k])>=0) { \
354 iarg+=*rvset; \
355 if (yarg_nil(iarg)) { \
356 if ((*rvset)++) y_error("Only one return value possible"); \
357 ypush_double((*OBJ) -> get##MEMBER ()); \
358 } else \
359 (*OBJ) -> set##MEMBER (ygets_d(iarg)); \
360 }
361
362 #define YGYOTO_WORKER_GET_DOUBLEcxx . . $ `yorick/ygyoto.h:362:9`!(MEMBER) \
363 if ((iarg=kiargs[++k])>=0) { \
364 iarg+=*rvset; \
365 if (yarg_nil(iarg)) { \
366 if ((*rvset)++) y_error("Only one return value possible"); \
367 ypush_double((*OBJ) -> MEMBER ()); \
368 } else \
369 y_error( #MEMBER " is read only"); \
370 }
371
372 #define YGYOTO_WORKER_GETSET_DOUBLE2cxx . . $ `yorick/ygyoto.h:372:9`!(MEMBER) \
373 if ((iarg=kiargs[++k])>=0) { \
374 iarg+=*rvset; \
375 if (yarg_nil(iarg)) { \
376 if ((*rvset)++) y_error("Only one return value possible"); \
377 ypush_double((*OBJcxx . . $ `yorick/stdplug/gyoto_Disk3D.C:33:9`!) -> MEMBER ()); \
378 } else \
379 (*OBJcxx . . $ `yorick/stdplug/gyoto_Disk3D.C:33:9`!) -> MEMBER (ygets_d(iarg)); \
380 }
381
382 #define YGYOTO_WORKER_GETSET_STRING2cxx . . $ `yorick/ygyoto.h:382:9`!(MEMBER) \
383 if ((iarg=kiargs[++k])>=0) { \
384 iarg+=*rvset; \
385 if (yarg_nil(iarg)) { \
386 if ((*rvset)++) y_error("Only one return value possible"); \
387 *ypush_q(0) = p_strcpy((*OBJcxx . . $ `yorick/gyoto_Photon.C:28:9`!) -> MEMBER () . c_str() ); \
388 } else \
389 (*OBJcxx . . $ `yorick/gyoto_Photon.C:28:9`!) -> MEMBER (std::string(ygets_q(iarg))); \
390 }
391
392 #define YGYOTO_WORKER_GETSET_LONGcxx . . $ `yorick/ygyoto.h:392:9`!(MEMBER) \
393 if ((iarg=kiargs[++k])>=0) { \
394 iarg+=*rvset; \
395 if (yarg_nil(iarg)) { \
396 if ((*rvset)++) y_error("Only one return value possible"); \
397 ypush_long((*OBJ) -> get##MEMBER ()); \
398 } else \
399 (*OBJ) -> set##MEMBER (ygets_l(iarg)); \
400 }
401
402 #define YGYOTO_WORKER_GETSET_LONG2cxx . . $ `yorick/ygyoto.h:402:9`!(MEMBER) \
403 if ((iarg=kiargs[++k])>=0) { \
404 iarg+=*rvset; \
405 if (yarg_nil(iarg)) { \
406 if ((*rvset)++) y_error("Only one return value possible"); \
407 ypush_long((*OBJcxx . . $ `yorick/gyoto_Photon.C:28:9`!) -> MEMBER ()); \
408 } else \
409 (*OBJcxx . . $ `yorick/gyoto_Photon.C:28:9`!) -> MEMBER (ygets_l(iarg)); \
410 }
411
412 #define YGYOTO_WORKER_GETSET_OBJECT0cxx . . $ `yorick/ygyoto.h:412:9`!(SETMEMBER,GETMEMBER,YMEMBER) \
413 if ((iarg=kiargs[++k])>=0) { \
414 iarg+=*rvset; \
415 if (yarg_nil(iarg)) { \
416 GYOTO_DEBUGcxx . . $ `include/GyotoDefs.h:341:9`! << "pushing " #YMEMBER << std::endl; \
417 if ((*rvset)++) y_error("Only one return value possible"); \
418 void * tmp = (*OBJcxx . . $ `yorick/gyoto_Photon.C:28:9`!) -> GETMEMBER (); \
419 if (tmp) \
420 *ypush_##YMEMBER () = (*OBJcxx . . $ `yorick/gyoto_Photon.C:28:9`!) -> GETMEMBER (); \
421 else ypush_long(0); \
422 } else { \
423 GYOTO_DEBUGcxx . . $ `include/GyotoDefs.h:341:9`! << "setting " #YMEMBER << std::endl; \
424 if (yarg_number(iarg)) { \
425 if (ygets_l(iarg) != 0) \
426 y_error("Argument should be a " #YMEMBER " or 0"); \
427 (*OBJcxx . . $ `yorick/gyoto_Photon.C:28:9`!) -> SETMEMBER (0); \
428 } else \
429 (*OBJcxx . . $ `yorick/gyoto_Photon.C:28:9`!) -> SETMEMBER (*yget_##YMEMBER (kiargs[k])); \
430 } \
431 }
432
433 #define YGYOTO_WORKER_GETSET_OBJECTcxx . . $ `yorick/ygyoto.h:433:9`!(MEMBER) \
434 YGYOTO_WORKER_GETSET_OBJECT0(set##MEMBER,get##MEMBER,MEMBER)
435
436 #define YGYOTO_WORKER_GETSET_OBJECT2cxx . . $ `yorick/ygyoto.h:436:9`!(MEMBER,YMEMBER) \
437 YGYOTO_WORKER_GETSET_OBJECT0cxx . . $ `yorick/ygyoto.h:412:9`!(MEMBER,MEMBER,YMEMBER)
438
439 #define YGYOTO_WORKER_SET_UNITcxx . . $ `yorick/ygyoto.h:439:9`! \
440 if ((iarg=kiargs[++k])>=0) { \
441 iarg+=*rvset; \
442 GYOTO_DEBUGcxx . . $ `include/GyotoDefs.h:341:9`! << "set unit" << std::endl; \
443 unit = ygets_q(iarg); \
444 }
445
446 #define YGYOTO_WORKER_SETPARAMETERcxx . . $ `yorick/ygyoto.h:446:9`! \
447 if ((iarg=kiargs[++k])>=0) { \
448 iarg+=*rvset; \
449 if ((*paUsed)++) y_error("pmsg"); \
450 string name = ygets_q(iarg); \
451 string content = ""; \
452 if (piargs[0] >= 0) content = ygets_q(*piargs); \
453 try { \
454 (*OBJcxx . . $ `yorick/gyoto_Photon.C:28:9`!)->setParameter(name, content, unit?unit:""); \
455 } YGYOTO_STD_CATCHcxx . . $ `yorick/ygyoto.h:37:9`!; \
456 }
457
458 #ifdef GYOTO_USE_XERCEScxx . . $ `include/GyotoConfig.h:161:9`!
459 # define YGYOTO_WORKER_XMLWRITEcxx . . $ `yorick/ygyoto.h:459:10`! \
460 if ((iarg=kiargs[++k])>=0) { \
461 iarg+=*rvset; \
462 char *filename=ygets_q(iarg); \
463 Gyoto::Factory(*OBJcxx . . $ `yorick/gyoto_SpectroUniform.C:91:9`!).write(filename); \
464 }
465 #else
466 # define YGYOTO_WORKER_XMLWRITE \
467 if ((iarg=kiargs[++k])>=0) { \
468 y_error("This GYOTO was compiled without xerces: no xml i/o"); \
469 }
470 #endif
471
472 #define YGYOTO_WORKER_CLONEcxx . . $ `yorick/ygyoto.h:472:9`!(TYPE) \
473 if ((iarg=kiargs[++k])>=0) { \
474 if ((*rvset)++) y_error(rmsg); \
475 *ypush_##TYPE () = (*OBJcxx . . $ `yorick/gyoto_Photon.C:28:9`!)->clone(); \
476 }
477
478 #define YGYOTO_WORKER_RUNcxx . . $ `yorick/ygyoto.h:478:9`!(METHOD) \
479 if ((iarg=kiargs[++k])>=0) { \
480 GYOTO_DEBUGcxx . . $ `include/GyotoDefs.h:341:9`! << #METHOD << std::endl ; \
481 iarg+=*rvset; \
482 (*OBJcxx . . $ `yorick/gyoto_Photon.C:28:9`!)-> METHOD ; \
483 }
484
485 #define YGYOTO_WORKER_HELPcxx . . $ `yorick/ygyoto.h:485:9`! \
486 if ((iarg=kiargs[++k])>=0) { \
487 GYOTO_DEBUGcxx . . $ `include/GyotoDefs.h:341:9`! << "help" << std::endl ; \
488 iarg+=*rvset; \
489 (*OBJcxx . . $ `yorick/gyoto_Photon.C:28:9`!)-> help() ; \
490 ypush_nil(); \
491 }
492
493 #define YGYOTO_WORKER_CALL_GENERICcxx . . $ `yorick/ygyoto.h:493:9`!(BASE) \
494 ygyoto_##BASE##_generic_eval(YGYOTO_CATcxx . . $ `yorick/ygyoto.h:210:9`!(OBJcxx . . $ `yorick/stdplug/gyoto_Disk3D.C:33:9`!,_), \
495 kiargs+k+1, piargs, rvset, paUsed, unit);
496
497 /*
498
499 The following are needed to export the ABI to other plug-ins.
500
501 You usually don't need to read below this line.
502
503 */
504
505 typedef Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Metriccxx . . $ Gyoto/Metric/::Genericcxx . . $ Gyoto/Metric/Generic#> *ygyoto_yget_Metric_tcxx . . $ ygyoto_yget_Metric_t#(int);
506 typedef Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Metriccxx . . $ Gyoto/Metric/::Genericcxx . . $ Gyoto/Metric/Generic#> *ygyoto_ypush_Metric_tcxx . . $ ygyoto_ypush_Metric_t#();
507
508 typedef void ygyoto_ypush_property_tcxx . . $ ygyoto_ypush_property_t#
509 (Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::SmartPointeecxx . . $ Gyoto/SmartPointee#>,
510 Gyotocxx . . $ Gyoto/::Propertycxx . . $ Gyoto/Property# const&, stdcxx . . $ std/::stringcxx . . $ std/string#, stdcxx . . $ std/::stringcxx . . $ std/string#);
511 typedef void ygyoto_yget_property_tcxx . . $ ygyoto_yget_property_t#
512 (Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::SmartPointeecxx . . $ Gyoto/SmartPointee#>,
513 Gyotocxx . . $ Gyoto/::Propertycxx . . $ Gyoto/Property# const&, int, stdcxx . . $ std/::stringcxx . . $ std/string#, stdcxx . . $ std/::stringcxx . . $ std/string#);
514
515 typedef int yarg_OBJTYPE_tcxx . . $ yarg_OBJTYPE_t#(int);
516 typedef void ygyoto_Metric_register_tcxx . . $ ygyoto_Metric_register_t#(char const * const, ygyoto_Metric_eval_worker_tcxx . . $ ygyoto_Metric_eval_worker_t#*);
517 typedef void ygyoto_Metric_generic_eval_tcxx . . $ ygyoto_Metric_generic_eval_t#(Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Metriccxx . . $ Gyoto/Metric/::Genericcxx . . $ Gyoto/Metric/Generic#>*, \
518 int *, int *, int*, int*, char *);
519
520 typedef Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Astrobjcxx . . $ Gyoto/Astrobj/::Genericcxx . . $ Gyoto/Astrobj/Generic#> *ygyoto_yget_Astrobj_tcxx . . $ ygyoto_yget_Astrobj_t#(int);
521 typedef Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Astrobjcxx . . $ Gyoto/Astrobj/::Genericcxx . . $ Gyoto/Astrobj/Generic#> *ygyoto_ypush_Astrobj_tcxx . . $ ygyoto_ypush_Astrobj_t#();
522 //typedef int yarg_Astrobj_t(int);
523 typedef void ygyoto_Astrobj_register_tcxx . . $ ygyoto_Astrobj_register_t#(char const * const, ygyoto_Astrobj_eval_worker_tcxx . . $ ygyoto_Astrobj_eval_worker_t#*);
524 typedef void ygyoto_Astrobj_generic_eval_tcxx . . $ ygyoto_Astrobj_generic_eval_t# \
525 (Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Astrobjcxx . . $ Gyoto/Astrobj/::Genericcxx . . $ Gyoto/Astrobj/Generic#>*, int *, int *, int*, int*, char *);
526
527 typedef Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Spectrumcxx . . $ Gyoto/Spectrum/::Genericcxx . . $ Gyoto/Spectrum/Generic#> *\
528 ygyoto_yget_Spectrum_t(int);
529 typedef Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Spectrumcxx . . $ Gyoto/Spectrum/::Genericcxx . . $ Gyoto/Spectrum/Generic#> *\
530 ygyoto_ypush_Spectrum_t();
531 //typedef int yarg_Spectrum::Generic_t(int);
532 typedef void ygyoto_Spectrum_register_tcxx . . $ ygyoto_Spectrum_register_t#\
533 (char const*const, ygyoto_Spectrum_eval_worker_tcxx . . $ ygyoto_Spectrum_eval_worker_t#*);
534 typedef void ygyoto_Spectrum_generic_eval_tcxx . . $ ygyoto_Spectrum_generic_eval_t# \
535 (Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Spectrumcxx . . $ Gyoto/Spectrum/::Genericcxx . . $ Gyoto/Spectrum/Generic#>*, int *, int *, int*, int*, char*);
536
537 typedef Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Screencxx . . $ Gyoto/Screen#> *ygyoto_yget_Screen_tcxx . . $ ygyoto_yget_Screen_t#(int);
538 typedef Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Screencxx . . $ Gyoto/Screen#> *ygyoto_ypush_Screen_tcxx . . $ ygyoto_ypush_Screen_t#();
539
540 typedef Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Scenerycxx . . $ Gyoto/Scenery#> *ygyoto_yget_Scenery_tcxx . . $ ygyoto_yget_Scenery_t#(int);
541 typedef Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Scenerycxx . . $ Gyoto/Scenery#> *ygyoto_ypush_Scenery_tcxx . . $ ygyoto_ypush_Scenery_t#();
542
543 typedef Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Photoncxx . . $ Gyoto/Photon#> *ygyoto_yget_Photon_tcxx . . $ ygyoto_yget_Photon_t#(int);
544 typedef Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Photoncxx . . $ Gyoto/Photon#> *ygyoto_ypush_Photon_tcxx . . $ ygyoto_ypush_Photon_t#();
545
546 typedef Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Spectrometercxx . . $ Gyoto/Spectrometer/::Genericcxx . . $ Gyoto/Spectrometer/Generic#> *\
547 ygyoto_yget_Spectrometer_t(int);
548 typedef Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Spectrometercxx . . $ Gyoto/Spectrometer/::Genericcxx . . $ Gyoto/Spectrometer/Generic#> *\
549 ygyoto_ypush_Spectrometer_t();
550 //typedef int yarg_Spectrometer::Generic_t(int);
551 typedef void ygyoto_Spectrometer_register_tcxx . . $ ygyoto_Spectrometer_register_t#\
552 (char const*const, ygyoto_Spectrometer_eval_worker_tcxx . . $ ygyoto_Spectrometer_eval_worker_t#*);
553 typedef void ygyoto_Spectrometer_generic_eval_tcxx . . $ ygyoto_Spectrometer_generic_eval_t# \
554 (Gyotocxx . . $ Gyoto/::SmartPointercxx . . $ Gyoto/SmartPointer#<Gyotocxx . . $ Gyoto/::Spectrometercxx . . $ Gyoto/Spectrometer/::Genericcxx . . $ Gyoto/Spectrometer/Generic#>*, int *, int *, int*, int*, char*);
555
556 typedef struct YGyotoSuppliercxx . . $ YGyotoSupplier# {
557 // Metric
558 ygyoto_yget_Metric_tcxx . . $ ygyoto_yget_Metric_t# *yget_Metriccxx . . $ YGyotoSupplier#yget_Metric.;
559 ygyoto_ypush_Metric_tcxx . . $ ygyoto_ypush_Metric_t# *ypush_Metriccxx . . $ YGyotoSupplier#ypush_Metric.;
560 yarg_OBJTYPE_tcxx . . $ yarg_OBJTYPE_t# *yarg_Metriccxx . . $ YGyotoSupplier#yarg_Metric.;
561 ygyoto_Metric_register_tcxx . . $ ygyoto_Metric_register_t# *ygyoto_Metric_registercxx . . $ YGyotoSupplier#ygyoto_Metric_register.;
562 ygyoto_Metric_generic_eval_tcxx . . $ ygyoto_Metric_generic_eval_t#* ygyoto_Metric_generic_evalcxx . . $ YGyotoSupplier#ygyoto_Metric_generic_eval.;
563 // Astrobj
564 ygyoto_yget_Astrobj_tcxx . . $ ygyoto_yget_Astrobj_t# *yget_Astrobjcxx . . $ YGyotoSupplier#yget_Astrobj.;
565 ygyoto_ypush_Astrobj_tcxx . . $ ygyoto_ypush_Astrobj_t# *ypush_Astrobjcxx . . $ YGyotoSupplier#ypush_Astrobj.;
566 yarg_OBJTYPE_tcxx . . $ yarg_OBJTYPE_t# *yarg_Astrobjcxx . . $ YGyotoSupplier#yarg_Astrobj.;
567 ygyoto_Astrobj_register_tcxx . . $ ygyoto_Astrobj_register_t# *ygyoto_Astrobj_registercxx . . $ YGyotoSupplier#ygyoto_Astrobj_register.;
568 ygyoto_Astrobj_generic_eval_tcxx . . $ ygyoto_Astrobj_generic_eval_t#* ygyoto_Astrobj_generic_evalcxx . . $ YGyotoSupplier#ygyoto_Astrobj_generic_eval.;
569 ygyoto_Astrobj_generic_eval_tcxx . . $ ygyoto_Astrobj_generic_eval_t#* ygyoto_ThinDisk_generic_evalcxx . . $ YGyotoSupplier#ygyoto_ThinDisk_generic_eval.;
570 // Spectrum
571 ygyoto_yget_Spectrum_tcxx . . $ ygyoto_yget_Spectrum_t# *yget_Spectrumcxx . . $ YGyotoSupplier#yget_Spectrum.;
572 ygyoto_ypush_Spectrum_tcxx . . $ ygyoto_ypush_Spectrum_t# *ypush_Spectrumcxx . . $ YGyotoSupplier#ypush_Spectrum.;
573 yarg_OBJTYPE_tcxx . . $ yarg_OBJTYPE_t# *yarg_Spectrumcxx . . $ YGyotoSupplier#yarg_Spectrum.;
574 ygyoto_Spectrum_register_tcxx . . $ ygyoto_Spectrum_register_t# *ygyoto_Spectrum_registercxx . . $ YGyotoSupplier#ygyoto_Spectrum_register.;
575 ygyoto_Spectrum_generic_eval_tcxx . . $ ygyoto_Spectrum_generic_eval_t#* ygyoto_Spectrum_generic_evalcxx . . $ YGyotoSupplier#ygyoto_Spectrum_generic_eval.;
576 // Screen
577 ygyoto_yget_Screen_tcxx . . $ ygyoto_yget_Screen_t# *yget_Screencxx . . $ YGyotoSupplier#yget_Screen.;
578 ygyoto_ypush_Screen_tcxx . . $ ygyoto_ypush_Screen_t# *ypush_Screencxx . . $ YGyotoSupplier#ypush_Screen.;
579 yarg_OBJTYPE_tcxx . . $ yarg_OBJTYPE_t# *yarg_Screencxx . . $ YGyotoSupplier#yarg_Screen.;
580 // Scenery
581 ygyoto_yget_Scenery_tcxx . . $ ygyoto_yget_Scenery_t# *yget_Scenerycxx . . $ YGyotoSupplier#yget_Scenery.;
582 ygyoto_ypush_Scenery_tcxx . . $ ygyoto_ypush_Scenery_t# *ypush_Scenerycxx . . $ YGyotoSupplier#ypush_Scenery.;
583 yarg_OBJTYPE_tcxx . . $ yarg_OBJTYPE_t# *yarg_Scenerycxx . . $ YGyotoSupplier#yarg_Scenery.;
584 // Photon
585 ygyoto_yget_Photon_tcxx . . $ ygyoto_yget_Photon_t# *yget_Photoncxx . . $ YGyotoSupplier#yget_Photon.;
586 ygyoto_ypush_Photon_tcxx . . $ ygyoto_ypush_Photon_t# *ypush_Photoncxx . . $ YGyotoSupplier#ypush_Photon.;
587 yarg_OBJTYPE_tcxx . . $ yarg_OBJTYPE_t# *yarg_Photoncxx . . $ YGyotoSupplier#yarg_Photon.;
588 // Spectrometer
589 ygyoto_yget_Spectrometer_tcxx . . $ ygyoto_yget_Spectrometer_t# *yget_Spectrometercxx . . $ YGyotoSupplier#yget_Spectrometer.;
590 ygyoto_ypush_Spectrometer_tcxx . . $ ygyoto_ypush_Spectrometer_t# *ypush_Spectrometercxx . . $ YGyotoSupplier#ypush_Spectrometer.;
591 yarg_OBJTYPE_tcxx . . $ yarg_OBJTYPE_t# *yarg_Spectrometercxx . . $ YGyotoSupplier#yarg_Spectrometer.;
592 ygyoto_Spectrometer_register_tcxx . . $ ygyoto_Spectrometer_register_t# *ygyoto_Spectrometer_registercxx . . $ YGyotoSupplier#ygyoto_Spectrometer_register.;
593 ygyoto_Spectrometer_generic_eval_tcxx . . $ ygyoto_Spectrometer_generic_eval_t#* ygyoto_Spectrometer_generic_evalcxx . . $ YGyotoSupplier#ygyoto_Spectrometer_generic_eval.;
594 // Properties
595 ygyoto_ypush_property_tcxx . . $ ygyoto_ypush_property_t# *ypush_propertycxx . . $ YGyotoSupplier#ypush_property.;
596 ygyoto_yget_property_tcxx . . $ ygyoto_yget_property_t# *yget_propertycxx . . $ YGyotoSupplier#yget_property.;
597 } YGyotoSupplier_tcxx . . $ YGyotoSupplier_t#;
598
599
600 #ifdef YGYOTO_LOCAL_SUPPLIERcxx . . $ `<built-in>:483:9`!
601 // The above ABI is exposed as macros in external plug-ins
602
603 extern YGyotoSupplier_tcxx . . $ YGyotoSupplier_t#* YGYOTO_LOCAL_SUPPLIERcxx . . $ `<built-in>:483:9`!;
604
605 #define yget_Metriccxx . . $ `yorick/ygyoto.h:605:9`!(iarg) YGYOTO_LOCAL_SUPPLIER -> yget_Metric(iarg)
606 #define ypush_Metriccxx . . $ `yorick/ygyoto.h:606:9`!() YGYOTO_LOCAL_SUPPLIER -> ypush_Metric()
607 #define yget_propertycxx . . $ `yorick/ygyoto.h:607:9`!(a, b, c, d, e) \
608 YGYOTO_LOCAL_SUPPLIERcxx . . $ `<built-in>:483:9`! -> yget_property(a, b, c, d, e)
609 #define ypush_propertycxx . . $ `yorick/ygyoto.h:609:9`!(a, b, c, d)\
610 YGYOTO_LOCAL_SUPPLIERcxx . . $ `<built-in>:483:9`! -> ypush_property(a, b, c, d)
611 #define yarg_Metriccxx . . $ `yorick/ygyoto.h:611:9`!(iarg) YGYOTO_LOCAL_SUPPLIER -> yarg_Metric(iarg)
612 #define ygyoto_Metric_registercxx . . $ `yorick/ygyoto.h:612:9`!(kind, on_eval) \
613 YGYOTO_LOCAL_SUPPLIER -> \
614 ygyoto_Metric_register(kind, on_eval)
615 #define ygyoto_Metric_generic_evalcxx . . $ `yorick/ygyoto.h:615:9`!(gg, kiargs, piargs, rvset, paUsed, unit) \
616 YGYOTO_LOCAL_SUPPLIER -> \
617 ygyoto_Metric_generic_eval(gg, kiargs, piargs, rvset, paUsed, unit)
618
619 #define yget_Astrobjcxx . . $ `yorick/ygyoto.h:619:9`!(iarg) YGYOTO_LOCAL_SUPPLIERcxx . . $ `<built-in>:483:9`! -> yget_Astrobj(iarg)
620 #define ypush_Astrobjcxx . . $ `yorick/ygyoto.h:620:9`!() YGYOTO_LOCAL_SUPPLIERcxx . . $ `<built-in>:483:9`! -> ypush_Astrobj()
621 #define yarg_Astrobjcxx . . $ `yorick/ygyoto.h:621:9`!(iarg) YGYOTO_LOCAL_SUPPLIERcxx . . $ `<built-in>:483:9`! -> yarg_Astrobj(iarg)
622 #define ygyoto_Astrobj_registercxx . . $ `yorick/ygyoto.h:622:9`!(kind, on_eval) \
623 YGYOTO_LOCAL_SUPPLIERcxx . . $ `<built-in>:483:9`! -> \
624 ygyoto_Astrobj_register(kind, on_eval)
625 #define ygyoto_Astrobj_generic_evalcxx . . $ `yorick/ygyoto.h:625:9`!(gg, kiargs, piargs, rvset, paUsed, unit) \
626 YGYOTO_LOCAL_SUPPLIERcxx . . $ `<built-in>:483:9`! -> \
627 ygyoto_Astrobj_generic_eval(gg, kiargs, piargs, rvset, paUsed, unit)
628 #define ygyoto_ThinDisk_generic_evalcxx . . $ `yorick/ygyoto.h:628:9`!(gg, kiargs, piargs, rvset, paUsed, unit) \
629 YGYOTO_LOCAL_SUPPLIER -> \
630 ygyoto_ThinDisk_generic_eval(gg, kiargs, piargs, rvset, paUsed, unit)
631
632 #define yget_Spectrumcxx . . $ `yorick/ygyoto.h:632:9`!(iarg) YGYOTO_LOCAL_SUPPLIER -> yget_Spectrum(iarg)
633 #define ypush_Spectrumcxx . . $ `yorick/ygyoto.h:633:9`!() YGYOTO_LOCAL_SUPPLIER -> ypush_Spectrum()
634 #define yarg_Spectrumcxx . . $ `yorick/ygyoto.h:634:9`!(iarg) YGYOTO_LOCAL_SUPPLIER -> yarg_Spectrum(iarg)
635 #define ygyoto_Spectrum_registercxx . . $ `yorick/ygyoto.h:635:9`!(kind, on_eval) \
636 YGYOTO_LOCAL_SUPPLIER -> \
637 ygyoto_Spectrum_register(kind, on_eval)
638 #define ygyoto_Spectrum_generic_evalcxx . . $ `yorick/ygyoto.h:638:9`!(gg, kiargs, piargs, rvset, paUsed, unit) \
639 YGYOTO_LOCAL_SUPPLIER -> \
640 ygyoto_Spectrum_generic_eval(gg, kiargs, piargs, rvset, paUsed, unit)
641
642 #define yget_Screencxx . . $ `yorick/ygyoto.h:642:9`!(iarg) YGYOTO_LOCAL_SUPPLIER -> yget_Screen(iarg)
643 #define ypush_Screencxx . . $ `yorick/ygyoto.h:643:9`!() YGYOTO_LOCAL_SUPPLIER -> ypush_Screen()
644 #define yarg_Screencxx . . $ `yorick/ygyoto.h:644:9`!(iarg) YGYOTO_LOCAL_SUPPLIER -> yarg_Screen(iarg)
645
646 #define yget_Scenerycxx . . $ `yorick/ygyoto.h:646:9`!(iarg) YGYOTO_LOCAL_SUPPLIER -> yget_Scenery(iarg)
647 #define ypush_Scenerycxx . . $ `yorick/ygyoto.h:647:9`!() YGYOTO_LOCAL_SUPPLIER -> ypush_Scenery()
648 #define yarg_Scenerycxx . . $ `yorick/ygyoto.h:648:9`!(iarg) YGYOTO_LOCAL_SUPPLIER -> yarg_Scenery(iarg)
649
650 #define yget_Photoncxx . . $ `yorick/ygyoto.h:650:9`!(iarg) YGYOTO_LOCAL_SUPPLIER -> yget_Photon(iarg)
651 #define ypush_Photoncxx . . $ `yorick/ygyoto.h:651:9`!() YGYOTO_LOCAL_SUPPLIER -> ypush_Photon()
652 #define yarg_Photoncxx . . $ `yorick/ygyoto.h:652:9`!(iarg) YGYOTO_LOCAL_SUPPLIER -> yarg_Photon(iarg)
653
654 #define yget_Spectrometercxx . . $ `yorick/ygyoto.h:654:9`!(iarg) YGYOTO_LOCAL_SUPPLIER -> yget_Spectrometer(iarg)
655 #define ypush_Spectrometercxx . . $ `yorick/ygyoto.h:655:9`!() YGYOTO_LOCAL_SUPPLIER -> ypush_Spectrometer()
656 #define yarg_Spectrometercxx . . $ `yorick/ygyoto.h:656:9`!(iarg) YGYOTO_LOCAL_SUPPLIER -> yarg_Spectrometer(iarg)
657 #define ygyoto_Spectrometer_registercxx . . $ `yorick/ygyoto.h:657:9`!(kind, on_eval) \
658 YGYOTO_LOCAL_SUPPLIER -> \
659 ygyoto_Spectrometer_register(kind, on_eval)
660 #define ygyoto_Spectrometer_generic_evalcxx . . $ `yorick/ygyoto.h:660:9`!(gg, kiargs, piargs, rvset, paUsed) \
661 YGYOTO_LOCAL_SUPPLIER -> \
662 ygyoto_Spectrometer_generic_eval(gg, kiargs, piargs, rvset,paUsed)
663
664 #endif
665
666
667 #endif