SM sensitive detector class based on G4VSensitiveDetector. More...
#include <SM_SD.h>
Public Member Functions | |
SM_SD (G4String name) | |
Constructor. | |
~SM_SD () | |
Destructor. | |
void | clear () |
In the event of an aborted event clear hit collections not assigned to the usual hit collection.. | |
void | DrawAll () |
Draw all hits. | |
void | EndOfEvent (G4HCofThisEvent *HCE) |
End of event routine. | |
G4double | getEresol () |
G4double | getThreshold () |
void | Initialize (G4HCofThisEvent *HCE) |
Initialise the hits collection. | |
void | PrintAll () |
Print all hits. | |
G4bool | ProcessHits (G4Step *aStep, G4TouchableHistory *ROhist) |
Routine to process each hit. | |
G4double | setEresol (G4double) |
Set/Get energy resolution of PMT. | |
G4double | setThreshold (G4double) |
Set/Get energy threshold. | |
Private Attributes | |
G4double | SM_Eresol |
E resolution. | |
SM_HitsCollection * | SM_HC |
Data member consists of a pointer to the hits collection. | |
G4AffineTransform | SM_LocaltoWorld [N_SM] |
G4double | SM_threshold |
Energy threshold for valid hit. | |
G4bool | SM_Transform [N_SM] |
G4AffineTransform | SM_WorldtoLocal [N_SM] |
Boolean if transforms defined. |
SM sensitive detector class based on G4VSensitiveDetector.
Creates the SM_SD class and provides the member routines for initialising the hits collection, processing of hits, and end of event action.
Definition at line 46 of file SM_SD.h.
SM_SD::SM_SD | ( | G4String | name ) |
Constructor.
Definition at line 48 of file SM_SD.cc.
References SM_Messenger::Instance(), N_SM, SM_Messenger::setSM_SDptr(), SM_Eresol, SM_threshold, and SM_Transform.
void SM_SD::clear | ( | ) |
void SM_SD::EndOfEvent | ( | G4HCofThisEvent * | HCE ) |
End of event routine.
Definition at line 164 of file SM_SD.cc.
References SM_Data::e, SM_Data::id, SM_Data::nSM, SM_Data::Reset(), SM_HC, EventAction::smdata, SM_Data::t, SM_Data::tr, SM_Data::tx, SM_Data::txl, SM_Data::ty, SM_Data::tyl, SM_Data::tz, SM_Data::tzl, SM_Data::x, SM_Data::xl, SM_Data::y, SM_Data::yl, SM_Data::z, and SM_Data::zl.
G4double SM_SD::getThreshold | ( | ) |
Definition at line 217 of file SM_SD.cc.
References SM_threshold.
void SM_SD::Initialize | ( | G4HCofThisEvent * | HCE ) |
G4bool SM_SD::ProcessHits | ( | G4Step * | aStep, |
G4TouchableHistory * | ROhist | ||
) |
Routine to process each hit.
Stores all the hit information in the data members of the hit class. ROHist is only given if a readout geometry is associated with this detector.
Definition at line 89 of file SM_SD.cc.
References SM_Hit::copyno, SM_Hit::edep, SM_Hit::local, SM_Eresol, SM_HC, SM_LocaltoWorld, SM_threshold, SM_Transform, SM_WorldtoLocal, SM_Hit::time, SM_Hit::tlocal, SM_Hit::trackid, SM_Hit::tworld, and SM_Hit::world.
G4double SM_SD::setEresol | ( | G4double | res ) |
G4double SM_SD::setThreshold | ( | G4double | thres ) |
G4double SM_SD::SM_Eresol [private] |
E resolution.
Definition at line 106 of file SM_SD.h.
Referenced by getEresol(), ProcessHits(), setEresol(), and SM_SD().
SM_HitsCollection* SM_SD::SM_HC [private] |
Data member consists of a pointer to the hits collection.
Pointer to hits collection.
Definition at line 103 of file SM_SD.h.
Referenced by EndOfEvent(), Initialize(), PrintAll(), and ProcessHits().
G4AffineTransform SM_SD::SM_LocaltoWorld[N_SM] [private] |
Definition at line 113 of file SM_SD.h.
Referenced by ProcessHits().
G4double SM_SD::SM_threshold [private] |
Energy threshold for valid hit.
Definition at line 105 of file SM_SD.h.
Referenced by getThreshold(), ProcessHits(), setThreshold(), and SM_SD().
G4bool SM_SD::SM_Transform[N_SM] [private] |
Definition at line 108 of file SM_SD.h.
Referenced by ProcessHits(), and SM_SD().
G4AffineTransform SM_SD::SM_WorldtoLocal[N_SM] [private] |
Boolean if transforms defined.
Pointers to transformations.
Definition at line 112 of file SM_SD.h.
Referenced by ProcessHits().