Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-01-18 10:11:43

0001 // @(#)root/eve:$Id$
0002 // Authors: Matevz Tadel & Alja Mrak-Tadel: 2006, 2007
0003 
0004 /*************************************************************************
0005  * Copyright (C) 1995-2007, Rene Brun and Fons Rademakers.               *
0006  * All rights reserved.                                                  *
0007  *                                                                       *
0008  * For the licensing terms see $ROOTSYS/LICENSE.                         *
0009  * For the list of contributors see $ROOTSYS/README/CREDITS.             *
0010  *************************************************************************/
0011 
0012 #ifndef ROOT_TEveTrackProjected
0013 #define ROOT_TEveTrackProjected
0014 
0015 #include "TEveTrack.h"
0016 #include "TEveProjectionBases.h"
0017 #include <vector>
0018 
0019 class TEveTrackProjected : public TEveTrack,
0020                            public TEveProjected
0021 {
0022    friend class TEveTrackProjectedGL;
0023 
0024 private:
0025    TEveTrackProjected(const TEveTrackProjected&) = delete;
0026    TEveTrackProjected& operator=(const TEveTrackProjected&) = delete;
0027 
0028    Int_t GetBreakPointIdx(Int_t start);
0029 
0030    TEveVector*          fOrigPnts;     // original track points
0031 
0032 protected:
0033    std::vector<Int_t>   fBreakPoints; // indices of track break-points
0034 
0035    void SetDepthLocal(Float_t d) override;
0036 
0037 public:
0038    TEveTrackProjected();
0039    ~TEveTrackProjected() override {}
0040 
0041    void SetProjection(TEveProjectionManager* mng, TEveProjectable* model) override;
0042 
0043    void UpdateProjection() override;
0044    TEveElement* GetProjectedAsElement() override { return this; }
0045    void MakeTrack(Bool_t recurse=kTRUE) override;
0046 
0047 
0048    void         PrintLineSegments();
0049 
0050    void SecSelected(TEveTrack*) override; // marked as signal in TEveTrack
0051 
0052    ClassDefOverride(TEveTrackProjected, 0); // Projected copy of a TEveTrack.
0053 };
0054 
0055 
0056 /******************************************************************************/
0057 // TEveTrackListProjected
0058 /******************************************************************************/
0059 
0060 class TEveTrackListProjected : public TEveTrackList,
0061                                public TEveProjected
0062 {
0063 private:
0064    TEveTrackListProjected(const TEveTrackListProjected&);            // Not implemented
0065    TEveTrackListProjected& operator=(const TEveTrackListProjected&); // Not implemented
0066 
0067 protected:
0068    void SetDepthLocal(Float_t d) override;
0069 
0070 public:
0071    TEveTrackListProjected();
0072    ~TEveTrackListProjected() override {}
0073 
0074    void SetProjection(TEveProjectionManager* proj, TEveProjectable* model) override;
0075    void UpdateProjection() override  {}
0076    TEveElement* GetProjectedAsElement() override { return this; }
0077 
0078    void SetDepth(Float_t d) override;
0079    virtual void SetDepth(Float_t d, TEveElement* el);
0080 
0081    ClassDefOverride(TEveTrackListProjected, 0); // Specialization of TEveTrackList for holding TEveTrackProjected objects.
0082 };
0083 
0084 #endif