Changeset 9552


Ignore:
Timestamp:
02/23/10 10:43:20 (15 years ago)
Author:
tbretz
Message:
*** empty log message ***
Location:
trunk/MagicSoft/Mars
Files:
8 edited

Legend:

Unmodified
Added
Removed
  • trunk/MagicSoft/Mars/Changelog

    r9551 r9552  
    1818
    1919                                                 -*-*- END OF LINE -*-*-
     20
     21 2010/02/23 Thomas Bretz
     22
     23   * mbase/MAGIC.cc:
     24     - projections are supposed to work again in root 5.26
     25       (not tested yet)
     26
     27   * mbase/MGMap.cc, mbase/MObjLookup.cc:
     28     - key and val are Long64 in newer root versions
     29
     30   * mdata/MDataPhrase.cc:
     31     - need inclusion of TFormulaPrimitive in root 5.26
     32
     33   * mhflux/MMcSpectrumWeight.cc:
     34     - root 5.26 has a different calling convention for TH1::Intgeral
     35
     36   * mjobs/MJob.cc:
     37     - added a suggested parenthesis
     38
     39   * mjtrain/MJTrainDisp.cc:
     40     - cast the MH3 histogram correctly to a TH2
     41
     42
    2043
    2144 2010/02/22 Daniela Dorner
  • trunk/MagicSoft/Mars/mbase/MAGIC.cc

    r9518 r9552  
    4040bool MARS::CheckRootVer()
    4141{
    42     if (strcmp(gROOT->GetVersion(), "5.22/00")>0)
     42    if (strcmp(gROOT->GetVersion(), "5.22/00")>0 && strcmp(gROOT->GetVersion(), "5.26/00")<0)
    4343    {
    4444        cout << "WARNING - Especially root 5.24/00 has a severe bug in projection 2D histograms" << endl;
  • trunk/MagicSoft/Mars/mbase/MGMap.cc

    r9195 r9552  
    158158void MGMap::Delete(Option_t *)
    159159{
     160#if ROOT_VERSION_CODE < ROOT_VERSION(5,26,00)
    160161    Long_t key, val;
     162#else
     163    Long64_t key, val;
     164#endif
     165
    161166    TExMapIter map(this);
    162167    while (map.Next(key, val))
     
    424429void MGMap::Paint(Option_t *)
    425430{
     431#if ROOT_VERSION_CODE < ROOT_VERSION(5,26,00)
    426432    Long_t key, val;
     433#else
     434    Long64_t key, val;
     435#endif
     436
    427437    TExMapIter map(this);
    428438    while (map.Next(key, val))
     
    441451    scale /= TMath::Hypot((float)w, (float)h)/2;
    442452
     453#if ROOT_VERSION_CODE < ROOT_VERSION(5,26,00)
    443454    Long_t key, val;
     455#else
     456    Long64_t key, val;
     457#endif
     458
    444459    TExMapIter map(this);
    445460    while (map.Next(key, val))
     
    458473TObject *MGMap::PickObject(Int_t px, Int_t py, TString &str) const
    459474{
     475#if ROOT_VERSION_CODE < ROOT_VERSION(5,26,00)
    460476    Long_t key, val;
     477#else
     478    Long64_t key, val;
     479#endif
     480
    461481    TExMapIter map(this);
    462482    while (map.Next(key, val))
     
    500520    Int_t min = INT_MAX;
    501521
     522#if ROOT_VERSION_CODE < ROOT_VERSION(5,26,00)
    502523    Long_t key, val;
     524#else
     525    Long64_t key, val;
     526#endif
     527
    503528    TExMapIter map(this);
    504529    while (map.Next(key, val))
  • trunk/MagicSoft/Mars/mbase/MObjLookup.cc

    r8930 r9552  
    4444    TExMapIter iter(&fMap);
    4545
    46     Long_t key;
    47     Long_t value;
     46#if ROOT_VERSION_CODE < ROOT_VERSION(5,26,00)
     47    Long_t key, value;
     48#else
     49    Long64_t key, value;
     50#endif
    4851
    4952    while (iter.Next(key, value))
  • trunk/MagicSoft/Mars/mdata/MDataPhrase.cc

    r8907 r9552  
    115115#include <TPRegexp.h>
    116116#include <TFormula.h>
     117#if ROOT_VERSION_CODE >= ROOT_VERSION(5,26,00)
     118#include <TFormulaPrimitive.h>
     119#endif
    117120
    118121#include "MLog.h"
  • trunk/MagicSoft/Mars/mhflux/MMcSpectrumWeight.cc

    r9337 r9552  
    489489        // Ratio between the number of events in the zenith angle
    490490        // bin corresponding to x and the new spectrum.
     491#if ROOT_VERSION_CODE < ROOT_VERSION(5,26,00)
    491492        const Double_t f = h.Integral(x, x, -1, 9999)/norm;
     493#else
     494        const Double_t f = h.Integral(x, x)/norm;
     495#endif
    492496
    493497        // Fill histogram with the "new spectrum" between
  • trunk/MagicSoft/Mars/mjobs/MJob.cc

    r9497 r9552  
    414414        }
    415415
    416         if (flags&2==0)
     416        if ((flags&2)==0)
    417417        {
    418418            *fLog << err << "ERROR - " << dirname << " is not a directory." << endl;
  • trunk/MagicSoft/Mars/mjtrain/MJTrainDisp.cc

    r8888 r9552  
    6060#include "MJTrainDisp.h"
    6161
     62#include <TH2.h>
    6263#include <TLine.h>
    6364#include <TCanvas.h>
     
    113114    MH::SetPalette("pretty");
    114115
    115     TH1 &hist = *(TH1*)mh3.GetHist().Clone();
     116    TH2 &hist = *static_cast<TH2*>(mh3.GetHist().Clone());
    116117    hist.SetBit(TH1::kNoStats);
    117118    hist.SetDirectory(0);
Note: See TracChangeset for help on using the changeset viewer.