Index: /trunk/MagicSoft/Mars/Changelog
===================================================================
--- /trunk/MagicSoft/Mars/Changelog	(revision 3729)
+++ /trunk/MagicSoft/Mars/Changelog	(revision 3730)
@@ -18,4 +18,11 @@
 
                                                  -*-*- END OF LINE -*-*-
+ 2004/04/14: Markus Gaug
+  
+   * htmldoc/images/CalibClasses.gif
+   * htmldoc/images/RelTimeClasses.gif
+     - two schemes used in the class descriptions
+
+
  2004/04/13: Markus Gaug
 
Index: /trunk/MagicSoft/Mars/macros/calibClasses.C
===================================================================
--- /trunk/MagicSoft/Mars/macros/calibClasses.C	(revision 3729)
+++ /trunk/MagicSoft/Mars/macros/calibClasses.C	(revision 3730)
@@ -27,5 +27,6 @@
 //  calibClasses
 //
-//  This macro draws the scheme found in htmldoc/images/CalibClasses.gif
+//  This macro draws the schemes found in htmldoc/images/CalibClasses.gif
+//  and htmldoc/images/RelTimeClasses.gif
 //
 /////////////////////////////////////////////////////////////////////////////
@@ -63,5 +64,4 @@
   const Float_t pt3x2 = 0.975;
 
-
   Float_t arry1  = 0.;
   Float_t arry2  = 0.;
@@ -530,3 +530,200 @@
 
    CalibClasses->SaveAs("htmldoc/images/CalibClasses.gif");
