Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014 #ifndef TGO4WINCOND_H
00015 #define TGO4WINCOND_H
00016
00017 #include "TGo4Condition.h"
00018
00019 class TH1;
00020
00021 class TGo4WinCond : public TGo4Condition {
00022 public:
00023 TGo4WinCond();
00024
00025 TGo4WinCond(const char* name, const char* title = "Go4 window condition");
00026
00027 virtual ~TGo4WinCond();
00028
00030 virtual TGo4ConditionPainter* CreatePainter();
00031
00035 virtual void SetPainter(TGo4ConditionPainter* painter);
00036
00037
00038
00039
00040
00042 virtual void SetValues(Double_t low1, Double_t up1);
00043
00045 virtual void SetValues(Double_t low1, Double_t up1, Double_t low2, Double_t up2);
00046
00047
00048
00049
00051 virtual Bool_t Test(Double_t v1);
00052
00055 virtual Bool_t Test(Double_t v1, Double_t v2);
00056
00058 virtual void GetValues(Int_t & dim, Double_t & x1, Double_t & y1, Double_t & x2, Double_t & y2);
00059
00060 inline virtual Double_t GetXLow(){return fLow1;}
00061 inline virtual Double_t GetXUp() {return fUp1;}
00062 inline virtual Double_t GetYLow(){return fLow2;}
00063 inline virtual Double_t GetYUp() {return fUp2;}
00064
00066 virtual void PrintCondition(Bool_t full = kTRUE);
00067
00069 Bool_t UpdateFrom(TGo4Condition * cond, Bool_t counts);
00070
00072 virtual Double_t GetIntegral(TH1* histo, Option_t* opt="");
00073
00075 virtual Double_t GetMean(TH1* histo, Int_t axis=1);
00076
00078 virtual Double_t GetRMS(TH1* histo, Int_t axis=1);
00079
00081 virtual Double_t GetXMax(TH1* histo);
00082
00084 virtual Double_t GetYMax(TH1* histo);
00085
00087 virtual Double_t GetCMax(TH1* histo);
00088
00089 virtual Bool_t IsPolygonType();
00090
00091 virtual Int_t GetMemorySize();
00092
00094 virtual void SavePrimitive(std::ostream& fs, Option_t* = "");
00095
00096 private:
00097
00099 Double_t fLow1;
00100
00102 Double_t fUp1;
00103
00105 Double_t fLow2;
00106
00108 Double_t fUp2;
00109
00111 Int_t fiSaveXMin;
00112
00114 Int_t fiSaveXMax;
00115
00117 Int_t fiSaveYMin;
00118
00120 Int_t fiSaveYMax;
00121
00123 void SetHistogramRanges(TH1* histo);
00124
00126 void RestoreHistogramRanges(TH1* histo);
00127
00128 ClassDef(TGo4WinCond,6)
00129 };
00130
00131 #endif //TGO4WINCOND_H