46 #ifdef BUILD_CIRCLE_DLL
47 #define EGS_CIRCLE_EXPORT __declspec(dllexport)
49 #define EGS_CIRCLE_EXPORT __declspec(dllimport)
51 #define EGS_CIRCLE_LOCAL
55 #ifdef HAVE_VISIBILITY
56 #define EGS_CIRCLE_EXPORT __attribute__ ((visibility ("default")))
57 #define EGS_CIRCLE_LOCAL __attribute__ ((visibility ("hidden")))
59 #define EGS_CIRCLE_EXPORT
60 #define EGS_CIRCLE_LOCAL
101 A = M_PI*dr*(dr + 2*ro);
105 EGS_Float r = ro + dr*sqrt(rndm->
getUniform());
106 EGS_Float cphi, sphi;
108 return EGS_Vector(xo + r*cphi, yo + r*sphi, 0);
113 EGS_Float xo, yo, ro, dr;
EGS_CircleShape(EGS_Float Xo, EGS_Float Yo, EGS_Float R, EGS_Float R_i=0, const string &Name="", EGS_ObjectFactory *f=0)
Conctruct a circle with midpoint given by Xo and Yo, radius R and innder radius R_i.
A class representing 3D vectors.
void getAzimuth(EGS_Float &cphi, EGS_Float &sphi)
Sets cphi and sphi to the cosine and sine of a random angle uniformely distributed between 0 and ...
virtual EGS_Vector getPoint(EGS_RandomGenerator *rndm)
Sample and return a random 3D vector.
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.
Attempts to fix broken math header files.
EGS_Float getUniform()
Returns a random number uniformly distributed between zero (inclusive) and 1 (exclusive).