Ignore:
Timestamp:
02/27/04 06:52:39 (21 years ago)
Author:
wittek
Message:
*** empty log message ***
Location:
trunk/MagicSoft/Mars/mhist
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/MagicSoft/Mars/mhist/MHBlindPixels.cc

    r3140 r3339  
    3535#include "MMcEvt.hxx"
    3636#include "MBlindPixels.h"
     37#include "MGeomCam.h"
    3738#include "MPedPhotCam.h"
    3839#include "MParList.h"
     
    7879Bool_t MHBlindPixels::SetupFill(const MParList *plist)
    7980{
     81    MGeomCam *fCam = (MGeomCam*)plist->FindObject(AddSerialNumber("MGeomCam"));
     82    if (!fCam)   
     83    {
     84        *fLog << err << "MHBlindPixels::SetupFill; MGeomCam not found... aborting." << endl;
     85        return kFALSE;
     86    }
     87
    8088    fMcEvt = (MMcEvt*)plist->FindObject("MMcEvt");
    8189    if (!fMcEvt)
     
    92100        return kFALSE;
    93101    }
     102    fPedPhot->InitSize(fCam->GetNumPixels());
    94103   
    95104
  • trunk/MagicSoft/Mars/mhist/MHBlindPixels.h

    r3140 r3339  
    1212class MMcEvt;
    1313class MParList;
    14 
     14class MGeomCam;
    1515
    1616class MHBlindPixels : public MH
    1717{
    1818private:
    19     MPedPhotCam   *fPedPhot;      //!
     19    MGeomCam      *fCam;      //!
     20    MPedPhotCam   *fPedPhot;  //!
    2021    MMcEvt        *fMcEvt;    //!
    2122
  • trunk/MagicSoft/Mars/mhist/MHSigmaTheta.cc

    r3140 r3339  
    113113Bool_t MHSigmaTheta::SetupFill(const MParList *plist)
    114114{
     115    fCam = (MGeomCam*)plist->FindObject("MGeomCam");
     116    if (!fCam)
     117    {
     118        *fLog << err << "MGeomCam not found (no geometry information available)... aborting." << endl;
     119        return kFALSE;
     120    }
     121
    115122    fMcEvt = (MMcEvt*)plist->FindObject("MMcEvt");
    116123    if (!fMcEvt)
    117124        *fLog << warn << "MMcEvt not found... aborting." << endl;
    118125
     126
    119127    fPed = (MPedPhotCam*)plist->FindObject("MPedPhotCam");
    120128    if (!fPed)
     
    123131        return kFALSE;
    124132    }
    125 
    126     fCam = (MGeomCam*)plist->FindObject("MGeomCam");
    127     if (!fCam)
    128     {
    129         *fLog << err << "MGeomCam not found (no geometry information available)... aborting." << endl;
    130         return kFALSE;
    131     }
     133    fPed->InitSize(fCam->GetNumPixels());
     134
    132135
    133136    fEvt = (MCerPhotEvt*)plist->FindObject("MCerPhotEvt");
     
    166169
    167170    // Get binning for pixel number
    168     //const UInt_t npix1 = fPed->GetSize()+1;
    169     //*fLog << "npix1 = " << npix1 << endl;
    170     //MBinning binspix("BinningPixel");
    171     //binspix.SetEdges(npix1, -0.5, npix1-0.5);
    172     // the above gives npix1 = 1; therefore :
     171    const UInt_t npix1 = fPed->GetSize()+1;
     172    *fLog << "npix1 = " << npix1 << endl;
    173173    MBinning binspix("BinningPixel");
    174     binspix.SetEdges(578, -0.5, 577.5);
     174    binspix.SetEdges(npix1, -0.5, npix1-0.5);
    175175
    176176    // Set binnings in histograms
Note: See TracChangeset for help on using the changeset viewer.