Changeset 7436 for trunk/MagicSoft


Ignore:
Timestamp:
11/30/05 13:19:55 (19 years ago)
Author:
tbretz
Message:
*** empty log message ***
Location:
trunk/MagicSoft
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/MagicSoft/Mars/showplot.cc

    r7432 r7436  
    163163        TString file = "/magic/data/";
    164164        switch (kInput.Hash())
    165 
    166165        {
    167         case (unsigned long)-856860927:
     166        case 3438106369:
    168167        case  764164111:
    169168            file += "callisto";
     
    182181    }
    183182
    184     if (kNamePs.IsNull()    && kSaveAsPs)
     183    if (kNamePs.IsNull()   && kSaveAsPs)
    185184        kNamePs = kInput;
    186     if (kNamePdf.IsNull()   && kSaveAsPdf)
     185    if (kNamePdf.IsNull()  && kSaveAsPdf)
    187186        kNamePdf = kInput;
    188     if (kNameSvg.IsNull()   && kSaveAsSvg)
     187    if (kNameSvg.IsNull()  && kSaveAsSvg)
    189188        kNameSvg = kInput;
    190     if (kNameGif.IsNull()   && kSaveAsGif)
     189    if (kNameGif.IsNull()  && kSaveAsGif)
    191190        kNameGif = kInput;
    192     if (kNameJpg.IsNull()   && kSaveAsJpg)
     191    if (kNameJpg.IsNull()  && kSaveAsJpg)
    193192        kNameJpg = kInput;
    194     if (kNameXpm.IsNull()   && kSaveAsXpm)
     193    if (kNameXpm.IsNull()  && kSaveAsXpm)
    195194        kNameXpm = kInput;
    196     if (kNamePng.IsNull()   && kSaveAsPng)
     195    if (kNamePng.IsNull()  && kSaveAsPng)
    197196        kNamePng = kInput;
    198     if (kNameRoot.IsNull()  && kSaveAsRoot)
     197    if (kNameRoot.IsNull() && kSaveAsRoot)
    199198        kNameRoot = kInput;
    200     if (kNameC.IsNull()     && kSaveAsC)
     199    if (kNameC.IsNull()    && kSaveAsC)
    201200        kNameC = kInput;
    202201
  • trunk/MagicSoft/include-Classes/MMcFormat/MMcFadcHeader.cxx

    r3041 r7436  
     1/* ======================================================================== *\
     2!
     3! *
     4! * This file is part of MARS, the MAGIC Analysis and Reconstruction
     5! * Software. It is distributed to you in the hope that it can be a useful
     6! * and timesaving tool in analysing Data of imaging Cerenkov telescopes.
     7! * It is distributed WITHOUT ANY WARRANTY.
     8! *
     9! * Permission to use, copy, modify and distribute this software and its
     10! * documentation for any purpose is hereby granted without fee,
     11! * provided that the above copyright notice appear in all copies and
     12! * that both that copyright notice and this permission notice appear
     13! * in supporting documentation. It is provided "as is" without express
     14! * or implied warranty.
     15! *
     16!
     17!
     18!   Author(s): Unknown
     19!
     20!   Copyright: MAGIC Software Development, 2000-2005
     21!
     22!
     23\* ======================================================================== */
     24
     25//////////////////////////////////////////////////////////////////////////////
     26//
     27// MMcFadcHeader
     28//
     29// This class contains the MonteCarlo information
     30// of the FADC simulation for the current run.
     31// The information is saved only once, whatever the
     32// number of events is
     33//
     34// NOTE : meaning of fAmplFadc, fAmplFadcOuter changed in camera 0.7,
     35// 30/03/2004: before it was amplitude of (gaussian) pulse, now is
     36// integral of pulse (which may be gaussian or not).
     37//
     38// In camera 0.7, the meaning of fPedesSigmaHigh, fPedesSigmaLow changed:
     39// before it was the rms of the single FADC slice. Now we calculate the
     40// RMS of the distribution of the sum of 14 FADC slices. The value we set
     41// as fPedesSigmaHigh/Low is that RMS divided by sqrt(14). It can be seen
     42// that the fluctuations of the integrated pedestal, when adding n slices
     43// to obtain the pixel signal, with n>~6, is more or less well
     44// approximated by sqrt(n)*RMS(sum_14)slices)/sqrt(14).
     45//
     46// Version 5:
     47//   Added member fGainFluctuations
     48//
     49// Version 6:
     50//   Added member fNoiseGainFluctuations
     51//
     52// Version 7:
     53//   Derived class from MCamEvent
     54//
     55//////////////////////////////////////////////////////////////////////////////
    156#include "MMcFadcHeader.hxx"
    257
    358#include <iostream>
    459
    5 //==========
    6 // MMcFadcHeader
    7 //   
    8 // This class contains the MonteCarlo information
    9 // of the FADC simulation for the current run.
    10 // The information is saved only once, whatever the
    11 // number of events is
    12  
    13 
    14 
    1560ClassImp(MMcFadcHeader);
    1661
    1762using namespace std;
    18 
    1963
    2064MMcFadcHeader::MMcFadcHeader(const char *name, const char *title) {
     
    4488}
    4589
    46 MMcFadcHeader::~MMcFadcHeader(){
    47   //
    48   //  default destructor
    49   //
    50 }
    51 
    52 
    5390void MMcFadcHeader::Print(Option_t *Option) const {
    5491  //
     
    70107  cout << endl ;
    71108}
     109
     110Bool_t MMcFadcHeader::GetPixelContent(Double_t &val, Int_t idx, const MGeomCam &cam, Int_t type) const
     111{
     112    if ((UInt_t)idx>=GetNumPixel())
     113        return kFALSE;
     114
     115    switch (type)
     116    {
     117    case 0:
     118        val = fPedesMean[idx];
     119        break;
     120    case 1:
     121        val = fPedesSigmaHigh[idx];
     122        break;
     123    case 2:
     124        val = fPedesSigmaLow[idx];
     125        break;
     126    case 3:
     127        val = fElecNoise[idx];
     128        break;
     129    case 4:
     130        val = fDigitalNoise[idx];
     131        break;
     132    default:
     133        return kFALSE;
     134    }
     135    return kTRUE;
     136}
  • trunk/MagicSoft/include-Classes/MMcFormat/MMcFadcHeader.hxx

    r5410 r7436  
    44#ifndef MARS_MParContainer
    55#include "MParContainer.h"
     6#endif
     7#ifndef MARS_MCamEvent
     8#include "MCamEvent.h"
    69#endif
    710
     
    1518//   Added member fNoiseGainFluctuations
    1619//
     20// Version 7:
     21//   Derived class from MCamEvent
     22//
    1723
    18 class MMcFadcHeader : public MParContainer{
     24class MMcFadcHeader : public MParContainer, public MCamEvent {
    1925 private:
    2026
     
    7177 public:
    7278  MMcFadcHeader(const char *name=NULL, const char *title=NULL);
    73 
    74   ~MMcFadcHeader();
    7579
    7680  void Print(Option_t *opt=NULL) const;
     
    131135  UInt_t GetNumPixel() const { return MFADC_CHANNELS; }
    132136
    133   ClassDef(MMcFadcHeader, 6)  //Stores Montecarlo Information describing the FADC behaviour
     137  // MCamEvent
     138  Bool_t GetPixelContent(Double_t &val, Int_t idx, const MGeomCam &cam, Int_t type=0) const;
     139  void   DrawPixelContent(Int_t num) const { }
     140
     141  ClassDef(MMcFadcHeader, 7)  //Stores Montecarlo Information describing the FADC behaviour
    134142
    135143};
    136144
    137145#endif
    138 
  • trunk/MagicSoft/include-Classes/MMcFormat/Makefile

    r6375 r7436  
    1111#------------------------------------------------------------------------------
    1212
    13 INCLUDES = -I.  -I../mbase -I../MBase -I../mgeom
     13INCLUDES = -I.  -I../mbase -I../MBase -I../mgeom -I../mgui
    1414
    1515CINT     = Mc
Note: See TracChangeset for help on using the changeset viewer.