7 #include "TEvePointSet.h"
9 #include "TEveViewer.h"
10 #include "TGLViewer.h"
12 #include "TEveCaloLegoOverlay.h"
65 TEveCaloLegoOverlay* overlay =
new TEveCaloLegoOverlay();
66 overlay->SetShowPlane(kFALSE);
67 overlay->SetShowPerspective(kFALSE);
68 overlay->SetCaloLego(lego);
69 overlay->SetShowScales(1);
70 viewerGL()->AddOverlayElement(overlay);
73 viewerGL()->SetCurrentCamera(TGLViewer::kCameraOrthoXOY);
80 viewerGL()->RequestDraw(TGLRnrCtx::kLODHigh);
93 TLatex* latex =
new TLatex(x, y,
"");
94 const double textsize(0.05);
95 latex->SetTextSize(2*textsize);
97 float h = latex->GetTextSize()*0.6;
98 latex->DrawLatex(x, y,
id.
item()->modelName(
id.
index()).c_str() );
101 latex->DrawLatex(x, y, Form(
" E_{T} = %.1f GeV, #eta = %0.2f, #varphi = %0.2f",
102 photon->
et(), photon->
eta(), photon->
phi()) );
112 unsigned int subdetId(0);
113 if ( !i->
superCluster()->seed()->hitsAndFractions().empty() )
114 subdetId = i->
superCluster()->seed()->hitsAndFractions().front().first.subdetId();
117 Double_t
x(0),
y(0),
z(0);
118 TEvePointSet *scposition =
new TEvePointSet(
"sc position");
119 scposition->SetPickable(kTRUE);
120 scposition->SetTitle(
"Super cluster centroid");
128 scposition->SetNextPoint(
x,
y,z);
129 scposition->SetMarkerSize(1);
130 scposition->SetMarkerStyle(4);
131 scposition->SetMarkerColor(kBlue);
132 tList->AddElement(scposition);
135 TEvePointSet *seedposition =
new TEvePointSet(
"seed position");
136 seedposition->SetTitle(
"Seed cluster centroid");
137 seedposition->SetPickable(kTRUE);
141 seedposition->SetMarkerSize(0.01);
145 seedposition->SetMarkerSize(1);
147 seedposition->SetNextPoint(
x,
y, z);
148 seedposition->SetMarkerStyle(2);
149 seedposition->SetMarkerColor(kRed);
150 tList->AddElement(seedposition);
void showSuperCluster(const reco::SuperCluster &cluster, Color_t color=kYellow)
TGLViewer * viewerGL() const
double makeLegend(double x0=0.02, double y0=0.95, Color_t clustered1=kGreen+1, Color_t clustered2=kTeal, Color_t supercluster=kYellow)
virtual double et() const
transverse energy
virtual float phi() const
momentum azimuthal angle
const FWEventItem * item()
reco::SuperClusterRef superCluster() const
Ref to SuperCluster.
virtual ~FWPhotonDetailView()
FWECALDetailViewBuilder * m_builder
virtual float eta() const
momentum pseudorapidity
The Signals That Services Can Subscribe To This is based on ActivityRegistry h
Helper function to determine trigger accepts.
math::XYZPointF caloPosition() const
position in ECAL: this is th SC position if r9<0.93. If r8>0.93 is position of seed BasicCluster taki...
virtual void build(const FWModelId &id, const reco::Photon *)
void showSuperClusters(Color_t color1=kGreen+2, Color_t color2=kTeal)
void addSceneInfo(const reco::Photon *, TEveElementList *)
virtual void setTextInfo(const FWModelId &id, const reco::Photon *)
#define REGISTER_FWDETAILVIEW(_classname_, _name_)