-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathsphereAbsorber.h
37 lines (27 loc) · 1006 Bytes
/
sphereAbsorber.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
//
// sphere.h
// Xcode
//
// Created by jacob on 6/20/11.
//
#ifndef SPHEREABSORBER_H
#define SPHEREABSORBER_H
class Absorber;
class SphereAbsorber : public Absorber
{
public:
SphereAbsorber(const double radius, const double x, const double y, const double z);
SphereAbsorber(const double radius, const Vector3d &c);
SphereAbsorber(const double radius, const boost::shared_ptr<Vector3d> c);
~SphereAbsorber();
virtual bool hitAbsorberBoundary(const boost::shared_ptr<Vector3d> photonVector);
virtual bool inAbsorber(const boost::shared_ptr<Vector3d> photonVector);
virtual bool crossedAbsorber(const boost::shared_ptr<Vector3d> A,
const boost::shared_ptr<Vector3d> B);
// Check if photon is within the radius of the absorber.
bool inSphereVolume(const boost::shared_ptr<Vector3d> photonVector);
sphereCoords cartesianToSpherical(const coords &c);
private:
double radius;
};
#endif // SPHERE_H