59#include "TRestDetectorHitsTranslationProcess.h"
65TRestDetectorHitsTranslationProcess::TRestDetectorHitsTranslationProcess() {
Initialize(); }
79TRestDetectorHitsTranslationProcess::TRestDetectorHitsTranslationProcess(
const char* configFilename) {
84TRestDetectorHitsTranslationProcess::~TRestDetectorHitsTranslationProcess() {}
98 for (
unsigned int hit = 0; hit <
fInputEvent->GetNumberOfHits(); hit++) {
118 fTranslation = Get3DVectorParameterWithUnits(
"translation", {0, 0, 1});
Double_t GetX(int n) const
Returns the X-coordinate of hit entry n in mm.
Double_t GetY(int n) const
Returns the Y-coordinate of hit entry n in mm.
Double_t GetZ(int n) const
Returns the Z-coordinate of hit entry n in mm.
void AddHit(Double_t x, Double_t y, Double_t z, Double_t en, Double_t t=0, REST_HitType type=XYZ)
Adds a new hit to this event.
A process to translate hits by a given user amount.
void InitFromConfigFile() override
To make settings from rml file. This method must be implemented in the derived class.
TRestDetectorHitsEvent * fInputEvent
A pointer to the process input event.
TVector3 fTranslation
The amount to be translated every hit.
TRestEvent * ProcessEvent(TRestEvent *inputEvent) override
Process one event.
void PrintMetadata() override
Implemented it in the derived metadata class to print out specific metadata information.
TRestDetectorHitsEvent * fOutputEvent
A pointer to the process output event.
void Initialize() override
Making default settings.
virtual void InitFromConfigFile() override
To make settings from rml file. This method must be implemented in the derived class.
void BeginPrintProcess()
[name, cut range]
A base class for any REST event.
void SetEventInfo(TRestEvent *eve)