ATLAS Offline Software
Toggle main menu visibility
Loading...
Searching...
No Matches
graphics
VP1
VP1Systems
VP1RawDataSystems
src
VP1RawDataHandle_PixelRDO.cxx
Go to the documentation of this file.
1
/*
2
Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
3
*/
4
6
// //
7
// Implementation of class VP1RawDataHandle_PixelRDO //
8
// //
9
// Author: Thomas H. Kittelmann (Thomas.Kittelmann@cern.ch) //
10
// Initial version: April 2008 (rewritten January 2009) //
11
// //
13
14
#include "
VP1RawDataSystems/VP1RawDataHandle_PixelRDO.h
"
15
#include "
VP1RawDataSystems/VP1RawDataCommonData.h
"
16
#include "
VP1Utils/HitsSoNodeManager.h
"
17
#include "
VP1Utils/VP1DetInfo.h
"
18
#include "
VP1Utils/VP1LinAlgUtils.h
"
19
20
#include "
PixelReadoutGeometry/PixelDetectorManager.h
"
21
#include "
InDetReadoutGeometry/SiDetectorElement.h
"
22
#include "
InDetRawData/PixelRDORawData.h
"
23
#include "
InDetIdentifier/PixelID.h
"
24
25
#include "
GeoPrimitives/GeoPrimitives.h
"
26
27
28
//____________________________________________________________________
29
VP1RawDataHandle_PixelRDO::VP1RawDataHandle_PixelRDO
(
VP1RawDataCollBase
*
coll
,
const
PixelRDORawData
*data)
30
:
VP1RawDataHandleBase
(
coll
),
m_data
(data)
31
{
32
}
33
34
//____________________________________________________________________
35
VP1RawDataHandle_PixelRDO::~VP1RawDataHandle_PixelRDO
()
36
{
37
}
38
39
//____________________________________________________________________
40
QStringList
VP1RawDataHandle_PixelRDO::clicked
(
bool
verbose
)
const
41
{
42
static
const
PixelID
* idhelper =
VP1DetInfo::pixelIDHelper
();
43
QStringList l;
44
l <<
" ===> PixelRDORawData"
;
45
l <<
" Data word: "
+
unsignedToHex
(
m_data
->getWord());
46
if
(
verbose
) {
47
if
(idhelper) {
48
//Fixme: We should have common identify -> QStringList method in VP1DetInfo!!
49
Identifier
id(
m_data
->identify());
50
const
bool
barrel
= idhelper->
is_barrel
(
id
);
51
l <<
" Barrel: "
+QString(
barrel
?
"Yes"
:
"No"
);
52
l <<
" B-Layer: "
+QString(idhelper->
is_blayer
(
id
)?
"Yes"
:
"No"
);
53
l <<
" "
+QString(
barrel
?
"Layer"
:
"Disk"
)+
": "
+QString::number(idhelper->
layer_disk
(
id
));
54
l <<
" Phi module: "
+QString::number(idhelper->
phi_module
(
id
));
55
l <<
" Eta module: "
+QString::number(idhelper->
eta_module
(
id
));
56
l <<
" Phi index: "
+QString::number(idhelper->
phi_index
(
id
));
57
l <<
" Eta index: "
+QString::number(idhelper->
eta_index
(
id
));
58
}
59
l <<
" Time over Threshold (0..255): "
+QString::number(
m_data
->getToT());
60
l <<
" Beam Crossing ID: "
+QString::number(
m_data
->getBCID());
61
l <<
" Level 1 accept (0..15): "
+QString::number(
m_data
->getLVL1A());
62
l <<
" ATLAS LVL1 ID (0-255): "
+QString::number(
m_data
->getLVL1ID());
63
}
64
return
l;
65
}
66
67
//____________________________________________________________________
68
SoNode *
VP1RawDataHandle_PixelRDO::buildShape
()
69
{
70
return
common
()->
nodeManager
()->
getShapeNode_Point
();
71
}
72
73
//____________________________________________________________________
74
SoTransform *
VP1RawDataHandle_PixelRDO::buildTransform
()
75
{
76
//Fixme: Do we need more?
77
const
InDetDD::SiDetectorElement
* elem =
element
();
78
if
(!elem)
79
return
common
()->
nodeManager
()->
getUnitTransform
();
//fixme: warn
80
Amg::Vector2D
localpos = elem->rawLocalPositionOfCell(
m_data
->identify());
//Fixme:raw or lorentz corrected?? Make it option?
81
82
// return VP1LinAlgUtils::toSoTransform(elem->transform() * HepGeom::Translate3D(localpos.x(),localpos.y(),0));
83
Amg::Transform3D
transf = elem->transform();
84
transf = transf *
Amg::Translation3D
(localpos.x(),localpos.y(),0);
85
return
VP1LinAlgUtils::toSoTransform
( transf );
86
}
87
88
//____________________________________________________________________
89
const
InDetDD::SiDetectorElement
*
VP1RawDataHandle_PixelRDO::element
()
const
90
{
91
const
InDetDD::PixelDetectorManager
* detmgr =
VP1DetInfo::pixelDetMgr
();
92
if
(!detmgr)
93
return
0;
94
return
detmgr->
getDetectorElement
(
m_data
->identify());
95
}
96
97
// //____________________________________________________________________
98
// SoMaterial * VP1RawDataHandle_PixelRDO::determineMaterial() const
99
// {
100
// return common()->pixelMaterial();
101
// }
102
103
//____________________________________________________________________
104
VP1RawDataFlags::InDetPartsFlags
VP1RawDataHandle_PixelRDO::inInDetParts
()
const
105
{
106
const
InDetDD::SiDetectorElement
* elem =
element
();
107
if
(!elem)
108
return
VP1RawDataFlags::All
;
109
if
(elem->center().z()>=0)
110
return
elem->isBarrel() ?
VP1RawDataFlags::BarrelPositive
:
VP1RawDataFlags::EndCapPositive
;
111
else
112
return
elem->isBarrel() ?
VP1RawDataFlags::BarrelNegative
:
VP1RawDataFlags::EndCapNegative
;
113
114
}
DetectorZone::barrel
@ barrel
Definition
FPGATrackSimTypes.h:28
GeoPrimitives.h
HitsSoNodeManager.h
PixelDetectorManager.h
PixelID.h
This is an Identifier helper class for the Pixel subdetector.
PixelRDORawData.h
SiDetectorElement.h
VP1DetInfo.h
VP1LinAlgUtils.h
VP1RawDataCommonData.h
VP1RawDataHandle_PixelRDO.h
HitsSoNodeManager::getShapeNode_Point
SoNode * getShapeNode_Point()
Definition
HitsSoNodeManager.cxx:412
HitsSoNodeManager::getUnitTransform
SoTransform * getUnitTransform()
Definition
HitsSoNodeManager.cxx:456
InDetDD::PixelDetectorManager
Dedicated detector manager extending the functionality of the SiDetectorManager with dedicated pixel ...
Definition
PixelDetectorManager.h:47
InDetDD::PixelDetectorManager::getDetectorElement
virtual const SiDetectorElement * getDetectorElement(const Identifier &id) const override
access to individual elements : via Identifier
Definition
PixelDetectorManager.cxx:75
InDetDD::SiDetectorElement
Class to hold geometrical description of a silicon detector element.
Definition
SiDetectorElement.h:109
PixelID
This is an Identifier helper class for the Pixel subdetector.
Definition
PixelID.h:69
PixelID::eta_index
int eta_index(const Identifier &id) const
Definition
PixelID.h:640
PixelID::layer_disk
int layer_disk(const Identifier &id) const
Definition
PixelID.h:602
PixelID::eta_module
int eta_module(const Identifier &id) const
Definition
PixelID.h:627
PixelID::phi_index
int phi_index(const Identifier &id) const
Definition
PixelID.h:634
PixelID::is_blayer
bool is_blayer(const Identifier &id) const
Test for b-layer - WARNING: id MUST be pixel id, otherwise answer is not accurate....
Definition
PixelID.h:609
PixelID::phi_module
int phi_module(const Identifier &id) const
Definition
PixelID.h:620
PixelID::is_barrel
bool is_barrel(const Identifier &id) const
Test for barrel - WARNING: id MUST be pixel id, otherwise answer is not accurate. Use SiliconID for g...
Definition
PixelID.h:581
PixelRDORawData
Definition
PixelRDORawData.h:23
VP1DetInfo::pixelDetMgr
static const InDetDD::PixelDetectorManager * pixelDetMgr()
Definition
VP1DetInfo.cxx:145
VP1DetInfo::pixelIDHelper
static const PixelID * pixelIDHelper()
Definition
VP1DetInfo.cxx:164
VP1LinAlgUtils::toSoTransform
static SoTransform * toSoTransform(const HepGeom::Transform3D &, SoTransform *t=0)
Definition
VP1LinAlgUtils.cxx:40
VP1RawDataCollBase
Definition
VP1RawDataCollBase.h:29
VP1RawDataCommonData::nodeManager
HitsSoNodeManager * nodeManager() const
Definition
VP1RawDataCommonData.h:42
VP1RawDataFlags::EndCapPositive
@ EndCapPositive
Definition
VP1RawDataFlags.h:27
VP1RawDataFlags::EndCapNegative
@ EndCapNegative
Definition
VP1RawDataFlags.h:28
VP1RawDataFlags::All
@ All
Definition
VP1RawDataFlags.h:31
VP1RawDataFlags::BarrelPositive
@ BarrelPositive
Definition
VP1RawDataFlags.h:25
VP1RawDataFlags::BarrelNegative
@ BarrelNegative
Definition
VP1RawDataFlags.h:26
VP1RawDataHandleBase::common
VP1RawDataCommonData * common() const
Definition
VP1RawDataHandleBase.h:41
VP1RawDataHandleBase::VP1RawDataHandleBase
VP1RawDataHandleBase(VP1RawDataCollBase *)
Definition
VP1RawDataHandleBase.cxx:50
VP1RawDataHandleBase::unsignedToHex
static QString unsignedToHex(unsigned)
Definition
VP1RawDataHandleBase.cxx:158
VP1RawDataHandleBase::coll
VP1RawDataCollBase * coll() const
Definition
VP1RawDataHandleBase.h:40
VP1RawDataHandle_PixelRDO::buildTransform
SoTransform * buildTransform()
Definition
VP1RawDataHandle_PixelRDO.cxx:74
VP1RawDataHandle_PixelRDO::buildShape
SoNode * buildShape()
Definition
VP1RawDataHandle_PixelRDO.cxx:68
VP1RawDataHandle_PixelRDO::VP1RawDataHandle_PixelRDO
VP1RawDataHandle_PixelRDO(VP1RawDataCollBase *, const PixelRDORawData *)
Definition
VP1RawDataHandle_PixelRDO.cxx:29
VP1RawDataHandle_PixelRDO::inInDetParts
VP1RawDataFlags::InDetPartsFlags inInDetParts() const
Definition
VP1RawDataHandle_PixelRDO.cxx:104
VP1RawDataHandle_PixelRDO::m_data
const PixelRDORawData * m_data
Definition
VP1RawDataHandle_PixelRDO.h:37
VP1RawDataHandle_PixelRDO::~VP1RawDataHandle_PixelRDO
virtual ~VP1RawDataHandle_PixelRDO()
Definition
VP1RawDataHandle_PixelRDO.cxx:35
VP1RawDataHandle_PixelRDO::clicked
QStringList clicked(bool verbose) const
Definition
VP1RawDataHandle_PixelRDO.cxx:40
VP1RawDataHandle_PixelRDO::element
const InDetDD::SiDetectorElement * element() const
Definition
VP1RawDataHandle_PixelRDO.cxx:89
verbose
bool verbose
Definition
hcg.cxx:75
Amg::Transform3D
Eigen::Affine3d Transform3D
Definition
GeoPrimitives.h:46
Amg::Vector2D
Eigen::Matrix< double, 2, 1 > Vector2D
Definition
GeoPrimitives.h:49
Amg::Translation3D
Eigen::Translation< double, 3 > Translation3D
Definition
GeoPrimitives.h:44
Identifier
Definition
IdentifierFieldParser.cxx:14
Generated on
for ATLAS Offline Software by
1.17.0