1 /**************************************************************************
2 * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * Author: The ALICE Off-line Project. *
5 * Contributors are mentioned in the code where appropriate. *
7 * Permission to use, copy, modify and distribute this software and its *
8 * documentation strictly for non-commercial purposes is hereby granted *
9 * without fee, provided that the above copyright notice appears in all *
10 * copies and that both the copyright notice and this permission notice *
11 * appear in the supporting documentation. The authors make no claims *
12 * about the suitability of this software for any purpose. It is *
13 * provided "as is" without express or implied warranty. *
14 **************************************************************************/
16 /* $Id: AliTRDqaGuiClusters.cxx 23871 2008-02-12 11:48:20Z hristov $ */
18 //////////////////////////////////////////////////////////////////////////////////
20 // This class is a Graphical User Interface for the Quality Monitorig
21 // of clusters on the full detector level.
22 // It displays histograms created by the AliTRDQADataMakerRec
23 // run during the reconstruction
29 //////////////////////////////////////////////////////////////////////////////////
31 #include "AliTRDqaGuiClusters.h"
36 #include "TRootEmbeddedCanvas.h"
38 ClassImp(AliTRDqaGuiClusters)
40 const Int_t AliTRDqaGuiClusters::fgkLogList[4] = {0,1,0,1};
42 //////////////////////////////////////////////////////////////////////////////////
43 AliTRDqaGuiClusters::AliTRDqaGuiClusters(TGWindow *parent)
44 : TGCompositeFrame(parent, 720, 400) {
49 SetLayoutManager(new TGMatrixLayout(this,2,2,1,1));
51 fNameList[0] = "detMap";
52 fNameList[1] = "nCls";
53 fNameList[2] = "signal";
54 fNameList[3] = "ampMPV";
56 for(Int_t i=0; i<4; i++) {
57 fCanvasList[i] = new TRootEmbeddedCanvas(fNameList[i], this, 480, 320);
58 AddFrame(fCanvasList[i]);
61 for(Int_t i=0; i<4; i++) {
67 //////////////////////////////////////////////////////////////////////////////////
69 void AliTRDqaGuiClusters::SetQAFile(const char *filename) {
71 // sets the file with histograms
74 for(Int_t i=0; i<4; i++) {
75 if (fHistList[i]) delete fHistList[i];
78 const char *opt[4] = {"colz", "", "", ""};
80 TFile *file = new TFile(filename);
81 file->cd("TRD/RecPoints");
83 for(int i=0; i<4; i++) {
84 fHistList[i] = (TH1D*)gDirectory->Get(Form("qaTRD_recPoints_%s", fNameList[i]));
85 fCanvasList[i]->GetCanvas()->cd();
86 gPad->SetLogy(fgkLogList[i]);
87 if (fHistList[i]) fHistList[i]->Draw(opt[i]);
88 fCanvasList[i]->GetCanvas()->Update();
92 //////////////////////////////////////////////////////////////////////////////////