Index: fact/tools/rootmacros/PulseTemplates/FPulseOverlay.C
===================================================================
--- fact/tools/rootmacros/PulseTemplates/FPulseOverlay.C	(revision 13738)
+++ fact/tools/rootmacros/PulseTemplates/FPulseOverlay.C	(revision 13779)
@@ -39,5 +39,4 @@
 
 #define NPIX  1440
-#define NCELL 1024
 #define FAD_MAX_SAMPLES 1024
 #define HAVE_ZLIB
@@ -160,5 +159,5 @@
     //Root-File Objects
 //    TObjArray*  hList[pixelSetSize] = {NULL};
-    TObjArray*  hRootList           = NULL;
+    TList*  hRootList           = NULL;
 
     TCanvas**   cgpPixelPulses      = NULL;
@@ -183,5 +182,4 @@
 void UpdateCanvases( int, int, bool);
 void DeletePixelCanvases( int, int );
-TString SetHostsPaths(TString filename, bool Input);
 
 TString gDataDirectory;
@@ -195,7 +193,7 @@
 //----------------------------------------------------------------------------
 int FPulseOverlay(
-        TString     datafilename        = "raw/2011/11/09/20111109_006.fits.gz",
-        TString     drsfilename         = "raw/2011/11/09/20111109_003.drs.fits.gz",
-        TString     OutRootFileName     = "analysis/FPulseTemplate/20111109_006/Overlay/20111109_006.root",
+        TString     datafilename        = "raw/2012/03/09/20120309_018.fits.gz",
+        TString     drsfilename         = "raw/2012/03/09/20120309_012.drs.fits.gz",
+        TString     OutRootFileName     = "analysis/FPulseTemplate/20120309_018/Overlay/20120309_018.root",
         bool            ProduceGraphic      = false,
         bool            spikeDebug          = false,
@@ -203,12 +201,12 @@
         bool            testmode            = false,
         bool            saveResults         = true,
-        int             verbosityLevel      = 0,        // different verbosity levels can be implemented here
+        int             verbosityLevel      = 1,        // different verbosity levels can be implemented here
         int             firstevent          = 1,        // Hast to be between 1 and infinity NOT 0!!!!
-        int             nevents             = 1,
+        int             nevents             = -1,
         int             firstpixel          = 0,
-        int             npixel              = 1,
-        int             pixelSetSize       = 200,
-        int             maxPulseOrder       = 4,
-        int             AmplWindowWidth     = 14,       //Width of Window for selection of pulses to histograms
+        int             npixel              = 2,
+        int             pixelSetSize       = 150,
+        int             maxPulseOrder       = 5,
+        int             AmplWindowWidth     = 16,       //Width of Window for selection of pulses to histograms
         TString         histoOptions        = "SRM",
         float           GainMean            = 9,
@@ -225,11 +223,11 @@
 //	Save-Root-File Settings
 //----------------------------------------------------------------------------
-    datafilename        = SetHostsPaths(datafilename      , true  );
-    drsfilename         = SetHostsPaths(drsfilename       , true  );
-    OutRootFileName     = SetHostsPaths(OutRootFileName   , false );
+    datafilename        = SetHostsPaths(false,   datafilename );
+    drsfilename         = SetHostsPaths(false,   drsfilename );
+    OutRootFileName     = SetHostsPaths(true,  OutRootFileName );
 
     if (saveResults)
     {
-        CreateRootFile( OutRootFileName, false, verbosityLevel );
+        CreateRootFile( OutRootFileName, true, verbosityLevel );
     }
 
@@ -487,10 +485,10 @@
                                 verbosityLevel,
                                 false,
+                                histoOptions,
                                 NULL,
                                 gPixelOverlayXaxisLeft,
                                 gPixelOverlayXaxisRight,
                                 gBSLMean,
-                                gGainMean,
-                                histoOptions
+                                gGainMean
                                 );
                 }
@@ -716,8 +714,8 @@
 // Draw Histograms
 //-------------------------------------
-
+    TString test = "root";
     SaveHistograms(     //save histograms of generell results into output root file
                 OutRootFileName,
-                "root",
+                test,
                 hRootList,
                 saveResults,
@@ -815,5 +813,5 @@
 {
     if (verbosityLevel > 2) cout << endl << "...book histograms" << endl;
-    hRootList = new TObjArray;
+    hRootList = new TList();
     debugHistos = new TH1F[ Number_Of_Debug_Histo_Types ];
     for ( int type = 0; type < Number_Of_Debug_Histo_Types; type++){
@@ -1216,37 +1214,5 @@
 
 
-TString
-SetHostsPaths(TString filename, bool Input)
-{
-    ghostname = gSystem->HostName();
-
-    TString temp_filename;
-
-    if ( ghostname.Contains("isdc") ) //IF ONE IS WORKING AT ISDC
-    {
-        gDataDirectory = "/fact/";
-        gHomeDirectory = "/home_nfs/isdc/jbbuss/";
-    }
-    if ( ghostname.Contains("hpc") ) //IF ONE IS WORKING AT PHIDO
-    {
-        gDataDirectory = "/fhgfs/groups/app/fact-construction/";
-        gHomeDirectory = "/home/jbuss/";
-    }
-
-    if (Input)
-    {
-        temp_filename = gDataDirectory;
-        temp_filename += filename;
-        filename = temp_filename;
-    }
-    else if (!Input)
-    {
-        temp_filename = gHomeDirectory;
-        temp_filename += filename;
-        filename = temp_filename;
-    }
-
-    return filename;
-}
+
 
 
