Fireworks
Electrons
plugins
FWPhotonLegoProxyBuilder.cc
Go to the documentation of this file.
1
// -*- C++ -*-
2
//
3
// Package: Muons
4
// Class : FWPhotonLegoProxyBuilder
5
//
6
//
7
8
#include "TEveStraightLineSet.h"
9
10
#include "
Fireworks/Core/interface/FWSimpleProxyBuilderTemplate.h
"
11
12
#include "
DataFormats/EgammaCandidates/interface/Photon.h
"
13
14
class
FWPhotonLegoProxyBuilder
:
public
FWSimpleProxyBuilderTemplate
<reco::Photon> {
15
public
:
16
FWPhotonLegoProxyBuilder
() {}
17
~FWPhotonLegoProxyBuilder
()
override
{}
18
19
REGISTER_PROXYBUILDER_METHODS
();
20
21
private
:
22
FWPhotonLegoProxyBuilder
(
const
FWPhotonLegoProxyBuilder
&) =
delete
;
23
const
FWPhotonLegoProxyBuilder
&
operator=
(
const
FWPhotonLegoProxyBuilder
&) =
delete
;
24
25
using
FWSimpleProxyBuilderTemplate<reco::Photon>::build
;
26
void
build
(
const
reco::Photon
& iData,
unsigned
int
iIndex, TEveElement& oItemHolder,
const
FWViewContext
*)
override
;
27
};
28
29
void
FWPhotonLegoProxyBuilder::build
(
const
reco::Photon
& iData,
30
unsigned
int
iIndex,
31
TEveElement& oItemHolder,
32
const
FWViewContext
*) {
33
TEveStraightLineSet* marker =
new
TEveStraightLineSet(
"marker"
);
34
setupAddElement
(marker, &oItemHolder);
35
36
const
double
delta
= 0.1;
37
marker->AddLine(iData.
eta
() -
delta
, iData.
phi
() -
delta
, 0.1, iData.
eta
() +
delta
, iData.
phi
() +
delta
, 0.1);
38
marker->AddLine(iData.
eta
() -
delta
, iData.
phi
() +
delta
, 0.1, iData.
eta
() +
delta
, iData.
phi
() -
delta
, 0.1);
39
}
40
41
REGISTER_FWPROXYBUILDER
(
FWPhotonLegoProxyBuilder
,
reco::Photon
,
"Photons"
,
FWViewType::kAllLegoBits
);
FWSimpleProxyBuilderTemplate.h
REGISTER_FWPROXYBUILDER
#define REGISTER_FWPROXYBUILDER(_name_, _type_, _purpose_, _view_)
Definition:
FWProxyBuilderFactory.h:33
REGISTER_PROXYBUILDER_METHODS
#define REGISTER_PROXYBUILDER_METHODS()
Definition:
register_dataproxybuilder_macro.h:27
FWPhotonLegoProxyBuilder::FWPhotonLegoProxyBuilder
FWPhotonLegoProxyBuilder()
Definition:
FWPhotonLegoProxyBuilder.cc:16
Photon.h
FWPhotonLegoProxyBuilder
Definition:
FWPhotonLegoProxyBuilder.cc:14
FWViewType::kAllLegoBits
static const int kAllLegoBits
Definition:
FWViewType.h:69
reco::LeafCandidate::eta
double eta() const final
momentum pseudorapidity
Definition:
LeafCandidate.h:152
dumpMFGeometry_cfg.delta
delta
Definition:
dumpMFGeometry_cfg.py:25
FWProxyBuilderBase::setupAddElement
void setupAddElement(TEveElement *el, TEveElement *parent, bool set_color=true) const
Definition:
FWProxyBuilderBase.cc:350
FWProxyBuilderBase::build
void build()
Definition:
FWProxyBuilderBase.cc:110
FWViewContext
Definition:
FWViewContext.h:32
reco::Photon
Definition:
Photon.h:22
reco::LeafCandidate::phi
double phi() const final
momentum azimuthal angle
Definition:
LeafCandidate.h:148
FWPhotonLegoProxyBuilder::operator=
const FWPhotonLegoProxyBuilder & operator=(const FWPhotonLegoProxyBuilder &)=delete
FWSimpleProxyBuilderTemplate
Definition:
FWSimpleProxyBuilderTemplate.h:30
FWPhotonLegoProxyBuilder::~FWPhotonLegoProxyBuilder
~FWPhotonLegoProxyBuilder() override
Definition:
FWPhotonLegoProxyBuilder.cc:17
Generated for CMSSW Reference Manual by
1.8.16