39 #ifndef EGS_BEAM_SOURCE_
40 #define EGS_BEAM_SOURCE_
52 #ifdef BUILD_BEAM_SOURCE_DLL
53 #define EGS_BEAM_SOURCE_EXPORT __declspec(dllexport)
55 #define EGS_BEAM_SOURCE_EXPORT __declspec(dllimport)
57 #define EGS_BEAM_SOURCE_LOCAL
61 #ifdef HAVE_VISIBILITY
62 #define EGS_BEAM_SOURCE_EXPORT __attribute__ ((visibility ("default")))
63 #define EGS_BEAM_SOURCE_LOCAL __attribute__ ((visibility ("hidden")))
65 #define EGS_BEAM_SOURCE_EXPORT
66 #define EGS_BEAM_SOURCE_LOCAL
72 typedef void (*InitFunction)(
const int *,
const int *,
const int *,
73 const char *,
const char *,
const char *,
74 const char *,
const char *, int,int,int,int,int);
75 typedef void (*FinishFunction)();
76 typedef void (*SampleFunction)(EGS_Float *, EGS_Float *, EGS_Float *,
77 EGS_Float *, EGS_Float *, EGS_Float *, EGS_Float *, EGS_Float *,
78 EGS_I32 *, EGS_I32 *, EGS_I64 *, EGS_I32 *);
79 typedef void (*MotionSampleFunction)(EGS_Float *, EGS_Float *, EGS_Float *,
80 EGS_Float *, EGS_Float *, EGS_Float *, EGS_Float *, EGS_Float *,
81 EGS_I32 *, EGS_I32 *, EGS_I64 *, EGS_I32 *, EGS_Float *);
82 typedef void (*MaxEnergyFunction)(EGS_Float *);
146 int &q,
int &latch, EGS_Float &E, EGS_Float &wt,
148 EGS_Float getEmax()
const {
151 EGS_Float getFluence()
const {
162 bool storeState(ostream &data)
const {
165 bool setState(istream &data) {
168 bool addState(istream &data) {
174 void resetCounter() {
178 bool isValid()
const {
182 void setCutout(EGS_Float xmin, EGS_Float xmax, EGS_Float ymin,
196 MotionSampleFunction motionsample;
201 string the_file_name;
209 EGS_Float Xmin, Xmax, Ymin, Ymax;
210 EGS_Float wmin, wmax;
213 int q_save, latch_save;
214 EGS_Float E_save, wt_save, mu_save;
218 int n_reuse_photon, n_reuse_electron;
219 int i_reuse_photon, i_reuse_electron;
224 EGS_Float tei,txi,tyi,tzi,tui,tvi,twi,twti,tmui;
225 int tqi,tlatchi,tiphati;
A class for dynamically loading shared libraries.
bool EGS_EXPORT egsGetI64(istream &data, EGS_I64 &n)
Reads a 64 bit integer from the stream data and assigns it to n. Returns true on success, false on failure.
EGS_BaseSource class header file.
SampleFunction sample
The function that returns the next particle.
EGS_Vector methods for the manipulation of 3D vectors in cartesian co-ordinates.
bool EGS_EXPORT egsStoreI64(ostream &data, EGS_I64 n)
Writes the 64 bit integer n to the output stream data and returns true on success, false on failure.
A class representing 3D vectors.
Global egspp functions header file.
A BEAM simulation source.
Base random number generator class. All random number generators should be derived from this class...
EGS_RandomGenerator class header file.
bool mu_stored
true if mu index stored
Base source class. All particle sources must be derived from this class.