Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2021-02-14 13:27:29

0001 #ifndef _FWPFRHOPHIRECHIT_H_
0002 #define _FWPFRHOPHIRECHIT_H_
0003 
0004 // -*- C++ -*-
0005 //
0006 // Package:     ParticleFlow
0007 // Class  :     FWPFRhoPhiRecHit
0008 //
0009 // Implementation:
0010 //     <Notes on implementation>
0011 //
0012 // Original Author:  Simon Harris
0013 //
0014 
0015 // System include files
0016 #include <cmath>
0017 #include "TEveScalableStraightLineSet.h"
0018 #include "TEveCompound.h"
0019 
0020 // User include files
0021 #include "Fireworks/Core/interface/FWProxyBuilderBase.h"
0022 #include "Fireworks/Core/interface/FWViewContext.h"
0023 #include "Fireworks/Core/interface/FWViewEnergyScale.h"
0024 
0025 //-----------------------------------------------------------------------------
0026 // FWPFRhoPhiRecHit
0027 //-----------------------------------------------------------------------------
0028 class FWPFRhoPhiRecHit {
0029 public:
0030   // ---------------- Constructor(s)/Destructor ----------------------
0031   FWPFRhoPhiRecHit(FWProxyBuilderBase *pb,
0032                    TEveElement *iH,
0033                    const FWViewContext *vc,
0034                    float E,
0035                    float et,
0036                    double lPhi,
0037                    double rPhi,
0038                    std::vector<TEveVector> &bCorners);
0039   virtual ~FWPFRhoPhiRecHit();
0040 
0041   // --------------------- Member Functions --------------------------
0042   void updateScale(TEveScalableStraightLineSet *ls, Double_t scale, unsigned int i);
0043   void updateScale(const FWViewContext *vc);
0044   void addChild(FWProxyBuilderBase *pb, TEveElement *itemHolder, const FWViewContext *vc, float E, float et);
0045   void buildRecHit(FWProxyBuilderBase *pb,
0046                    TEveElement *itemHolder,
0047                    const FWViewContext *vc,
0048                    std::vector<TEveVector> &bCorners);
0049   void clean();
0050 
0051   // ----------------------Accessor Methods --------------------------
0052   Double_t getlPhi() { return m_lPhi; }
0053   TEveScalableStraightLineSet *getLineSet() { return m_ls; }
0054   void setHasChild(bool b) { m_hasChild = b; }
0055   void setCorners(int i, TEveVector vec) { m_corners[i] = vec; }
0056 
0057 private:
0058   FWPFRhoPhiRecHit(const FWPFRhoPhiRecHit &);             // Stop default copy constructor
0059   FWPFRhoPhiRecHit &operator=(const FWPFRhoPhiRecHit &);  // Stop default assignment operator
0060 
0061   // ----------------------- Data Members ----------------------------
0062   bool m_hasChild;
0063   float m_energy;
0064   float m_et;
0065   Double_t m_lPhi;
0066   Double_t m_rPhi;
0067   TEveScalableStraightLineSet *m_ls;
0068   FWPFRhoPhiRecHit *m_child;
0069   std::vector<TEveVector> m_corners;
0070 };
0071 #endif
0072 //=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_=_