+
+   //
+   // Relative Time classes
+   //
+
+   TCanvas *RelTimeClasses = new TCanvas("RelTimeClasses", "Relative Time Calibration Classes",89,96,758,1051);
+   RelTimeClasses->Range(0,0,1,1);
+   RelTimeClasses->SetBorderSize(2);
+   RelTimeClasses->SetFrameFillColor(0);
+   
+// First line:
+   TPaveText *pt = new TPaveText(0.375,0.895,0.785,0.95,"br");
+   pt->SetFillColor(18);
+   TText *text = pt->AddText("MRawEvtData");
+   pt->Draw();
+      tex = new TLatex(0.55,0.955,"C");
+   tex->SetTextSize(0.05);
+   tex->SetLineWidth(2);
+   tex->Draw();
+   
+
+// Second line:
+   elly1 = 0.805;
+
+   ellipse = new TEllipse(ell2x1,elly1,ellr1,ellr2,0,360,0);
+   ellipse->Draw();
+   
+   texy1 = 0.805;
+
+      tex = new TLatex(tex2x1,texy1,"MArrivalTimeCalc:");
+   tex->SetTextSize(texsize);
+   tex->SetLineWidth(2);
+   tex->Draw();
+
+   texy1 = 0.79;
+
+   tex = new TLatex(tex2x1+0.02,texy1,"Abs. Arrival Time");
+   tex->SetTextSize(texsize2);
+   tex->SetTextColor(kRed);
+   tex->SetLineWidth(1);
+   tex->Draw();
+
+   arry1 = 0.89;
+   arry2 = 0.84;
+
+   arrow = new TArrow(arr2x1,arry1,arr2x1,arry2,arrsize,"|>");
+   arrow->SetFillColor(1);
+   arrow->SetFillStyle(1001);
+   arrow->Draw();
+
+   
+// Third line:
+   pty1 = 0.67;
+   pty2 = 0.73;
+   
+   pt = new TPaveText(pt2x1,pty1,pt2x2,pty2,"br");
+   pt->SetFillColor(18);
+   text = pt->AddText("MArrivalTimeCam");
+   pt->Draw();
+   
+   arry1 = 0.77;
+   arry2 = 0.73;
+
+   arrow = new TArrow(arr2x1,arry1,arr2x1,arry2,arrsize,"|>");
+   arrow->SetFillColor(1);
+   arrow->SetFillStyle(1001);
+   arrow->Draw();
+
+// Fourth line:
+   elly1 = 0.6;
+
+   TEllipse *ellipse = new TEllipse(ell2x1,elly1,0.235,0.04,0,360,0);
+   ellipse->Draw();
+   
+   texy1 = 0.6;
+
+   tex = new TLatex(tex2x1-0.05,texy1,"MHCalibrationRelTimeCam:");
+   tex->SetTextSize(texsize);
+   tex->SetLineWidth(2);
+   tex->Draw();
+
+
+   arrow = new TArrow(0.35,0.465,0.15,0.39,arrsize,"|>");
+   arrow->SetFillColor(1);
+   arrow->SetFillStyle(1001);
+   arrow->Draw();
+
+   tex = new TLatex(0.17,0.425,"Oscillations");
+   tex->SetTextSize(texsize2+0.006);
+   tex->SetTextAngle(27);
+   tex->SetTextColor(006);
+   tex->SetLineWidth(1);
+   tex->Draw();
+
+   tex = new TLatex(0.175,0.41,"Absurd results");
+   tex->SetTextSize(texsize2+0.006);
+   tex->SetTextAngle(27);
+   tex->SetTextColor(006);
+   tex->SetLineWidth(1);
+   tex->Draw();
+
+// seventh line
+   pty1 = 0.315;
+   pty2 = 0.39;
+
+   pt = new TPaveText(0.015,pty1,0.25,pty2,"br");
+   pt->SetFillColor(18);
+   text = pt->AddText("MBadPixelsCam:");
+   text = pt->AddText("kUnreliableRun");
+   text->SetTextColor(kBlue);
+   pt->Draw();
+   
+   texy1 = 0.59;
+
+   tex = new TLatex(tex2x1-0.04,texy1,"Calculate Rel. Arrival Times");
+   tex->SetTextSize(texsize2);
+   tex->SetTextColor(kRed);
+   tex->SetLineWidth(1);
+   tex->Draw();
+   tex = new TLatex(tex2x1-0.04,texy1-0.01," (w.r.t. pixel 1 software idx)");
+   tex->SetTextSize(texsize2);
+   tex->SetTextColor(kRed);
+   tex->SetLineWidth(1);
+   tex->Draw();
+
+   arry1 = 0.67;
+   arry2 = 0.63;
+
+   arrow = new TArrow(arr2x1,arry1,arr2x1,arry2,arrsize,"|>");
+   arrow->SetFillColor(1);
+   arrow->SetFillStyle(1001);
+   arrow->Draw();
+
+   arry1 = 0.56;
+   arry2 = 0.52;
+
+   arrow = new TArrow(arr2x1,arry1,arr2x1,arry2,arrsize,"|>");
+   arrow->SetFillColor(1);
+   arrow->SetFillStyle(1001);
+   arrow->Draw();
+
+// Fifth line:
+   pty1 = 0.44;
+   pty2 = 0.52;
+
+
+   pt = new TPaveText(0.3,pty1,0.85,pty2,"br");
+   pt->SetFillColor(18);
+   text = pt->AddText("MCalibrationRelTimeCam:");
+   pt->Draw();
+   text = pt->AddText("Offset, Resolution, errors");
+   text->SetTextColor(kBlue);
+   pt->Draw();
+
+
+
+// eightth line:
+
+   Float_t nellx1 = 0.39;
+   elly1 = 0.36;
+
+   ellipse = new TEllipse(0.57,elly1,0.235,0.04,0,360,0);
+   ellipse->Draw();
+
+   tex = new TLatex(nellx1,elly1,"MCalibrateTime:");
+   tex->SetTextSize(0.0328253);
+   tex->SetLineWidth(2);
+   tex->Draw();
+
+   tex = new TLatex(nellx1+0.02,elly1-0.02,"Offset correction");
+   tex->SetTextSize(texsize);
+   tex->SetTextColor(kRed);
+   tex->SetLineWidth(1);
+   tex->Draw();
+
+   arry1 = 0.44;
+   arry2 = 0.4;
+
+   arrow = new TArrow(arr2x1,arry1,arr2x1,arry2,arrsize,"|>");
+   arrow->SetFillColor(1);
+   arrow->SetFillStyle(1001);
+   arrow->Draw();
+
+   Float_t linex1 = 0.25;
+   Float_t liney1 = 0.36;
+
+   arrow = new TArrow(linex1,liney1,0.335,liney1,arrsize,"|>");
+   arrow->SetFillColor(1);
+   arrow->SetFillStyle(1001);
+   arrow->Draw();
+
+   RelTimeClasses->Modified();
+   RelTimeClasses->cd();
+
+   RelTimeClasses->SaveAs("htmldoc/images/RelTimeClasses.gif");
+
+
 }
Index: /trunk/MagicSoft/Mars/mjobs/MJCalibration.cc
===================================================================
--- /trunk/MagicSoft/Mars/mjobs/MJCalibration.cc	(revision 3729)
+++ /trunk/MagicSoft/Mars/mjobs/MJCalibration.cc	(revision 3730)
@@ -50,4 +50,16 @@
 //           MCalibrationChargeBlindPix, MCalibrationChargePINDiode,
 //           MCalibrationQECam, MBadPixelsPix, MBadPixelsCam
+//
+// If the flag RelTimeCalibration() is set, a calibration of the relative arrival 
+// times is also performed. The following containers (rectangular) and 
+// tasks (ellipses) are called to produce an MCalibrationRelTimeCam used by  
+// MCalibrateTime to correct timing offset between pixels: (MCalibrateTime is not 
+// called from this class)
+//
+//Begin_Html
+/*
+<img src="images/RelTimeClasses.gif">
+*/
+//End_Html
 //
 /////////////////////////////////////////////////////////////////////////////
