CbmRoot
Loading...
Searching...
No Matches
CbmMuchPadRadial.cxx
Go to the documentation of this file.
1
/* Copyright (C) 2012-2020 Petersburg Nuclear Physics Institute named by B.P.Konstantinov of National Research Centre "Kurchatov Institute", Gatchina
2
SPDX-License-Identifier: GPL-3.0-only
3
Authors: Evgeny Kryshen [committer], Florian Uhlig */
4
12
#include "
CbmMuchPadRadial.h
"
13
14
#include <TColor.h>
// for TColor
15
#include <TCrown.h>
// for TCrown
16
#include <TMath.h>
// for RadToDeg
17
18
#include <math.h>
// for cos, sin
19
20
// ----- Default constructor ----------------------------------------------
21
CbmMuchPadRadial::CbmMuchPadRadial
() :
CbmMuchPad
(), TCrown(), fPhi1(0.), fPhi2(0.) {}
22
// -------------------------------------------------------------------------
23
24
// -------------------------------------------------------------------------
25
CbmMuchPadRadial::CbmMuchPadRadial
(Int_t address, Double_t r1, Double_t r2, Double_t phi1, Double_t phi2)
26
:
CbmMuchPad
(address, (r1 + r2) / 2. *
cos
((phi1 + phi2) / 2.), (r1 + r2) / 2. *
sin
((phi1 + phi2) / 2.), r2 - r1,
27
r2 - r1)
28
, TCrown(0, 0, r1, r2, phi1 * TMath::RadToDeg(), phi2 * TMath::RadToDeg())
29
, fPhi1(phi1)
30
, fPhi2(phi2)
31
{
32
SetFillColor(kYellow);
33
SetLineWidth(1);
34
SetLineColor(34);
35
}
36
// -------------------------------------------------------------------------
37
38
// -------------------------------------------------------------------------
39
void
CbmMuchPadRadial::SetFired
(Int_t iDigi, Int_t ADCcharge, Int_t nADCChannels)
40
{
41
fDigiIndex
= iDigi;
42
if
(
fDigiIndex
>= 0) SetFillColor(TColor::GetColor(nADCChannels - 1 - ADCcharge, nADCChannels - 1 - ADCcharge, 245));
43
else
44
SetFillColor(kYellow);
45
}
46
// -------------------------------------------------------------------------
47
48
// -------------------------------------------------------------------------
49
void
CbmMuchPadRadial::DrawPad
()
50
{
51
Draw(
"f"
);
52
Draw();
53
}
54
// -------------------------------------------------------------------------
55
56
ClassImp
(
CbmMuchPadRadial
)
ClassImp
ClassImp(CbmConverterManager)
CbmMuchPadRadial.h
cos
friend fvec cos(const fvec &a)
Definition
KfSimdPseudo.h:124
sin
friend fvec sin(const fvec &a)
Definition
KfSimdPseudo.h:123
CbmMuchPadRadial
Definition
CbmMuchPadRadial.h:21
CbmMuchPadRadial::DrawPad
void DrawPad()
Definition
CbmMuchPadRadial.cxx:49
CbmMuchPadRadial::SetFired
void SetFired(Int_t iDigi, Int_t ADCcharge, Int_t nADCChannels=256)
Definition
CbmMuchPadRadial.cxx:39
CbmMuchPadRadial::CbmMuchPadRadial
CbmMuchPadRadial()
Definition
CbmMuchPadRadial.cxx:21
CbmMuchPad
Definition
CbmMuchPad.h:25
CbmMuchPad::fDigiIndex
Int_t fDigiIndex
Definition
CbmMuchPad.h:57
core
detectors
much
CbmMuchPadRadial.cxx
Generated on Sun Dec 22 2024 23:04:09 for CbmRoot by
1.12.0