23#ifndef RestCore_TRestDetectorReadout
24#define RestCore_TRestDetectorReadout
26#include <TRestMetadata.h>
30#include "TRestDetectorReadoutPlane.h"
43 std::vector<TRestDetectorReadoutPlane>
48 std::vector<TRestDetectorReadoutModule> fModuleDefinitions;
73 void GetPlaneModuleChannel(Int_t daqID, Int_t& planeID, Int_t& moduleID, Int_t& channelID);
74 Int_t GetHitsDaqChannel(
const TVector3& position, Int_t& planeID, Int_t& moduleID, Int_t& channelID);
77 Double_t
GetX(Int_t signalID);
78 Double_t
GetY(Int_t signalID);
81 Double_t
GetX(Int_t planeID, Int_t modID, Int_t chID);
82 Double_t
GetY(Int_t planeID, Int_t modID, Int_t chID);
A metadata class to generate/store a readout description.
std::vector< TRestDetectorReadoutPlane > fReadoutPlanes
A std::vector storing the TRestDetectorReadoutPlane definitions.
void PrintMetadata() override
Implemented it in the derived metadata class to print out specific metadata information.
Int_t GetNumberOfChannels()
Returns the total number of channels implemented in all the readout planes and modules.
~TRestDetectorReadout() override
TRestDetectorReadout default destructor.
Int_t GetHitsDaqChannelAtReadoutPlane(const TVector3 &hitPosition, Int_t &moduleID, Int_t &channelID, Int_t planeId=0)
This method recovers the channel daq id corresponding to the (x,y,z) coordinates given by argument....
TRestDetectorReadoutPlane * GetReadoutPlane(int p)
Returns a pointer to the readout plane by index.
TRestDetectorReadoutPlane * GetReadoutPlaneWithID(int id)
Returns a pointer to the readout plane by ID.
Double_t GetY(Int_t signalID)
It returns the physical Y-coordinate corresponding to a given signal id in plane coordinates.
TRestDetectorReadout()
TRestDetectorReadout default constructor.
void InitFromConfigFile() override
Initializes the readout members using the information given in the TRestDetectorReadout RML section.
Int_t fNReadoutPlanes
Number of readout planes present on the readout.
TRestDetectorReadoutModule * GetReadoutModuleWithID(int id)
Returns a pointer to the readout module by ID.
void AddReadoutPlane(TRestDetectorReadoutPlane plane)
Adds a readout plane to the readout.
Double_t GetX(Int_t signalID)
It returns the physical X-coordinate corresponding to a given signal id in plane coordinates.
Int_t GetNumberOfModules()
Returns the total number of modules implemented in all the readout planes.
TRestDetectorReadoutChannel * GetReadoutChannelWithDaqID(int daqId)
Returns a pointer to the readout channel by daq id.
*TRestDetectorReadoutModule definitions *void ValidateReadout()
This method is not implemented yet. But it could do some checks to help verifying the readout.
void Initialize() override
Initializes the readout members and defines the section name.
Int_t GetModuleDefinitionId(TString name)
Returns the id of the readout module with a given name.
Int_t GetNumberOfReadoutPlanes()
Returns the number of readout planes defined on the readout.
void Draw()
Draws the readout on screen. Not yet implemented.