00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016 #ifndef TGO4WINCOND_H
00017 #define TGO4WINCOND_H
00018
00019 #include "TGo4Condition.h"
00020
00021 class TH1;
00022
00023 class TGo4WinCond : public TGo4Condition {
00024 public:
00025 TGo4WinCond();
00026
00027 TGo4WinCond(const char* name, const char* title = "Go4 window condition");
00028
00029 virtual ~TGo4WinCond();
00030
00032 virtual TGo4ConditionPainter* CreatePainter();
00033
00037 virtual void SetPainter(TGo4ConditionPainter* painter);
00038
00039
00040
00041
00042
00044 virtual void SetValues(Double_t low1, Double_t up1);
00045
00047 virtual void SetValues(Double_t low1, Double_t up1, Double_t low2, Double_t up2);
00048
00049
00050
00051
00053 virtual Bool_t Test(Double_t v1);
00054
00057 virtual Bool_t Test(Double_t v1, Double_t v2);
00058
00060 virtual void GetValues(Int_t & dim, Double_t & x1, Double_t & y1, Double_t & x2, Double_t & y2);
00061
00062 virtual Double_t GetXLow();
00063 virtual Double_t GetXUp();
00064 virtual Double_t GetYLow();
00065 virtual Double_t GetYUp();
00066
00068 void PrintCondition(Bool_t limits);
00069
00071 Bool_t UpdateFrom(TGo4Condition * cond, Bool_t counts);
00072
00074 virtual Double_t GetIntegral(TH1* histo, Option_t* opt="");
00075
00077 virtual Double_t GetMean(TH1* histo, Int_t axis=1);
00078
00080 virtual Double_t GetRMS(TH1* histo, Int_t axis=1);
00081
00083 virtual Double_t GetXMax(TH1* histo);
00084
00086 virtual Double_t GetYMax(TH1* histo);
00087
00089 virtual Double_t GetCMax(TH1* histo);
00090
00091 virtual Bool_t IsPolygonType();
00092
00093 virtual Int_t GetMemorySize();
00094
00095 private:
00096
00098 Double_t fLow1;
00099
00101 Double_t fUp1;
00102
00104 Double_t fLow2;
00105
00107 Double_t fUp2;
00108
00110 Int_t fiSaveXMin;
00111
00113 Int_t fiSaveXMax;
00114
00116 Int_t fiSaveYMin;
00117
00119 Int_t fiSaveYMax;
00120
00122 void SetHistogramRanges(TH1* histo);
00123
00125 void RestoreHistogramRanges(TH1* histo);
00126
00127 ClassDef(TGo4WinCond,6)
00128 };
00129
00130 #endif //TGO4WINCOND_H
00131
00132