Garfield++ v2r0
A toolkit for the detailed simulation of particle detectors based on ionisation measurement in gases and semiconductors
Loading...
Searching...
No Matches
GeometryBase.hh
Go to the documentation of this file.
1#ifndef G_GEOMETRY_BASE_H
2#define G_GEOMETRY_BASE_H
3
4#include <string>
5
6#include "Medium.hh"
7
8namespace Garfield {
9
10/// Abstract base class for geometry classes.
11
13
14 public:
15 // Constructor
16 GeometryBase() : m_className("GeometryBase") {}
17 // Destructor
18 virtual ~GeometryBase() {}
19
20 virtual Medium* GetMedium(const double x, const double y,
21 const double z) const = 0;
22
23 // Check if a point is inside the geometry
24 virtual bool IsInside(const double x, const double y,
25 const double z) const = 0;
26
27 // Bounding box (envelope of geometry)
28 virtual bool GetBoundingBox(double& xmin, double& ymin, double& zmin,
29 double& xmax, double& ymax, double& zmax) = 0;
30
31 protected:
32 std::string m_className;
33};
34}
35
36#endif
Abstract base class for geometry classes.
Definition: GeometryBase.hh:12
virtual Medium * GetMedium(const double x, const double y, const double z) const =0
virtual bool IsInside(const double x, const double y, const double z) const =0
virtual bool GetBoundingBox(double &xmin, double &ymin, double &zmin, double &xmax, double &ymax, double &zmax)=0
Abstract base class for media.
Definition: Medium.hh:11