CMS 3D CMS Logo

FWPFBlockProxyBuilder.h
Go to the documentation of this file.
1 #ifndef _FWPFBLOCKPROXYBUILDER_H_
2 #define _FWPFBLOCKPROXYBUILDER_H_
3 
4 // -*- C++ -*-
5 //
6 // Package: ParticleFlow
7 // Class : FWPFBlockProxyBuilder
8 //
9 // Implementation:
10 // <Notes on implementation>
11 //
12 // Original Author: Simon Harris
13 // Created: 14/02/2011
14 //
15 
16 // System include files
17 #include <cmath>
18 #include "TEveScalableStraightLineSet.h"
19 
20 // User include files
24 
28 
31 
32 //-----------------------------------------------------------------------------
33 // FWPFBlockProxyBuilder
34 //-----------------------------------------------------------------------------
35 class FWPFBlockProxyBuilder : public FWSimpleProxyBuilderTemplate<reco::PFBlock> {
36 public:
37  enum BuilderType { BASE = 0, ECAL = 1, HCAL = 2 };
38 
39  // ---------------- Constructor(s)/Destructor ----------------------
41  ~FWPFBlockProxyBuilder() override {}
42 
44 
45 protected:
46  // --------------------- Member Functions --------------------------
47  void setupTrackElement(const reco::PFBlockElement&, TEveElement&, const FWViewContext*, FWViewType::EType);
48  void setupClusterElement(const reco::PFBlockElement&, TEveElement&, const FWViewContext*, FWViewType::EType, float r);
49  void clusterSharedBuild(const reco::PFCluster&, TEveElement&, const FWViewContext*);
50 
52  bool havePerViewProduct(FWViewType::EType) const override { return true; }
53 
55  bool haveSingleProduct() const override { return false; } // different view types
56 
58  void scaleProduct(TEveElementList* parent, FWViewType::EType, const FWViewContext* vc) override;
59 
61  void cleanLocal() override { m_clusters.clear(); }
62 
64  void buildViewType(const reco::PFBlock&, unsigned int, TEveElement&, FWViewType::EType, const FWViewContext*) override;
65 
66  // ----------------------- Data Members ----------------------------
68  std::vector<ScalableLines> m_clusters;
69 
70 private:
73 };
74 //=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_
75 
76 //-----------------------------------------------------------------------------
77 // FWPFBlockEcalProxyBuilder
78 //-----------------------------------------------------------------------------
80 public:
83 
85 
86 private:
89 };
90 //=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_
91 
92 //-----------------------------------------------------------------------------
93 // FWPFBlockHcalProxyBuilder
94 //-----------------------------------------------------------------------------
96 public:
99 
101 
102 private:
105 };
106 #endif
107 //=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_
Abstract base class for a PFBlock element (track, cluster...)
virtual void scaleProduct(TEveElementList *parent, FWViewType::EType, const FWViewContext *vc)
void setupTrackElement(const reco::PFBlockElement &, TEveElement &, const FWViewContext *, FWViewType::EType)
void setupClusterElement(const reco::PFBlockElement &, TEveElement &, const FWViewContext *, FWViewType::EType, float r)
Particle flow cluster, see clustering algorithm in PFClusterAlgo.
Definition: PFCluster.h:46
virtual bool havePerViewProduct(FWViewType::EType) const
std::vector< ScalableLines > m_clusters
virtual void cleanLocal()
void clusterSharedBuild(const reco::PFCluster &, TEveElement &, const FWViewContext *)
bool havePerViewProduct(FWViewType::EType) const override
Definition: HCAL.py:1
virtual bool haveSingleProduct() const
void scaleProduct(TEveElementList *parent, FWViewType::EType, const FWViewContext *vc) override
#define REGISTER_PROXYBUILDER_METHODS()
const FWPFBlockProxyBuilder & operator=(const FWPFBlockProxyBuilder &)
void buildViewType(const reco::PFBlock &, unsigned int, TEveElement &, FWViewType::EType, const FWViewContext *) override
bool haveSingleProduct() const override
Block of elements.
Definition: PFBlock.h:26