Changeset 698 for trunk/MagicSoft
- Timestamp:
- 03/22/01 12:24:47 (24 years ago)
- Location:
- trunk/MagicSoft
- Files:
-
- 17 added
- 4 deleted
- 49 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/Changelog
r695 r698 1 1 -*-*- END -*-*- 2 3 2000/03/21: Thomas Bretz 4 5 * macros/CT1Hillas.C, manalysis/MImgCleanStd.cc, manalysis/MImgCleanStd.h, 6 manalysis/MMcPedestalCopy.cc, manalysis/MMcPedestalCopy.h, 7 manalysis/MCerPhotCalc.h, manalysis/MCerPhotCalc.cc, mdatacheck/MHHillas.h, 8 mdatacheck/MHHillas.cc, mdatacheck/MFillHFadc.cc, mdatacheck/MFillHFadc.h, 9 mdatacheck/MHFadcCam.cc, mdatacheck/MHFadcCam.h, mdatacheck/MHFadcPix.cc, 10 mdatacheck/MHFadcPix.h, mdatacheck/MFillHHillas.cc, 11 mdatacheck/MFillHHillas.h 12 - added 13 14 * mdatacheck/MHistosAdc.[h,cc]: 15 - replaced by MHFadc[Cam,Pix] 16 17 * mdatacheck/MFillAdcSpect.[h,cc]: 18 - replaced by MFillHFadc 19 20 * macros/readCT1.C: 21 - uses the new classes now 22 - calculates and displays hillas 23 24 * manalysis/AnalysisLinkDef.h: 25 - added MCerPhotCalc, MImgCleanStd, MMcPedestalCopy 26 27 * manalysis/MCT1ReadAscii.cc: 28 - PreProcess uses FindCreateObj now 29 30 * manalysis/MCerPhotEvt.cc, manalysis/MPedestalCam.cc: 31 - changed the new back to 'new with placement' 32 33 * manalysis/MCerPhotEvt.[h, cc]: 34 - removed cleaning from this class 35 36 * manalysis/MHillas.cc: 37 - some small changes in the naming inside Calc() 38 39 * manalysis/MHillas.h: 40 - added Get-functions 41 42 * manalysis/MPedestalCam.h: 43 - added InitSize-function 44 45 * manalysis/MPedestalPix.h: 46 - made Get-functions const 47 48 * manalysis/Makefile: 49 - added MMcPedestalCopy, MImgCleanStd, MCerPhotCalc 50 51 * mbase/MLogManip.h: 52 - "l." before line number 53 54 * mbase/MParList.cc: 55 - added the autodelete feature for automatically created classes 56 57 * mdatacheck/DataCheckLinkDef.h: 58 - added MHFadc[Cam,Pix], MHHillas 59 - removed MHistosAdc 60 - added MFillHFadc, MFillHHillas 61 62 * mdatacheck/MGDisplayAdc.[h,cc], MShowSpect.[h,cc], 63 mdatacheck/MViewAdcSpectra.[h,cc], : 64 - changed from MHistaosAdc to MHFadcCam 65 66 * mdatacheck/Makefile: 67 - added MFillHFadc.cc, MFillHHillas.cc 68 - removed MFillAdcSpect.cc 69 70 * manalysis/MCT1ReadAscii.h, mbase/MEvtLoop.h, mbase/MLog.h, 71 mbase/MParList.h, mbase/MReadTree.h, mbase/MTask.h, 72 mbase/MTaskList.h, mdatacheck/MDumpEvtHeader.h, 73 meventdisp/MGFadcDisp.h, mgui/MCamDisplay.h, 74 mgui/MCamNeighbor.h, mgui/MGDataCheckMain.h, 75 mgui/MGEventDispMain.h, mgui/MGMarsMain.h, 76 mgui/MGMonteCarloMain.h, mgui/MGPrototyp.h, mgui/MHexagon.h, 77 mmontecarlo/MCollAreaTrigger.h, mraw/MRawEvtPixelIter.h, 78 mraw/MRawFileRead.h, mraw/MRawFileWrite.h: 79 - set version number to '0' (no i/o for this class) 80 81 * mgui/MGeomCamCT1.cc: 82 - new claculation algorith for the CT1 camera. It is more 83 exact in the camera plain 84 85 * mgui/MHexagon.cc: 86 - removed Draw-function (it is inherited from TObject) 87 88 * mmc/MMcFadcHeader.hxx: 89 - Added get-functions 90 91 2 92 3 93 2000/03/20: Thomas Bretz -
trunk/MagicSoft/Mars/macros/readCT1.C
r695 r698 3 3 MParList plist; 4 4 5 MGeomCam Magiccamct1;6 MHillas 7 MTaskList 5 MGeomCamCT1 camct1; 6 MHillas hillas; 7 MTaskList tlist; 8 8 9 9 plist->AddToList(&camct1); … … 12 12 13 13 MCT1ReadAscii readct1("CT1_99_on1.dat") ; 14 MHillasCalc hcalc; 14 MImgCleanStd clean; 15 MHillasCalc hcalc; 15 16 16 17 tlist.AddToList(&readct1); 18 tlist.AddToList(&clean); 17 19 tlist.AddToList(&hcalc); 18 20 … … 40 42 break; 41 43 42 phevt.CleanLevel1(); 43 phevt.CleanLevel2(); 44 display.DrawPhotNum(&phevt); 45 gClient->HandleInput(); 46 if(getchar()=='q') 47 break; 48 49 phevt.CleanLevel3(); 50 44 clean.Process(); 51 45 hcalc.Process(); 52 46 -
trunk/MagicSoft/Mars/manalysis/AnalysisLinkDef.h
r695 r698 7 7 #pragma link C++ class MCerPhotPix; 8 8 #pragma link C++ class MCerPhotEvt; 9 #pragma link C++ class MCerPhotCalc; 10 11 #pragma link C++ class MImgCleanStd; 9 12 10 13 #pragma link C++ class MCT1ReadAscii; … … 13 16 #pragma link C++ class MPedestalPix; 14 17 #pragma link C++ class MPedestalCam; 18 #pragma link C++ class MMcPedestalCopy; 15 19 16 20 #pragma link C++ class MHillas; -
trunk/MagicSoft/Mars/manalysis/MCT1Pedestals.cc
r654 r698 34 34 // skip the next 4 values 35 35 // 36 fin >> dummyF; 37 fin >> dummyF; 38 fin >> dummyF; 39 fin >> dummyF; 36 fin >> dummyF; 37 fin >> dummyF; 38 fin >> dummyF; 39 fin >> dummyF; 40 40 41 41 // -
trunk/MagicSoft/Mars/manalysis/MCT1ReadAscii.cc
r656 r698 10 10 11 11 #include "MLog.h" 12 #include "MLogManip.h" 13 12 14 #include "MParList.h" 13 15 #include "MCerPhotEvt.h" … … 41 43 if (!(*fIn)) 42 44 { 43 *fLog << "Error: MCT1ReadAscii::PreProcess:Cannot open file." << endl;45 *fLog << dbginf << "Cannot open file." << endl; 44 46 return kFALSE; 45 47 } … … 48 50 // look for the MCerPhotEvt class in the plist 49 51 // 50 fNphot = (MCerPhotEvt*)pList->Find Object("MCerPhotEvt");52 fNphot = (MCerPhotEvt*)pList->FindCreateObj("MCerPhotEvt"); 51 53 if (!fNphot) 52 { 53 *fLog << "MRawCT1Ascii::PreProcess - WARNING: MCerPhotEvt not found... creating." << endl; 54 fNphot = new MCerPhotEvt; 55 pList->AddToList(fNphot); 56 } 54 return kFALSE; 57 55 58 56 // 59 57 // look for the pedestal class in the plist 60 58 // 61 fPedest = (MCT1Pedestals*)pList->Find Object("MCT1Pedestals");59 fPedest = (MCT1Pedestals*)pList->FindCreateObj("MCT1Pedestals"); 62 60 if (!fPedest) 63 { 64 *fLog << "MRawCT1Ascii::PreProcess - WARNING: MCT1Pedestals not found... creating." << endl; 65 fPedest = new MCT1Pedestals; 66 pList->AddToList(fPedest); 67 } 61 return kFALSE; 68 62 69 63 return kTRUE; … … 73 67 { 74 68 // 69 // FIXME. This function should switch between reading pedestals and 70 // reading event data by the 'switch entry'. 71 // After reading it should set the InputStreamID correctly. 72 // ( should use MPedestalCam ) 73 // 74 75 // 75 76 // read in a dummy number (event number) 76 77 // … … 78 79 *fIn >> dummyI; 79 80 81 // 82 // check if we are done 83 // 80 84 if (fIn->eof()) 81 {82 *fLog << "MRawCT1Ascii::Process - Error: EOF reached." << endl;83 85 return kFALSE; 84 }85 86 86 87 // … … 94 95 // five unsused numbers 95 96 // 96 *fIn >> dummyI; 97 *fIn >> dummyI; 98 *fIn >> dummyI; 99 *fIn >> dummyI; 97 *fIn >> dummyI; // ener 98 *fIn >> dummyI; // zenang 99 *fIn >> dummyI; // sec1 100 *fIn >> dummyI; // sec2 100 101 101 102 // … … 110 111 for (Int_t i = 0; i<127; i++ ) 111 112 { 112 Float_t dummyF;113 Float_t nphot; 113 114 114 *fIn >> dummyF;115 *fIn >> nphot; 115 116 116 if ( dummyF> 0.0)117 fNphot->AddPixel(i, dummyF, (*fPedest)[i]);117 if (nphot > 0.0) 118 fNphot->AddPixel(i, nphot, (*fPedest)[i]); 118 119 } 119 120 -
trunk/MagicSoft/Mars/manalysis/MCT1ReadAscii.h
r653 r698 26 26 Bool_t PostProcess(); 27 27 28 ClassDef(MCT1ReadAscii, 1) // Reads the CT1 data file28 ClassDef(MCT1ReadAscii, 0) // Reads the CT1 data file 29 29 }; 30 30 -
trunk/MagicSoft/Mars/manalysis/MCerPhotEvt.cc
r695 r698 47 47 } 48 48 49 Int_t MCerPhotEvt::GetNumPixels()50 {51 return fNumPixels;52 }53 54 49 void MCerPhotEvt::AddPixel(Int_t id, Float_t nph, Float_t err) 55 50 { … … 58 53 // of valid pixels in the list by one 59 54 // 60 (*fPixels)[fNumPixels++] = new MCerPhotPix( id, nph, err); 55 56 // TClonesArray -> 'operator new with placement' should be used 57 new ((*fPixels)[fNumPixels++]) MCerPhotPix( id, nph, err); 61 58 } 62 59 … … 83 80 } 84 81 82 /* 85 83 void MCerPhotEvt::CleanLevel1() 86 84 { … … 228 226 } 229 227 } 230 228 */ 231 229 232 230 Bool_t MCerPhotEvt::IsPixelExisting(Int_t id) … … 293 291 294 292 Float_t testval; 295 for ( Int_t i=1 ; i<fNumPixels; i++ )293 for (UInt_t i=1 ; i<fNumPixels; i++ ) 296 294 { 297 295 testval = (*this)[i].GetNumPhotons(); … … 315 313 316 314 Float_t testval; 317 for ( Int_t i=1; i<fNumPixels; i++)315 for (UInt_t i=1; i<fNumPixels; i++) 318 316 { 319 317 testval = (*this)[i].GetNumPhotons(); -
trunk/MagicSoft/Mars/manalysis/MCerPhotEvt.h
r695 r698 6 6 #endif 7 7 #ifndef ROOT_TClonesArray 8 #include "TClonesArray.h"8 #include <TClonesArray.h> 9 9 #endif 10 10 #ifndef MPARCONTAINER_H … … 21 21 private: 22 22 23 Int_t fNumPixels;23 UInt_t fNumPixels; 24 24 TClonesArray *fPixels; 25 25 … … 27 27 28 28 public: 29 MCerPhotEvt(const char *name=NULL, const char *title=NULL) ; 29 MCerPhotEvt(const char *name=NULL, const char *title=NULL) ; 30 ~MCerPhotEvt() { delete fPixels; } 30 31 31 32 void Draw(Option_t* option = "" ) ; 32 33 33 Int_t GetNumPixels() ;34 UInt_t GetNumPixels() const { return fNumPixels; } 34 35 35 36 void AddPixel(Int_t id, Float_t nph, Float_t err ); … … 39 40 void Print(Option_t *opt=NULL) ; 40 41 41 void CleanLevel1() ;42 void CleanLevel2() ;43 void CleanLevel3() ;42 // void CleanLevel1() ; 43 // void CleanLevel2() ; 44 // void CleanLevel3() ; 44 45 45 Bool_t IsPixelExisting( Int_t id ) 46 Bool_t IsPixelUsed ( Int_t id ) 47 Bool_t IsPixelCore ( Int_t id ) 46 Bool_t IsPixelExisting( Int_t id ); 47 Bool_t IsPixelUsed ( Int_t id ); 48 Bool_t IsPixelCore ( Int_t id ); 48 49 49 50 Float_t GetNumPhotonsMin(); -
trunk/MagicSoft/Mars/manalysis/MHillas.cc
r695 r698 79 79 // calculate mean valu of pixels 80 80 // 81 float xav =0; 82 float yav =0; 83 float spix=0; 81 float xmean =0; 82 float ymean =0; 83 84 fSize = 0; 84 85 85 86 for (UInt_t i=0; i<nevt; i++) … … 94 95 const float nphot = pix.GetNumPhotons(); 95 96 96 spix+= nphot;97 x av += nphot * gpix.GetX();98 y av += nphot * gpix.GetY();97 fSize += nphot; 98 xmean += nphot * gpix.GetX(); // [mm] 99 ymean += nphot * gpix.GetY(); // [mm] 99 100 } 100 101 101 x av /= spix;102 y av /= spix;102 xmean /= fSize; // [mm] 103 ymean /= fSize; // [mm] 103 104 104 105 // 105 106 // calculate sdev 106 107 // 107 float dis11=0;108 float dis12=0;109 float dis22=0;108 float sigmaxx=0; 109 float sigmaxy=0; 110 float sigmayy=0; 110 111 111 112 for (UInt_t i=0; i<nevt; i++) … … 118 119 const MGeomPix &gpix = geom[pix.GetPixId()]; 119 120 120 const float dx = gpix.GetX() - x av;121 const float dy = gpix.GetY() - y av;121 const float dx = gpix.GetX() - xmean; 122 const float dy = gpix.GetY() - ymean; 122 123 123 124 const float nphot = pix.GetNumPhotons(); 124 125 125 dis11 += nphot * dx*dx;126 dis12 += nphot * dx*dy;127 dis22 += nphot * dy*dy;126 sigmaxx += nphot * dx*dx; // [mm^2] 127 sigmaxy += nphot * dx*dy; // [mm^2] 128 sigmayy += nphot * dy*dy; // [mm^2] 128 129 } 129 130 … … 131 132 // check for orientation 132 133 // 133 const float theta = atan( dis12/(dis11-dis22)*2)/2;134 const float theta = atan(sigmaxy/(sigmaxx-sigmayy)*2)/2; 134 135 135 float c = cos(theta); 136 float s = sin(theta); 136 float c = cos(theta); // [1] 137 float s = sin(theta); // [1] 137 138 138 const float direction = c*x av+s*yav;139 const float direction = c*xmean + s*ymean; 139 140 140 141 if (direction<0) … … 144 145 } 145 146 146 float rot1 = 2.0*c*s*dis12 + c*c*dis11 + s*s*dis22;147 float rot2 = -2.0*c*s*dis12 + s*s*dis11 + c*c*dis22;147 float axis1 = 2.0*c*s*sigmaxy + c*c*sigmaxx + s*s*sigmayy; // [mm^2] 148 float axis2 = -2.0*c*s*sigmaxy + s*s*sigmaxx + c*c*sigmayy; // [mm^2] 148 149 149 rot1 /= spix;150 rot2 /= spix;150 axis1 /= fSize; // [mm^2] 151 axis2 /= fSize; // [mm^2] 151 152 152 153 // 153 154 // check for numerical negatives 154 155 // 155 if ( rot1 < 0) rot1=0;156 if ( rot2 < 0) rot2=0;156 if (axis1 < 0) axis1=0; 157 if (axis2 < 0) axis2=0; 157 158 158 159 // 159 160 // check the rotation of the axis 160 161 // 161 const int rotation = rot1<rot2;162 const int rotation = axis1<axis2; 162 163 163 fLength = rotation ? sqrt( rot2) : sqrt(rot1);164 fWidth = rotation ? sqrt( rot1) : sqrt(rot2);164 fLength = rotation ? sqrt(axis2) : sqrt(axis1); // [mm] 165 fWidth = rotation ? sqrt(axis1) : sqrt(axis2); // [mm] 165 166 166 fAlpha = 180/kPI*atan((-x av*s+yav*c)/direction);167 fAlpha = 180/kPI*atan((-xmean*s+ymean*c)/direction); // [deg] 167 168 168 fDist = sqrt(x av*xav + yav*yav);169 fDist = sqrt(xmean*xmean + ymean*ymean); // [mm] 169 170 170 fTheta = atan(y av/xav);171 if (x av<0) fTheta += kPI;171 fTheta = atan(ymean/xmean); // [rad] 172 if (xmean<0) fTheta += kPI; // [deg] 172 173 } -
trunk/MagicSoft/Mars/manalysis/MHillas.h
r695 r698 34 34 void Clear(Option_t *opt=NULL); 35 35 36 Float_t GetAlpha() const { return fAlpha; } 37 Float_t GetWidth() const { return fWidth; } 38 Float_t GetLength() const { return fLength; } 39 Float_t GetDist() const { return fDist; } 40 36 41 ClassDef(MHillas, 1) // Storage Container for Hillas Parameter 37 42 }; -
trunk/MagicSoft/Mars/manalysis/MPedestalCam.cc
r695 r698 18 18 19 19 fArray = new TClonesArray("MPedestalPix", 577); 20 21 // 22 // TClonesArray: The 'new operator with placement' must be used 23 // 24 for (int i=0; i<577; i++) 25 new ((*fArray)[i]) MPedestalPix; 20 26 } 21 27 -
trunk/MagicSoft/Mars/manalysis/MPedestalCam.h
r695 r698 23 23 ~MPedestalCam(); 24 24 25 void InitSize(const UInt_t i) { fArray->ExpandCreateFast(i); } 26 25 27 MPedestalPix &operator[](Int_t i) { return *(MPedestalPix*)fArray->At(i); } 26 28 -
trunk/MagicSoft/Mars/manalysis/MPedestalPix.h
r695 r698 17 17 MPedestalPix(); 18 18 19 Float_t GetMean() { return fMean; }20 Float_t GetSigma() { return fSigma; }21 Float_t GetMeanRms() { return fMeanRms; }22 Float_t GetSigmaRms() { return fSigmaRms; }19 Float_t GetMean() const { return fMean; } 20 Float_t GetSigma() const { return fSigma; } 21 Float_t GetMeanRms() const { return fMeanRms; } 22 Float_t GetSigmaRms() const { return fSigmaRms; } 23 23 24 24 void SetMean(Float_t f) { fMean = f; } … … 27 27 void SetSigmaRms(Float_t f) { fSigmaRms = f; } 28 28 29 void SetPedestal(Float_t m, Float_t s) { fMean = m; fSigma = s; } 30 void SetPedestalRms(Float_t m, Float_t s) { fMeanRms = m; fSigmaRms = s; } 31 29 32 ClassDef(MPedestalPix, 1) // Storage Container for Pedestal information of one pixel 30 33 }; -
trunk/MagicSoft/Mars/manalysis/Makefile
r695 r698 22 22 # connect the include files defined in the config.mk file 23 23 # 24 INCLUDES = -I. -I../mbase -I../mgui 24 INCLUDES = -I. -I../mbase -I../mgui -I../mmc -I../mraw 25 25 26 26 #------------------------------------------------------------------------------ … … 32 32 MPedestalCam.cc \ 33 33 MPedestalPix.cc \ 34 MMcPedestalCopy.cc \ 35 MImgCleanStd.cc \ 34 36 MHillas.cc \ 35 37 MHillasCalc.cc \ 38 MCerPhotCalc.cc \ 36 39 MCerPhotEvt.cc \ 37 40 MCerPhotPix.cc -
trunk/MagicSoft/Mars/mbase/MEvtLoop.h
r604 r698 39 39 void Eventloop(Int_t maxcnt=-1, const char *tlist="MTaskList"); 40 40 41 ClassDef(MEvtLoop, 1) // Class to execute the tasks in a tasklist41 ClassDef(MEvtLoop, 0) // Class to execute the tasks in a tasklist 42 42 }; 43 43 -
trunk/MagicSoft/Mars/mbase/MLog.h
r609 r698 116 116 } 117 117 118 ClassDef(MLog, 1)118 ClassDef(MLog, 0) 119 119 }; 120 120 -
trunk/MagicSoft/Mars/mbase/MLogManip.h
r654 r698 53 53 // 54 54 #ifndef __CINT__ 55 #define dbginf __FILE__ << " " << __LINE__ << ": "55 #define dbginf __FILE__ << " l." << __LINE__ << ": " 56 56 #endif 57 57 // -
trunk/MagicSoft/Mars/mbase/MParList.cc
r667 r698 24 24 ClassImp(MParList) 25 25 26 // 27 // FIXME: The Automatic created classes are NEVER deleted!!!!! 28 // 29 26 30 MParList::MParList(const char *name, const char *title) 27 31 { … … 32 36 *fName = name ? name : "MParList"; 33 37 *fTitle = title ? title : "List of Parameter Containers"; 38 39 // 40 // This sets a flag that the list is the owner, which means 41 // that the destructor of the list deletes all it's objects 42 // 43 fAutodelete.SetOwner(); 34 44 } 35 45 … … 151 161 AddToList(pcont); 152 162 163 fAutodelete.Add(pcont); 164 153 165 // 154 166 // Find an object in the list. -
trunk/MagicSoft/Mars/mbase/MParList.h
r667 r698 27 27 private: 28 28 TOrdCollection fContainer; // Collection of Parameter and Data Containers 29 TOrdCollection fAutodelete; // All what this list contains is deleted in the destructor 29 30 30 31 public: … … 45 46 void Print(Option_t *t = NULL); 46 47 47 ClassDef(MParList, 1) //list of parameter containers (MParContainer)48 ClassDef(MParList, 0) // list of parameter containers (MParContainer) 48 49 }; 49 50 -
trunk/MagicSoft/Mars/mbase/MReadTree.h
r585 r698 36 36 UInt_t GetEntries() {return fNumEntries;} 37 37 38 ClassDef(MReadTree, 1) // Reads one tree38 ClassDef(MReadTree, 0) // Reads one tree 39 39 }; 40 40 -
trunk/MagicSoft/Mars/mbase/MTask.h
r609 r698 27 27 virtual Bool_t PostProcess(); 28 28 29 ClassDef(MTask, 1) //Abstract base class for a task29 ClassDef(MTask, 0) //Abstract base class for a task 30 30 }; 31 31 -
trunk/MagicSoft/Mars/mbase/MTaskList.h
r609 r698 41 41 void Print(Option_t *t = NULL); 42 42 43 ClassDef(MTaskList, 1) //collection of tasks to be performed in the eventloop43 ClassDef(MTaskList, 0) //collection of tasks to be performed in the eventloop 44 44 }; 45 45 -
trunk/MagicSoft/Mars/mdatacheck/DataCheckLinkDef.h
r666 r698 5 5 #pragma link off all functions; 6 6 7 #pragma link C++ class MHFadcCam; 8 #pragma link C++ class MHFadcPix; 9 #pragma link C++ class MHHillas; 10 7 11 #pragma link C++ class MShowSpect; 8 #pragma link C++ class MHistosAdc; 9 #pragma link C++ class MFillAdcSpect; 12 13 #pragma link C++ class MFillHFadc; 14 #pragma link C++ class MFillHHillas; 10 15 11 16 #pragma link C++ class MDumpEvtHeader; -
trunk/MagicSoft/Mars/mdatacheck/MDumpEvtHeader.h
r666 r698 26 26 Bool_t Process() ; 27 27 28 ClassDef(MDumpEvtHeader, 1) // Class to dump the pixel ids of a raw evt to the screen28 ClassDef(MDumpEvtHeader, 0) // Class to dump the pixel ids of a raw evt to the screen 29 29 30 30 }; -
trunk/MagicSoft/Mars/mdatacheck/MGDisplayAdc.cc
r667 r698 23 23 } ; 24 24 25 MGDisplayAdc::MGDisplayAdc ( MH istosAdc*histos,25 MGDisplayAdc::MGDisplayAdc ( MHFadcCam *histos, 26 26 const TGWindow *p, const TGWindow *main, 27 27 UInt_t w, UInt_t h, … … 218 218 // Histogramms in there. 219 219 // 220 // In the class MH istosAdcare in fact two lists. One for the high and220 // In the class MHFadcCam are in fact two lists. One for the high and 221 221 // one for the low gain. Here we will use only the high gain list!!! 222 222 // With some special options (settings in the gui) we will also be able … … 224 224 // 225 225 226 const Int_t nhi = fHists->Get HiEntries();226 const Int_t nhi = fHists->GetEntries(); 227 227 for ( Int_t i=0 ; i < nhi; i++ ) { 228 228 fHistoList->AddEntry(fHists->GetHistHi(i)->GetName(), i+1) ; -
trunk/MagicSoft/Mars/mdatacheck/MGDisplayAdc.h
r665 r698 12 12 #endif 13 13 14 #ifndef MH ISTOSADC_H15 #include "MH istosAdc.h"14 #ifndef MHFADCCAM_H 15 #include "MHFadcCam.h" 16 16 #endif 17 17 … … 24 24 private: 25 25 26 MH istosAdc*fHists; // Pointer to Container with the histograms26 MHFadcCam *fHists; // Pointer to Container with the histograms 27 27 28 28 // Create a main frame with a number of different buttons. … … 71 71 TCanvas *fCanvas; 72 72 73 MGDisplayAdc(MH istosAdc *fHists ,73 MGDisplayAdc(MHFadcCam *fHists , 74 74 const TGWindow *p, const TGWindow *main, 75 75 UInt_t w, UInt_t h, -
trunk/MagicSoft/Mars/mdatacheck/MShowSpect.cc
r667 r698 34 34 // Do the preprocessing for MShowSpect 35 35 // 36 // Connects Histogramms in the MH istosAdccontainer as the input36 // Connects Histogramms in the MHFadcCam container as the input 37 37 // 38 38 39 fHists = (MH istosAdc*) pList->FindObject( fHistName );39 fHists = (MHFadcCam*) pList->FindObject( fHistName ); 40 40 41 41 if (!fHists) 42 42 { 43 *fLog << dbginf << " Error: MH istosAdc'" << fHistName << "' not found!" << endl;43 *fLog << dbginf << " Error: MHFadcCam '" << fHistName << "' not found!" << endl; 44 44 return kFALSE; 45 45 } -
trunk/MagicSoft/Mars/mdatacheck/MShowSpect.h
r667 r698 11 11 12 12 class MGDisplayAdc; 13 class MH istosAdc;13 class MHFadcCam; 14 14 class MParList ; 15 15 … … 19 19 char fHistName[256] ; 20 20 21 MH istosAdc*fHists; // Pointer to Container with the histograms21 MHFadcCam *fHists; // Pointer to Container with the histograms 22 22 23 23 public: … … 29 29 Bool_t PostProcess(); 30 30 31 ClassDef(MShowSpect, 1) // Fill the raw ADC in the histograms31 ClassDef(MShowSpect, 0) // Fill the raw ADC in the histograms 32 32 }; 33 33 -
trunk/MagicSoft/Mars/mdatacheck/MViewAdcSpectra.cc
r667 r698 15 15 #include "MReadTree.h" 16 16 #include "MDumpEvtHeader.h" 17 #include "MFill AdcSpect.h"17 #include "MFillHFadc.h" 18 18 #include "MShowSpect.h" 19 #include "MH istosAdc.h"19 #include "MHFadcCam.h" 20 20 21 21 MViewAdcSpectra::MViewAdcSpectra() … … 65 65 plist.AddToList(&evttime); 66 66 67 fHistosAdc= new MH istosAdc;67 fHistosAdc= new MHFadcCam; 68 68 plist.AddToList( fHistosAdc ) ; 69 69 … … 80 80 // tasks->AddToList( dumpheader ) ; 81 81 82 MFill AdcSpectfillspect;82 MFillHFadc fillspect; 83 83 tasks.AddToList( &fillspect ) ; 84 84 85 MShowSpect showspect( "MH istosAdc" ) ;85 MShowSpect showspect( "MHFadcCam" ) ; 86 86 tasks.AddToList( &showspect ) ; 87 87 -
trunk/MagicSoft/Mars/mdatacheck/MViewAdcSpectra.h
r667 r698 6 6 #endif 7 7 8 class MH istosAdc;8 class MHFadcCam; 9 9 10 10 class MViewAdcSpectra { … … 12 12 private: 13 13 14 MH istosAdc*fHistosAdc;14 MHFadcCam *fHistosAdc; 15 15 16 16 public: -
trunk/MagicSoft/Mars/mdatacheck/Makefile
r665 r698 22 22 # connect the include files defined in the config.mk file 23 23 # 24 INCLUDES = -I. -I../mbase -I../mraw 24 INCLUDES = -I. -I../mbase -I../mraw -I../manalysis 25 25 26 26 #------------------------------------------------------------------------------ … … 29 29 30 30 SRCFILES = MDumpEvtHeader.cc \ 31 MFillAdcSpect.cc \ 31 MFillHFadc.cc \ 32 MFillHHillas.cc \ 32 33 MGDisplayAdc.cc \ 33 MHistosAdc.cc \ 34 MHFadcPix.cc \ 35 MHFadcCam.cc \ 36 MHHillas.cc \ 34 37 MShowSpect.cc \ 35 38 MViewAdcSpectra.cc -
trunk/MagicSoft/Mars/meventdisp/MGFadcDisp.cc
r695 r698 36 36 37 37 // first connect the file with this Object 38 39 pList = new MParList();38 39 pList = new MParList(); 40 40 41 41 fRunHeader = new MRawRunHeader(); -
trunk/MagicSoft/Mars/meventdisp/MGFadcDisp.h
r695 r698 118 118 virtual Bool_t ProcessMessage(Long_t msg, Long_t parm1, Long_t parm2); 119 119 120 ClassDef(MGFadcDisp, 1)120 ClassDef(MGFadcDisp, 0) 121 121 }; 122 122 -
trunk/MagicSoft/Mars/mgui/MCamDisplay.h
r695 r698 73 73 } 74 74 75 ClassDef(MCamDisplay, 1) // Display the magic camera75 ClassDef(MCamDisplay, 0) // Display the magic camera 76 76 }; 77 77 -
trunk/MagicSoft/Mars/mgui/MCamNeighbor.h
r653 r698 20 20 void Print(Option_t *opt=NULL) ; 21 21 22 ClassDef(MCamNeighbor, 1) // Conatins the neighbors in the magic camera22 ClassDef(MCamNeighbor, 0) // Conatins the neighbors in the magic camera 23 23 } ; 24 24 -
trunk/MagicSoft/Mars/mgui/MGDataCheckMain.cc
r571 r698 252 252 if ( strcmp ( fInputFile, "\n") == 0 ) 253 253 { 254 return ( kFALSE ) ;254 return kFALSE ; 255 255 } 256 256 257 return (kTRUE) ;257 return kTRUE ; 258 258 } 259 259 -
trunk/MagicSoft/Mars/mgui/MGDataCheckMain.h
r669 r698 86 86 Bool_t ProcessMessage(Long_t msg, Long_t parm1, Long_t parm2); 87 87 88 ClassDef(MGDataCheckMain, 1)88 ClassDef(MGDataCheckMain, 0) 89 89 90 90 } ; -
trunk/MagicSoft/Mars/mgui/MGEventDispMain.h
r587 r698 97 97 Bool_t ProcessMessage(Long_t msg, Long_t parm1, Long_t parm2); 98 98 99 ClassDef(MGEventDispMain, 1)99 ClassDef(MGEventDispMain, 0) 100 100 101 101 } ; -
trunk/MagicSoft/Mars/mgui/MGMarsMain.h
r466 r698 58 58 Bool_t ProcessMessage(Long_t msg, Long_t parm1, Long_t parm2); 59 59 60 ClassDef(MGMarsMain, 1)60 ClassDef(MGMarsMain, 0) 61 61 } ; 62 62 -
trunk/MagicSoft/Mars/mgui/MGMonteCarloMain.h
r571 r698 81 81 Bool_t ProcessMessage(Long_t msg, Long_t parm1, Long_t parm2); 82 82 83 ClassDef(MGMonteCarloMain, 1)83 ClassDef(MGMonteCarloMain, 0) 84 84 85 85 } ; -
trunk/MagicSoft/Mars/mgui/MGPrototyp.h
r609 r698 93 93 Bool_t ProcessMessage(Long_t msg, Long_t parm1, Long_t parm2); 94 94 95 ClassDef(MGPrototyp, 1)95 ClassDef(MGPrototyp, 0) 96 96 97 97 } ; -
trunk/MagicSoft/Mars/mgui/MGeomCamCT1.cc
r695 r698 34 34 // it was punt into a root/C++ context by Harald Kornmayer and Thomas Bretz 35 35 36 const Float_t pixdiameter = 21 ; // units are cm 36 const Float_t diameter = 21 ; // units are mm 37 const Float_t kS32 = sqrt(3)/2; 37 38 38 39 // 39 40 // add the first pixel to the list 40 41 // 41 (*this)[0].Set(0, 0, pixdiameter);42 //fPixels->Add( new MGeomPix( ) ;43 44 const Float_t kS32 = sqrt(3)/2;45 const Float_t kPI23 = kPI*2/3;46 47 42 Int_t pixnum = 1; 48 43 49 for (Int_t ringcounter=1; ringcounter<7; ringcounter++) { 50 // 51 // calc. numofpix in ring number i first 52 // 53 const Int_t numpixthisring = ringcounter*6; 44 (*this)[pixnum++].Set(0, 0, diameter); 54 45 46 for (Int_t ring=1; ring<7; ring++) 47 { 55 48 // 56 49 // calc. coords for this ring counting from the 57 50 // starting number to the ending number 58 51 // 59 for (Int_t ipix = 0; ipix < numpixthisring; ipix++) { 52 for (int i=0; i<ring; i++) 53 (*this)[pixnum++].Set((-ring+i*0.5)*diameter, 54 i*kS32*diameter, 55 diameter); 60 56 61 Float_t ang = 60.0/ringcounter * ipix; 62 Float_t fracang = ang - 60*(int)floor(ang/60); 57 for (int i=0; i<ring; i++) 58 (*this)[pixnum++].Set((-ring*0.5+i)*diameter, 59 ring*kS32 * diameter, 60 diameter); 63 61 64 ang /= kRad2Deg; 65 fracang /= kRad2Deg; 62 for (int i=0; i<ring; i++) 63 (*this)[pixnum++].Set((ring+i)*0.5*diameter, 64 (ring-i)*kS32*diameter, 65 diameter); 66 66 67 Float_t rad = pixdiameter * ringcounter; 68 rad *= sin(kPI23-fracang) * kS32; 67 for (int i=0; i<ring; i++) 68 (*this)[pixnum++].Set((ring-0.5*i)*diameter, 69 -i*kS32*diameter, 70 diameter); 69 71 70 // 71 // fill the Data into the array 72 // 72 for (int i=0; i<ring; i++) 73 (*this)[pixnum++].Set((ring*0.5-i)*diameter, 74 -ring*kS32 * diameter, 75 diameter); 73 76 74 (*this)[pixnum++].Set(rad * cos(ang), 75 rad * sin(ang), 76 pixdiameter); 77 // fPixels->Add( new MGeomPix( ) ; 78 } 77 for (int i=0; i<ring; i++) 78 (*this)[pixnum++].Set((-ring-i)*0.5*diameter, 79 (-ring+i)*kS32*diameter, 80 diameter); 79 81 } 80 82 } -
trunk/MagicSoft/Mars/mgui/MHexagon.cc
r653 r698 92 92 } 93 93 94 95 void MHexagon::Draw(Option_t *option ) 96 { 97 // Draw this ellipse with its current attributes 98 AppendPad(option) ; 99 } 100 101 void MHexagon::DrawHexagon( Float_t x, Float_t y, Float_t d ) 94 void MHexagon::DrawHexagon( Float_t x, Float_t y, Float_t d ) 102 95 { 103 96 // Draw this ellipse with new coordinate -
trunk/MagicSoft/Mars/mgui/MHexagon.h
r665 r698 43 43 44 44 virtual Int_t DistancetoPrimitive(Int_t px, Int_t py ) ; 45 virtual void Draw( Option_t *Option="") ;46 45 virtual void DrawHexagon( Float_t x, Float_t y, Float_t d ) ; 47 46 … … 53 52 virtual void Print(Option_t *Option="") ; 54 53 55 ClassDef ( MHexagon, 1) // a hexagon for MAGIC54 ClassDef ( MHexagon, 0 ) // a hexagon for MAGIC 56 55 57 56 } ; -
trunk/MagicSoft/Mars/mmontecarlo/MCollAreaTrigger.h
r686 r698 24 24 Bool_t PostProcess() ; 25 25 26 ClassDef(MCollAreaTrigger, 1) // Task to fill the collection area histograms26 ClassDef(MCollAreaTrigger, 0) // Task to fill the collection area histograms 27 27 28 28 }; -
trunk/MagicSoft/Mars/mraw/MRawEvtPixelIter.h
r664 r698 89 89 void Draw(Option_t *t="GRAPH"); 90 90 91 ClassDef(MRawEvtPixelIter, 1) // iterates over all pixels of one MRawEvtData object91 ClassDef(MRawEvtPixelIter, 0) // iterates over all pixels of one MRawEvtData object 92 92 }; 93 93 -
trunk/MagicSoft/Mars/mraw/MRawFileRead.h
r690 r698 33 33 Bool_t Process(); 34 34 35 ClassDef(MRawFileRead, 1) // Task to read the raw data binary file35 ClassDef(MRawFileRead, 0) // Task to read the raw data binary file 36 36 }; 37 37 -
trunk/MagicSoft/Mars/mraw/MRawFileWrite.h
r454 r698 44 44 Bool_t PostProcess(); 45 45 46 ClassDef(MRawFileWrite, 1) // Task to write the raw data containers to a root file46 ClassDef(MRawFileWrite, 0) // Task to write the raw data containers to a root file 47 47 }; 48 48 -
trunk/MagicSoft/include-Classes/MMcFormat/MMcFadcHeader.hxx
r693 r698 56 56 fElecNoise[i]=sigma[i]; 57 57 } 58 59 Float_t GetPedestal(UInt_t i) const { return fPedesMean[i]; } 60 Float_t GetPedestalRms(UInt_t i) const { return fElecNoise[i]; } 61 62 const UInt_t GetNumPixel() const { return MFADC_CHANNELS; } 58 63 59 64 ClassDef(MMcFadcHeader, 1) //Stores Montecarlo Information
Note:
See TracChangeset
for help on using the changeset viewer.