#ifndef ROOT_TEveProjections
#define ROOT_TEveProjections
#include "TEveVSDStructs.h"
class TEveProjection
{
public:
enum EPType_e { kPT_Unknown, kPT_CFishEye, kPT_RhoZ };
enum EPProc_e { kPP_Plane, kPP_Distort, kPP_Full };
enum EGeoMode_e { kGM_Unknown, kGM_Polygons, kGM_Segments };
protected:
EPType_e fType;
EGeoMode_e fGeoMode;
TString fName;
TEveVector fCenter;
TEveVector fZeroPosVal;
Float_t fDistortion;
Float_t fFixedRadius;
Float_t fScale;
TEveVector fUpLimit;
TEveVector fLowLimit;
public:
TEveProjection(TEveVector& center);
virtual ~TEveProjection(){}
virtual void ProjectPoint(Float_t&, Float_t&, Float_t&, EPProc_e p = kPP_Full ) = 0;
virtual void ProjectPointFv(Float_t* v){ ProjectPoint(v[0], v[1], v[2]); }
virtual void ProjectVector(TEveVector& v);
const char* GetName() { return fName.Data(); }
void SetName(const char* txt) { fName = txt; }
virtual void SetCenter(TEveVector& v) { fCenter = v; UpdateLimit(); }
virtual Float_t* GetProjectedCenter() { return fCenter.Arr(); }
void SetType(EPType_e t) { fType = t; }
EPType_e GetType() { return fType; }
void SetGeoMode(EGeoMode_e m) { fGeoMode = m; }
EGeoMode_e GetGeoMode() { return fGeoMode; }
void UpdateLimit();
void SetDistortion(Float_t d);
Float_t GetDistortion() { return fDistortion; }
void SetFixedRadius(Float_t x);
Float_t GetFixedRadius() { return fFixedRadius; }
virtual Bool_t AcceptSegment(TEveVector&, TEveVector&, Float_t ) { return kTRUE; }
virtual void SetDirectionalVector(Int_t screenAxis, TEveVector& vec);
virtual Float_t GetValForScreenPos(Int_t ax, Float_t value);
virtual Float_t GetScreenVal(Int_t ax, Float_t value);
Float_t GetLimit(Int_t i, Bool_t pos) { return pos ? fUpLimit[i] : fLowLimit[i]; }
static Float_t fgEps;
ClassDef(TEveProjection, 0);
};
class TEveRhoZProjection: public TEveProjection
{
private:
TEveVector fProjectedCenter;
public:
TEveRhoZProjection(TEveVector& center) : TEveProjection(center) { fType = kPT_RhoZ; fName="RhoZ"; }
virtual ~TEveRhoZProjection() {}
virtual Bool_t AcceptSegment(TEveVector& v1, TEveVector& v2, Float_t tolerance);
virtual void ProjectPoint(Float_t& x, Float_t& y, Float_t& z, EPProc_e proc = kPP_Full);
virtual void SetDirectionalVector(Int_t screenAxis, TEveVector& vec);
virtual void SetCenter(TEveVector& center);
virtual Float_t* GetProjectedCenter() { return fProjectedCenter.Arr(); }
ClassDef(TEveRhoZProjection, 0);
};
class TEveCircularFishEyeProjection : public TEveProjection
{
public:
TEveCircularFishEyeProjection(TEveVector& center):TEveProjection(center) { fType = kPT_CFishEye; fGeoMode = kGM_Polygons; fName="CircularFishEye"; }
virtual ~TEveCircularFishEyeProjection() {}
virtual void ProjectPoint(Float_t& x, Float_t& y, Float_t& z, EPProc_e proc = kPP_Full);
ClassDef(TEveCircularFishEyeProjection, 0);
};
#endif
Last update: Thu Jan 17 08:49:15 2008
This page has been automatically generated. If you have any comments or suggestions about the page layout send a mail to ROOT support, or contact the developers with any questions or problems regarding ROOT.