Main Page
Namespaces
Classes
Package Documentation
Fireworks
Calo
plugins
FWHFRecHitProxyBuilder.cc
Go to the documentation of this file.
1
#include "
DataFormats/HcalRecHit/interface/HcalRecHitCollections.h
"
2
#include "
Fireworks/Calo/plugins/FWCaloRecHitDigitSetProxyBuilder.h
"
3
4
class
FWHFRecHitProxyBuilder
:
public
FWCaloRecHitDigitSetProxyBuilder
{
5
public
:
6
FWHFRecHitProxyBuilder
(
void
) {
invertBox
(
true
); }
7
~FWHFRecHitProxyBuilder
(
void
)
override
{}
8
9
REGISTER_PROXYBUILDER_METHODS
();
10
11
private
:
12
FWHFRecHitProxyBuilder
(
const
FWHFRecHitProxyBuilder
&) =
delete
;
13
const
FWHFRecHitProxyBuilder
&
operator=
(
const
FWHFRecHitProxyBuilder
&) =
delete
;
14
};
15
16
REGISTER_FWPROXYBUILDER
(
FWHFRecHitProxyBuilder
,
HFRecHitCollection
,
"HF RecHit"
,
FWViewType::kISpyBit
);
17
18
// AMT: Reflect box. Previously used energyScaledBox3DCorners(). Scaling and e/et mode added now.
19
20
/*
21
void
22
FWHFRecHitProxyBuilder::build( const FWEventItem* iItem, TEveElementList* product, const FWViewContext* )
23
{
24
const HFRecHitCollection* collection = 0;
25
iItem->get( collection );
26
27
if( 0 == collection )
28
{
29
return;
30
}
31
32
std::vector<HFRecHit>::const_iterator it = collection->begin();
33
std::vector<HFRecHit>::const_iterator itEnd = collection->end();
34
for( ; it != itEnd; ++it )
35
{
36
if(( *it ).energy() > m_maxEnergy )
37
m_maxEnergy = ( *it ).energy();
38
}
39
40
TEveBoxSet* boxSet = addBoxSetToProduct(product);
41
int index = 0;
42
for (std::vector<HFRecHit>::const_iterator it = collection->begin() ; it != collection->end(); ++it)
43
{
44
unsigned int rawid = ( *it ).detid().rawId();
45
if( ! context().getGeom()->contains( rawid ))
46
{
47
fwLog( fwlog::kInfo ) << "FWHFRecHitProxyBuilder cannot get geometry for DetId: "
48
<< rawid << ". Ignored.\n";
49
}
50
const float* corners = context().getGeom()->getCorners( rawid );
51
52
std::vector<float> scaledCorners(24);
53
if (corners)
54
fireworks::energyScaledBox3DCorners(corners, (*it).energy() / m_maxEnergy, scaledCorners, true);
55
56
addBox(boxSet, &scaledCorners[0], iItem->modelInfo(index++).displayProperties());
57
}
58
}
59
*/
FWViewType::kISpyBit
Definition:
FWViewType.h:54
edm::SortedCollection
Definition:
SortedCollection.h:51
FWCaloRecHitDigitSetProxyBuilder::invertBox
virtual void invertBox(bool x)
Definition:
FWCaloRecHitDigitSetProxyBuilder.h:21
FWCaloRecHitDigitSetProxyBuilder
Definition:
FWCaloRecHitDigitSetProxyBuilder.h:9
FWCaloRecHitDigitSetProxyBuilder.h
FWHFRecHitProxyBuilder::FWHFRecHitProxyBuilder
FWHFRecHitProxyBuilder(void)
Definition:
FWHFRecHitProxyBuilder.cc:6
REGISTER_PROXYBUILDER_METHODS
#define REGISTER_PROXYBUILDER_METHODS()
Definition:
register_dataproxybuilder_macro.h:28
REGISTER_FWPROXYBUILDER
#define REGISTER_FWPROXYBUILDER(_name_, _type_, _purpose_, _view_)
Definition:
FWProxyBuilderFactory.h:33
HcalRecHitCollections.h
FWHFRecHitProxyBuilder::operator=
const FWHFRecHitProxyBuilder & operator=(const FWHFRecHitProxyBuilder &)=delete
FWHFRecHitProxyBuilder::~FWHFRecHitProxyBuilder
~FWHFRecHitProxyBuilder(void) override
Definition:
FWHFRecHitProxyBuilder.cc:7
FWHFRecHitProxyBuilder
Definition:
FWHFRecHitProxyBuilder.cc:4
Generated for CMSSW Reference Manual by
1.8.11