1 |
querten |
1.1 |
// Geometry.h: interface for the Geometry class.
|
2 |
|
|
//
|
3 |
|
|
//////////////////////////////////////////////////////////////////////
|
4 |
|
|
|
5 |
|
|
#ifndef _GEOMETRY_H__
|
6 |
|
|
#define _GEOMETRY_H__
|
7 |
|
|
|
8 |
querten |
1.6 |
#define _CRT_SECURE_NO_DEPRECATE 1
|
9 |
querten |
1.1 |
|
10 |
|
|
#include <vector>
|
11 |
|
|
#include "Chunk.h"
|
12 |
|
|
|
13 |
querten |
1.3 |
|
14 |
|
|
struct TrackerDet {unsigned int DetId; float TrapezoidalParam;
|
15 |
querten |
1.2 |
float PosX; float PosY; float PosZ;
|
16 |
|
|
float WidthX; float WidthY; float WidthZ;
|
17 |
|
|
float LengthX; float LengthY; float LengthZ;
|
18 |
|
|
float ThickX; float ThickY; float ThickZ;};
|
19 |
querten |
1.1 |
|
20 |
querten |
1.4 |
struct CaloDet {unsigned int DetId;
|
21 |
|
|
float PosX; float PosY; float PosZ;
|
22 |
|
|
float C1X; float C1Y; float C1Z;
|
23 |
|
|
float C2X; float C2Y; float C2Z;
|
24 |
|
|
float C3X; float C3Y; float C3Z;
|
25 |
|
|
float C4X; float C4Y; float C4Z;
|
26 |
|
|
float C5X; float C5Y; float C5Z;
|
27 |
|
|
float C6X; float C6Y; float C6Z;
|
28 |
|
|
float C7X; float C7Y; float C7Z;
|
29 |
|
|
float C8X; float C8Y; float C8Z;};
|
30 |
|
|
|
31 |
querten |
1.3 |
|
32 |
querten |
1.1 |
class Geometry
|
33 |
|
|
{
|
34 |
|
|
public:
|
35 |
|
|
Geometry(void);
|
36 |
|
|
~Geometry(void);
|
37 |
|
|
|
38 |
|
|
void Read (FILE* pFile, stChunk* ParentChunk);
|
39 |
|
|
void Write(stChunkToSave* ParentChunk);
|
40 |
|
|
|
41 |
|
|
void Load (char* path);
|
42 |
|
|
void Save (char* path);
|
43 |
|
|
|
44 |
querten |
1.3 |
void Add_TrackerDet (unsigned int DetId, float TrapezoidalParam,
|
45 |
querten |
1.2 |
float PosX, float PosY, float PosZ,
|
46 |
|
|
float WidthX, float WidthY, float WidthZ,
|
47 |
|
|
float LengthX, float LengthY, float LengthZ,
|
48 |
|
|
float ThickX, float ThickY, float ThickZ);
|
49 |
querten |
1.1 |
|
50 |
querten |
1.4 |
void Add_CaloDet (unsigned int DetId,
|
51 |
|
|
float PosX, float PosY, float PosZ,
|
52 |
|
|
float C1X, float C1Y, float C1Z,
|
53 |
|
|
float C2X, float C2Y, float C2Z,
|
54 |
|
|
float C3X, float C3Y, float C3Z,
|
55 |
|
|
float C4X, float C4Y, float C4Z,
|
56 |
|
|
float C5X, float C5Y, float C5Z,
|
57 |
|
|
float C6X, float C6Y, float C6Z,
|
58 |
|
|
float C7X, float C7Y, float C7Z,
|
59 |
|
|
float C8X, float C8Y, float C8Z);
|
60 |
|
|
|
61 |
querten |
1.1 |
TrackerDet* Find_TrackerDet (unsigned int DetId);
|
62 |
querten |
1.6 |
CaloDet* Find_CaloDet (unsigned int DetId);
|
63 |
querten |
1.1 |
|
64 |
|
|
std::vector<TrackerDet*> Det_Tracker_ALL;
|
65 |
|
|
std::vector<TrackerDet*> Det_Tracker_PIB;
|
66 |
|
|
std::vector<TrackerDet*> Det_Tracker_PIE;
|
67 |
|
|
std::vector<TrackerDet*> Det_Tracker_TIB;
|
68 |
|
|
std::vector<TrackerDet*> Det_Tracker_TID;
|
69 |
|
|
std::vector<TrackerDet*> Det_Tracker_TOB;
|
70 |
|
|
std::vector<TrackerDet*> Det_Tracker_TEC;
|
71 |
querten |
1.4 |
|
72 |
|
|
std::vector<CaloDet*> Det_ECAL_ALL;
|
73 |
|
|
std::vector<CaloDet*> Det_ECAL_EB;
|
74 |
|
|
std::vector<CaloDet*> Det_ECAL_EE;
|
75 |
querten |
1.5 |
std::vector<CaloDet*> Det_ECAL_PS;
|
76 |
|
|
|
77 |
|
|
std::vector<CaloDet*> Det_HCAL_ALL;
|
78 |
|
|
std::vector<CaloDet*> Det_HCAL_HB;
|
79 |
|
|
std::vector<CaloDet*> Det_HCAL_HE;
|
80 |
|
|
std::vector<CaloDet*> Det_HCAL_HO;
|
81 |
|
|
std::vector<CaloDet*> Det_HCAL_HF;
|
82 |
roberfro |
1.7 |
|
83 |
querten |
1.8 |
private :
|
84 |
|
|
class isLowerId {
|
85 |
|
|
public:
|
86 |
|
|
template <class T> bool operator () (const T& det1, const T& det2) {
|
87 |
|
|
return (det1->DetId < det2->DetId); }
|
88 |
|
|
};
|
89 |
roberfro |
1.7 |
|
90 |
querten |
1.8 |
void sortDet();
|
91 |
querten |
1.1 |
};
|
92 |
|
|
|
93 |
|
|
#endif
|