37 #ifndef EGS_PARALLEL_BEAM_
38 #define EGS_PARALLEL_BEAM_
48 #ifdef BUILD_PARALLEL_BEAM_DLL
49 #define EGS_PARALLEL_BEAM_EXPORT __declspec(dllexport)
51 #define EGS_PARALLEL_BEAM_EXPORT __declspec(dllimport)
53 #define EGS_PARALLEL_BEAM_LOCAL
57 #ifdef HAVE_VISIBILITY
58 #define EGS_PARALLEL_BEAM_EXPORT __attribute__ ((visibility ("default")))
59 #define EGS_PARALLEL_BEAM_LOCAL __attribute__ ((visibility ("hidden")))
61 #define EGS_PARALLEL_BEAM_EXPORT
62 #define EGS_PARALLEL_BEAM_LOCAL
152 x = shape->getRandomPoint(rndm);
158 return count/shape->area();
170 return (s != 0 && shape != 0);
virtual void getPositionDirection(EGS_RandomGenerator *rndm, EGS_Vector &x, EGS_Vector &u, EGS_Float &wt)=0
Sample a particle position and direction.
EGS_BaseSource class header file.
EGS_Vector methods for the manipulation of 3D vectors in cartesian co-ordinates.
A class representing 3D vectors.
static void deleteObject(EGS_Object *o)
Delete an object.
Base shape class. All shapes in the EGSnrc C++ class library are derived from EGS_BaseShape.
EGS_ParallelBeam(int Q, EGS_BaseSpectrum *Spec, EGS_BaseShape *Shape, const string &Name="", EGS_ObjectFactory *f=0)
Constructor.
Base random number generator class. All random number generators should be derived from this class...
EGS_RandomGenerator class header file.
EGS_BaseShape and shape classes header file.
EGS_Vector uo
The direction of the particles.
virtual EGS_Float getFluence() const =0
Return the fluence this source has emitted so far.
virtual bool storeFluenceState(ostream &data_out) const
Store the fluence state of this source to the data stream data_out.
Base class for energy spectra. All energy spectra in the EGSnrc C++ class library are derived from th...
Base class for 'simple' particle sources.
virtual bool isValid() const
Is this a valid source?
virtual bool setFluenceState(istream &data)
Set the data related to the sampling of positions and directions to a state contained in the stream d...