/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveEventManager.h"
//
// Missing support for raw-data. For now this is handled individually
// by each sub-detector.
-//
+//
ClassImp(AliEveEventManager)
else
Warning(eH, "Bootstraping of run-loader failed.");
}
-
+
TString esd_path(Form("%s/AliESDs.root", fPath.Data()));
if (gSystem->AccessPathName(esd_path, kReadPermission) == kFALSE)
if (fgAssertESDTree)
{
throw(eH + "ESD not initialized. Its precence was requested.");
- } else {
+ } else {
Warning(eH, "ESD not initialized.");
}
}
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_EventAlieve_H
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
/**************************************************************************
* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
/** @file AliEveHOMERManager.cxx
@author Jochen Thaeder
- @date
+ @date
@brief Manger for HOMER in offline
*/
/*
* ---------------------------------------------------------------------------------
- * Constructor / Destructor
- * ---------------------------------------------------------------------------------
+ * Constructor / Destructor
+ * ---------------------------------------------------------------------------------
*/
//##################################################################################
fLibManager(new AliHLTHOMERLibManager),
fXMLFile(xmlFile),
- fXMLParser(NULL),
+ fXMLParser(NULL),
fRootNode(NULL),
fSourceList(NULL),
fReader(NULL),
fReader = NULL;
}
- if ( fXMLParser )
+ if ( fXMLParser )
delete fXMLParser;
fXMLParser = NULL;
/*
* ---------------------------------------------------------------------------------
* Source Handling
- * ---------------------------------------------------------------------------------
+ * ---------------------------------------------------------------------------------
*/
//##################################################################################
fXMLParser = new TDOMParser();
fXMLParser->SetValidate( kFALSE );
-
+
Int_t iResult = fXMLParser->ParseFile( fXMLFile );
if ( iResult < 0 ) {
iResult = 1;
if ( fSourceList != NULL )
delete fSourceList;
fSourceList = NULL;
-
+
fSourceList = new TList();
fSourceList->SetOwner( kTRUE );
// -- Set ROOT node
fRootNode = fXMLParser->GetXMLDocument()->GetRootNode();
-
+
TXMLNode * node = NULL;
TXMLNode * prevNode = fRootNode->GetChildren();
// -- Find only "Process" nodes, otherwise continue to next node
if ( strcmp( node->GetNodeName(), "Proc" ) != 0 )
continue;
-
+
// -- Get Attributes of current node
TList *attrList = node->GetAttributes();
TXMLAttr *attr = 0;
TIter next(attrList);
-
+
while ( ( attr = (TXMLAttr*)next() ) ) {
-
+
// -- Find "ID" attribute, otherwise continue to next attribute
- if ( strcmp( attr->GetName(), "ID" ) != 0 )
+ if ( strcmp( attr->GetName(), "ID" ) != 0 )
continue;
-
+
TString nodeId( attr->GetValue() );
- // -- Find only TDS processes
+ // -- Find only TDS processes
TObjArray * nodeIdTok = nodeId.Tokenize("_");
for ( Int_t ii=0 ; ii < nodeIdTok->GetEntries() ; ii++ ) {
//##################################################################################
Int_t AliEveHOMERManager::GetTDSAttributes( TXMLNode * xmlNode ) {
// see header file for class documentation
-
+
Int_t iResult = 0;
TXMLNode * attrNode = NULL;
TString xmlHostname = 0;
TString xmlPort = 0;
- TString hostname = 0;
+ TString hostname = 0;
Int_t port = 0;
// -- Get hostname and port from TDS node out of XML
while ( ( attrNode = prevNode->GetNextNode() ) ) {
prevNode = attrNode;
-
+
// -- Get port out of the commandline
if ( strcmp( attrNode->GetNodeName(), "Cmd" ) == 0 ) {
TString cmd( attrNode->GetText() );
-
+
TObjArray * cmdTok = cmd.Tokenize(" ");
xmlPort = ((TObjString*) cmdTok->At(2))->GetString();
- }
+ }
// -- Get hostname
- else if ( strcmp( attrNode->GetNodeName(), "Node" ) == 0 )
+ else if ( strcmp( attrNode->GetNodeName(), "Node" ) == 0 )
xmlHostname = attrNode->GetText();
} // while ( ( attrNode = prevNode->GetNextNode() ) ) {
-
+
// -- Resolve hostname and port information
iResult = ResolveHostPortInformation ( xmlHostname, xmlPort, hostname, port );
if ( iResult == 1 ) {
}
// -- Reset loop to TDS node
- prevNode = xmlNode;
+ prevNode = xmlNode;
// -- Get Sources out of XML, resolve sources, add to sources ListxmlHostname.Data()
while ( ( attrNode = prevNode->GetNextNode() ) ) {
prevNode = attrNode;
-
+
// Find only "Parent" tags, otherwise continue to next tag
- if ( strcmp( attrNode->GetNodeName(), "Parent" ) != 0 )
+ if ( strcmp( attrNode->GetNodeName(), "Parent" ) != 0 )
continue;
TString xmlParent = attrNode->GetText();
-
+
AliHLTHOMERSourceDesc * source = new AliHLTHOMERSourceDesc( hostname, port );
-
+
if ( ResolveSourceInformation( xmlParent, source ) ) {
iResult = 3;
AliError( Form("Error resolving source : %s", xmlParent.Data()) );
-
+
delete source;
}
else {
fSourceList->Add( source );
AliInfo( Form("New Source added : %s", xmlParent.Data()) );
}
-
+
} // while ( ( attrNode = prevNode->GetNextNode() ) ) {
-
+
return iResult;
}
TString nodeName = 0;
while ( ( node = prevNode->GetNextNode() ) && iResult == 1 ) {
prevNode = node;
-
+
// -- Find only "Node" nodes, otherwise continue
if ( strcmp( node->GetNodeName(), "Node" ) != 0 )
continue;
TList *attrList = node->GetAttributes();
TXMLAttr *attr = 0;
TIter next(attrList);
-
+
TString nodeId = 0;
// TString nodeName = 0;
-
+
// Get "nodeID" and "nodeName" of this "Node" node
while ( ( attr = (TXMLAttr*)next() ) ) {
if ( strcmp( attr->GetName(), "ID" ) == 0 )
nodeId = attr->GetValue();
else if ( strcmp( attr->GetName(), "hostname" ) == 0 )
nodeName = attr->GetValue();
- }
+ }
// -- if this is not the correct nodeID continue
if ( nodeId != xmlHostname )
// *** Resolve port
if ( xmlPort.IsDigit() ) {
-
+
if ( nodeName.CompareTo("feptriggerdet") ==0 ){
if ( xmlPort.CompareTo("49152") == 0 ){
port = 58140;
} else if ( xmlPort.CompareTo("49153") == 0 ){
port = 58141;
- }
+ }
} else if ( nodeName.CompareTo("fepfmdaccorde") == 0 ){
if ( xmlPort.CompareTo("49152") == 0 ){
port = 58144;
} else if ( xmlPort.CompareTo("49153") == 0 ){
port = 58145;
- }
+ }
} else if ( nodeName.CompareTo("feptpcao15") == 0 ){
if ( xmlPort.CompareTo("49152") == 0 ){
port = 50340;
// *** Summary
if ( !iResult ) {
- AliInfo( Form("%s:%i resolved out of %s:%s", hostname.Data(), port, xmlHostname.Data(), xmlPort.Data()) );
+ AliInfo( Form("%s:%i resolved out of %s:%s", hostname.Data(), port, xmlHostname.Data(), xmlPort.Data()) );
}
return iResult;
return iResult;
}
-
+
TObjArray * parentTokens = xmlParent.Tokenize("_");
-
+
Int_t nEntries = parentTokens->GetEntries();
-
+
TString detector = ((TObjString*) parentTokens->At(0) )->GetString();
TString subDetector = "";
TString subSubDetector = "";
TString name = ((TObjString*) parentTokens->At(1) )->GetString();
TString objName = "";
-
- if ( nEntries == 3 )
- subDetector = ((TObjString*) parentTokens->At(2) )->GetString();
+
+ if ( nEntries == 3 )
+ subDetector = ((TObjString*) parentTokens->At(2) )->GetString();
else if ( nEntries == 4 ) {
- subDetector = ((TObjString*) parentTokens->At(2) )->GetString();
- subSubDetector = ((TObjString*) parentTokens->At(3) )->GetString();
+ subDetector = ((TObjString*) parentTokens->At(2) )->GetString();
+ subSubDetector = ((TObjString*) parentTokens->At(3) )->GetString();
}
-
+
// -- Corecct TPC subdetector, because in we have somtimes "A","C"
if ( ! detector.CompareTo("TPC") ) {
if ( subDetector.BeginsWith('A') ) {
objName = "";
dataType = "DDL_RAW";
specification = 0;
- }
+ }
// **** TPC ****
else if ( detector == "TPC" ) {
-
+
if ( name == "CalibPedestal" ) {
objName = "AliTPCCalibPedestal";
dataType = "HIS_CAL";
specification = 0;
}
else if ( name == "CalibPulser" ) {
- objName = "AliTPCCalibPulser";
+ objName = "AliTPCCalibPulser";
dataType = "HIS_CAL";
specification = 0;
}
else if ( name == "CF" || name == "RelayCF" ) {
- objName = "AliHLTTPCClusterDataFormat";
+ objName = "AliHLTTPCClusterDataFormat";
dataType = "CLUSTERS";
specification = 0;
}
else if ( name == "ESDConv" ) {
- objName = "AliESDEvent";
+ objName = "AliESDEvent";
dataType = "ESD_TREE";
specification = 0;
}
else if ( detector == "MUON" ) {
} // else if ( detector == "MUON" ) {
-
+
// -- Fill object
source->SetSourceName( name, objName );
source->SetSourceType( specification, dataType );
AliInfo( Form("Set Source %s , Type %s, ClassName %s .", name.Data(), dataType.Data(), objName.Data()) );
- AliInfo( Form(" Detector %s , SubDetector : %s, SubSubDetector %s .",
+ AliInfo( Form(" Detector %s , SubDetector : %s, SubSubDetector %s .",
detector.Data(), subDetector.Data(), subSubDetector.Data()) );
return iResult;
/*
* ---------------------------------------------------------------------------------
* Connection Handling
- * ---------------------------------------------------------------------------------
+ * ---------------------------------------------------------------------------------
*/
//##################################################################################
Int_t AliEveHOMERManager::ConnectHOMER(){
// see header file for class documentation
- Int_t iResult = 0;
+ Int_t iResult = 0;
// -- Check if already connected and state has not changed
if ( fStateHasChanged == kFALSE && IsConnected() ) {
AliInfo( Form("No need for reconnection.") );
return iResult;
}
-
+
// -- If already connected, disconnect before connect
- if ( IsConnected() )
+ if ( IsConnected() )
DisconnectHOMER();
// *** Create the Readoutlist
UInt_t sourceCount = 0;
CreateReadoutList( sourceHostnames, sourcePorts, sourceCount );
-
+
if ( sourceCount == 0 ) {
AliError(Form("No sources selected, aborting.") );
return iResult;
}
// *** Connect to data sources
-
+
if ( !fReader ) {
- if ( fLibManager )
+ if ( fLibManager )
fReader = fLibManager->OpenReader( sourceCount, sourceHostnames, sourcePorts );
}
-
+
iResult = fReader->GetConnectionStatus();
-
- if ( iResult ) {
- // -- Connection failed
-
+
+ if ( iResult ) {
+ // -- Connection failed
+
UInt_t ndx = fReader->GetErrorConnectionNdx();
-
+
if ( ndx < sourceCount ) {
- AliError( Form("Error : Error establishing connection to TCP source %s:%hu: %s (%d)",
+ AliError( Form("Error : Error establishing connection to TCP source %s:%hu: %s (%d)",
sourceHostnames[ndx], sourcePorts[ndx], strerror(iResult), iResult) );
}
else {
fLibManager->DeleteReader( fReader );
fReader = NULL;
- }
+ }
else {
// -- Connection ok - set reader
- fConnected = kTRUE;
-
+ fConnected = kTRUE;
+
AliInfo( Form("Connection established") );
}
-
+
delete[] sourceHostnames;
delete[] sourcePorts;
-
+
// -- Get next event
if ( ! iResult )
NextEvent();
-
+
return iResult;
}
fStateHasChanged = kTRUE;
fConnected = kFALSE;
-
+
AliInfo( Form("Connection closed") );
return;
TIter next( fSourceList );
while ( ( source = (AliHLTHOMERSourceDesc*)next() ) ) {
- if ( ! source->IsSelected() )
+ if ( ! source->IsSelected() )
continue;
-
+
Bool_t exists = kFALSE;
// -- Loop over existing entries and check if entry is already in readout list
break;
}
}
-
+
// -- Add new entires to readout list
if ( ! exists ) {
sourcePorts[sourceCount] = source->GetPort();
/*
* ---------------------------------------------------------------------------------
* AliEveEventManager Handling
- * ---------------------------------------------------------------------------------
+ * ---------------------------------------------------------------------------------
*/
//##################################################################################
Int_t AliEveHOMERManager::NextEvent(){
// see header file for class documentation
-
+
Int_t iResult = 0;
-
+
if ( !fReader || ! IsConnected() ) {
AliWarning( Form( "Not connected yet." ) );
return 1;
}
-
+
// -- Read next event data and error handling for HOMER (error codes and empty blocks)
while( 1 ) {
iResult = fReader->ReadNextEvent( 20000000 /*timeout in us*/);
-
+
if ( iResult == 111 || iResult == 32 || iResult == 6 ) {
Int_t ndx = fReader->GetErrorConnectionNdx();
AliError( Form("Error, No Connection to source %d: %s (%d)", ndx, strerror(iResult), iResult) );
-
+
return 2;
}
else if ( iResult == 110 ) {
Int_t ndx = fReader->GetErrorConnectionNdx();
AliError( Form("Timout occured, reading event from source %d: %s (%d)", ndx, strerror(iResult), iResult) );
- return 3;
+ return 3;
}
else if ( iResult == 56) {
Int_t ndx = fReader->GetErrorConnectionNdx();
AliError( Form("Error reading event from source %d: %s (%d) -- IRESULTRY", ndx, strerror(iResult), iResult) );
- continue;
+ continue;
}
else if ( iResult ) {
Int_t ndx = fReader->GetErrorConnectionNdx();
}
} // while( 1 ) {
- if ( iResult )
+ if ( iResult )
return iResult;
// -- Fill block list
while ( iter != NULL ){
-
+
// -- Create new block
- AliHLTHOMERBlockDesc * block = new AliHLTHOMERBlockDesc( GetBlk(), GetBlkSize(), GetBlkOrigin(),
+ AliHLTHOMERBlockDesc * block = new AliHLTHOMERBlockDesc( GetBlk(), GetBlkSize(), GetBlkOrigin(),
GetBlkType(), GetBlkSpecification() );
-
+
// -- Check sources list if block is requested
if ( CheckIfRequested( block ) )
- fBlockList->Add( block );
- else
+ fBlockList->Add( block );
+ else
delete block;
-
+
iter = GetNextBlk();
-
+
} // while ( iter != NULL ){
-
+
return iResult;
}
/*
* ---------------------------------------------------------------------------------
* BlockHandling
- * ---------------------------------------------------------------------------------
+ * ---------------------------------------------------------------------------------
*/
//##################################################################################
// see header file for class documentation
void* data = NULL;
-
+
if ( !fReader || ! IsConnected() ) {
- AliError( Form("Not connected yet.") );
+ AliError( Form("Not connected yet.") );
}
else {
- if ( ( ndx ) < (Int_t) fNBlks )
+ if ( ( ndx ) < (Int_t) fNBlks )
data = (void*) fReader->GetBlockData( ndx );
}
ULong_t length = 0;
if ( !fReader || ! IsConnected() ) {
- AliError( Form("Not connected yet.") );
+ AliError( Form("Not connected yet.") );
}
else {
- if ( ( ndx ) < (Int_t) fNBlks )
+ if ( ( ndx ) < (Int_t) fNBlks )
length = (ULong_t) fReader->GetBlockDataLength( ndx );
}
// -- Check for Connection
if ( !fReader || ! IsConnected() ) {
- AliError( Form("Not connected yet.") );
+ AliError( Form("Not connected yet.") );
return origin;
}
// -- Check block index
if ( ( ndx ) >= (Int_t) fNBlks ) {
- AliError( Form("Block index %d out of range.", ndx ) );
- return origin;
+ AliError( Form("Block index %d out of range.", ndx ) );
+ return origin;
}
// -- Get origin
// -- Check for Connection
if ( !fReader || ! IsConnected() ) {
- AliError( Form("Not connected yet.") );
+ AliError( Form("Not connected yet.") );
return type;
}
// -- Check blockk index
if ( ( ndx ) >= (Int_t) fNBlks ) {
- AliError( Form("Block index %d out of range.", ndx ) );
- return type;
+ AliError( Form("Block index %d out of range.", ndx ) );
+ return type;
}
// -- Get type
// -- Check for Connection
if ( !fReader || ! IsConnected() ) {
- AliError( Form("Not connected yet.") );
+ AliError( Form("Not connected yet.") );
return spec;
}
// -- Check blockk index
if ( ( ndx ) >= (Int_t) fNBlks ) {
- AliError( Form("Block index %d out of range.", ndx ) );
- return spec;
+ AliError( Form("Block index %d out of range.", ndx ) );
+ return spec;
}
-
+
spec = (ULong_t) fReader->GetBlockDataSpec( ndx );
return spec;
// see header file for class documentation
Bool_t requested = kFALSE;
-
+
AliHLTHOMERSourceDesc * source= NULL;
-
+
// -- Read all sources and check if they should be read out
TIter next( fSourceList );
while ( ( source = (AliHLTHOMERSourceDesc*)next() ) ) {
- if ( ! source->IsSelected() )
+ if ( ! source->IsSelected() )
continue;
if ( source->GetDetector().CompareTo( block->GetDetector() ) )
if ( source->GetSubDetector().Atoi() != block->GetSubDetector().Atoi() )
continue;
-
+
if ( ! block->HasSubSubDetectorRange() ) {
-
+
// if ( source->GetSubSubDetector().Atoi() != block->GetSubSubDetector().Atoi() )
// continue;
-
+
} // if ( ! block->HasSubSubDetectorRange ) {
} // if ( ! block->HasSubDetectorRange ) {
-
+
requested = kTRUE;
-
+
} // while ( ( source = (AliHLTHOMERSourceDesc*)next() ) ) {
-
+
if ( requested) {
- AliInfo( Form("Block requested : %s - %s : %s/%s -> %s ", block->GetDetector().Data(), block->GetDataType().Data(),
+ AliInfo( Form("Block requested : %s - %s : %s/%s -> %s ", block->GetDetector().Data(), block->GetDataType().Data(),
block->GetSubDetector().Data(), block->GetSubSubDetector().Data(), block->GetClassName().Data() ) );
}
else
// see header file for class documentation
TList* srcList = GetSourceList();
-
+
AliHLTHOMERSourceDesc *desc = 0;
TIter next(srcList);
-
+
while ( ( desc = (AliHLTHOMERSourceDesc*)next() ) ) {
- if ( ! desc->GetClassName().CompareTo( objectName ) )
+ if ( ! desc->GetClassName().CompareTo( objectName ) )
desc->Select();
}
}
// see header file for class documentation
TList* srcList = GetSourceList();
-
+
AliHLTHOMERSourceDesc *desc = 0;
TIter next(srcList);
-
+
while ( ( desc = (AliHLTHOMERSourceDesc*)next() ) ) {
if ( ! desc->GetDataType().CompareTo( "DDL_RAW" ) ) {
desc->Select();
// see header file for class documentation
TList* srcList = GetSourceList();
-
+
AliHLTHOMERSourceDesc *desc = 0;
TIter next(srcList);
-
+
while ( ( desc = (AliHLTHOMERSourceDesc*)next() ) ) {
if ( ! desc->GetDataType().CompareTo( "CLUSTERS" ) ) {
desc->Select();
// see header file for class documentation
TList* srcList = GetSourceList();
-
+
AliHLTHOMERSourceDesc *desc = 0;
TIter next(srcList);
-
+
while ( ( desc = (AliHLTHOMERSourceDesc*)next() ) ) {
if ( ! desc->GetDataType().CompareTo( "ESD_TREE" ) ) {
desc->Select();
AliHLTHOMERBlockDesc *desc = 0;
TIter next(blockList);
-
+
while ( ( desc = (AliHLTHOMERBlockDesc*)next() ) ) {
if ( ! desc->IsTObject() )
continue;
-
+
Int_t sectorTPC = 0;
if ( desc->GetSubSubDetector().Atoi() <= 1 ) {
else {
sectorTPC = 36 + desc->GetSubDetector().Atoi();
}
-
+
if ( ! objectName.CompareTo( desc->GetClassName() ) ){
//
if ( ! objectName.CompareTo( "AliTPCCalibPedestal" ) ) {
AliTPCCalROC* calROC = NULL;
-
+
AliTPCCalibPedestal * cal = (AliTPCCalibPedestal*) desc->GetTObject();
if ( cal == NULL ) {
cout << "error 1" << endl;
continue;
}
-
+
cal->Analyse();
calROC = cal->GetCalRocRMS(sectorTPC);
cout << "error 2" << endl;
continue;
}
-
+
calROC->SetName(Form("RMS_ROC%d", sectorTPC));
fTPCPre->AddComponent((TObject*) calROC );
cout << "error 3" << endl;
continue;
}
-
+
calROC->SetName(Form("Pedestal_ROC%d", sectorTPC));
cout << "added" << endl;
AliTPCCalibPulser * cal = (AliTPCCalibPulser*) desc->GetTObject();
cal->Analyse();
-
+
calROC = cal->GetCalRocT0(sectorTPC);
calROC->SetName(Form("T0_ROC%d", sectorTPC));
fTPCPre->AddComponent((TObject*) calROC );
calROC->SetName(Form("Outliers_ROC%d", sectorTPC));
fTPCPre->AddComponent((TObject*) calROC );
}
-
+
*/
//
// AliTPCCalibCE
AliTPCCalibPulser * cal = (AliTPCCalibPulser*) desc->GetTObject();
cal->Analyse();
-
+
calROC = cal->GetCalRocT0(sectorTPC);
calROC->SetName(Form("T0_ROC%d", sectorTPC));
fTPCPre->AddComponent((TObject*) calROC );
}
*/
} // if ( ! objectName.CompareTo( desc->GetClassName() ) ) {
-
+
} // while ( ( desc = (AliHLTHOMERBlockDesc*)next() ) ) {
if ( dumpToFile ) {
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
//-*- Mode: C++ -*-
#ifndef ALIEVEHOMERMANGER_H
/** @file AliEveHOMERManager.h
@author Jochen Thaeder
- @date
+ @date
@brief Manager for HOMER in offline
*/
/**
* @class AliEveHOMERManager
- *
+ *
* This class is the main class of the AliEveHOMERManager
* ... more to come
*
/*
* ---------------------------------------------------------------------------------
- * Constructor / Destructor
- * ---------------------------------------------------------------------------------
+ * Constructor / Destructor
+ * ---------------------------------------------------------------------------------
*/
- /** constructor
+ /** constructor
* @param argc Number of command line arguments.
* @param argv Array of command line arguments.
*/
- AliEveHOMERManager(TString xmlFile="" );
+ AliEveHOMERManager(TString xmlFile="" );
/** not a valid copy constructor, defined according to effective C++ style */
- AliEveHOMERManager( const AliEveHOMERManager& );
+ AliEveHOMERManager( const AliEveHOMERManager& );
/** not a valid assignment op, but defined according to effective C++ style */
- AliEveHOMERManager& operator=( const AliEveHOMERManager& );
+ AliEveHOMERManager& operator=( const AliEveHOMERManager& );
/** destructor */
virtual ~AliEveHOMERManager();
/*
* ---------------------------------------------------------------------------------
* Source Handling - public
- * ---------------------------------------------------------------------------------
+ * ---------------------------------------------------------------------------------
*/
-
+
/** Create Sources List from HOMER-Proxy */
Int_t CreateHOMERSourcesList();
* @param source Pointer to AliHLTHOMERSourceDesc object.
* @param state New (selected/not selected) state.
*/
- void SetSourceState( AliHLTHOMERSourceDesc* source, Bool_t state);
+ void SetSourceState( AliHLTHOMERSourceDesc* source, Bool_t state);
/** Get pointer to source List
* @return returns pointer to TList of sources
/*
* ---------------------------------------------------------------------------------
* Connection Handling - public
- * ---------------------------------------------------------------------------------
+ * ---------------------------------------------------------------------------------
*/
-
+
/** Connect to HOMER sources, out of Readout List, which gets created when state has changed
- * @return 0 on sucess, "HOMER" errors on error
+ * @return 0 on sucess, "HOMER" errors on error
*/
Int_t ConnectHOMER();
/*
* ---------------------------------------------------------------------------------
* AliEveEventManager Handling - public
- * ---------------------------------------------------------------------------------
+ * ---------------------------------------------------------------------------------
*/
- /** Loads the next AliEveEventManager, after being connected
- * @return 0 on sucess, "HOMER" errors on error
+ /** Loads the next AliEveEventManager, after being connected
+ * @return 0 on sucess, "HOMER" errors on error
*/
Int_t NextEvent();
-
+
/** Get event ID
* @return Returns eventID
*/
/** Dynamic loader manager for the HOMER library */
AliHLTHOMERLibManager* fLibManager; //! transient
-
+
private:
/*
* ---------------------------------------------------------------------------------
* Source Handling - private
- * ---------------------------------------------------------------------------------
+ * ---------------------------------------------------------------------------------
*/
-
+
/** Get Information out of a TDS process in XML file
* @param xmlNode Pointer to childs of TDS node
- * @return 0 on sucess, > 0 on error
+ * @return 0 on sucess, > 0 on error
*/
Int_t GetTDSAttributes( TXMLNode * xmlNode );
* @param xmlPort Port out of the XML
* @param hostname Return of the hostname
* @param port Return of the port
- * @return 0 on sucess, 1 if hostname couldn't be resolved, 2 if port couldn't be resolved,
+ * @return 0 on sucess, 1 if hostname couldn't be resolved, 2 if port couldn't be resolved,
*/
Int_t ResolveHostPortInformation( TString xmlHostname, TString xmlPort, TString &hostname, Int_t &port );
- /** Resolve information of source
+ /** Resolve information of source
* @param xmlParent ParentString out of the XML
* @param source Return the filled AliHLTHOMERSourceDesc object
* @return 0 on sucess, 1 on error
/*
* ---------------------------------------------------------------------------------
* Connection Handling - private
- * ---------------------------------------------------------------------------------
+ * ---------------------------------------------------------------------------------
*/
-
- /** Create a readout list for Hostname and ports
+
+ /** Create a readout list for Hostname and ports
* @param socurceHostnames Array of selected hostnames
* @param socurcePorts Array of selected ports
* @param socurceCount Number of selected hostname:port
/* ---------------------------------------------------------------------------------
* Eve AliEveHOMERManager::foo(nt Handling - private
- * ---------------------------------------------------------------------------------
+ * ---------------------------------------------------------------------------------
*/
-
+
/** Create a TList of blocks, which have been readout */
Int_t CreateBlockList();
/*
* ---------------------------------------------------------------------------------
* Block Handling - private
- * ---------------------------------------------------------------------------------
+ * ---------------------------------------------------------------------------------
*/
/** Get Number of blocks in current event
* @return returns pointer to blk, 0 if no block present
*/
ULong_t GetBlkSize() { return GetBlkSize( fCurrentBlk ); }
-
+
/** Get origin of block ndx
* @param ndx Block index
* @return origin of block
*/
- TString GetBlkOrigin( Int_t ndx );
-
+ TString GetBlkOrigin( Int_t ndx );
+
/** Get origin of current block
* @param ndx Block index
* @return origin of block
/** Get specification of current block
* @param ndx Block index
* @return specification of block
- */
+ */
ULong_t GetBlkSpecification(){ return GetBlkSpecification( fCurrentBlk ); }
/** Checks if current Block should was requested
/*
* ---------------------------------------------------------------------------------
* Members - private
- * ---------------------------------------------------------------------------------
+ * ---------------------------------------------------------------------------------
*/
// == XML parser ==
TString fXMLFile; // see above
/** XML parser into DOM model */
- TDOMParser* fXMLParser; //! transient
-
+ TDOMParser* fXMLParser; //! transient
+
/** Root node of parsed config file */
- TXMLNode * fRootNode; //! transient
+ TXMLNode * fRootNode; //! transient
// == sources ==
/** List to HOMER sources */
- TList * fSourceList; //! transient
+ TList * fSourceList; //! transient
// == connection ==
-
+
/** Pointer to HOMER reader */
- AliHLTHOMERReader* fReader; //! transient
+ AliHLTHOMERReader* fReader; //! transient
// == blocks ==
/** List to HOMER blocks */
- TList * fBlockList; //! transient
+ TList * fBlockList; //! transient
// == events ==
-
+
/** Number of blockes in current event */
ULong_t fNBlks; // see above
/** Current block in current event */
ULong_t fCurrentBlk; // see above
-
+
// == states ==
/** Shows connection status */
Bool_t fConnected; // see above
- /** Indicates, if a sources have changes,
+ /** Indicates, if a sources have changes,
* so that one has to reconnect .
*/
Bool_t fStateHasChanged; // see above
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveHOMERManagerEditor.h"
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_AliEVEHOMERManagerEditor_H
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveHOMERSource.h"
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_AliEVEHOMERSource_H
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveHOMERSourceList.h"
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_AliEVEHOMERSourceList_H
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include <TMath.h>
// spd lowest resolution
Int_t nx = 8; // fSegSPD->Npx()/8; // 32
Int_t nz = 6; // fSegSPD->Npz()/2; // 128
- fSPDScaleX[1] = Int_t(nx);
- fSPDScaleZ[1] = Int_t(nz);
- fSPDScaleX[2] = Int_t(nx*2);
- fSPDScaleZ[2] = Int_t(nz*2);
- fSPDScaleX[3] = Int_t(nx*3);
- fSPDScaleZ[3] = Int_t(nz*3);
- fSPDScaleX[4] = Int_t(nx*4);
- fSPDScaleZ[4] = Int_t(nz*4);
+ fSPDScaleX[1] = Int_t(nx);
+ fSPDScaleZ[1] = Int_t(nz);
+ fSPDScaleX[2] = Int_t(nx*2);
+ fSPDScaleZ[2] = Int_t(nz*2);
+ fSPDScaleX[3] = Int_t(nx*3);
+ fSPDScaleZ[3] = Int_t(nz*3);
+ fSPDScaleX[4] = Int_t(nx*4);
+ fSPDScaleZ[4] = Int_t(nz*4);
fSDDScaleX[1] = 2;
fSDDScaleZ[1] = 2;
/**************************************************************************/
-AliEveITSDigitsInfo:: ~AliEveITSDigitsInfo()
+AliEveITSDigitsInfo:: ~AliEveITSDigitsInfo()
{
// Destructor.
// Deletes the data-maps and the tree.
for(j = fSSDmap.begin(); j != fSSDmap.end(); ++j)
delete j->second;
- delete fSegSPD; delete fSegSDD; delete fSegSSD;
+ delete fSegSPD; delete fSegSDD; delete fSegSSD;
delete fGeom;
delete fTree;
}
Int_t module = inputSPD.GetModuleID();
Int_t column = inputSPD.GetColumn();
Int_t row = inputSPD.GetRow();
-
+
if (inputSPD.IsNewModule())
{
digits = fSPDmap[module];
fSPDZCoord[0]=fZ1pitchSPD -fHlSPD;
for (m=1; m<fNzSPD; m++) {
Double_t dz=fZ1pitchSPD;
- if (m==31 || m==32 || m==63 || m==64 || m==95 || m==96 ||
- m==127 || m==128) dz=fZ2pitchSPD;
+ if (m==31 || m==32 || m==63 || m==64 || m==95 || m==96 ||
+ m==127 || m==128) dz=fZ2pitchSPD;
fSPDZCoord[m]=fSPDZCoord[m-1]+dz;
}
-
+
for (m=0; m<fNzSPD; m++) {
Double_t dz=1.*fZ1pitchSPD;
- if (m==31 || m==32 || m==63 || m==64 || m==95 || m==96 ||
- m==127 || m==128) dz=1.*fZ2pitchSPD;
+ if (m==31 || m==32 || m==63 || m==64 || m==95 || m==96 ||
+ m==127 || m==128) dz=1.*fZ2pitchSPD;
fSPDZCoord[m]-=dz;
}
-
+
// SDD
fSegSDD = new AliITSsegmentationSDD(fGeom);
// given by the AliEveITSModuleSelection object.
Int_t idx0 = 0, idx1 = 0;
- switch(sel->fType)
+ switch(sel->GetType())
{
case 0:
idx0 = 0;
for (Int_t id = idx0; id<idx1; ++id)
{
fGeom->GetModuleId(id, lay, lad, det);
- if (sel->fLayer == lay || sel->fLayer == -1)
+ if (sel->GetLayer() == lay || sel->GetLayer() == -1)
{
// check data from matrix
mx.UnitTrans();
mx.SetBaseVec(1, x[0], x[3], x[6]);
mx.SetBaseVec(2, x[1], x[4], x[7]);
mx.SetBaseVec(3, x[2], x[5], x[8]);
- fGeom->GetTrans(id, x);
+ fGeom->GetTrans(id, x);
mx.SetBaseVec(4, x);
mx.GetPos(v);
- if (v.Phi() <= sel->fMaxPhi && v.Phi() >= sel->fMinPhi &&
- v.Theta() <= sel->fMaxTheta && v.Theta() >= sel->fMinTheta)
+ if (v.Phi() <= sel->GetMaxPhi() && v.Phi() >= sel->GetMinPhi() &&
+ v.Theta() <= sel->GetMaxTheta() && v.Theta() >= sel->GetMinTheta())
{
ids.push_back(id);
}
printf("SPD dimesion of (%d,%d) in pixel(%f,%f)\n", ix, iz, fSegSPD->Dpx(ix), fSegSPD->Dpz(iz));
iz = 32;
printf("SPD dimesion of pixel (%d,%d) are (%f,%f)\n", ix, iz, fSegSPD->Dpx(ix)*0.001, fSegSPD->Dpz(iz)*0.001);
-
+
printf("*********************************************************\n");
printf("SDD module dimension (%f,%f)\n", fSegSDD->Dx()*0.0001, fSegSDD->Dz()*0.0001);
printf("SDD first,last module:: %d,%d\n", fGeom->GetStartSDD(), fGeom->GetLastSDD());
printf("SSD strips in module %d\n", fSegSSD->Npx());
printf("SSD strip sizes are (%f,%f)\n", fSegSSD->Dpx(1), fSegSSD->Dpz(1));
fSegSSD->SetLayer(5); fSegSSD->Angles(ap,an);
- printf("SSD layer 5 stereoP %f stereoN %f angle\n", ap, an);
+ printf("SSD layer 5 stereoP %f stereoN %f angle\n", ap, an);
fSegSSD->SetLayer(6); fSegSSD->Angles(ap,an);
- printf("SSD layer 6 stereoP %f stereoN %f angle\n", ap, an);
+ printf("SSD layer 6 stereoP %f stereoN %f angle\n", ap, an);
}
printf("Z::original (%3f) scaled (%3f, %3f) \n", zo, zn-dpz/2, zn+dpz/2);
printf("X::original (%3f) scaled (%3f, %3f) \n", xo, xn-dpx/2, xn+dpx/2);
printf("%d,%d maped to %d,%d \n", od->GetCoord1(), od->GetCoord2(), i,j );
-*/
+*/
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_ITSDigitsInfo_H
Float_t fMaxPhi; // Max phi.
Float_t fMinTheta; // Min theta.
Float_t fMaxTheta; // Max theta.
-
+
public:
AliEveITSModuleSelection();
virtual ~AliEveITSModuleSelection() {}
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveITSModule.h"
{
Float_t dx = info->fSegSPD->Dx()*0.00005;
- Float_t dz = 3.50;
+ Float_t dz = 3.50;
fgSPDFrameBox = new TEveFrameBox();
fgSPDFrameBox->SetAAQuadXZ(-dx, 0, -dz, 2*dx, 2*dz);
if (!fgStaticInitDone) {
InitStatics(fInfo);
-
+
fgSPDFrameBox->IncRefCount(this);
fgSPDPalette->IncRefCount();
-
+
fgSDDFrameBox->IncRefCount(this);
fgSDDPalette->IncRefCount();
TString strSensor = "Sensor";
TString symname;
Int_t id, nsector, nstave, nladder, rest;
-
+
if (fID <= fInfo->fGeom->GetLastSPD())
{
// SPD
SetFrame(fgSPDFrameBox);
SetPalette(fgSPDPalette);
-
+
symname += strLadder;
if (fID < 80)
{
SetName(symname);
fDetID = 0;
fDx = fInfo->fSegSPD->Dx()*0.00005;
- fDz = 3.50;
+ fDz = 3.50;
fDy = fInfo->fSegSPD->Dy()*0.00005;
}
SetFrame(fgSDDFrameBox);
SetPalette(fgSDDPalette);
-
+
symname += strSensor;
if (fID < 324)
{
symname += rest;
SetName(symname);
fDetID = 2;
- fInfo->fSegSSD->SetLayer(fLayer);
+ fInfo->fSegSSD->SetLayer(fLayer);
fDx = fInfo->fSegSSD->Dx()*0.00005;
fDz = fInfo->fSegSSD->Dz()*0.00005;
fDy = fInfo->fSegSSD->Dy()*0.00005;
}
- LoadQuads();
+ LoadQuads();
ComputeBBox();
if (trans)
SetTrans();
TClonesArray *digits = fInfo->GetDigits(fID, fDetID);
Int_t ndigits = digits ? digits->GetEntriesFast() : 0;
- Float_t x, z, dpx, dpz;
+ Float_t x, z, dpx, dpz;
Int_t i, j;
switch(fDetID)
{
case 0: { // SPD
- AliITSsegmentationSPD* seg = fInfo->fSegSPD;
+ AliITSsegmentationSPD* seg = fInfo->fSegSPD;
Reset(kQT_RectangleXZFixedY, kFALSE, 32);
}
case 1: { // SDD
- AliITSsegmentationSDD *seg = fInfo->fSegSDD;
+ AliITSsegmentationSDD *seg = fInfo->fSegSDD;
Reset(kQT_RectangleXZFixedY, kFALSE, 32);
}
case 2: { // SSD
- AliITSsegmentationSSD* seg = fInfo->fSegSSD;
+ AliITSsegmentationSSD* seg = fInfo->fSegSSD;
Reset(kQT_LineXZFixedY, kFALSE, 32);
fHMTrans.SetBaseVec(2, x[1], x[4], x[7]);
fHMTrans.SetBaseVec(3, x[2], x[5], x[8]);
// translation
- fInfo->fGeom->GetTrans(fID, x);
+ fInfo->fGeom->GetTrans(fID, x);
fHMTrans.SetBaseVec(4, x);
}
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_ITSModule_H
#define ALIEVE_ITSModule_H
AliEveITSModule& operator=(const AliEveITSModule&); // Not implemented
protected:
- AliEveITSDigitsInfo* fInfo;
+ AliEveITSDigitsInfo* fInfo;
Int_t fID; // Module id
Int_t fDetID; // Detector id (0~SPD, 1~SDD, 2~SSD)
Int_t fLayer;
Int_t fLadder;
Int_t fDet;
-
+
Float_t fDx;
Float_t fDz;
Float_t fDy;
AliEveITSDigitsInfo* GetDigitsInfo() const { return fInfo; }
void SetDigitsInfo(AliEveITSDigitsInfo* info);
-
+
Int_t GetSubDetID() const { return fDetID; }
Int_t GetID() const { return fID; }
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveITSModuleStepper.h"
AliEveITSModuleStepper::AliEveITSModuleStepper(AliEveITSDigitsInfo* di) :
TEveElementList("ITS 2DStore", "AliEveITSModuleStepper", kTRUE),
- fPosition(0),
-
+ fPosition(0),
+
fDigitsInfo(di),
fScaleInfo(0),
if (N != GetNChildren())
{
DestroyElements();
- for (Int_t m=0; m<N; m++)
+ for (Int_t m=0; m<N; m++)
{
AddElement(new AliEveITSScaledModule(m, fDigitsInfo, fScaleInfo));
}
void AliEveITSModuleStepper::SetFirst(Int_t first)
{
Int_t lastpage = fIDs.size()/Nxy();
- if(fIDs.size() % Nxy() ) lastpage++;
-
+ if(fIDs.size() % Nxy() ) lastpage++;
+
Int_t first_lastpage = (lastpage -1)*Nxy();
if(first > first_lastpage) first = first_lastpage;
if(first < 0) first = 0;
}
void AliEveITSModuleStepper::End()
-{
+{
Int_t lastpage = fIDs.size()/Nxy();
- if(fIDs.size() % Nxy() ) lastpage++;
+ if(fIDs.size() % Nxy() ) lastpage++;
fPosition = (lastpage -1)*Nxy();
- fStepper->Reset();
+ fStepper->Reset();
Apply();
}
fSubDet = det;
fIDs.clear();
AliEveITSModuleSelection sel = AliEveITSModuleSelection();
- sel.fType = det; sel.fLayer=layer;
+ sel.SetType (det);
+ sel.SetLayer(layer);
fDigitsInfo->GetModuleIDs(&sel, fIDs);
//in reder menu define a space between left and right pager
fPagerGap = 1.2*TextLength(Form("%d/%d",GetPages(), GetPages()));
{
fIDs.clear();
AliEveITSModuleSelection sel = AliEveITSModuleSelection();
- sel.fMaxTheta = max; sel.fMinTheta=min;
+ sel.SetThetaRange(min, max);
fDigitsInfo->GetModuleIDs(&sel, fIDs);
Start();
}
Int_t AliEveITSModuleStepper::GetCurrentPage()
{
- Int_t idx = fPosition +1;
+ Int_t idx = fPosition +1;
Int_t n = idx/Nxy();
if(idx % Nxy()) n++;
return n;
Int_t AliEveITSModuleStepper::GetPages()
{
- Int_t n = fIDs.size()/Nxy();
- if(fIDs.size() % Nxy()) n++;
+ Int_t n = fIDs.size()/Nxy();
+ if(fIDs.size() % Nxy()) n++;
return n;
}
-
+
/**************************************************************************/
void AliEveITSModuleStepper::Apply()
UInt_t idx = fPosition;
for(List_i childit=fChildren.begin(); childit!=fChildren.end(); ++childit)
{
- if(idx < fIDs.size())
+ if(idx < fIDs.size())
{
AliEveITSScaledModule* mod = dynamic_cast<AliEveITSScaledModule*>(*childit);
- mod->SetID(fIDs[idx], kFALSE);
+ mod->SetID(fIDs[idx], kFALSE);
TEveTrans& tr = mod->RefHMTrans();
tr.UnitTrans();
tr.RotateLF(3,2,TMath::PiOver2());
- tr.RotateLF(1,3,TMath::PiOver2());
+ tr.RotateLF(1,3,TMath::PiOver2());
- // scaling
+ // scaling
Float_t mz, mx;
Float_t* fp = mod->GetFrame()->GetFramePoints();
// switch x,z it will be rotated afterwards
Float_t p[3];
fStepper->GetPosition(p);
tr.SetPos(p[0]+0.5*fStepper->GetDx(), p[1]+0.5*fStepper->GetDy(), p[2]+0.5*fStepper->GetDz());
-
+
if(mod->GetSubDetID() == 2)
mod->SetName(Form("SSD %d", idx));
else if(mod->GetSubDetID() == 1)
gluPickMatrix(rect.X(), rect.Y(), rect.Width(), rect.Height(),
(Int_t*) rnrCtx.GetCamera()->RefViewport().CArr());
}
-
+
glMatrixMode(GL_MODELVIEW);
glPushMatrix();
glLoadIdentity();
glPolygonMode(GL_FRONT_AND_BACK, GL_FILL);
glDisable(GL_CULL_FACE);
glEnable(GL_BLEND);
- glBlendFunc(GL_ONE, GL_ONE_MINUS_SRC_ALPHA);
+ glBlendFunc(GL_ONE, GL_ONE_MINUS_SRC_ALPHA);
RenderMenu();
RenderPalette(fPaletteLength, 1.6*fWWidth, fWHeight*0.6);
glPopMatrix();
glPopAttrib();
-
+
if (lightp) glEnable(GL_LIGHTING);
glMatrixMode(GL_PROJECTION);
if(id > 0) glLoadName(id);
if(id>0 && fWActive == id)
fText->SetTextColor(fWActiveCol);
- else
+ else
fText->SetTextColor(fFontCol);
-
+
if(id>0)
- {
- if(fWActive == id)
+ {
+ if(fWActive == id)
fText->SetTextColor(fWActiveCol);
else
fText->SetTextColor(fFontCol);
RenderFrame(bw,fWHeight*2,id);
glTranslatef( bw, 0, 0);
}
- else
+ else
{
fText->SetTextColor(fFontCol);
fText->PaintGLText(0, txtY, -0.8, string.Data());
UChar_t color[4];
if (fWActive == id)
TEveUtil::TEveUtil::ColorFromIdx(fWActiveCol, color);
- else
+ else
TEveUtil:: TEveUtil::ColorFromIdx(fWCol, color);
glColor4ubv(color);
UChar_t color[4];
if (fWActive == id)
TEveUtil::TEveUtil::ColorFromIdx(fWActiveCol, color);
- else
+ else
TEveUtil::TEveUtil::ColorFromIdx(fWCol, color);
glColor4ubv(color);
Float_t xs = dx/4, ys = dy/4;
if(id == 0) {
glBegin(GL_QUADS);
- glVertex2f(0,ys); glVertex2f(0, ys*3);
+ glVertex2f(0,ys); glVertex2f(0, ys*3);
glVertex2f(dx, ys*3); glVertex2f(dx, ys);
glEnd();
return;
glVertex2f(xs, ys*1.5); glVertex2f(xs*2, ys*0.5); glVertex2f(xs*3, ys*1.5);
break;
}
-
+
default:
break;
}
{
Float_t xs = dx/(p->GetMaxVal() - p->GetMinVal());
Float_t x0 = xs;
- for(Int_t i=p->GetMinVal() + 1; i<p->GetMaxVal(); i++)
+ for(Int_t i=p->GetMinVal() + 1; i<p->GetMaxVal(); i++)
{
glColor4ubv(p->ColorFromValue(i));
glVertex2f(x0, 0);
Float_t H = 1.9*wh*(1+ 2*fWOff);
if(1) {
glBegin(GL_QUADS);
- glVertex3f(-1, -1, 0.1); glVertex3f(-1, -1+H, 0.1);
+ glVertex3f(-1, -1, 0.1); glVertex3f(-1, -1+H, 0.1);
glVertex3f(1 , -1+H, 0.1); glVertex3f( 1, -1 , 0.1);
glEnd();
}
RenderFrame(ww,wh,1);
glTranslatef(soff, 0, 0);
// text info
- {
+ {
const char* txt = Form("%d/%d ", GetCurrentPage(), GetPages());
Float_t dx = (fPagerGap - TextLength(txt))*0.5;
fText->SetTextColor(fFontCol);
RenderSymbol(ww, wh, 4);
RenderFrame(ww,wh,4);
glTranslatef(2*ww, 0, 0);
- glPopMatrix();
+ glPopMatrix();
// scale info
glPushMatrix();
Int_t cnx = 0, cnz = 0;
switch(sm->GetSubDetID())
{
- case 0:
+ case 0:
cnx = di->fSPDScaleX[scale], cnz = di->fSPDScaleZ[scale];
break;
- case 1:
+ case 1:
cnx = di->fSDDScaleX[scale], cnz = di->fSDDScaleZ[scale];
break;
case 2:
glPushMatrix();
glTranslatef(18*ww, 0, 0);
Float_t bs = ww*0.2;
- RenderString("SPD", 8);
+ RenderString("SPD", 8);
glTranslatef(bs, 0, 0);
- RenderString("SDD", 9);
+ RenderString("SDD", 9);
glTranslatef(bs, 0, 0);
RenderString("SSD", 10);
glPopMatrix();
UInt_t idx = fPosition;
for (List_i childit=fChildren.begin(); childit!=fChildren.end(); ++childit)
{
- if(idx < fIDs.size())
- {
+ if(idx < fIDs.size())
+ {
AliEveITSScaledModule* mod = dynamic_cast<AliEveITSScaledModule*>(*childit);
TEveTrans& tr = mod->RefHMTrans();
TString name = Form("%d",mod->GetID());
// Return TRUE if event was handled.
switch (event->fType)
- {
+ {
case kMotionNotify:
{
Int_t item = rec.GetN() < 2 ? -1 : (Int_t)rec.GetItem(1);
case 5:
{
AliEveDigitScaleInfo* si = fScaleInfo;
- if(si->GetScale() < 5)
+ if(si->GetScale() < 5)
{
- si->ScaleChanged(si->GetScale() + 1);
+ si->ScaleChanged(si->GetScale() + 1);
ElementChanged(kTRUE, kTRUE);
}
break;
case 6:
{
AliEveDigitScaleInfo* si = fScaleInfo;
- if(si->GetScale() > 1)
+ if(si->GetScale() > 1)
{
- si->ScaleChanged(si->GetScale() - 1);
+ si->ScaleChanged(si->GetScale() - 1);
ElementChanged(kTRUE, kTRUE);
}
break;
case 8:
DisplayDet(0, -1);
break;
- case 9:
+ case 9:
DisplayDet(1, -1);
break;
- case 10:
+ case 10:
DisplayDet(2, -1);
break;
default:
// Mouse has left the element.
fWActive = -1;
-}
+}
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_ITSModuleStepper_H
// palette configuratiom
Float_t fPaletteOffset;
- Float_t fPaletteLength;
+ Float_t fPaletteLength;
- // symbol configuration
- Int_t fWActive;
+ // symbol configuration
+ Int_t fWActive;
Float_t fWWidth;
Float_t fWHeight;
Float_t fWOff; ///offset relative to widget size
- Color_t fWCol;
+ Color_t fWCol;
Int_t fWActiveCol;
Color_t fFontCol;
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveITSModuleStepperEditor.h"
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_ITSModuleStepperEditor_H
AliEveITSModuleStepper* fM; // fModel dynamic-casted to AliEveITSModuleStepperEditor
TEveGridStepperSubEditor* fStepper;
-
+
public:
AliEveITSModuleStepperEditor(const TGWindow* p=0, Int_t width=170, Int_t height=30, UInt_t options = kChildFrame, Pixel_t back=GetDefaultFrameBackground());
virtual ~AliEveITSModuleStepperEditor();
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveITSScaledModule.h"
void AliEveDigitScaleInfo::ScaleChanged(Int_t s)
{
fScale = s;
-
+
AliEveITSScaledModule* sm;
std::list<TEveElement*>::iterator i = fBackRefs.begin();
while (i != fBackRefs.end())
{
fStatType = t;
fSyncPalette = kTRUE;
-
+
AliEveITSScaledModule* sm;
std::list<TEveElement*>::iterator i = fBackRefs.begin();
while (i != fBackRefs.end())
SetOwnIds(kTRUE);
SetDigitsInfo(info);
- SetID(gid);
+ SetID(gid);
fScaleInfo->IncRefCount(this);
}
Int_t scale = fScaleInfo->GetScale() -1;
switch(fDetID)
{
- case 0:
- {
+ case 0:
+ {
// SPD
Reset(kQT_RectangleXZFixedY, kFALSE, 32);
fNCx = fInfo->fSPDScaleX[scale];
fNz = Int_t(fInfo->fSegSPD->Npz()/fNCz);
fNx = Int_t(fInfo->fSegSPD->Npx()/fNCx);
- dpz = 2*fDz/fNz;
+ dpz = 2*fDz/fNz;
dpx = 2*fDx/fNx;
//printf("SPD orig cells (%d, %d) (%d, %d)\n", fInfo->fSegSPD->Npx(), fInfo->fSegSPD->Npz(), Nx, Nz);
i = Int_t((zo+fDz)/dpz);
j = Int_t((od->GetCoord2()*fNx)/fInfo->fSegSPD->Npx());
id = j*fNx + i;
-
+
miter = dmap.find(id);
if(miter == dmap.end())
- {
+ {
dmap[id] = fPlex.Size();
z = dpz*(i) - fDz;
x = dpx*(j) - fDx;
sd = new ScaledDigit(c1, c2);
QuadId(sd);
}
- else
+ else
{
sd = dynamic_cast<ScaledDigit*>(GetId(miter->second));
- if(c1 < sd->min_i)
+ if(c1 < sd->min_i)
sd->min_i = c1;
else if( c1 > sd->max_i)
sd->max_i = c1;
-
- if(c2 < sd->min_j)
+
+ if(c2 < sd->min_j)
sd->min_j = c2;
else if( c2 > sd->max_j)
sd->max_j = c2;
}
-
+
sd->N++;
sd->sum += od->GetSignal();
sd->sqr_sum += od->GetSignal()*od->GetSignal();
}
break;
}
- case 1:
- {
+ case 1:
+ {
// SDD
Reset(kQT_RectangleXZFixedY, kFALSE, 32);
fNCz = fInfo->fSDDScaleZ[scale];
- fNCx = fInfo->fSDDScaleX[scale];
+ fNCx = fInfo->fSDDScaleX[scale];
fNz = Int_t(fInfo->fSegSDD->Npz()/fNCz);
fNx = Int_t(fInfo->fSegSDD->Npx()/fNCx);
dpz = 2*fDz/fNz;
id = j*fNx + i;
c1 = od->GetCoord1(); c2 = od->GetCoord2();
-
+
miter = dmap.find(id);
if(miter == dmap.end())
- {
+ {
dmap[id] = fPlex.Size();
z = dpz*(i) - fDz;
x = dpx*(j) - fDx;
sd = new ScaledDigit(od->GetCoord1(),od->GetCoord2());
QuadId(sd);
}
- else
+ else
{
sd = dynamic_cast<ScaledDigit*>(GetId(miter->second));
- if(c1 < sd->min_i)
+ if(c1 < sd->min_i)
sd->min_i = c1;
else if( c1 > sd->max_i)
sd->max_i = c1;
-
- if(c2 < sd->min_j)
+
+ if(c2 < sd->min_j)
sd->min_j = c2;
else if( c2 > sd->max_j)
sd->max_j = c2;
sd->sqr_sum += od->GetSignal()*od->GetSignal();
}
break;
- }
- case 2:
- {
- // SSD
+ }
+ case 2:
+ {
+ // SSD
Reset(kQT_LineXZFixedY, kFALSE, 32);
- AliITSsegmentationSSD* seg = fInfo->fSegSSD;
+ AliITSsegmentationSSD* seg = fInfo->fSegSSD;
Float_t ap, an; // positive/negative angles -> offsets
seg->Angles(ap, an);
ap = TMath::Tan(ap) * fDz;
an = - TMath::Tan(an) * fDz;
- fNCx = fInfo->fSSDScale[scale];
+ fNCx = fInfo->fSSDScale[scale];
fNz = 1;
fNx = Int_t(fInfo->fSegSSD->Npx()/fNCx);
dpz = 2*fDz/fNz;
AliITSdigitSSD *od=0;
for (Int_t k=0; k<ndigits; k++) {
od=(AliITSdigitSSD*)digits->UncheckedAt(k);
- if(od->GetCoord1() == 1)
+ if(od->GetCoord1() == 1)
i = 1; // p side
- else
+ else
i= -1; // n side
j = Int_t(od->GetCoord2()/fNCx);
c1 = od->GetCoord1(); c2 = od->GetCoord2();
- id = j*i;
+ id = j*i;
miter = dmap.find(id);
ScaledDigit* sd;
if(miter == dmap.end())
- {
+ {
// printf("orig digit %d,%d scaled %d,%d \n",od->GetCoord1(),od->GetCoord2(),i,j);
dmap[id] = fPlex.Size();
z = dpz*(i) - fDz;
sd = new ScaledDigit(c1, c2);
QuadId(sd);
}
- else
+ else
{
- sd = dynamic_cast<ScaledDigit*>(GetId(miter->second));
- if(c1 < sd->min_i)
+ sd = dynamic_cast<ScaledDigit*>(GetId(miter->second));
+ if(c1 < sd->min_i)
sd->min_i = c1;
else if( c1 > sd->max_i)
sd->max_i = c1;
-
- if(c2 < sd->min_j)
+
+ if(c2 < sd->min_j)
sd->min_j = c2;
else if( c2 > sd->max_j)
sd->max_j = c2;
{
if(fScaleInfo->GetSyncPalette()) SyncPalette();
- Int_t N = fPlex.Size();
+ Int_t N = fPlex.Size();
for (Int_t i = 0 ; i< N; i++)
{
ScaledDigit* sd = dynamic_cast<ScaledDigit*>(GetId(i));
/**************************************************************************/
void AliEveITSScaledModule::SyncPalette()
-{
+{
// printf("AliEveITSScaledModule::SyncPalette()\n");
- if(fScaleInfo->GetStatType() == AliEveDigitScaleInfo::ST_Occup)
+ if(fScaleInfo->GetStatType() == AliEveDigitScaleInfo::ST_Occup)
{
// SPD
AliEveITSModule::fgSPDPalette->SetLimits(0, 100);
AliEveITSModule::fgSPDPalette->SetMinMax(0, 100);
-
+
// SDD
AliEveITSModule::fgSDDPalette->SetLimits(0, 100);
AliEveITSModule::fgSDDPalette->SetMinMax(0, 100);
// SPD
AliEveITSModule::fgSPDPalette->SetLimits(0, DI.fSPDHighLim);
AliEveITSModule::fgSPDPalette->SetMinMax(DI.fSPDMinVal, DI.fSPDMaxVal);
-
+
// SDD
AliEveITSModule::fgSDDPalette->SetLimits(0, DI.fSDDHighLim);
AliEveITSModule::fgSDDPalette->SetMinMax(DI.fSDDMinVal, DI.fSDDMaxVal);
printf("%d digits in cell scaleX = %d, scaleZ = %d \n", sd->N, fNCx, fNCz);
Int_t il = 0;
- for(Int_t k=0; k<ndigits; k++)
+ for(Int_t k=0; k<ndigits; k++)
{
AliITSdigit *d = (AliITSdigit*) digits->UncheckedAt(k);
- if(d->GetCoord1()>=sd->min_i && d->GetCoord1()<=sd->max_i &&
- d->GetCoord2()>=sd->min_j && d->GetCoord2()<=sd->max_j)
+ if(d->GetCoord1()>=sd->min_i && d->GetCoord1()<=sd->max_i &&
+ d->GetCoord2()>=sd->min_j && d->GetCoord2()<=sd->max_j)
{
printf("%3d, %3d: %3d", d->GetCoord1(), d->GetCoord2(), d->GetSignal());
printf(" | ");
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_ITSScaledModule_H
AliEveDigitScaleInfo& operator=(const AliEveDigitScaleInfo&); // Not implemented
protected:
- Int_t fScale;
+ Int_t fScale;
Int_t fStatType;
-
+
Bool_t fSyncPalette;
public:
AliEveDigitScaleInfo();
virtual ~AliEveDigitScaleInfo(){}
-
+
Int_t GetScale() { return fScale; }
void ScaleChanged(Int_t s);
ScaledDigit();
ScaledDigit(Int_t di, Int_t dj);
-
+
virtual void Dump() const;
-};
+};
/**************************************************************************/
// AliEveITSScaledModule
{
friend class ITSSDSubEditor;
private:
- map<Int_t, ScaledDigit> fDigitsMap;
-
+ map<Int_t, ScaledDigit> fDigitsMap;
+
AliEveITSScaledModule(const AliEveITSScaledModule&); // Not implemented
AliEveITSScaledModule& operator=(const AliEveITSScaledModule&); // Not implemented
protected:
- Int_t fNx; // per module
+ Int_t fNx; // per module
Int_t fNz;
Int_t fNCx; // per cell
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveITSScaledModuleEditor.h"
//______________________________________________________________________
-// AliEveITSScaledModuleEditor
+// AliEveITSScaledModuleEditor
//
ClassImp(AliEveITSScaledModuleEditor)
fInfoFrame(0),
- fModule(0),
+ fModule(0),
fScale(0),
fStatistic(0),
f->AddFrame(fScale, new TGLayoutHints(kLHintsLeft, 1, 7, 1, 1));
fScale->Associate(f);
fScale->Connect("ValueSet(Long_t)", "AliEveITSScaledModuleEditor", this, "DoScale()");
-
+
TGLabel* lab = new TGLabel(f, "Statistic:");
f->AddFrame(lab, new TGLayoutHints(kLHintsLeft|kLHintsBottom, 1, 2, 1, 2));
fStatistic = new TGComboBox(f);
void AliEveITSScaledModuleEditor::CreateInfoFrame()
{
fInfoFrame = CreateEditorTabSubFrame("Info");
- TGCompositeFrame *title1 = new TGCompositeFrame(fInfoFrame, 145, 10,
- kHorizontalFrame |
- kLHintsExpandX |
- kFixedWidth |
+ TGCompositeFrame *title1 = new TGCompositeFrame(fInfoFrame, 145, 10,
+ kHorizontalFrame |
+ kLHintsExpandX |
+ kFixedWidth |
kOwnBackground);
- title1->AddFrame(new TGLabel(title1, "ScaledDigits Info"),
+ title1->AddFrame(new TGLabel(title1, "ScaledDigits Info"),
new TGLayoutHints(kLHintsLeft, 1, 1, 0, 0));
title1->AddFrame(new TGHorizontal3DLine(title1),
new TGLayoutHints(kLHintsExpandX, 5, 5, 7, 7));
void AliEveITSScaledModuleEditor::SetModel(TObject* obj)
{
- fModule = dynamic_cast<AliEveITSScaledModule*>(obj);
+ fModule = dynamic_cast<AliEveITSScaledModule*>(obj);
// widgets
fScale->SetIntNumber(fModule->GetScaleInfo()->GetScale());
fStatistic->Select(fModule->GetScaleInfo()->GetStatType(), kFALSE);
- // text info
+ // text info
Int_t cnx, cnz, total;
fModule->GetScaleData(cnx, cnz, total);
fInfoLabel0->SetText(Form("Cell size: Nx=%d Nz=%d", cnx, cnz));
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_ITSScaledModuleEditor_H
AliEveITSScaledModule* fModule; // fModel dynamic-casted to AliEveITSScaledModuleEditor
TGNumberEntry* fScale;
- TGComboBox* fStatistic;
+ TGComboBox* fStatistic;
TGLabel* fInfoLabel0;
TGLabel* fInfoLabel1;
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveJetPlane.h"
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_JetPlane_H
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveJetPlaneEditor.h"
}
void AliEveJetPlaneEditor::DoStaticDataWindow()
-{
+{
printf("\n Soon available ... \n");
if (fgStaticWindow == 0)
fgStaticWindow = new StaticDataWindow(gClient->GetRoot(), this, 400, 200);
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_JetPlaneEditor_H
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveJetPlaneGL.h"
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_JetPlaneGL_H
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveKineTools.h"
while(iter != cont->EndChildren())
{
- TEveTrack* track = dynamic_cast<TEveTrack*>(*iter);
+ TEveTrack* track = dynamic_cast<TEveTrack*>(*iter);
TParticle* p = stack->Particle(track->GetLabel());
if(p->GetNDaughters()) {
Int_t d0 = p->GetDaughter(0), d1 = p->GetDaughter(1);
- for(int d=d0; d>0 && d<=d1; ++d)
- {
+ for(int d=d0; d>0 && d<=d1; ++d)
+ {
TParticle* dp = stack->Particle(d);
TEvePathMark* pm = new TEvePathMark(TEvePathMark::kDaughter);
pm->fV.Set(dp->Vx(), dp->Vy(), dp->Vz());
- pm->fP.Set(dp->Px(), dp->Py(), dp->Pz());
+ pm->fP.Set(dp->Px(), dp->Py(), dp->Pz());
pm->fTime = dp->T();
track->AddPathMark(pm);
}
{
TEveElement::List_i citer = cont->BeginChildren();
while(citer != cont->EndChildren())
- {
- TEveTrack* track = dynamic_cast<TEveTrack*>(*citer);
+ {
+ TEveTrack* track = dynamic_cast<TEveTrack*>(*citer);
tracks[track->GetLabel()] = track;
if (recurse)
slurp_tracks(tracks, track, recurse);
// Fill map
map<Int_t, TEveTrack*> tracks;
slurp_tracks(tracks, cont, recurse);
-
+
Int_t nPrimaries = (Int_t) treeTR->GetEntries();
TIter next(treeTR->GetListOfBranches());
TBranchElement* el;
TClonesArray* arr = 0;
el->SetAddress(&arr);
- for (Int_t iPrimPart = 0; iPrimPart<nPrimaries; iPrimPart++)
+ for (Int_t iPrimPart = 0; iPrimPart<nPrimaries; iPrimPart++)
{
el->GetEntry(iPrimPart);
Int_t last_label = -1;
- map<Int_t, TEveTrack*>::iterator iter = tracks.end();
+ map<Int_t, TEveTrack*>::iterator iter = tracks.end();
Int_t Nent = arr->GetEntriesFast();
- for (Int_t iTrackRef = 0; iTrackRef < Nent; iTrackRef++)
+ for (Int_t iTrackRef = 0; iTrackRef < Nent; iTrackRef++)
{
AliTrackReference* atr = (AliTrackReference*)arr->UncheckedAt(iTrackRef);
if (label < 0)
throw(eH + Form("negative label for entry %d in branch %s.",
iTrackRef, el->GetName()));
-
+
if(label != last_label) {
iter = tracks.find(label);
last_label = label;
if (iter != tracks.end()) {
TEvePathMark* pm = new TEvePathMark(isRef ? TEvePathMark::kReference : TEvePathMark::kDecay);
pm->fV.Set(atr->X(),atr->Y(), atr->Z());
- pm->fP.Set(atr->Px(),atr->Py(), atr->Pz());
+ pm->fP.Set(atr->Px(),atr->Py(), atr->Pz());
pm->fTime = atr->GetTime();
TEveTrack* track = iter->second;
track->AddPathMark(pm);
}
- } // loop track refs
+ } // loop track refs
} // loop primaries, clones arrays
delete arr;
} // end loop through top branches
map<Int_t, TEveTrack*> tracks;
slurp_tracks(tracks, cont, recurse);
- // sort
+ // sort
for(map<Int_t, TEveTrack*>::iterator j=tracks.begin(); j!=tracks.end(); ++j)
{
j->second->SortPathMarksByTime();
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
-// Tools for import of kinematics.
+// Tools for import of kinematics.
// Preliminary/minimal solution.
#ifndef ALIEVE_KineTools_H
public:
AliEveKineTools();
virtual ~AliEveKineTools(){}
-
+
// data from TreeTR
void SetDaughterPathMarks(TEveElement* cont, AliStack* stack, Bool_t recurse=kFALSE);
void SetTrackReferences (TEveElement* cont, TTree* treeTR=0, Bool_t recurse=kFALSE);
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveMUONChamber.h"
#else
BBoxInit();
#endif
-
+
fBBox[0] = - 400.0;
fBBox[1] = + 400.0;
fBBox[2] = - 400.0;
for(Int_t i=0; i<6; ++i) { b3[i] = fBBox[i]; }
Float_t* b4 = fPointSet2.AssertBBox();
for(Int_t i=0; i<6; ++i) { b4[i] = fBBox[i]; }
-
+
}
//______________________________________________________________________
Int_t AliEveMUONChamber::ColorIndex(Int_t val) const
{
//
- // index color
+ // index color
//
if(val < fThreshold) val = fThreshold;
//______________________________________________________________________
AliEveMUONChamberData* AliEveMUONChamber::GetChamberData() const
{
-
+
return fMUONData ? fMUONData->GetChamberData(fChamberID) : 0;
}
fPointSet2.Reset();
AliEveMUONChamberData* data = GetChamberData();
-
+
Float_t *buffer;
Float_t x0, y0, z, w, h, clsq;
Int_t charge, cathode, nDigits, nClusters, nHits, oldSize, ic1, ic2;
Double_t clsX, clsY, clsZ;
Float_t hitX, hitY, hitZ;
-
+
if (data != 0) {
SetupColorArray();
// digits
nDigits = data->GetNDigits();
-
+
for (Int_t id = 0; id < nDigits; id++) {
buffer = data->GetDigitBuffer(id);
z = buffer[4];
charge = (Int_t)buffer[5];
cathode = (Int_t)buffer[6];
-
+
if (charge <= fThreshold) continue;
if (cathode == 0) {
fQuadSet1.AddQuad(x0, y0, z, w, h);
fQuadSet1.QuadColor(ColorIndex(charge));
-
+
}
if (cathode == 1) {
fQuadSet2.AddQuad(x0, y0, z, w, h);
fQuadSet2.QuadColor(ColorIndex(charge));
-
+
}
} // end digits loop
// clusters
-
+
nClusters = data->GetNClusters()/2; // only one cathode plane
oldSize = fPointSet1.GrowFor(nClusters);
ic1 = ic2 = 0;
clsX = (Double_t)buffer[0];
clsY = (Double_t)buffer[1];
clsZ = (Double_t)buffer[2];
- clsq = buffer[3];
+ clsq = buffer[3];
cathode = (Int_t)buffer[4];
if (cathode == 0) {
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_MUONChamber_H
#define ALIEVE_MUONChamber_H
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveMUONChamberData.h"
sseg = (AliMpSectorSegmentation*)
AliMpSegmentation::Instance()->GetMpSegmentation(detElemId,AliMp::kCath0);
sector = sseg->GetSector();
-
- position = sector->Position();
+
+ position = sector->Position();
dimension = sector->Dimensions(); // half length
-
+
locP[0] = position.Px();
locP[1] = position.Py();
locD[0] = dimension.Px() * 2.;
locD[1] = dimension.Py() * 2.;
-
+
locP[2] = 0.0;
locD[2] = 0.0;
- fgTransformer->Local2Global(detElemId,
- locP[0], locP[1], locP[2],
+ fgTransformer->Local2Global(detElemId,
+ locP[0], locP[1], locP[2],
gloP[0], gloP[1], gloP[2]);
-
+
fgTransformer->Local2Global(detElemId,
- locD[0], locD[1], locD[2],
+ locD[0], locD[1], locD[2],
gloD[0], gloD[1], gloD[2]);
-
- fFrameCoord[fNDetElem][0] = gloP[0];
- fFrameCoord[fNDetElem][1] = gloP[1];
- fFrameCoord[fNDetElem][2] = gloD[0];
- fFrameCoord[fNDetElem][3] = gloD[1];
+
+ fFrameCoord[fNDetElem][0] = gloP[0];
+ fFrameCoord[fNDetElem][1] = gloP[1];
+ fFrameCoord[fNDetElem][2] = gloD[0];
+ fFrameCoord[fNDetElem][3] = gloD[1];
fFrameCoord[fNDetElem][4] = gloP[2]; // Z position
fChamberBox[0] = TMath::Min(fChamberBox[0],gloP[0]-gloD[0]);
fChamberBox[3] = TMath::Max(fChamberBox[3],gloP[1]+gloD[1]);
fChamberBox[4] = TMath::Min(fChamberBox[4],gloP[2]);
fChamberBox[5] = TMath::Max(fChamberBox[5],gloP[2]);
-
+
} else {
// if (!fgSegmentation->HasDE(detElemId)) {
locP[2] = 0.0;
locD[2] = 0.0;
- fgTransformer->Local2Global(detElemId,
- locP[0], locP[1], locP[2],
+ fgTransformer->Local2Global(detElemId,
+ locP[0], locP[1], locP[2],
gloP[0], gloP[1], gloP[2]);
-
+
fgTransformer->Local2Global(detElemId,
- locD[0], locD[1], locD[2],
+ locD[0], locD[1], locD[2],
gloD[0], gloD[1], gloD[2]);
-
- fFrameCoord[fNDetElem][0] = gloP[0];
- fFrameCoord[fNDetElem][1] = gloP[1];
- fFrameCoord[fNDetElem][2] = gloD[0];
- fFrameCoord[fNDetElem][3] = gloD[1];
+
+ fFrameCoord[fNDetElem][0] = gloP[0];
+ fFrameCoord[fNDetElem][1] = gloP[1];
+ fFrameCoord[fNDetElem][2] = gloD[0];
+ fFrameCoord[fNDetElem][3] = gloD[1];
fFrameCoord[fNDetElem][4] = gloP[2]; // Z position
fChamberBox[0] = TMath::Min(fChamberBox[0],gloP[0]);
fChamberBox[3] = TMath::Max(fChamberBox[1],gloD[1]);
fChamberBox[4] = TMath::Min(fChamberBox[4],gloP[2]);
fChamberBox[5] = TMath::Max(fChamberBox[5],gloP[2]);
-
+
}
fNDetElem++;
->GetMpSegmentation(detElemId,AliMp::GetCathodType(cathode));
AliMpPad pad = vseg->PadByIndices(AliMpIntPair(ix,iy),kTRUE);
-
+
locP[0] = pad.Position().X();
locP[1] = pad.Position().Y();
locD[0] = pad.Dimensions().X();
locD[1] = pad.Dimensions().Y();
-
+
locP[2] = 0.0;
locD[2] = 0.0;
- fgTransformer->Local2Global(detElemId,
- locP[0], locP[1], locP[2],
+ fgTransformer->Local2Global(detElemId,
+ locP[0], locP[1], locP[2],
gloP[0], gloP[1], gloP[2]);
-
+
gloD[0] = locD[0];
gloD[1] = locD[1];
gloD[2] = gloP[2];
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_MUONChamberData_H
#define ALIEVE_MUONChamberData_H
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveMUONChamberEditor.h"
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_MUONChamberEditor_H
#define ALIEVE_MUONChamberEditor_H
AliEveMUONChamberEditor(const AliEveMUONChamberEditor&); // Not implemented
AliEveMUONChamberEditor& operator=(const AliEveMUONChamberEditor&); // Not implemented
-
+
protected:
AliEveMUONChamber* fM; // fModel dynamic-casted to AliEveMUONChamberEditor
public:
AliEveMUONChamberEditor(const TGWindow* p = 0,
- Int_t width = 170, Int_t height = 30,
- UInt_t options = kChildFrame,
+ Int_t width = 170, Int_t height = 30,
+ UInt_t options = kChildFrame,
Pixel_t back = GetDefaultFrameBackground());
-
+
virtual ~AliEveMUONChamberEditor();
virtual void SetModel(TObject* obj);
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
/**************************************************************************
* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
//
if(SetModelCheckClass(obj, AliEveMUONChamber::Class())) {
-
+
fChamber = (AliEveMUONChamber*) fExternalObj;
fQS1.SetModel(&fChamber->fQuadSet1);
fQS2.SetModel(&fChamber->fQuadSet2);
fChamber->UpdateQuads();
fRTS = fChamber->fRTS;
}
-
+
Bool_t hasData = (fChamber->GetChamberData() != 0);
-
+
if(hasData) {
DrawQuads(rnrCtx);
DrawPoints();
-
+
}
DrawChamberFrame();
glLineWidth(1.0);
glColor3f(1.0,1.0,1.0);
-
+
glBegin(GL_LINES);
-
+
// clusters
Int_t clsSize = fChamber->fClusterSize;
if (clsSize > 1) {
for (Int_t i = 0; i < fChamber->fPointSet1.GetN(); i++) {
-
+
fChamber->fPointSet1.GetPoint(i,x,y,z);
glVertex3f(x-clsSize,y+clsSize,z);
glVertex3f(x+clsSize,y-clsSize,z);
-
+
glVertex3f(x-clsSize,y-clsSize,z);
glVertex3f(x+clsSize,y+clsSize,z);
-
+
}
-
+
}
// hits
if (hitSize > 1) {
for (Int_t i = 0; i < fChamber->fPointSet2.GetN(); i++) {
-
+
fChamber->fPointSet2.GetPoint(i,x,y,z);
-
+
glVertex3f(x-hitSize,y,z);
glVertex3f(x+hitSize,y,z);
-
+
glVertex3f(x,y-hitSize,z);
glVertex3f(x,y+hitSize,z);
-
+
}
-
+
}
glEnd();
-
+
}
//______________________________________________________________________
{
//
// draw the chamber frame as GL_LINE_LOOP
- //
+ //
AliEveMUONChamberData* chamberData = fChamber->GetChamberData();
Int_t nDetElem = chamberData->GetNDetElem();
pix[3] = 255;
glColor4ubv(pix);
-
+
for (Int_t id = 0; id < nDetElem; id++) {
frameCoord = chamberData->GetFrameCoord(id);
xRad = frameCoord[2];
yRad = frameCoord[3];
z = frameCoord[4];
-
+
xRad += 0.0;
yRad += 0.0;
glBegin(GL_LINE_LOOP);
glVertex3f(xOrig,yOrig,z);
-
+
Int_t nstep = 100;
Float_t dstep = TMath::Pi()/2.0 / (Float_t)nstep;
Float_t d;
glVertex3f(x,y,z);
}
-
+
glVertex3f(xOrig,yOrig,z);
glEnd();
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_MUONChamberGL_H
#define ALIEVE_MUONChamberGL_H
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
//
// Sources:
//
// Constructor
//
-
+
for (Int_t i = 0; i < 256; i++) {
fTrackList[i] = -1;
}
//______________________________________________________________________
void AliEveMUONData::CreateChamber(Int_t chamber)
{
- //
+ //
// create data for the chamber with id=chamber (0 to 13)
//
//______________________________________________________________________
void AliEveMUONData::DropAllChambers()
{
- //
- // release data from all chambers
+ //
+ // release data from all chambers
//
for (Int_t c = 0; c < 14; ++c) {
AliMUONVClusterStore *clusterStore = AliMUONVClusterStore::Create(*tree);
clusterStore->Clear();
clusterStore->Connect(*tree,kFALSE);
-
+
tree->GetEvent(0);
-
+
AliMUONVCluster *cluster;
Int_t detElemId;
Double_t clsX, clsY, clsZ, charge;
for (Int_t ch = 0; ch < 10; ++ch) {
if (fChambers[ch] == 0) continue;
-
+
TIter next(clusterStore->CreateChamberIterator(ch,ch));
-
+
while ( ( cluster = static_cast<AliMUONVCluster*>(next()) ) ) {
detElemId = cluster->GetDetElemId();
-
+
clsX = cluster->GetX();
clsY = cluster->GetY();
clsZ = cluster->GetZ();
}
delete clusterStore;
-
+
}
//______________________________________________________________________
//______________________________________________________________________
void AliEveMUONData::LoadDigits(TTree* tree)
{
- //
+ //
// load digits from the TreeD
//
AliMUONVDigit* digit;
TIter next(digitStore->CreateIterator());
-
+
Int_t cathode, detElemId, ix, iy, charge, chamber, adc;
-
+
while ( ( digit = static_cast<AliMUONVDigit*>(next() ) ) )
{
cathode = digit->Cathode();
ix = digit->PadX();
iy = digit->PadY();
- detElemId = digit->DetElemId();
+ detElemId = digit->DetElemId();
charge = (Int_t)digit->Charge();
adc = digit->ADC();
chamber = detElemId/100 - 1;
fChambers[chamber]->RegisterDigit(detElemId,cathode,ix,iy,adc);
}
}
-
+
delete digitStore;
}
fgRawReader = new AliRawReaderDate(fileName); // DATE file
}
}
-
+
fgRawReader->RewindEvents();
fgRawReader->Reset();
Int_t iEvent = 0;
- while (fgRawReader->NextEvent())
+ while (fgRawReader->NextEvent())
{
- if (iEvent != gEvent->GetEventId())
+ if (iEvent != gEvent->GetEventId())
{
iEvent++;
continue;
digitMaker.SetMakeTriggerDigits(kTRUE);
AliMUONDigitStoreV1 digitStore;
-
+
digitMaker.Raw2Digits(fgRawReader,&digitStore);
AliMUONVDigit* digit;
TIter next(digitStore.CreateIterator());
-
+
Int_t cathode, detElemId, ix, iy, charge, chamber, adc;
-
+
while ( ( digit = static_cast<AliMUONVDigit*>(next() ) ) )
{
cathode = digit->Cathode();
ix = digit->PadX();
iy = digit->PadY();
- detElemId = digit->DetElemId();
+ detElemId = digit->DetElemId();
charge = (Int_t)digit->Charge();
adc = digit->ADC();
chamber = detElemId/100 - 1;
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_MUONData_H
#define ALIEVE_MUONData_H
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveMUONTrack.h"
cout << " MC track parameters at vertex" << endl;
cout << " -------------------------------------------------------------------------------------" << endl;
cout << " PDG code Vx Vy Vz Px Py Pz " << endl;
-
+
cout << " " <<
- setw(8) << setprecision(0) <<
- fPart->GetPdgCode() << " " <<
- setw(8) << setprecision(3) <<
- fPart->Vx() << " " <<
- setw(8) << setprecision(3) <<
- fPart->Vy() << " " <<
- setw(8) << setprecision(3) <<
- fPart->Vz() << " " <<
- setw(8) << setprecision(3) <<
- fPart->Px() << " " <<
- setw(8) << setprecision(3) <<
- fPart->Py() << " " <<
- setw(8) << setprecision(4) <<
- fPart->Pz() << " " <<
-
+ setw(8) << setprecision(0) <<
+ fPart->GetPdgCode() << " " <<
+ setw(8) << setprecision(3) <<
+ fPart->Vx() << " " <<
+ setw(8) << setprecision(3) <<
+ fPart->Vy() << " " <<
+ setw(8) << setprecision(3) <<
+ fPart->Vz() << " " <<
+ setw(8) << setprecision(3) <<
+ fPart->Px() << " " <<
+ setw(8) << setprecision(3) <<
+ fPart->Py() << " " <<
+ setw(8) << setprecision(4) <<
+ fPart->Pz() << " " <<
+
endl;
-
+
pt = TMath::Sqrt(fPart->Px()*fPart->Px()+fPart->Py()*fPart->Py());
p = TMath::Sqrt(fPart->Px()*fPart->Px()+fPart->Py()*fPart->Py()+fPart->Pz()*fPart->Pz());
-
+
cout << endl;
- cout << " Pt = " <<
+ cout << " Pt = " <<
setw(8) << setprecision(3) <<
pt << " GeV/c" << endl;
-
- cout << " P = " <<
+
+ cout << " P = " <<
setw(8) << setprecision(4) <<
p << " GeV/c" << endl;
-
+
}
//______________________________________________________________________
cout << endl;
cout << " Number of clusters " << fTrack->GetNClusters() << endl;
}
-
+
trackParamAtCluster = fTrack->GetTrackParamAtCluster();
nparam = trackParamAtCluster->GetEntries();
mtp = (AliMUONTrackParam*)trackParamAtCluster->At(i);
- cout <<
- setw(9)<< setprecision(3) <<
- i << " " <<
+ cout <<
+ setw(9)<< setprecision(3) <<
+ i << " " <<
- setw(8) << setprecision(3) <<
- mtp->GetInverseBendingMomentum() << " " <<
+ setw(8) << setprecision(3) <<
+ mtp->GetInverseBendingMomentum() << " " <<
setw(8) << setprecision(3) <<
- mtp->GetBendingSlope()*RADDEG << " " <<
+ mtp->GetBendingSlope()*RADDEG << " " <<
setw(8) << setprecision(3) <<
- mtp->GetNonBendingSlope()*RADDEG << " " <<
+ mtp->GetNonBendingSlope()*RADDEG << " " <<
setw(8) << setprecision(4) <<
- mtp->GetBendingCoor() << " " <<
+ mtp->GetBendingCoor() << " " <<
setw(8) << setprecision(4) <<
- mtp->GetNonBendingCoor() << " " <<
+ mtp->GetNonBendingCoor() << " " <<
setw(10) << setprecision(6) <<
- mtp->GetZ() << " " <<
+ mtp->GetZ() << " " <<
setw(8) << setprecision(4) <<
- mtp->Px() << " " <<
+ mtp->Px() << " " <<
setw(8) << setprecision(4) <<
- mtp->Py() << " " <<
+ mtp->Py() << " " <<
setw(8) << setprecision(4) <<
- mtp->Pz() << " " <<
+ mtp->Pz() << " " <<
setw(8) << setprecision(4) <<
- mtp->P() << " " <<
+ mtp->P() << " " <<
endl;
if (zc < 0.001) zc = 0.0;
cout << " " <<
- setw(8) << setprecision(3) <<
- mtp->GetInverseBendingMomentum() << " " <<
-
setw(8) << setprecision(3) <<
- mtp->GetBendingSlope()*RADDEG << " " <<
-
+ mtp->GetInverseBendingMomentum() << " " <<
+
+ setw(8) << setprecision(3) <<
+ mtp->GetBendingSlope()*RADDEG << " " <<
+
setw(8) << setprecision(3) <<
- mtp->GetNonBendingSlope()*RADDEG << " " <<
-
+ mtp->GetNonBendingSlope()*RADDEG << " " <<
+
setw(8) << setprecision(4) <<
- bc << " " <<
-
+ bc << " " <<
+
setw(8) << setprecision(4) <<
- nbc << " " <<
-
+ nbc << " " <<
+
setw(10) << setprecision(6) <<
- zc << " " <<
-
+ zc << " " <<
+
setw(8) << setprecision(4) <<
- mtp->Px() << " " <<
-
+ mtp->Px() << " " <<
+
setw(8) << setprecision(4) <<
- mtp->Py() << " " <<
-
+ mtp->Py() << " " <<
+
setw(8) << setprecision(4) <<
- mtp->Pz() << " " <<
-
+ mtp->Pz() << " " <<
+
setw(8) << setprecision(4) <<
- mtp->P() << " " <<
-
+ mtp->P() << " " <<
+
endl;
-
+
pt = TMath::Sqrt(mtp->Px()*mtp->Px()+mtp->Py()*mtp->Py());
cout << endl;
- cout << " Pt = " <<
+ cout << " Pt = " <<
setw(8) << setprecision(3) <<
pt << " GeV/c" << endl;
cout << " ESD muon track " << endl;
cout << " -----------------------------------------------------------------------------------------------------------" << endl;
cout << " InvBendMom BendSlope NonBendSlope BendCoord NonBendCoord Z Px Py Pz" << endl;
-
- cout << " " <<
-
- setw(8) << setprecision(4) <<
- mtp->GetInverseBendingMomentum() << " " <<
-
+
+ cout << " " <<
+
+ setw(8) << setprecision(4) <<
+ mtp->GetInverseBendingMomentum() << " " <<
+
setw(8) << setprecision(3) <<
- mtp->GetBendingSlope()*RADDEG << " " <<
-
+ mtp->GetBendingSlope()*RADDEG << " " <<
+
setw(8) << setprecision(3) <<
- mtp->GetNonBendingSlope()*RADDEG << " " <<
-
+ mtp->GetNonBendingSlope()*RADDEG << " " <<
+
setw(8) << setprecision(4) <<
- mtp->GetBendingCoor() << " " <<
-
+ mtp->GetBendingCoor() << " " <<
+
setw(8) << setprecision(4) <<
- mtp->GetNonBendingCoor() << " " <<
-
+ mtp->GetNonBendingCoor() << " " <<
+
setw(10) << setprecision(6) <<
- mtp->GetZ() << " " <<
-
+ mtp->GetZ() << " " <<
+
setw(8) << setprecision(3) <<
- mtp->Px() << " " <<
-
+ mtp->Px() << " " <<
+
setw(8) << setprecision(3) <<
- mtp->Py() << " " <<
-
+ mtp->Py() << " " <<
+
setw(8) << setprecision(3) <<
- mtp->Pz() << " " <<
-
+ mtp->Pz() << " " <<
+
endl;
-
+
pt = TMath::Sqrt(mtp->Px()*mtp->Px()+mtp->Py()*mtp->Py());
-
+
cout << endl;
- cout << " Pt = " <<
+ cout << " Pt = " <<
setw(8) << setprecision(3) <<
pt << " GeV/c" << endl;
-
- cout << " P = " <<
+
+ cout << " P = " <<
setw(8) << setprecision(4) <<
mtp->P() << " GeV/c" << endl;
-
+
AliESDEvent* esd = AliEveEventManager::AssertESD();
-
+
Double_t spdVertexX = 0;
Double_t spdVertexY = 0;
Double_t spdVertexZ = 0;
spdVertexY = spdVertex->GetYv();
spdVertexX = spdVertex->GetXv();
}
-
+
AliESDVertex* esdVertex = (AliESDVertex*) esd->GetPrimaryVertex();
if (esdVertex->GetNContributors()) {
esdVertexZ = esdVertex->GetZv();
esdVertexY = esdVertex->GetYv();
esdVertexX = esdVertex->GetXv();
}
-
+
Float_t t0v = esd->GetT0zVertex();
-
+
cout << endl;
cout << endl;
- cout << "External vertex SPD: " <<
+ cout << "External vertex SPD: " <<
setw(3) <<
spdVertex->GetNContributors() << " " <<
setw(8) << setprecision(3) <<
spdVertexX << " " <<
spdVertexY << " " <<
spdVertexZ << " " << endl;
- cout << "External vertex ESD: " <<
+ cout << "External vertex ESD: " <<
setw(3) <<
esdVertex->GetNContributors() << " " <<
setw(8) << setprecision(3) <<
esdVertexX << " " <<
esdVertexY << " " <<
esdVertexZ << " " << endl;
- cout << "External vertex T0: " <<
+ cout << "External vertex T0: " <<
setw(8) << setprecision(3) <<
t0v << " " << endl;
-
+
}
//______________________________________________________________________
if (fIsMCTrack) {
PrintMCTrackInfo();
}
-
+
if (fIsMUONTrack || fIsRefTrack) {
PrintMUONTrackInfo();
}
-
+
if (fIsESDTrack) {
PrintESDTrackInfo();
}
if (fIsMUONTriggerTrack) {
PrintMUONTriggerTrackInfo();
}
-
+
cout << endl;
cout << endl;
cout << endl;
cout << endl;
cout << "#########################################################################################################################<<<<<" << endl;
cout << endl;
-
+
}
}
Float_t xr[28], yr[28], zr[28];
Float_t xrc[28], yrc[28], zrc[28];
char form[1000];
-
+
TMatrixD smatrix(2,2);
TMatrixD sums(2,1);
TMatrixD res(2,1);
Float_t xRec, xRec0;
Float_t yRec, yRec0;
Float_t zRec, zRec0;
-
+
// middle z between the two detector planes of the trigger chambers
Float_t zg[4] = { -1603.5, -1620.5, -1703.5, -1720.5 };
SetName(form);
SetLineStyle(1);
}
-
- AliMUONTrackParam *trackParam = mtrack->GetTrackParamAtVertex();
+
+ AliMUONTrackParam *trackParam = mtrack->GetTrackParamAtVertex();
xRec0 = trackParam->GetNonBendingCoor();
yRec0 = trackParam->GetBendingCoor();
zRec0 = trackParam->GetZ();
-
+
if (fIsMUONTrack) {
SetPoint(fCount,xRec0,yRec0,zRec0);
fCount++;
}
for (Int_t i = 0; i < 28; i++) xr[i]=yr[i]=zr[i]=0.0;
-
+
Int_t nTrackHits = mtrack->GetNClusters();
-
+
Bool_t hitChamber[14] = {kFALSE};
Int_t iCha;
TClonesArray* trackParamAtCluster = mtrack->GetTrackParamAtCluster();
for (Int_t iHit = 0; iHit < nTrackHits; iHit++){
- trackParam = (AliMUONTrackParam*) trackParamAtCluster->At(iHit);
-
+ trackParam = (AliMUONTrackParam*) trackParamAtCluster->At(iHit);
+
if (iHit == 0) {
if (IsMUONTrack()) {
pt = TMath::Sqrt(trackParam->Px()*trackParam->Px()+trackParam->Py()*trackParam->Py());
xRec = trackParam->GetNonBendingCoor();
yRec = trackParam->GetBendingCoor();
zRec = trackParam->GetZ();
-
+
iCha = AliMUONConstants::ChamberNumber(zRec);
-
+
xr[iHit] = xRec;
yr[iHit] = yRec;
zr[iHit] = zRec;
fCount++;
}
}
-
+
if (!fIsMUONTrack) return;
Int_t nrc = 0;
if (mtrack->GetMatchTrigger() && 1) {
-
+
for (Int_t i = 0; i < nTrackHits; i++) {
if (TMath::Abs(zr[i]) > 1000.0) {
//printf("TEveHit %d x %f y %f z %f \n",iHit,xr[i],yr[i],zr[i]);
nrc++;
}
}
-
+
if (nrc < 2) return;
-
+
// fit x-z
smatrix.Zero();
sums.Zero();
res = smatrix.Invert() * sums;
ax = res(0,0);
bx = res(1,0);
-
+
// fit y-z
smatrix.Zero();
sums.Zero();
res = smatrix.Invert() * sums;
ay = res(0,0);
by = res(1,0);
-
+
Float_t xtc, ytc, ztc;
for (Int_t ii = 0; ii < 4; ii++) {
-
+
ztc = zg[ii];
ytc = ay+by*zg[ii];
xtc = ax+bx*zg[ii];
-
+
//printf("tc: x %f y %f z %f \n",xtc,ytc,ztc);
-
+
SetPoint(fCount,xtc,ytc,ztc);
fCount++;
-
+
}
-
+
} // end match trigger
}
pv[1] = trackParam.Py();
pv[2] = trackParam.Pz();
fP.Set(pv);
-
+
vect[0] = trackParam.GetNonBendingCoor();
vect[1] = trackParam.GetBendingCoor();
vect[2] = trackParam.GetZ();
TParticlePDG *ppdg = fPart->GetPDG(1);
Int_t charge = (Int_t)(ppdg->Charge()/3.0);
-
+
Double_t zMax = -1750.0;
Double_t rMax = 350.0;
Double_t r = 0.0;
trackParamAtCluster = fTrack->GetTrackParamAtCluster();
if (IsMUONTrack()) {
- trackParam = (AliMUONTrackParam*)trackParamAtCluster->At(i1);
+ trackParam = (AliMUONTrackParam*)trackParamAtCluster->At(i1);
charge = (Int_t)TMath::Sign(1.0,trackParam->GetInverseBendingMomentum());
}
if (IsRefTrack()) {
trackParam = fTrack->GetTrackParamAtVertex();
charge = (Int_t)TMath::Sign(1.0,trackParam->GetInverseBendingMomentum());
- trackParam = (AliMUONTrackParam*)trackParamAtCluster->At(i1);
+ trackParam = (AliMUONTrackParam*)trackParamAtCluster->At(i1);
}
-
+
vect[0] = xr[i1];
vect[1] = yr[i1];
vect[2] = zr[i1];
vect[i] = vout[i];
}
}
-
+
}
//______________________________________________________________________
void AliEveMUONTrack::GetField(Double_t *position, Double_t *field)
{
- //
+ //
// returns field components at position, for a give field map
//
field[0] = field[1] = field[2] = 0.0;
return;
}
-
+
// force components
//b[1] = 0.0;
//b[2] = 0.0;
}
//______________________________________________________________________
-void AliEveMUONTrack::OneStepRungekutta(Double_t charge, Double_t step,
+void AliEveMUONTrack::OneStepRungekutta(Double_t charge, Double_t step,
Double_t* vect, Double_t* vout)
{
/// ******************************************************************
Double_t g1, g2, g3, g4, g5, g6, ang2, dxt, dyt, dzt;
Double_t est, at, bt, ct, cba;
Double_t f1, f2, f3, f4, rho, tet, hnorm, hp, rho1, sint, cost;
-
+
Double_t x;
Double_t y;
Double_t z;
-
+
Double_t xt;
Double_t yt;
Double_t zt;
const Int_t kipx = 3;
const Int_t kipy = 4;
const Int_t kipz = 5;
-
+
// *.
// *. ------------------------------------------------------------------
// *.
Double_t h = step;
Double_t rest;
-
+
do {
rest = step - tl;
if (TMath::Abs(h) > TMath::Abs(rest)) h = rest;
h *= khalf;
continue;
}
-
+
xyzt[0] = xt;
xyzt[1] = yt;
xyzt[2] = zt;
h *= khalf;
continue;
}
-
+
xyzt[0] = xt;
xyzt[1] = yt;
xyzt[2] = zt;
if (iter++ > maxit) break;
tl += h;
- if (est < kdlt32)
+ if (est < kdlt32)
h *= 2.;
cba = 1./ TMath::Sqrt(a*a + b*b + c*c);
vout[0] = x;
f4 = TMath::Sqrt(f1*f1+f2*f2+f3*f3);
rho = -f4*pinv;
tet = rho * step;
-
+
hnorm = 1./f4;
f1 = f1*hnorm;
f2 = f2*hnorm;
hxp[0] = f2*vect[kipz] - f3*vect[kipy];
hxp[1] = f3*vect[kipx] - f1*vect[kipz];
hxp[2] = f1*vect[kipy] - f2*vect[kipx];
-
+
hp = f1*vect[kipx] + f2*vect[kipy] + f3*vect[kipz];
rho1 = 1./rho;
g4 = -cost;
g5 = sint;
g6 = cost * hp;
-
+
vout[kix] = vect[kix] + g1*vect[kipx] + g2*hxp[0] + g3*f1;
vout[kiy] = vect[kiy] + g1*vect[kipy] + g2*hxp[1] + g3*f2;
vout[kiz] = vect[kiz] + g1*vect[kipz] + g2*hxp[2] + g3*f3;
-
+
vout[kipx] = vect[kipx] + g4*vect[kipx] + g5*hxp[0] + g6*f1;
vout[kipy] = vect[kipy] + g4*vect[kipy] + g5*hxp[1] + g6*f2;
vout[kipz] = vect[kipz] + g4*vect[kipz] + g5*hxp[2] + g6*f3;
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_MUONTrack_H
#define ALIEVE_MUONTrack_H
void MakeRefTrack(AliMUONTrack *mtrack);
void GetField(Double_t *position, Double_t *field);
void Propagate(Float_t *xr, Float_t *yr, Float_t *zr, Int_t i1, Int_t i2);
- void OneStepRungekutta(Double_t charge, Double_t step,
+ void OneStepRungekutta(Double_t charge, Double_t step,
Double_t* vect, Double_t* vout);
Int_t ColorIndex(Float_t val);
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEvePMDModule.h"
{
TString smodule = "Module";
smodule+= ism;
-
+
Float_t xism =0, yism = 0;
Float_t dxism =0, dyism = 0;
Int_t xpad = 0, ypad = 0;
Float_t xpos, ypos;
- TClonesArray *digits = new TClonesArray("AliPMDdigit", 0);
+ TClonesArray *digits = new TClonesArray("AliPMDdigit", 0);
TBranch *branch = pmdt->GetBranch("PMDDigit");
branch->SetAddress(&digits);
AliPMDdigit *pmddigit;
- branch->GetEntry(ism);
+ branch->GetEntry(ism);
Int_t nentries = digits->GetLast();
//printf("%d\n", nentries);
for (Int_t ient = 0; ient < nentries+1; ient++)
{
pmddigit = (AliPMDdigit*)digits->UncheckedAt(ient);
-
+
det = pmddigit->GetDetector();
smn = pmddigit->GetSMNumber();
irow = pmddigit->GetRow();
xpad = irow;
ypad = icol;
}
-
+
RectGeomCellPos(smn, xpad, ypad, xpos, ypos);
AddHexagon(xpos, ypos, fgkZpos, fgkRad);
-
+
QuadValue(adc);
-
+
QuadId(new AliPMDdigit(*pmddigit));
// new TNamed(Form("Quad with idx=%d", ient),
// "This title is not confusing."));
for (Int_t ient = 0; ient < nentries; ient++)
{
AliPMDddldata *pmdddl = (AliPMDddldata*)ddlcont->UncheckedAt(ient);
-
+
det = pmdddl->GetDetector();
smn = pmdddl->GetSMN();
if (smn != ism) continue;
xpad = irow;
ypad = icol;
}
-
+
RectGeomCellPos(smn, xpad, ypad, xpos, ypos);
AddHexagon(xpos, ypos, fgkZpos, fgkRad);
-
+
QuadValue(adc);
-
+
QuadId(new AliPMDddldata(*pmdddl));
//new TNamed(Form("Quad with idx=%d", ient),
// "This title is not confusing."));
RefitPlex();
fHMTrans.SetPos(fX, fY, fZ);
-
+
}
// -------------------------------------------------------------------- //
void AliEvePMDModule::RectGeomCellPos(Int_t ism, Int_t xpad, Int_t ypad,
Float_t &xpos, Float_t &ypos)
{
- // This routine finds the cell eta,phi for the new PMD rectangular
+ // This routine finds the cell eta,phi for the new PMD rectangular
// geometry in ALICE
// Authors : Bedanga Mohanty and Dipak Mishra - 29.4.2003
// modified by B. K. Nandi for change of coordinate sys
//
// ism : Serial module number from 0 to 23 for each plane
-
+
// Corner positions (x,y) of the 24 unit moudles in ALICE PMD
const Double_t kXcorner[24] =
-8.9165, 33.7471, //Type-BR
};
-
+
const Double_t kYcorner[24] =
{
86.225, 86.225, 86.225, //Type-A
-35.925, -35.925 //Type-BR
};
-
+
// const Float_t kSqroot3 = 1.732050808; // sqrt(3.);
// const Float_t kCellRadius = 0.25;
-
+
//
//Every even row of cells is shifted and placed
//in geant so this condition
-8.9165, 33.7471, //Type-BR
};
-
+
const Double_t kYcorner[24] =
{
86.225, 86.225, 86.225, //Type-A
dxism = fgkRad*fgkSqRoot3*96.;
dyism = kDia*48. + fgkRad;
}
-
+
}
// -------------------------------------------------------------------- //
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_PMDModule_H
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEvePMDModuleEditor.h"
{
fInfoFrame = CreateEditorTabSubFrame("Info");
- TGCompositeFrame *title1 = new TGCompositeFrame(fInfoFrame, 145, 10,
- kHorizontalFrame |
- kLHintsExpandX |
- kFixedWidth |
+ TGCompositeFrame *title1 = new TGCompositeFrame(fInfoFrame, 145, 10,
+ kHorizontalFrame |
+ kLHintsExpandX |
+ kFixedWidth |
kOwnBackground);
- title1->AddFrame(new TGLabel(title1, "AliEvePMDModule Info"),
+ title1->AddFrame(new TGLabel(title1, "AliEvePMDModule Info"),
new TGLayoutHints(kLHintsLeft, 1, 1, 0, 0));
title1->AddFrame(new TGHorizontal3DLine(title1),
new TGLayoutHints(kLHintsExpandX, 5, 5, 7, 7));
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_PMDModuleEditor_H
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
//////////////////////////////////////////////////////////////////////////
// //
// The main AliEVE drawing module for the T0 detector //
// //
//////////////////////////////////////////////////////////////////////////
-
+
#include "AliEveEventManager.h"
#include "AliEveT0Module.h"
#include <TStyle.h>
#include <AliRawReaderRoot.h>
#include "AliT0RawReader.h"
#include <AliCDBManager.h>
-#include <AliCDBStorage.h>
+#include <AliCDBStorage.h>
//
// Default constructor
//
-
+
}
/**************************************************************************/
reader->RequireHeader(kTRUE);
AliT0RawReader *start = new AliT0RawReader(reader);
Int_t allData[110][5];
- TRandom r(0);
+ TRandom r(0);
// cout<<ievt<<endl;
TEveRGBAPalette* rawPalette = new TEveRGBAPalette(0, 3000);
rawPalette->SetLimits(1, 3000); // Set proper raw time range.
raw_a->Reset(TEveQuadSet::kQT_HexagonXY, kFALSE, 32);
TEveQuadSet* raw_c = new AliEveT0Module("T0_RAW_C", 3,digits, start); raw_c->SetPalette(rawPalette);
raw_c->Reset(TEveQuadSet::kQT_HexagonXY, kFALSE, 32);
- Float_t angle = 2 * TMath::Pi() / 12;
+ Float_t angle = 2 * TMath::Pi() / 12;
start->Next();
for (Int_t i=0; i<110; i++)
{
- for (Int_t iHit=0; iHit<5; iHit++)
+ for (Int_t iHit=0; iHit<5; iHit++)
{
allData[i][iHit]= start->GetData(i,iHit);
if (allData[i][iHit] != 0) cout<<"event"<<ievt<<" i "<< i<<" "<<allData[i][iHit] - allData[0][0]<<endl;
raw_a->RefitPlex();
raw_c->RefitPlex();
-
+
TEveTrans& ta_a = raw_a->RefHMTrans();
ta_a.SetPos(0, 0, 373);
TEveTrans& tc_c = raw_c->RefHMTrans();
/**************************************************************************/
void AliEveT0Module::MakeModules(AliT0digit *digits)
{
- TRandom r(0);
+ TRandom r(0);
TArrayI ADC(24);
TArrayI TDC(24);
-
+
digits->GetQT1(ADC);
digits->GetTimeCFD(TDC);
// printf("%3d\n",besttimeright);
qat->AddHexagon(x, y, r.Uniform(-0.1, 0.1), 1.0);
qat->QuadValue(TDC[i+12]);
// qat->QuadId(new TNamed(Form("Quad with idx=%d", i), "PMT's time in side A."));
-
+
qc->AddHexagon(x, y, r.Uniform(-0.1, 0.1), 1.0);
qc->QuadValue(ADC[i]);
// qc->QuadId(new TNamed(Form("Quad with idx=%d", i), "PMT's amplitude in side C."));
ta.SetPos(0, 0, 373);
TEveTrans& tc = qc->RefHMTrans();
tc.SetPos(0, 0, -69.7);
-
+
TEveTrans& tat = qat->RefHMTrans();
tat.SetPos(0, 0, 373);
TEveTrans& tct = qct->RefHMTrans();
tct.SetPos(0, 0, -69.7);
-
+
gEve->AddElement(qa);
gEve->AddElement(qc);
gEve->AddElement(qat);
printf(" idx=%d, amplitude=%d\n", idx, qb->fValue);
- }
+ }
if (fSigType == 1) {
printf("tdc====================\n");
-
+
Int_t besttimeright = fDigits->BestTimeA();
Int_t besttimeleft = fDigits->BestTimeC();
Int_t meantime = fDigits->MeanTime();
printf("besttimeC=%3d\n",fStart->GetData(52,0)-fStart->GetData(0,0));
printf("meantime=%3d\n",fStart->GetData(49,0)-fStart->GetData(0,0));
printf("amplitude= %3d\n",fStart->GetData(idx+1,0));
-
+
printf(" idx=%d, time %d\n", idx, qb->fValue);
}
if (fSigType == 3) {
printf("besttimeC=%3d\n",fStart->GetData(52,0)-fStart->GetData(0,0));
printf("meantime=%3d\n",fStart->GetData(49,0)-fStart->GetData(0,0));
printf("amplitude= %3d\n",fStart->GetData(idx+13,0));
-
+
printf(" idx=%d, time %d\n", idx, qb->fValue);
}
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_T0Module_H
#define ALIEVE_T0Module_H
#include <AliT0digit.h>
#include <AliT0RawReader.h>
-
+
class AliEveT0Module : public TEveQuadSet
{
-
+
AliEveT0Module(const AliEveT0Module&);
AliEveT0Module& operator=(const AliEveT0Module&);
public:
-
+
AliEveT0Module(const Text_t* n="AliEveT0Module", Int_t sigType=0, AliT0digit *digits=0,AliT0RawReader *start=0);
virtual ~AliEveT0Module();
AliT0digit *fDigits;
AliT0RawReader *fStart;
- ClassDef(AliEveT0Module,1);
+ ClassDef(AliEveT0Module,1);
};
/*
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
//
// AliEveTOFDigitsInfo
ClassImp(AliEveTOFDigitsInfo)
- AliEveTOFDigitsInfo::AliEveTOFDigitsInfo():
+ AliEveTOFDigitsInfo::AliEveTOFDigitsInfo():
TObject(),
TEveRefCnt(),
fTree (0),
{}
/* ******************************************************* */
-AliEveTOFDigitsInfo:: ~AliEveTOFDigitsInfo()
+AliEveTOFDigitsInfo:: ~AliEveTOFDigitsInfo()
{
delete fGeom;
void AliEveTOFDigitsInfo::SetTree(TTree* tree)
{
static const TEveException eH("AliEveTOFDigitsInfo::SetTree ");
-
+
if(fGeom == 0) {
fGeom = new AliTOFGeometry();
}
-
+
fTree = tree;
/*
DecRefCount();
for (Int_t digitNumber=0; digitNumber<digitsTOF->GetEntries(); digitNumber++) {
//if (digitNumber==digitsTOF->GetEntries()-1) printf(" Hello 4 -> %3i digit of %i \n", digitNumber+1, digitsTOF->GetEntries());
-
+
digs = (AliTOFdigit*)digitsTOF->UncheckedAt(digitNumber);
vol[0] = digs->GetSector(); // Sector Number (0-17)
//Int_t nSector = 1;
Int_t vol[5] = {nSector,-1,-1,-1,-1};
-
+
for(Int_t iPlate=0; iPlate<fGeom->NPlates(); iPlate++){
vol[1] = iPlate;
if(iPlate==2) nStrips=15;
else nStrips=19;
-
+
for(Int_t iStrip=0; iStrip<nStrips; iStrip++){
vol[2] = iStrip;
-
+
for(Int_t iPadZ=0; iPadZ<fGeom->NpadZ(); iPadZ++){
vol[4] = iPadZ;
for (Int_t ii=0; ii<4; ii++) informations[ii]=-1;
for (Int_t ii=0; ii<3; ii++) dummy[ii]=-1;
for (Int_t ii=0; ii<3; ii++) nDigitsInVolume[ii]=-1;
-
+
}
}
}
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_TOFDigitsInfo_H
#define ALIEVE_TOFDigitsInfo_H
#include <AliTOFGeometry.h>
#include <AliTOFDigitMap.h>
-
+
class AliEveTOFDigitsInfo : public TObject, public TEveRefCnt
{
AliEveTOFDigitsInfo(const AliEveTOFDigitsInfo&); // Not implemented
AliEveTOFDigitsInfo& operator=(const AliEveTOFDigitsInfo&); // Not implemented
-
+
private:
protected:
AliEveTOFDigitsInfo();
virtual ~AliEveTOFDigitsInfo();
-
+
void SetTree(TTree* tree);
void LoadDigits();
TClonesArray* GetDigits(Int_t nSector, Int_t nPlate, Int_t nStrip);
TClonesArray* GetDigits(Int_t nSector);
void GetDigits();
-
+
ClassDef(AliEveTOFDigitsInfo, 1);
}; // endclass AliEveTOFDigitsInfo
-
+
#endif
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveTOFDigitsInfoEditor.h"
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_TOFDigitsInfoEditor_H
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveTOFSector.h"
//fgTOFsectorPalette = new TEveRGBAPalette(0, 2048); // TOT
fgTOFsectorPalette = new TEveRGBAPalette(0, 8192/*1024*/); // TDC
- fgTOFsectorPalette->SetLimits(0, 8192);
+ fgTOFsectorPalette->SetLimits(0, 8192);
fgStaticInitDone = kTRUE;
}
//fFrame = fgTOFsectorFrameBox;
//fPalette = fgTOFsectorPalette;
- LoadQuads();
+ LoadQuads();
ComputeBBox();
SetTrans();
for (Int_t digitNumber=0; digitNumber<digitsTOFnew->GetEntries(); digitNumber++) {
//if (digitNumber==digitsTOF->GetEntries()-1) printf(" Hello 4 -> %3i digit of %i \n", digitNumber+1, digitsTOF->GetEntries());
-
+
digs = (AliTOFdigit*)digitsTOFnew->UncheckedAt(digitNumber);
if (digs->GetSector()!=fSectorID) continue;
for (Int_t ii=0; ii<fTOFarray->GetEntries(); ii++) {
tofDigit = (AliTOFdigit*)fTOFarray->UncheckedAt(ii);
-
+
if (fPlateFlag[tofDigit->GetPlate()]) {
vol[1] = tofDigit->GetPlate();
(Float_t)coord[1][0], (Float_t)coord[1][1], (Float_t)coord[1][2],
(Float_t)coord[2][0], (Float_t)coord[2][1], (Float_t)coord[2][2],
(Float_t)coord[3][0], (Float_t)coord[3][1], (Float_t)coord[3][2]};
-
+
AddQuad(vertices);
//AddQuad((Float_t*)coord);
//AddQuad(coord[0], coord[1], coord[2], 2.5, 3.5);
//QuadValue((Int_t)tot);
QuadValue((Int_t)tdc);
QuadId(tofDigit);
-
+
//}
} // closed if control on plates switched on
} // closed loop on TOF sector digits
RefitPlex();
fTOFarray = 0x0;
-
+
}
/* ************************************************************ */
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_TOFSector_H
#define ALIEVE_TOFSector_H
#include <AliTOFGeometry.h>
-
+
class AliEveTOFSector : public TEveQuadSet
-
+
{
AliEveTOFSector(const AliEveTOFSector&); // Not implemented
AliEveTOFSector& operator=(const AliEveTOFSector&); // Not implemented
-
+
//Int_t fSectorID;
private:
void LoadQuads();
-
+
protected:
-
+
AliTOFGeometry *fTOFgeometry;
-
+
TClonesArray *fTOFarray;
TTree *fTOFtree;
-
+
Int_t fSector;
//Int_t fPlate;
//Int_t fStrip;
-
+
Float_t fDx;
Float_t fDy;
Float_t fDz;
///////////////////////////////
- Bool_t fAutoTrans;
- Int_t fMinTime;
+ Bool_t fAutoTrans;
+ Int_t fMinTime;
Int_t fMaxTime;
Short_t fThreshold;
Int_t fMaxVal;
- Int_t fSectorID;
+ Int_t fSectorID;
Bool_t *fPlateFlag;
Bool_t fPlateFlag0;
Bool_t fPlateFlag2;
Bool_t fPlateFlag3;
Bool_t fPlateFlag4;
-
+
Color_t fFrameColor;
Bool_t fRnrFrame;
-
+
TGeoManager *fGeoManager;
-
- public:
+
+ public:
// Bool_t fAutoTrans;
-
+
virtual void InitModule();
- virtual void SetTrans();
+ virtual void SetTrans();
AliEveTOFSector(const Text_t* n="AliEveTOFSector", const Text_t* t=0);
AliEveTOFSector(TGeoManager *localGeoManager, Int_t nSector);
-
+
AliEveTOFSector(TGeoManager *localGeoManager, Int_t nSector,
TClonesArray *tofArray);
AliEveTOFSector(TGeoManager *localGeoManager,
Int_t nSector, TTree *tofTree);
virtual ~AliEveTOFSector();
-
+
static Bool_t fgStaticInitDone;
static void InitStatics();
Int_t GetSectorID() const {return fSectorID;};
virtual void DigitSelected(Int_t idx);
///////////////////////////////////////////
-
+
void SetPlate(Int_t nPlate, Bool_t r);
static TEveFrameBox *fgTOFsectorFrameBox;
static TEveRGBAPalette *fgTOFsectorPalette;
ClassDef(AliEveTOFSector, 1);
- };
+ };
#endif
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveTOFSectorEditor.h"
//
ClassImp(AliEveTOFSectorEditor)
-
+
AliEveTOFSectorEditor::AliEveTOFSectorEditor(const TGWindow *p, Int_t width, Int_t height,
UInt_t options, Pixel_t back) :
TGedFrame(p, width, height, options | kVerticalFrame, back),
// fTime (0)
// Initialize widget pointers to 0
//{
-
+
/*
fHMTrans = new TEveTransSubEditor(this);
fHMTrans->Connect("UseTrans()", "AliEveTPCSectorVizEditor", this, "Update()");
fHMTrans->Connect("TransChanged()", "AliEveTPCSectorVizEditor", this, "Update()");
AddFrame(fHMTrans, new TGLayoutHints(kLHintsTop | kLHintsExpandX, 2, 0, 0, 0));
-
+
MakeTitle("AliEveTPCSectorViz");*/
{
-
+
fPlate = new TGCheckButton*[5];
for (Int_t ii=0; ii<5; ii++) fPlate[ii] = new TGCheckButton;
-
+
//fPriority = 40;
- MakeTitle("AliEveTOFSector");
+ MakeTitle("AliEveTOFSector");
fSectorID = new TEveGValuator(this, "SectorID", 110, 0);
fSectorID->SetLabelWidth(60);
fSectorID->AddFrame(fAutoTrans, new TGLayoutHints(kLHintsLeft, 12, 0, 1, 0));
fAutoTrans->Connect("Toggled(Bool_t)","AliEveTOFSectorEditor", this, "DoAutoTrans()");
AddFrame(fSectorID, new TGLayoutHints(kLHintsTop, 1, 1, 1, 1));
-
+
// Create widgets
// fXYZZ = new TGSomeWidget(this, ...);
// AddFrame(fXYZZ, new TGLayoutHints(...));
fThreshold->Connect("ValueSet(Double_t)",
"AliEveTOFSectorEditor", this, "DoThreshold()");
AddFrame(fThreshold, new TGLayoutHints(kLHintsTop, 1, 1, 2, 1));
-
+
fMaxVal = new TEveGValuator(this,"MaxVal", 200, 0);
fMaxVal->SetNELength(4);
fMaxVal->SetLabelWidth(60);
fMaxVal->Connect("ValueSet(Double_t)",
"AliEveTOFSectorEditor", this, "DoMaxVal()");
AddFrame(fMaxVal, new TGLayoutHints(kLHintsTop, 1, 1, 2, 1));
-
+
}
/**************************************************************************/
/*
void AliEveTOFSectorEditor::DoTime()
-{
+{
fM->SetMinTime((Int_t) fTime->GetMin());
fM->SetMaxTime((Int_t) fTime->GetMax());
Update();
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_TOFSectorEditor_H
class TEveGDoubleValuator;
class TEveTransSubEditor;
-
+
class AliEveTOFSector;
-
+
class AliEveTOFSectorEditor : public TGedFrame
{
//private:
protected:
AliEveTOFSector* fM; // fModel dynamic-casted to AliEveTOFSectorEditor
-
+
TEveGValuator* fSectorID;
-
+
TGCheckButton* fAutoTrans;
TGCheckButton** fPlate;
TGCheckButton* fPlate4;
TEveGValuator* fThreshold;
- TEveGValuator* fMaxVal;
+ TEveGValuator* fMaxVal;
// Declare widgets
// TGSomeWidget* fXYZZ;
-
+
public:
AliEveTOFSectorEditor(const TGWindow* p=0, Int_t width=170, Int_t height=30, UInt_t options = kChildFrame, Pixel_t back=GetDefaultFrameBackground());
virtual ~AliEveTOFSectorEditor();
-
+
virtual void SetModel(TObject* obj);
void DoSectorID();
- void DoAutoTrans();
+ void DoAutoTrans();
void DoPlate0();
void DoPlate1();
void DoPlate2();
// Declare callback/slot methods
// void DoXYZZ();
-
+
ClassDef(AliEveTOFSectorEditor, 0); // Editor for AliEveTOFSector
}; // endclass AliEveTOFSectorEditor
-
+
#endif
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveTOFStrip.h"
fDx(0), fDz(0),
fGeoManager(localGeoManager)
{
-
+
//if (!fGeoManager) printf("ERROR: no TGeo\n");
InitModule();
//fFrame = fgTOFstripFrameBox;
//fPalette = fgTOFstripPalette;
- LoadQuads();
+ LoadQuads();
ComputeBBox();
SetTrans();
}
RefitPlex();
-
+
}
/* ************************************************************ */
fGeoManager->cd(path);
TGeoHMatrix global = *fGeoManager->GetCurrentMatrix();
Double_t *rotMat = global.GetRotationMatrix();
-
+
/*
// ok till 19 April 2007
fHMTrans.SetBaseVec(1, rotMat[0], rotMat[1], rotMat[2]);
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_TOFStrip_H
#define ALIEVE_TOFStrip_H
private:
void LoadQuads();
-
+
protected:
virtual void InitModule();
virtual void SetTrans();
static TEveRGBAPalette* fgTOFstripPalette;
ClassDef(AliEveTOFStrip, 1);
-};
+};
#endif
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveTOFStripEditor.h"
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_TOFStripEditor_H
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveTPCData.h"
// load time: use SetLoadThreshold(thresh) and SetLoadPedestal(ped).
//
// For raw-data (loaded using LoadRaw) pedestals can be calculated
-// automatically per pad. Use SetAutoPedestal(kTRUE) to activate it.
+// automatically per pad. Use SetAutoPedestal(kTRUE) to activate it.
// You might still want to set load threshold (default iz zero).
//
AliSimDigits digit, *digitPtr = &digit;
tree->GetBranch("Segment")->SetAddress(&digitPtr);
-
+
Int_t sector, row, pad, curPad;
Short_t time, signal;
Bool_t inFill = kFALSE;
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_TPCData_H
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveTPCLoader.h"
fReader->Select("TPC");
fData->DropAllSectors();
- fData->LoadRaw(input, kTRUE, kTRUE);
+ fData->LoadRaw(input, kTRUE, kTRUE);
}
void AliEveTPCLoader::NextEvent(Bool_t rewindOnEnd)
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_TPCLoader_H
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveTPCLoaderEditor.h"
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_TPCLoaderEditor_H
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveTPCSector2D.h"
buffer.fTransparency = 0;
fHMTrans.SetBuffer3D(buffer);
buffer.SetSectionsValid(TBuffer3D::kCore);
-
+
Int_t reqSections = gPad->GetViewer3D()->AddObject(buffer);
if (reqSections == TBuffer3D::kNone) {
return;
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_TPCSector2D_H
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveTPCSector2DEditor.h"
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_TPCSector2DEditor_H
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveTPCSector2DGL.h"
AliEveTPCSector2DGL::AliEveTPCSector2DGL() :
TGLObject(),
-
+
fSector (0),
fSectorData (0),
Int_t row, Int_t col_off) const
{
Int_t padVal;
- Int_t time, val;
+ Int_t time, val;
Int_t minTime = fSector->fMinTime;
Int_t maxTime = fSector->fMaxTime;
UChar_t* img_pos = GetRowCol(row, col_off);
while (iter.NextPad()) {
- padVal = 0;
+ padVal = 0;
while (iter.Next()) {
time = iter.Time();
Float_t u2 = u1 + (Float_t) seg.GetNMaxPads() / fgkTextureWidth;
Float_t v2 = v1 + (Float_t) seg.GetNRows() / fgkTextureHeight;
- glBegin(GL_QUADS);
+ glBegin(GL_QUADS);
glTexCoord2f(u1, v1); glVertex2f(-w, y1);
glTexCoord2f(u1, v2); glVertex2f(-w, y2);
glTexCoord2f(u2, v2); glVertex2f( w, y2);
glVertex2f(-s.GetNMaxPads()*s.GetPadWidth()/2, y);
}
-void AliEveTPCSector2DGL::TraceStepsDown(const AliEveTPCSectorData::SegmentInfo& s)
+void AliEveTPCSector2DGL::TraceStepsDown(const AliEveTPCSectorData::SegmentInfo& s)
{
Float_t x = s.GetNMaxPads()*s.GetPadWidth()/2;
Float_t y = s.GetRLow() + s.GetNRows()*s.GetPadHeight();
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_TPCSector2DGL_H
mutable UChar_t* fImage;
mutable UInt_t fTexture;
mutable UInt_t fRTS;
-
+
public:
AliEveTPCSector2DGL();
virtual ~AliEveTPCSector2DGL();
- virtual Bool_t SetModel(TObject* obj, const Option_t* opt=0);
+ virtual Bool_t SetModel(TObject* obj, const Option_t* opt=0);
virtual void SetBBox();
virtual Bool_t SupportsSecondarySelect() const { return kTRUE; }
static const Int_t fgkTextureByteSize;
}; // endclass TPCSector2D_GL_Rnr
-
+
inline UChar_t* AliEveTPCSector2DGL::GetRowCol(Int_t row, Int_t col) const
{
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveTPCSector3D.h"
buffer.fTransparency = 0;
fHMTrans.SetBuffer3D(buffer);
buffer.SetSectionsValid(TBuffer3D::kCore);
-
+
Int_t reqSections = gPad->GetViewer3D()->AddObject(buffer);
if (reqSections == TBuffer3D::kNone) {
return;
/**************************************************************************/
void AliEveTPCSector3D::LoadPadrow(AliEveTPCSectorData::RowIterator& iter,
- Float_t xs, Float_t ys, Float_t pw, Float_t ph)
+ Float_t xs, Float_t ys, Float_t pw, Float_t ph)
{
Short_t pad, time, val;
Float_t x0, z0;
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_TPCSector3D_H
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveTPCSector3DEditor.h"
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_TPCSector3DEditor_H
public:
AliEveTPCSector3DEditor(const TGWindow* p=0, Int_t width=170, Int_t height=30,
- UInt_t options=kChildFrame, Pixel_t back=GetDefaultFrameBackground());
+ UInt_t options=kChildFrame, Pixel_t back=GetDefaultFrameBackground());
virtual ~AliEveTPCSector3DEditor();
virtual void SetModel(TObject* obj);
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveTPCSector3DGL.h"
if(fRTS < fSector->fRTS) {
fSector->UpdateBoxes();
fRTS = fSector->fRTS;
- }
+ }
if (rnrCtx.SecSelection()) glPushName(0);
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_TPCSector3DGL_H
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveTPCSectorData.h"
fgOut1Seg.fLastRow = fgOut1Seg.fFirstRow + fgOut1Seg.fNRows - 1;
fgOut1Seg.fNMaxPads = fgParam->GetNPadsUp(fgOut1Seg.fNRows - 1);
fgSegInfoPtrs[1] = &fgOut1Seg;
-
+
fgOut2Seg.fPadWidth = fgParam->GetOuterPadPitchWidth();
fgOut2Seg.fPadHeight = fgParam->GetOuter2PadPitchLength();
fgOut2Seg.fRLow = fgParam->GetPadRowRadiiUp(fgOut1Seg.fNRows);
}
}
fgInnSeg.fNYSteps = k;
- // Out1 seg
+ // Out1 seg
k=0; npads = fgParam->GetNPadsUp(0);
for (int row = 0; row < fgOut1Seg.fNRows; ++row) {
if (fgParam->GetNPadsUp(row) > npads) {
if(autoPedestal) {
Short_t array[1024];
Short_t* val;
- val = beg + 1;
+ val = beg + 1;
while(val <= end) {
array[(val-beg)/2] = *val;
val += 2;
- }
+ }
Short_t pedestal = TMath::Nint(TMath::Median((end-beg)/2, array));
val = beg + 1;
while(val <= end) {
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_TPCSectorData_H
Bool_t NextPad();
void ResetRow();
void ResetRow(const PadData* first, Short_t npads);
-
+
Short_t TEvePad() const { return fPad; }
void Test();
static const SegmentInfo& GetOut2Seg() { return fgOut2Seg; }
static const SegmentInfo& GetSeg(Int_t seg);
-
+
static void InitStatics();
protected:
void* fPadRowHackSet;
-
+
ClassDef(AliEveTPCSectorData, 0);
}; // endclass AliEveTPCSectorData
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveTPCSectorViz.h"
/**************************************************************************/
-void AliEveTPCSectorViz::SetAutoTrans(Bool_t trans)
+void AliEveTPCSectorViz::SetAutoTrans(Bool_t trans)
{
fAutoTrans = trans;
if(fAutoTrans) {
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_TPCSectorViz_H
#include <TEveElement.h>
#include <TEveTrans.h>
-#include <TNamed.h>
+#include <TNamed.h>
#include <TAtt3D.h>
#include <TAttBBox.h>
AliEveTPCSectorViz& operator=(const AliEveTPCSectorViz&); // Not implemented
protected:
- AliEveTPCData* fTPCData;
+ AliEveTPCData* fTPCData;
Int_t fSectorID;
- Int_t fMinTime;
+ Int_t fMinTime;
Int_t fMaxTime;
Short_t fThreshold;
Int_t fMaxVal;
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveTPCSectorVizEditor.h"
/**************************************************************************/
void AliEveTPCSectorVizEditor::DoTime()
-{
+{
fM->SetMinTime((Int_t) fTime->GetMin());
fM->SetMaxTime((Int_t) fTime->GetMax());
Update();
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_TPCSectorVizEditor_H
TGCheckButton* fRnrOut2;
TEveGValuator* fThreshold;
- TEveGValuator* fMaxVal;
+ TEveGValuator* fMaxVal;
TEveGDoubleValuator* fTime;
void DoMaxVal();
void DoTime();
-
+
ClassDef(AliEveTPCSectorVizEditor, 0); // Editor for AliEveTPCSectorViz
}; // endclass AliEveTPCSectorVizEditor
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveTRDData.h"
#include "AliEveTRDModuleImp.h"
//________________________________________________________
void AliEveTRDDigits::SetData(AliTRDdigitsManager *digits)
{
-
+
fData.Allocate(fParent->rowMax, fParent->colMax, fParent->timeMax);
// digits->Expand();
for (Int_t row = 0; row < fParent->rowMax; row++)
TEveQuadSet::Reset(TEveQuadSet::kQT_FreeQuad, kTRUE, 64);
// MT fBoxes.fBoxes.clear();
-
+
Double_t colSize, rowSize, scale;
Double_t x, y, z;
Int_t charge;
Float_t t0;
Float_t timeBinSize;
-
+
AliTRDcalibDB* calibration = AliTRDcalibDB::Instance();
Double_t cloc[4][3], cglo[3];
Int_t color, dimension;
for (Int_t row = 0; row < fParent->rowMax; row++) {
rowSize = .5 * fParent->fPadPlane->GetRowSize(row);
z = fParent->fPadPlane->GetRowPos(row) - rowSize;
-
+
for (Int_t col = 0; col < fParent->colMax; col++) {
colSize = .5 * fParent->fPadPlane->GetColSize(col);
y = fParent->fPadPlane->GetColPos(col) - colSize;
t0 = calibration->GetT0(fParent->fDet, col, row);
timeBinSize = calibration->GetVdrift(fParent->fDet, col, row)/fParent->samplingFrequency;
-
+
for (Int_t time = 0; time < fParent->timeMax; time++) {
charge = fData.GetDataUnchecked(row, col, time);
if (charge < fParent->GetDigitsThreshold()) continue;
-
+
x = fParent->fX0 - (time+0.5-t0)*timeBinSize;
scale = fParent->GetDigitsLog() ? TMath::Log(float(charge))/TMath::Log(1024.) : charge/1024.;
color = 50+int(scale*50.);
-
+
cloc[0][2] = z - rowSize * scale;
cloc[0][1] = y - colSize * scale;
cloc[0][0] = x;
-
+
cloc[1][2] = z - rowSize * scale;
cloc[1][1] = y + colSize * scale;
cloc[1][0] = x;
-
+
cloc[2][2] = z + rowSize * scale;
cloc[2][1] = y + colSize * scale;
cloc[2][0] = x;
-
+
cloc[3][2] = z + rowSize * scale;
cloc[3][1] = y - colSize * scale;
cloc[3][0] = x;
-
+
Float_t* p = 0;
if( fParent->GetDigitsBox()){
// MT fBoxes.fBoxes.push_back(Box());
{
fM = dynamic_cast<AliEveTRDDigits*>(obj);
fM->fParent->SpawnEditor();
-
+
// printf("Chamber %d", fM->fParent->GetID());
// for (Int_t row = 0; row < fM->fParent->GetRowMax(); row++)
// for (Int_t col = 0; col < fM->fParent->GetColMax(); col++)
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
/////////////////////////////////////////////////////////////////////////
//
// - AliEVE implementation -
-// Containers for visualisation of TRD data structures
+// Containers for visualisation of TRD data structures
// - AliEveTRDHits - visualisation of MC Hits, Clusters (RecPoints)
// - AliEveTRDDigits - visualisation of TRD digits
//
protected:
AliEveTRDChamber *fParent;
-
+
ClassDef(AliEveTRDHits,1) // Base class for TRD hits visualisation
};
AliEveTRDHits* fM;
ClassDef(AliEveTRDHitsEditor,1) // Editor for AliEveTRDHits
- };
+ };
class AliEveTRDDigits : public TEveQuadSet
protected:
AliEveTRDChamber *fParent;
-
+
private:
TEveBoxSet fBoxes;
AliTRDdataArrayI fData;
-
+
ClassDef(AliEveTRDDigits,1) // Digits visualisation for TRD
};
-
+
class AliEveTRDDigitsEditor : public TGedFrame
{
public:
AliEveTRDClusters(AliEveTRDChamber *p);
void PointSelected(Int_t n);
-
+
ClassDef(AliEveTRDClusters,1) // Base class for TRD clusters visualisation
};
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveTRDLoader.h"
#include "AliEveTRDModuleImp.h"
//________________________________________________________
AliEveTRDLoader::AliEveTRDLoader(const Text_t* n, const Text_t* t) : TEveElementList(n, t), fSM(-1), fStack(-1), fLy(-1), fEvent(0)
-{
+{
kLoadHits = kFALSE;
kLoadDigits = kFALSE;
kLoadClusters = kFALSE;
fDir = ".";
fEvent = -1;
- fTRD = 0x0;
+ fTRD = 0x0;
fGeo = new AliTRDgeometry();
-
+
AliCDBManager *fCDBManager=AliCDBManager::Instance();
fCDBManager->SetDefaultStorage("local://$ALICE_ROOT");
fCDBManager->SetRun(0);
AliEveTRDChamber* AliEveTRDLoader::GetChamber(int d)
{
List_i ism, istack, ichmb;
-
+
ism = find_if(fChildren.begin(), fChildren.end(), ID<TEveElement*>(fGeo->GetSector(d)));
if(ism == fChildren.end()) return 0x0;
istack = find_if(((AliEveTRDNode*)(*ism))->begin(), ((AliEveTRDNode*)(*ism))->end(), ID<TEveElement*>(fGeo->GetChamber(d)));
fEvent = ev;
Unload();
-
+
TTree *t = 0x0;
TFile *f = new TFile(Form("%s/%s", fDir.Data(), fFilename.Data()));
if(! f->cd(Form("AliEveEventManager%d", ev))){
f->Close(); delete f;
return kFALSE;
}
-
+
if(kLoadDigits){
t = (TTree*)gDirectory->Get("TreeD");
if(!t) return kFALSE;
} else AliWarning("Please select first the type of data that you want to monitor and then hit the \"Load\" button.");
f->Close(); delete f;
-
+
gEve->Redraw3D();
-
+
return kTRUE;
}
TObjArray *clusters = new TObjArray();
tC->SetBranchAddress("TRDcluster", &clusters);
- AliEveTRDChamber *chmb = 0x0;
+ AliEveTRDChamber *chmb = 0x0;
AliTRDcluster *c=0x0;
for(int idet=0; idet<540; idet++){
tC->GetEntry(idet);
Bool_t AliEveTRDLoader::LoadDigits(TTree *tD)
{
AliInfo("Loading ...");
-
+
if(!fChildren.size()) return kTRUE;
-
+
AliEveTRDChamber *chmb;
AliTRDdigitsManager dm;
dm.ReadDigits(tD);
TObjArray *tracks = new TObjArray();
tT->SetBranchAddress("TRDmcmTracklet",&tracks);
-
+
AliEveTRDChamber *chmb = 0x0;
AliTRDmcmTracklet *trk=0x0;
for(int idet=0; idet<540; idet++){
if(tracks->GetEntriesFast()) trk = (AliTRDmcmTracklet*)tracks->UncheckedAt(0);
if((chmb = GetChamber(trk->GetDetector()))) chmb->LoadTracklets(tracks);
}
-
+
return kTRUE;
}
-
+
//________________________________________________________
Bool_t AliEveTRDLoader::Open(const char *filename, const char *dir)
count += kLoadDigits ? 1 : 0;
count += kLoadClusters ? 1 : 0;
count += kLoadTracks ? 1 : 0;
-
+
TObjArray *so = fFilename.Tokenize(".");
if(((TObjString*)(*so)[0])->GetString().CompareTo("TRD") != 0){
AliError("Filename didn't fulfill naming conventions. No data will be loaded.");
return kFALSE;
}
-
+
return kTRUE;
}
AliEveTRDLoaderEditor::AliEveTRDLoaderEditor(const TGWindow* p, Int_t width, Int_t height, UInt_t options, Pixel_t back) : TGedFrame(p, width, height, options | kVerticalFrame, back)
{
MakeTitle("AliEveTRDLoader");
-
+
fFile = 0x0;
TGTextButton *fOpenFile = 0x0;
Int_t labelW = 42;
-
+
TGHorizontalFrame* f = new TGHorizontalFrame(this);
TGHorizontalFrame* g = new TGHorizontalFrame(f, labelW, 0, kFixedWidth);
TGLabel* l = new TGLabel(g, "File: ");
fFile->SetWidth(140);
fFile->Connect("DoubleClicked()", "AliEveTRDLoaderEditor", this, "FileOpen()");
f->AddFrame(fFile);
-
+
fOpenFile = new TGTextButton(f, "Browse");
f->AddFrame(fOpenFile);
fOpenFile->Connect("Clicked()", "AliEveTRDLoaderEditor", this, "FileOpen()");
AddFrame(f);
-
+
fEvent = new TEveGValuator(this, "AliEveEventManager:", 110, 0);
fEvent->SetShowSlider(kFALSE);
fEvent->SetLabelWidth(labelW);
// "Chamber(s) selector" group frame
TGGroupFrame *fGroupFrame1974 = new TGGroupFrame(this,"Chamber(s) selector");
TGVerticalFrame *fVerticalFrame1974 = new TGVerticalFrame(fGroupFrame1974, 150, 50,kVerticalFrame);
-
+
fSMNumber = new TEveGValuator(fVerticalFrame1974, "SM:", 0, 0);
fSMNumber->SetShowSlider(kFALSE);
fSMNumber->SetLabelWidth(labelW);
fPlaneNumber->SetToolTip("Plane id [-1 for all in this stack]");
fVerticalFrame1974->AddFrame(fPlaneNumber, new TGLayoutHints(kLHintsLeft | kLHintsTop | kLHintsCenterX | kLHintsExpandY,2,2,2,2));
-
+
fGroupFrame1974->AddFrame(fVerticalFrame1974, new TGLayoutHints(kLHintsLeft | kLHintsTop | kLHintsExpandY | kLHintsCenterX,2,2,2,2));
TGTextButton *fTextButton2037 = new TGTextButton(fGroupFrame1974,"Select");
fEvent->SetEnabled(kFile);
fEvent->GetEntry()->SetIntNumber(fM->fEvent);
-
+
fSMNumber->SetEnabled(kFile);
fSMNumber->GetEntry()->SetIntNumber(fM->fSM);
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_TRDLoader_H
#define ALIEVE_TRDLoader_H
////////////////////////////////////////////////////////////////////////
// // - ALIEVE implementation -
-// Loader for the TRD detector - base class
+// Loader for the TRD detector - base class
// - AliEveTRDLoader - loader of TRD data (simulation + measured)
// - AliEveTRDLoaderEditor - UI
//
protected:
Bool_t kLoadHits, kLoadDigits, kLoadClusters, kLoadTracks;
Int_t fSM, fStack, fLy; // supermodule, stack, layer
- TString fFilename; // name of data file
+ TString fFilename; // name of data file
TString fDir; // data directory
Int_t fEvent; // current event to be displayed
-
+
AliTRDv1 *fTRD; // the TRD detector
AliTRDgeometry *fGeo; // the TRD geometry
-
+
ClassDef(AliEveTRDLoader, 1) // Alieve Loader class for the TRD detector
};
-
+
class AliEveTRDLoaderEditor : public TGedFrame
{
public:
virtual void Load();
virtual void SetEvent(Double_t ev){fM->fEvent = (Int_t)ev;}
virtual void SetModel(TObject* obj);
-
+
protected:
AliEveTRDLoader *fM;
TGTextEntry *fFile;
TEveGValuator *fEvent;
TEveGValuator *fSMNumber, *fStackNumber, *fPlaneNumber;
-
+
ClassDef(AliEveTRDLoaderEditor,1) // Editor for AliEveTRDLoader
};
-
+
#endif
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveTRDLoaderImp.h"
#include "AliEveTRDModuleImp.h"
AliWarning("Please select first the type of data that you want to monitor and then hit the \"Load\" button.");
return kFALSE;
}
-
+
fEvent = ev;
if(!fRunLoader){
}
fRunLoader->UnloadAll("TRD");
Unload();
-
+
if(fRunLoader->GetEvent(ev)) return kFALSE;
TTree *t = 0x0;
if(kLoadHits){
{
Info("LoadHits()", "Loading ...");
if(!fChildren.size()) return kTRUE;
-
+
AliEveTRDChamber *chmb = 0x0;
AliTRDhit *hit = 0x0;
Int_t d;
{
//Info("Open()", "");
-
+
fFilename = filename;
fDir = dir;
fDir += "/";
-
+
fRunLoader = AliRunLoader::GetRunLoader();
if(!fRunLoader) fRunLoader = AliRunLoader::Open(filename,
AliConfig::GetDefaultEventFolderName(),"read");
return kFALSE;
}
fRunLoader->SetDirName(fDir);
-
+
gAlice = fRunLoader->GetAliRun();
if(!gAlice) fRunLoader->LoadgAlice();
if(!gAlice){
AliError("Couldn't find TRD");
return kFALSE;
}
-
+
return kTRUE;
}
-
+
///////////////////////////////////////////////////////////
///////////// AliEveTRDLoaderRaw /////////////////////
if(fRaw) delete fRaw;
fRaw = new AliTRDrawData();
-
+
if(fDataRoot){
if(fRawRootReader) delete fRawRootReader;
fRawRootReader = new AliRawReaderRoot(filename);
fEventOld = -1;
checkEnd = kFALSE;
} else checkEnd = kTRUE;
-
+
do NextEvent(); while(fEventOld != ev && !(checkEnd == kTRUE && fEventOld == 0));
LoadEvent();
gEve->Redraw3D();
Bool_t AliEveTRDLoaderRaw::LoadEvent()
{
Info("LoadEvent()", "Loading ...");
-
+
static const TEveException eH("AliEveTRDLoader::LoadEvent ");
if(fRawRootReader == 0x0) throw(eH + "data file not opened.");
AliEveTRDLoaderSimEditor::AliEveTRDLoaderSimEditor(const TGWindow* p, Int_t width, Int_t height, UInt_t options, Pixel_t back) : TGedFrame(p, width, height, options | kVerticalFrame, back)
{
MakeTitle("AliEveTRDLoaderSim");
-
+
// "Data selector" group frame
TGGroupFrame *fGroupFrame = new TGGroupFrame(this,"Data selector");
fLoadHits = new TGCheckButton(fGroupFrame," Hits");
fLoadHits->Connect("Clicked()", "AliEveTRDLoaderSimEditor", this, "Toggle(=0)");
fGroupFrame->AddFrame(fLoadHits, new TGLayoutHints(kLHintsLeft | kLHintsTop | kLHintsCenterY | kLHintsExpandX,2,2,2,2));
-
+
fLoadDigits = new TGCheckButton(fGroupFrame," Digits");
fLoadDigits->Connect("Clicked()", "AliEveTRDLoaderSimEditor", this, "Toggle(=1)");
fGroupFrame->AddFrame(fLoadDigits, new TGLayoutHints(kLHintsLeft | kLHintsTop | kLHintsCenterY | kLHintsExpandX,2,2,2,2));
// {
// MakeTitle("AliEveTRDLoaderRaw");
// }
-//
+//
// void TRDLoaderRawEditor::SetModel(TObject* obj)
// {
// Info("SetModel()", "");
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_TRDLoaderImp_H
#define ALIEVE_TRDLoaderImp_H
public:
AliEveTRDLoaderSim(const Text_t* n="AliEveTRDLoaderSim", const Text_t* t=0);
~AliEveTRDLoaderSim();
-
+
Bool_t GoToEvent(int ev);
Bool_t LoadHits(TTree *tH);
Bool_t Open(const char *file, const char *dir=".");
-
+
private:
AliRunLoader *fRunLoader; // Run Loader
-
+
ClassDef(AliEveTRDLoaderSim, 1) // Alieve loader for the TRD detector (gAlice)
};
-
+
class AliEveTRDLoaderRaw : public AliEveTRDLoader
{
public:
AliEveTRDLoaderRaw(const Text_t* n="AliEveTRDLoaderRaw", const Text_t* t=0);
~AliEveTRDLoaderRaw();
-
+
Bool_t GoToEvent(int ev);
Bool_t LoadEvent();
Bool_t Open(const char *file, const char *dir=".");
void SetDataType(TRDDataTypes type);
-
+
private:
void NextEvent(Bool_t rewindOnEnd=kTRUE);
-
+
private:
AliRawReaderDate *fRawDateReader;
AliRawReaderRoot *fRawRootReader;
AliTRDrawData *fRaw;
Bool_t fDataRoot;
Int_t fEventOld;
-
+
ClassDef(AliEveTRDLoaderRaw, 1) // Alieve loader for the TRD detector (raw)
};
virtual void SetModel(TObject* obj);
virtual void Toggle(Int_t id);
-
+
protected:
AliEveTRDLoaderSim* fM;
TGCheckButton *fLoadHits, *fLoadDigits, *fLoadClusters, *fLoadTracks;
-
+
ClassDef(AliEveTRDLoaderSimEditor,1) // Editor for AliEveTRDLoaderSim
};
#endif
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveTRDLoaderManager.h"
#include "AliEveTRDLoader.h"
//fChildren.push_back(new AliEveTRDLoaderSim(name, title));
gEve->AddElement(trdl = new AliEveTRDLoaderSim(name, title), this);
((AliEveTRDLoaderSim*)trdl)->FindListTreeItem(gEve->GetListTree())->SetTipText(title);
- break;
+ break;
case 1:
case 2:
case 3:
trdl->SetDataType((TRDDataTypes)type);
break;
}
-
+
gEve->Redraw3D();
}
//________________________________________________________
AliEveTRDLoaderManagerEditor::~AliEveTRDLoaderManagerEditor()
{
-
+
}
case 3:
type = 1;
break;
- case 4:
+ case 4:
case 5:
type = 2;
break;
break;
}
-
+
// horizontal frame
TGHorizontalFrame *fHorizontalFrame = new TGHorizontalFrame(fGroupFrame, 264, 26, kHorizontalFrame);//, bg);
// vall717.fFont = ufont->GetFontHandle();
// vall717.fGraphicsExposures = kFALSE;
// uGC = gClient->GetGC(&vall717, kTRUE);
-
+
TGLabel *fLabel717 = new TGLabel(fHorizontalFrame, entry->GetText()->GetString()/*, uGC->GetGC(), ufont->GetFontStruct(), kChildFrame*/);//, bg);
fLabel717->SetTextJustify(36);
fHorizontalFrame->AddFrame(fLabel717, new TGLayoutHints(kLHintsLeft | kLHintsTop | kLHintsCenterY | kLHintsExpandX,2,2,2,2));
-
+
Int_t nbutton = fM->fChildren.size();
fRemoveButton = new((*fRemove)[nbutton]) TGTextButton(fHorizontalFrame, "Remove", nbutton);
fRemoveButton->SetTextJustify(36);
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_TRDLoaderManager_H
#define ALIEVE_TRDLoaderManager_H
protected:
void Add(Int_t type, const Text_t *name, const Text_t *title=0x0);
void Remove(Int_t entry);
-
+
ClassDef(AliEveTRDLoaderManager, 1) // Alieve loaders manager for TRD
};
virtual void Add();
virtual void Remove(Int_t entry);
virtual void SetModel(TObject* obj);
-
+
protected:
AliEveTRDLoaderManager* fM;
-
+
private:
ULong_t bg; // background color
TGComboBox *fSelector;
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveTRDModule.h"
#include "AliEveTRDModuleImp.h"
{
fLoadHits = kFALSE;
fRnrHits = kTRUE;
-
+
fLoadDigits = kFALSE;
fRnrDigits = kTRUE;
fDigitsLog = kFALSE;
AliEveTRDModuleEditor::AliEveTRDModuleEditor(const TGWindow* p, Int_t width, Int_t height, UInt_t options, Pixel_t back) : TGedFrame(p, width, height, options | kVerticalFrame, back)
{
MakeTitle("TRD Detector");
-
+
// "Hits" group frame
TGGroupFrame *fGroupFrame615 = new TGGroupFrame(this,"Hits");
fDisplayHits = new TGCheckButton(fGroupFrame615,"Display");
fGroupFrame615->AddFrame(fHitsColor, new TGLayoutHints(kLHintsLeft | kLHintsCenterX | kLHintsTop | kLHintsCenterY,2,2,2,2));
fHitsColor->Connect("ColorSelected(Pixel_t)",
"AliEveTRDModuleEditor", this, "UpdateHits(Pixel_t)");
-
+
fGroupFrame615->SetLayoutManager(new TGVerticalLayout(fGroupFrame615));
AddFrame(fGroupFrame615, new TGLayoutHints(kLHintsLeft | kLHintsTop | kLHintsCenterY | kLHintsExpandX,2,2,2,2));
fToggleBox->Connect("Clicked()",
"AliEveTRDModuleEditor", this, "ModifyDigitsView()");
fGroupFrame636->AddFrame(fVerticalFrame538, new TGLayoutHints(kLHintsLeft | kLHintsTop,2,2,2,2));
-
+
TGVertical3DLine *fVertical3DLine773 = new TGVertical3DLine(fGroupFrame636,8,63);
fGroupFrame636->AddFrame(fVertical3DLine773, new TGLayoutHints(kLHintsLeft | kLHintsCenterX | kLHintsTop | kLHintsExpandY,2,2,2,2));
-
+
// vertical frame
TGVerticalFrame *fVerticalFrame543 = new TGVerticalFrame(fGroupFrame636,81,47,kVerticalFrame);
fThreshold = new TGCheckButton(fVerticalFrame543, "Threshold");
fM = dynamic_cast<AliEveTRDModule*>(obj);
if(AliEveTRDNode *node = dynamic_cast<AliEveTRDNode*>(fM)) node->UpdateNode();
-
+
fDisplayHits->SetEnabled(fM->fLoadHits);
if(fM->fLoadHits) fDisplayHits->SetState( fM->fRnrHits ? kButtonDown : kButtonUp);
-
+
fDisplayDigits->SetEnabled(fM->fLoadDigits);
fToggleLog->SetEnabled(fM->fLoadDigits);
fToggleBox->SetEnabled(fM->fLoadDigits);
fToggleBox->SetState(fM->fDigitsBox ? kButtonDown : kButtonUp);
fThreshold->SetState(fM->kDigitsNeedRecompute ? kButtonDown : kButtonUp);
}
-
+
if(fM->fLoadRecPoints) fDisplayClusters->SetState(fM->fRnrRecPoints ? kButtonDown : kButtonUp);
else fDisplayClusters->SetEnabled(kFALSE);
-
+
if(fM->fLoadTracklets) fDisplayTracks->SetState(fM->fRnrTracklets ? kButtonDown : kButtonUp);
else fDisplayTracks->SetEnabled(kFALSE);
}
void AliEveTRDModuleEditor::SetThreshold(Long_t tres)
{
if(!fM->fLoadDigits) return;
-
+
fM->fDigitsThreshold = (tres == 0) ? (int)fThresValue->GetNumber():tres;
fM->kDigitsNeedRecompute = fThreshold->IsDown();
UpdateChamber();
fM->fRnrHits = kFALSE;
if(fDisplayHits->IsDown()) fM->fRnrHits = kTRUE;
-
+
fM->fRnrDigits = kFALSE;
if(fDisplayDigits->IsDown()){
fM->fRnrDigits = kTRUE;
if(fToggleBox->IsDown()) fM->fDigitsBox = kTRUE;
else fM->fDigitsBox = kFALSE;
}
-
+
fM->fRnrRecPoints = kFALSE;
if(fDisplayClusters->IsDown()) fM->fRnrRecPoints = kTRUE;
-
+
fM->fRnrTracklets = kFALSE;
if(fDisplayTracks->IsDown()) fM->fRnrTracklets = kTRUE;
void AliEveTRDModuleEditor::UpdateClusters(Pixel_t /*col*/)
{
// Info("UpdateClusters()","");
-/*
+/*
if(fM->fRecPoints){
fM->fRecPoints->SetMarkerColor(col ? fHitsColor->GetColor() : col);
gEve->Redraw3D();
void AliEveTRDModuleEditor::UpdateHits(Pixel_t /*col*/)
{
// Info("UpdateHits()","");
-/*
+/*
if(fM->fHits){
fM->fHits->SetMarkerColor(col ? fClustersColor->GetColor() : col);
gEve->Redraw3D();
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_TRDModule_H
#define ALIEVE_TRDModule_H
public:
AliEveTRDModule(const char *typ="XXX", Int_t id=0);
virtual ~AliEveTRDModule() {}
-
+
virtual Bool_t GetDigitsBox(){return fDigitsBox;}
virtual Bool_t GetDigitsLog(){return fDigitsLog;}
virtual UShort_t GetDigitsThreshold(){return fDigitsThreshold;}
Bool_t fLoadRecPoints, fRnrRecPoints;
Bool_t fLoadTracklets, fRnrTracklets;
-
+
Int_t fDet; // detector number
UShort_t fDigitsThreshold; // digits threshold
ClassDef(AliEveTRDModule,1) // Structure holder for TRD chamber
};
-
+
class AliEveTRDModuleEditor : public TGedFrame
{
void UpdateChamber();
void UpdateClusters(Pixel_t);
void UpdateHits(Pixel_t);
-
+
protected:
AliEveTRDModule* fM;
TGCheckButton *fDisplayClusters;
TGColorSelect *fClustersColor;
TGCheckButton *fDisplayTracks;
-
+
ClassDef(AliEveTRDModuleEditor,1) // Editor for AliEveTRDModule
};
#endif
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveTRDModuleImp.h"
#include "AliEveTRDData.h"
{
SetRnrSelf(kTRUE);
AliEveTRDNode *node = 0x0;
- AliEveTRDChamber *chmb = 0x0;
+ AliEveTRDChamber *chmb = 0x0;
List_i iter = fChildren.begin();
while(iter != fChildren.end()){
if((node = dynamic_cast<AliEveTRDNode*>(*iter))){
{
SetRnrSelf(kFALSE);
AliEveTRDNode *node = 0x0;
- AliEveTRDChamber *chmb = 0x0;
+ AliEveTRDChamber *chmb = 0x0;
List_i iter = fChildren.begin();
while(iter != fChildren.end()){
if((node = dynamic_cast<AliEveTRDNode*>(*iter))){
while(iter != fChildren.end()){
module = dynamic_cast<AliEveTRDModule*>(*iter);
if(!module) continue;
-
+
module->fRnrHits = fRnrHits;
module->fRnrDigits = fRnrDigits;
module->fDigitsLog = fDigitsLog;
if(!module) continue;
score[0] += (module->fLoadHits) ? 1 : 0;
score[1] += (module->fRnrHits) ? 1 : 0;
-
+
score[2] += (module->fLoadDigits) ? 1 : 0;
score[3] += (module->fRnrDigits) ? 1 : 0;
score[4] += (module->fDigitsLog) ? 1 : 0;
iter++;
}
- Int_t size = fChildren.size();
+ Int_t size = fChildren.size();
fLoadHits = (score[0] > 0) ? kTRUE : kFALSE;
fRnrHits = (score[1] == size) ? kTRUE : kFALSE;
//
// Constructor
//
-
+
fDigits = 0x0;
fHits = 0x0;
fRecPoints = 0x0;
fTracklets = 0x0;
-
+
AliTRDCommonParam* parCom = AliTRDCommonParam::Instance();
samplingFrequency = parCom->GetSamplingFrequency();
-
+
fGeo = 0x0;
fPadPlane = 0x0;
}
if(mod.fDigits) {}
if(mod.fHits) {}
- if(mod.fRecPoints){}
+ if(mod.fRecPoints){}
}
//________________________________________________________
fDet = mod.fDet;
if(mod.fDigits) {}
if(mod.fHits) {}
- if(mod.fRecPoints){}
+ if(mod.fRecPoints){}
}
return *this;
}
//
// Draw clusters
//
-
+
if(!fGeo){
AliError(Form("Geometry not set for chamber %d. Please call first AliEveTRDChamber::SetGeometry().", fDet));
return;
}
-
+
if(!fRecPoints){
fRecPoints = new AliEveTRDClusters(this);
fRecPoints->SetMarkerSize(1.);
Float_t q;
Double_t cloc[3], cglo[3];
-
+
AliTRDcluster *c=0x0;
for(int iclus=0; iclus<clusters->GetEntriesFast(); iclus++){
c = (AliTRDcluster*)clusters->UncheckedAt(iclus);
return;
}
// Info("LoadDigits()", Form("digits =0x%x", digits));
-
+
if(!fDigits) fDigits = new AliEveTRDDigits(this);
else fDigits->Reset();
-
+
fDigits->SetData(digits);
fLoadDigits = kTRUE;
}
fHits->SetMarkerColor(2);
fHits->SetOwnIds(kTRUE);
}
-
+
fHits->SetNextPoint(hit->X(), hit->Y(), hit->Z());
fHits->SetPointId(hit);
fLoadHits = kTRUE;
return;
}
// Info("LoadTracklets()", Form("tracks = 0x%x", tracks));
-
+
if(!fTracklets){
fTracklets = new std::vector<TEveTrack*>;
} else fTracklets->clear();
-
-
+
+
AliTRDmcmTracklet *trk = 0x0;
Double_t cloc[3], cglo[3];
for(int itrk=0; itrk<tracks->GetEntries();itrk++){
trk->MakeTrackletGraph(fGeo,.5);
fTracklets->push_back(new TEveTrack());
fTracklets->back()->SetLineColor(4);
-
+
cloc[0] = trk->GetTime0(); // x0
cloc[1] = trk->GetOffset(); // y0
cloc[2] = trk->GetRowz(); // z
fGeo->RotateBack(fDet,cloc,cglo);
fTracklets->back()->SetNextPoint(cglo[0], cglo[1], cglo[2]);
-
+
cloc[0] += 3.7; // x1
cloc[1] += TMath::Tan(trk->GetSlope()*TMath::Pi()/180.) * 3.7; // y1
fGeo->RotateBack(fDet,cloc,cglo);
void AliEveTRDChamber::SetGeometry(AliTRDgeometry *geo)
{
fGeo = geo;
-
+
fPla = fGeo->GetPlane(fDet);
fX0 = fGeo->GetTime0(fPla);
-
+
fPadPlane = fGeo->GetPadPlane(fPla,fGeo->GetChamber(fDet));
rowMax = fPadPlane->GetNrows();
colMax = fPadPlane->GetNcols();
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_TRDModuleImp_H
#define ALIEVE_TRDModuleImp_H
//
// Implementation of AliEveTRDModule:
// - AliEveTRDChamber - Data holder
-// - AliEveTRDNode - Node structure
+// - AliEveTRDNode - Node structure
//
// by A.Bercuci (A.Bercuci@gsi.de) Fri Oct 27 2006
/////////////////////////////////////////////////////////////////////////
{
friend class AliEveTRDDigits;
public:
-
+
AliEveTRDChamber(Int_t det=0);
virtual ~AliEveTRDChamber() {}
-
+
AliEveTRDChamber(const AliEveTRDChamber&);
AliEveTRDChamber& operator=(const AliEveTRDChamber&);
-
+
void AddHit(AliTRDhit *hit);
Int_t GetRowMax() const {return rowMax;}
Int_t GetColMax() const {return colMax;}
void Paint(Option_t* option="");
void Reset();
void SetGeometry(AliTRDgeometry *geo);
-
+
protected:
AliEveTRDDigits *fDigits; // digits representation
AliEveTRDHits *fHits; // hits representation
Int_t fPla; // detector plane
AliTRDpadPlane *fPadPlane; // pad plane object
AliTRDgeometry *fGeo; // TRD geometry
-
+
ClassDef(AliEveTRDChamber,1) // Holder for TRD chamber data
};
-
+
class AliEveTRDNode : public TEveElement, public AliEveTRDModule
{
public:
void DisableListElements(); // *MENU*
void UpdateLeaves();
void UpdateNode();
-
+
List_i begin(){return fChildren.begin();}
List_i end(){return fChildren.end();}
-
+
ClassDef(AliEveTRDNode, 1)
};
#endif
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveTrackFitter.h"
// points, listening to signal PointCtrlClicked() of any
// TEvePointSet. Via editor it fits selected points and creates a
// reconstructed track.
-//
+//
ClassImp(AliEveTrackFitter)
fGraphSelected = new TGraph();
fGraphSelected->SetName("Selected points");
fGraphSelected->SetMarkerColor(4);
- fGraphSelected->SetMarkerStyle(4);
+ fGraphSelected->SetMarkerStyle(4);
fGraphSelected->SetMarkerSize(2);
fGraphFitted = new TGraphErrors();
/**************************************************************************/
void AliEveTrackFitter::AddFitPoint(TEvePointSet* ps, Int_t n)
-{
+{
// Add/remove given point depending if exists in the fMapPS.
-
+
Float_t x, y, z;
std::map<Point_t, Int_t>::iterator g = fMapPS.find(Point_t(ps, n));
fMapPS.erase(g);
fLastPoint--;
}
- else
+ else
{
fMapPS[Point_t(ps, n)] = Size();
ps->GetPoint(n, x, y, z);
- SetNextPoint(x, y, z);
+ SetNextPoint(x, y, z);
SetPointId(ps->GetPointId(n));
}
ResetBBox();
GetPoint(alphaIdx, x, y, z);
fAlpha = ATan2(y, x);
Float_t sin = Sin(-fAlpha);
- Float_t cos = Cos(-fAlpha);
- for (Int_t i=0; i<=fLastPoint; i++) {
+ Float_t cos = Cos(-fAlpha);
+ for (Int_t i=0; i<=fLastPoint; i++) {
GetPoint(i, x, y, z);
fRieman->AddPoint(cos*x - sin*y, cos*y + sin*x, z, 1, 1);
}
Double_t P0[3];
trackParam.GetPxPyPzAt(r, TEveTrackPropagator::fgDefMagField, P0);
TEveRecTrack rc;
- rc.fV.Set(AliEveV0);
+ rc.fV.Set(AliEveV0);
rc.fP.Set(P0);
rc.fSign = trackParam.Charge();
{
GetPoint(i, x, y, z);
pm->fV.Set(x, y, z);
- pm->fP.Set(P0);
+ pm->fP.Set(P0);
track->AddPathMark(pm);
}
track->MakeTrack();
- track->SetAttLineAttMarker(fTrackList);
+ track->SetAttLineAttMarker(fTrackList);
gEve->AddElement(track, fTrackList);
}
fGraphSelected->Set(nR);
fGraphFitted->Set(nR);
- Double_t* x = fRieman->GetX();
+ Double_t* x = fRieman->GetX();
Double_t* y = fRieman->GetY();
Double_t* sy = fRieman->GetSy();
for (Int_t i=0; i<nR; i++)
fGraphFitted->SetPoint(i, x[i], fRieman->GetYat(x[i]));
fGraphFitted->SetPointError(i, 0.1, sy[i]);
}
-
+
if (gPad) gPad->Clear();
fGraphSelected->Draw("AP");
fGraphFitted->Draw("SAME P");
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_TrackFitter_H
// inner structure to check duplicates
TEvePointSet* fPS; // selected pointset
Int_t fIdx; // location in the point set array
- Point_t(TEvePointSet* ps, Int_t i): fPS(ps), fIdx(i){}
+ Point_t(TEvePointSet* ps, Int_t i): fPS(ps), fIdx(i){}
bool operator<(const Point_t& o) const
{ if (fPS != o.fPS) return fPS < o.fPS; return fIdx < o.fIdx; }
};
Float_t fAlpha; // transformation agle to local system (where x>>y)
AliRieman* fRieman; // rieman fitter
- Bool_t fConnected; // object connected to pointset Ctrl-shift signal
-
- TEveTrackList* fTrackList; // track list created with rieman fit
+ Bool_t fConnected; // object connected to pointset Ctrl-shift signal
+
+ TEveTrackList* fTrackList; // track list created with rieman fit
std::map<Point_t, Int_t> fMapPS; // map of selected points from different TEvePointSet
public:
AliEveTrackFitter(const Text_t* name, Int_t n_points=0);
virtual ~AliEveTrackFitter();
-
+
virtual void AddFitPoint(TEvePointSet*,Int_t); // slot for PointCtrlClicked() signal
virtual void DestroyElements(); // *MENU*
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveTrackFitterEditor.h"
/**************************************************************************/
void AliEveTrackFitterEditor::SetModel(TObject* obj)
-{
+{
// Set model object.
fM = dynamic_cast<AliEveTrackFitter*>(obj);
fStop->SetState(kButtonUp);
}
else
- {
+ {
fStop->SetState(kButtonDisabled);
fStart->SetState(kButtonEngaged);
fStart->SetState(kButtonUp);
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_TrackFitterEditor_H
void DoStart();
void DoFit();
- void DoReset();
+ void DoReset();
void DoStop();
void DoGraph();
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "AliEveVSDCreator.h"
mKineType (KT_Standard),
mDataDir ("."),
mEvent (0),
-
+
mTPCHitRes (2),
mTRDHitRes (2),
0,2,"Ion",kion+20030);
}
- // AliKalmanTrack::SetConvConst(1);
+ // AliKalmanTrack::SetConvConst(1);
}
/**************************************************************************/
mEvent = event;
string galice_file (Form("%s/galice.root", mDataDir.Data()));
-
+
if(mDebugLevel > 0)
printf("%s opening %s \n", eH.Data(), galice_file.c_str());
file->Write();
file->Close();
- delete file;
+ delete file;
fDirectory =0;
//GledNS::PopFD();
{
static const TEveException eH("AliEveVSDCreator::ConvertKinematics ");
- if(fTreeK != 0)
+ if(fTreeK != 0)
throw (eH + "kinematics already converted");
AliStack* stack = pRunLoader->Stack();
fDirectory->cd();
fTreeK = new TTree("Kinematics", "TParticles sorted by Label");
-
+
Int_t nentries = stack->GetNtrack();
vector<TEveMCTrack> vmc(nentries);
for (Int_t idx=0; idx<nentries; idx++) {
// printf("T0 fTreeTR->GetEntry(%d) \n",iPrimPart);
fTreeTR->GetEntry(iPrimPart);
// printf("END fTreeTR->GetEntry(%d) \n",iPrimPart);
-
+
for (Int_t iTrackRef = 0; iTrackRef < RunArrayTR->GetEntriesFast(); iTrackRef++) {
- AliTrackReference *trackRef = (AliTrackReference*)RunArrayTR->At(iTrackRef);
+ AliTrackReference *trackRef = (AliTrackReference*)RunArrayTR->At(iTrackRef);
Int_t track = trackRef->GetTrack();
- if(track < nentries && track > 0){
- TEveMCTrack& mct = vmc[track];
+ if(track < nentries && track > 0){
+ TEveMCTrack& mct = vmc[track];
if(trackRef->TestBit(kNotDeleted)) {
mct.decayed = true;
mct.t_decay = trackRef->GetTime();
if(TMath::Abs(mct.GetPdgCode()) == 11)
mct.decayed = false; // a bug in TreeTR
}
- }
+ }
}
}
}
namespace {
- struct Detector
+ struct Detector
{
const char* name;
const char* hitbranch;
fDirectory->cd();
fTreeH = new TTree("Hits", "Combined detector hits.");
fTreeH->Branch("H", "TEveHit", &fpH, fBuffSize);
-
+
map<Int_t, Int_t> hmap;
// parameters for ITS, TPC hits filtering
Float_t x,y,z, x1,y1,z1;
Detector& det = detects[l++];
switch(det.detidx) {
- case 1: {
+ case 1: {
Int_t count = 0;
TTree* treeh = pRunLoader->GetTreeH(det.name, false);
if(treeh == 0) {
Warning(eH, Form("no hits for %s.", det.name));
continue;
}
- AliTPCTrackHitsV2 hv2, *_hv2=&hv2;
+ AliTPCTrackHitsV2 hv2, *_hv2=&hv2;
treeh->SetBranchAddress("TPC2", &_hv2);
Int_t np = treeh->GetEntries();
for(Int_t i=0; i<np; i++){
treeh->SetBranchAddress(det.name, &arr);
Int_t np = treeh->GetEntries();
// in TreeH files hits are grouped in clones arrays
- // each eva particle has its own clone array
+ // each eva particle has its own clone array
for (Int_t i=0; i<np; i++) {
treeh->GetEntry(i);
Int_t eva_idx = np -i -1;
x1=ali_hit->X();y1=ali_hit->Y();z1=ali_hit->Z();
if((x-x1)*(x-x1)+(y-y1)*(y-y1)+(z-z1)*(z-z1) < trd_sqr_res) continue;
x=x1; y=y1; z=z1;
- }
+ }
hmap[fH.fLabel]++;
- fTreeH->Fill();
+ fTreeH->Fill();
}
}
delete arr;
break;
- } // end default
+ } // end default
} // end switch
} // end while
-
+
//set geninfo
for(map<Int_t, Int_t>::iterator j=hmap.begin(); j!=hmap.end(); ++j) {
{
static const TEveException eH("AliEveVSDCreator::ConvertTPCClusters ");
- auto_ptr<TFile> f
+ auto_ptr<TFile> f
( TFile::Open(Form("%s/TPC.RecPoints.root", mDataDir.Data())) );
if(!f.get())
throw(eH + "can not open 'TPC.RecPoints.root' file.");
-
+
auto_ptr<TDirectory> d
( (TDirectory*) f->Get(Form("AliEveEventManager%d", mEvent)) );
if(!d.get())
nClusters += _clrow->GetArray()->GetEntriesFast();
}
- // calculate xyz for a cluster and add it to container
+ // calculate xyz for a cluster and add it to container
Double_t x,y,z;
Float_t cs, sn, tmp;
map<Int_t, Int_t> cmap;
Int_t ncl = _clrow->GetArray()->GetEntriesFast();
if(ncl > 0) {
Int_t sec,row;
- par->AdjustSectorRow(_clrow->GetID(),sec,row);
+ par->AdjustSectorRow(_clrow->GetID(),sec,row);
while (ncl--) {
if(_clrow->GetArray()) {
// cl = new AliTPCclusterMI(*(AliTPCclusterMI*)_clrow->GetArray()->UncheckedAt(ncl));
{
x = par->GetPadRowRadii(sec,row); y = cl->GetY(); z = cl->GetZ();
par->AdjustCosSin(sec,cs,sn);
- tmp = x*cs-y*sn; y= x*sn+y*cs; x=tmp;
+ tmp = x*cs-y*sn; y= x*sn+y*cs; x=tmp;
fC.fDetId = 1;
fC.fSubdetId = 0;
{
static const TEveException eH("AliEveVSDCreator::ConvertITSClusters ");
- auto_ptr<TFile> f
+ auto_ptr<TFile> f
( TFile::Open(Form("%s/ITS.RecPoints.root", mDataDir.Data())) );
if(!f.get())
throw(eH + "can not open 'ITS.RecPoints.root' file.");
-
+
auto_ptr<TDirectory> d
( (TDirectory*) f->Get(Form("AliEveEventManager%d", mEvent)) );
if(!d.get())
for (Int_t j=0; j<nc; j++) {
AliITSclusterV2* recp = (AliITSclusterV2*)arr->UncheckedAt(j);
- Double_t rot[9];
+ Double_t rot[9];
geom->GetRotMatrix(mod,rot);
- Int_t lay,lad,det;
+ Int_t lay,lad,det;
geom->GetModuleId(mod,lay,lad,det);
- Float_t tx,ty,tz;
- geom->GetTrans(lay,lad,det,tx,ty,tz);
+ Float_t tx,ty,tz;
+ geom->GetTrans(lay,lad,det,tx,ty,tz);
Double_t alpha=TMath::ATan2(rot[1],rot[0])+TMath::Pi();
Double_t phi1=TMath::Pi()/2+alpha;
while(i < 3 && fC.fLabel[i])
cmap[fC.fLabel[i++]]++;
}
- }
+ }
for(map<Int_t, Int_t>::iterator j=cmap.begin(); j!=cmap.end(); ++j) {
GetGeninfo(j->first)->fNClus += j->second;
fTreeR = new TTree("RecTracks", "rec tracks");
fTreeR->Branch("R", "TEveRecTrack", &fpR, 512*1024,1);
-
+
TFile f(Form("%s/AliESDs.root", mDataDir.Data()));
if(!f.IsOpen())
throw(eH + "no AliESDs.root file.");
TTree* tree = (TTree*) f.Get("esdTree");
- if (tree == 0)
+ if (tree == 0)
throw(eH + "no esdTree.");
-
- AliESDEvent *fEvent= new AliESDEvent();
+
+ AliESDEvent *fEvent= new AliESDEvent();
fEvent->ReadFromTree(tree);
- tree->GetEntry(mEvent);
+ tree->GetEntry(mEvent);
if(fEvent->GetAliESDOld())fEvent->CopyFromOldESD();
-
+
// reconstructed tracks
AliESDtrack* esd_t;
Double_t dbuf[3];
}
TTree* tree = (TTree*) f.Get("esdTree");
- if (tree == 0)
+ if (tree == 0)
throw(eH + "no esdTree.");
- AliESDEvent *fEvent= new AliESDEvent();
+ AliESDEvent *fEvent= new AliESDEvent();
fEvent->ReadFromTree(tree);
- tree->GetEntry(mEvent);
+ tree->GetEntry(mEvent);
if(fEvent->GetAliESDOld())fEvent->CopyFromOldESD();
for (Int_t n =0; n< fEvent->GetNumberOfV0s(); n++)
fV0.fStatus = av->GetStatus();
// Point of closest approach
av->GetXYZ(pos[0],pos[1],pos[2]);
- fV0.fVCa.fX = pos[0];
+ fV0.fVCa.fX = pos[0];
fV0.fVCa.fY = pos[1];
fV0.fVCa.fZ = pos[2];
- // set birth vertex of neutral particle
+ // set birth vertex of neutral particle
av->GetXYZ(pos[0], pos[1], pos[2]);
fV0.fV0Birth.Set(pos);
fV0.fDLabel[0] = TMath::Abs(trackN->GetLabel());
fV0.fDLabel[1] = TMath::Abs(trackP->GetLabel());
- // printf("AliEveV0 convert labels(%d,%d) index(%d,%d)\n",
+ // printf("AliEveV0 convert labels(%d,%d) index(%d,%d)\n",
// fV0.d_label[0], fV0.d_label[1],
// av->GetNIndex(), av->GetPIndex());
}
TTree* tree = (TTree*) f.Get("esdTree");
- if (tree == 0)
+ if (tree == 0)
throw(eH + "no esdTree.");
- AliESDEvent *fEvent= new AliESDEvent();
+ AliESDEvent *fEvent= new AliESDEvent();
fEvent->ReadFromTree(tree);
- tree->GetEntry(mEvent);
+ tree->GetEntry(mEvent);
if(fEvent->GetAliESDOld())fEvent->CopyFromOldESD();
fKK.fVKink.Set(kk->GetPosition());
const AliExternalTrackParam& tp_mother = kk->RefParamMother();
- // momentum and position of mother
+ // momentum and position of mother
tp_mother.GetPxPyPz(pos);
fKK.fP.Set(pos);
tp_mother.GetXYZ(pos);
const Double_t* par = tp_mother.GetParameter();
// printf("KINK Pt %f, %f \n",1/tp_mother.Pt(),par[4] );
fKK.fSign = (par[4] < 0) ? -1 : 1;
-
+
const AliExternalTrackParam& tp_daughter = kk->RefParamDaughter();
- // momentum and position of daughter
+ // momentum and position of daughter
tp_daughter.GetPxPyPz(pos);
fKK.fPSec.Set(pos);
tp_daughter.GetXYZ(pos);
if (fTreeR) {
Int_t re = fTreeR->GetEntryNumberWithIndex(j->first);
- if(re != -1)
+ if(re != -1)
fGI.fIsRec = true;
}
// Int_t has_v0 = fTreeV0->GetEntryNumberWithIndex(j->first);
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_VSDCreator_H
TString mDataDir; // X{G}
Int_t mEvent; // X{G}
- Float_t mTPCHitRes; // X{gs}
- Float_t mTRDHitRes; // X{gs}
+ Float_t mTPCHitRes; // X{gs}
+ Float_t mTRDHitRes; // X{gs}
Int_t mDebugLevel;
virtual ~AliEveVSDCreator() {}
void CreateVSD(const Text_t* data_dir, Int_t event,
- const Text_t* vsd_file); // X{Ed}
+ const Text_t* vsd_file); // X{Ed}
void CreateTrees();
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#pragma link off all functions;
#pragma link off all globals;
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include <TInterpreter.h>
#include <TRint.h>
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
/**************************************************************************
* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
TEveTrackPropagator& RS((fRnrStyle != 0) ? *fRnrStyle : TEveTrackPropagator::fgDefStyle);
- Float_t px = p.x, py = p.y, pz = p.z;
+ Float_t px = p.x, py = p.y, pz = p.z;
MCVertex mc_v0;
mc_v0.x = vtx.x;
- mc_v0.y = vtx.y;
- mc_v0.z = vtx.z;
+ mc_v0.y = vtx.y;
+ mc_v0.z = vtx.z;
mc_v0.t = 0;
std::vector<MCVertex> track_points;
Bool_t decay = kFALSE;
- if ((TMath::Abs(vtx.z) > RS.fMaxZ) || (vtx.x*vtx.x + vtx.y*vtx.y > RS.fMaxR*RS.fMaxR))
+ if ((TMath::Abs(vtx.z) > RS.fMaxZ) || (vtx.x*vtx.x + vtx.y*vtx.y > RS.fMaxR*RS.fMaxR))
goto make_polyline;
-
+
if (TMath::Abs(RS.fMagField) > 1e-5) {
// Charged particle in magnetic field
Float_t a = RS.fgkB2C * RS.fMagField * charge;
-
+
MCHelix helix(fRnrStyle, &mc_v0, TMath::C()*beta, &track_points, a); //m->cm
helix.Init(TMath::Sqrt(px*px+py*py), pz);
-
+
if(!pathMark.empty()){
for(std::vector<TEvePathMark*>::iterator i=pathMark.begin();
i!=pathMark.end(); ++i) {
TEvePathMark* pm = *i;
-
+
if(RS.fFitDaughters && pm->type == TEvePathMark::Daughter){
- if(TMath::Abs(pm->V.z) > RS.fMaxZ
+ if(TMath::Abs(pm->V.z) > RS.fMaxZ
|| TMath::Sqrt(pm->V.x*pm->V.x + pm->V.y*pm->V.y) > RS.fMaxR )
goto helix_bounds;
- //printf("%s fit daughter \n", fName.Data());
+ //printf("%s fit daughter \n", fName.Data());
helix.LoopToVertex(p.x, p.y, p.z, pm->V.x, pm->V.y, pm->V.z);
p.x -= pm->P.x;
p.y -= pm->P.y;
p.z -= pm->P.z;
}
if(RS.fFitDecay && pm->type == TEvePathMark::Decay){
-
- if(TMath::Abs(pm->V.z) > RS.fMaxZ
+
+ if(TMath::Abs(pm->V.z) > RS.fMaxZ
|| TMath::Sqrt(pm->V.x*pm->V.x + pm->V.y*pm->V.y) > RS.fMaxR )
goto helix_bounds;
helix.LoopToVertex(p.x, p.y, p.z, pm->V.x, pm->V.y, pm->V.z);
// Neutral particle or no field
MCLine line(fRnrStyle, &mc_v0, TMath::C()*beta, &track_points);
-
+
if(!pathMark.empty()) {
for(std::vector<TEvePathMark*>::iterator i=pathMark.begin();
i!=pathMark.end(); ++i) {
TEvePathMark* pm = *i;
if(RS.fFitDaughters && pm->type == TEvePathMark::Daughter){
- if(TMath::Abs(pm->V.z) > RS.fMaxZ
+ if(TMath::Abs(pm->V.z) > RS.fMaxZ
|| TMath::Sqrt(pm->V.x*pm->V.x + pm->V.y*pm->V.y) > RS.fMaxR )
goto line_bounds;
line.GotoVertex(pm->V.x, pm->V.y, pm->V.z);
}
if(RS.fFitDecay && pm->type == TEvePathMark::Decay){
- if(TMath::Abs(pm->V.z) > RS.fMaxZ
+ if(TMath::Abs(pm->V.z) > RS.fMaxZ
|| TMath::Sqrt(pm->V.x*pm->V.x + pm->V.y*pm->V.y) > RS.fMaxR )
goto line_bounds;
line.GotoVertex(pm->V.x, pm->V.y, pm->V.z);
//______________________________________________________________________
void AliEveCascade::MakeV0path() {
-
+
MCVertex mc_v0;
mc_v0.x = (fV_neg.x+fV_pos.x)/2;
mc_v0.y = (fV_neg.y+fV_pos.y)/2;
//______________________________________________________________________
void AliEveCascade::MakeCasPath() {
-
+
MCVertex mc_v0;
mc_v0.x = fV_birth.x;
mc_v0.y = fV_birth.y;
MakeTrack(fPathMarksPos, fV_pos, fP_pos, 1, fBeta_pos, fPolyLinePos);
if (fBeta_bach>0)
MakeTrack(fPathMarksBach, fV_bach, fP_bach, 1, fBeta_bach, fPolyLineBach);
- else
+ else
MakeTrack(fPathMarksBach, fV_bach, fP_bach, -1, -fBeta_bach, fPolyLineBach);
MakeV0path();
MakeCasPath();
Float_t px = GetPx(), py = GetPy(), pz = GetPz();
Float_t p2 = px*px + py*py + pz*pz;
if (p2 < 1.e-39) return -999;
-
+
Float_t posXcas, posP2;
-
+
if (fBeta_bach>0) {
posXcas = fP_bach.x*px + fP_bach.y*py + fP_bach.z*pz;
posP2 = GetBachP2();
if ((iHist<0)||(iHist>=fgkNcutVar)) return;
if (! fHist[iHist]) return;
-
+
TString name = fHist[iHist]->GetName();
Int_t nBin = fHist[iHist]->GetXaxis()->GetNbins();
delete fHist[iHist];
for (Int_t i=0; i<fgkNcutVar2D; i++)
fHist2D[i]->Reset();
-
+
AliEveCascade* myCas;
for(List_i i=fChildren.begin(); i!=fChildren.end(); ++i) {
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_Cascade_H
#define ALIEVE_Cascade_H
static const Float_t fgkMassProton2;
static const Float_t fgkMassLambda2;
-public:
+public:
AliEveCascade();
AliEveCascade(TEveTrackPropagator* rs);
virtual ~AliEveCascade();
void SetBachP(Float_t px, Float_t py, Float_t pz) {fP_bach.x = px; fP_bach.y = py; fP_bach.z = pz;}
void SetV0vtx(Float_t vx, Float_t vy, Float_t vz) {
- fV_neg.x = vx; fV_neg.y = vy; fV_neg.z = vz;
- fV_pos.x = vx; fV_pos.y = vy; fV_pos.z = vz;
+ fV_neg.x = vx; fV_neg.y = vy; fV_neg.z = vz;
+ fV_pos.x = vx; fV_pos.y = vy; fV_pos.z = vz;
}
void SetCascadeVtx(Float_t vx, Float_t vy, Float_t vz) {
fV_decay.x = vx; fV_decay.y = vy; fV_decay.z = vz; }
virtual void Paint(Option_t* option="");
void SetRnrStyle(TEveTrackPropagator* rst) { fRnrStyle= rst; }
- TEveTrackPropagator* GetPropagator() { return fRnrStyle; }
+ TEveTrackPropagator* GetPropagator() { return fRnrStyle; }
Bool_t GetRnrCasVtx() const { return fRnrCasVtx; }
Bool_t GetRnrCasPath() const { return fRnrCasPath; }
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
/***********************************************************************
fMainTabB(0)
{
MakeTitle("CascadeList");
-
+
//TGHorizontalFrame* frame = new TGHorizontalFrame(this);
-
+
// --- Rendering control
fRnrVtx = new TGCheckButton(this, "Render v0 and cascade vertices");
fRnrV0path = new TGCheckButton(this, "Render v0 path");
AddFrame(fRnrV0path, new TGLayoutHints(kLHintsTop, 3, 1, 1, 0));
fRnrV0path->Connect("Toggled(Bool_t)",
- "CascadeListEditor", this, "DoRnrV0path()");
+ "CascadeListEditor", this, "DoRnrV0path()");
fRnrCasPath = new TGCheckButton(this, "Render cascade path");
AddFrame(fRnrCasPath, new TGLayoutHints(kLHintsTop, 3, 1, 1, 0));
fRnrCasPath->Connect("Toggled(Bool_t)",
- "CascadeListEditor", this, "DoRnrCasPath()");
+ "CascadeListEditor", this, "DoRnrCasPath()");
fRnrV0Daughters = new TGCheckButton(this, "Render v0 daughter tracks");
AddFrame(fRnrV0Daughters, new TGLayoutHints(kLHintsTop, 3, 1, 1, 0));
AddFrame(fRnrBach, new TGLayoutHints(kLHintsTop, 3, 1, 1, 0));
fRnrBach->Connect("Toggled(Bool_t)",
"CascadeListEditor", this, "DoRnrBach()");
-
+
for (Int_t i=0; i<fgkNRange; i++) fRange[i]=0;
for (Int_t i=0; i<fgkNCanvas; i++) fCanvasA[i]=0;
for (Int_t i=0; i<fgkNCanvas; i++) fCanvasB[i]=0;
c1->SetTicks(1,0);
c1->SetGrid();
c1->SetBorderMode(0);
-
+
frameTab->AddFrame(*embeddedCanvas, new TGLayoutHints(kLHintsTop|kLHintsExpandX,
0, 0, 0, 0));
return frameTab;
// container of "Tab1"
TGCompositeFrame *frameTab1 = pMainTab[0]->AddTab("ident.");
frameTab1->SetLayoutManager(new TGVerticalLayout(frameTab1));
-
+
// tab widget
ptab[0] = new TGTab(frameTab1,2,2);
ptab[0]->Resize(ptab[0]->GetDefaultSize());
// (it updates every canvas)
ptab[0]->Connect("Selected(Int_t)", "CascadeListEditor", this, "UpdateSelectedTab()");
frameTab1->AddFrame(ptab[0], new TGLayoutHints(kLHintsLeft| kLHintsExpandX,0,0,0,0));
-
+
//------
// container of "Tab2"
TGCompositeFrame *frameTab2 = pMainTab[0]->AddTab("cascade");
frameTab2->SetLayoutManager(new TGVerticalLayout(frameTab2));
-
+
// tab widget
ptab[1] = new TGTab(frameTab2,440,299);
ptab[1]->Resize(ptab[1]->GetDefaultSize());
ptab[1]->Connect("Selected(Int_t)", "CascadeListEditor", this, "UpdateSelectedTab()");
frameTab2->AddFrame(ptab[1], new TGLayoutHints(kLHintsLeft| kLHintsExpandX ,0,0,0,0));
-
+
//------
// container of "Tab3"
TGCompositeFrame *frameTab3 = pMainTab[0]->AddTab("V0daugh/bach.");
frameTab3->SetLayoutManager(new TGVerticalLayout(frameTab3));
-
+
// tab widget
ptab[2] = new TGTab(frameTab3,440,299);
ptab[2]->Resize(ptab[2]->GetDefaultSize());
//------
TGCompositeFrame **frameTab = new TGCompositeFrame*[fgkNCanvas];
-
+
frameTab[0] = AddTab(ptab[0], 0, can, "Xi");
frameTab[1] = AddTab(ptab[0], 1, can, "Omega");
frameTab[2] = AddTab(ptab[0], 2, can, "Arm.Podo.");
//_________________________________________________________________________
void CascadeListEditor::AddSelectTab() {
-
+
TGCompositeFrame** tab = CreateTab(&fMainTabA, fTabA, 1);
AddValuator(tab[0], "mass Xi", 0, 5, 3, "MassXiRange()", 0);
Float_t min,max;
for (Int_t i=0; i<fgkNRange;i++) {
-
+
if (i==2) continue;
min = fRange[i]->GetLimitMin();
max = fRange[i]->GetLimitMax();
if (is2D) hist2D->Draw("colz"); else hist->Draw();
c1->Modified();
c1->Update();
-
+
c1b = fCanvasB[i]->GetCanvas();
c1b->cd();
if (is2D) hist2D->Draw("colz"); else hist->Draw();
gClient->GetColorByName("yellow", yellow);
gClient->GetColorByName("grey", grey);
- TGTabElement *tabElem;
+ TGTabElement *tabElem;
for (i=0; i<fMainTabA->GetNumberOfTabs(); i++) {
tabElem = fMainTabA->GetTabTab(i);
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
/***********************************************************************
This editor appears in the TEveUtil window when cascades are visualize.
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
/**************************************************************************
* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
TEveTrackPropagator& RS((fRnrStyle != 0) ? *fRnrStyle : TEveTrackPropagator::fgDefStyle);
- Float_t px = p.x, py = p.y, pz = p.z;
+ Float_t px = p.x, py = p.y, pz = p.z;
MCVertex mc_v0;
mc_v0.x = vtx.x;
- mc_v0.y = vtx.y;
- mc_v0.z = vtx.z;
+ mc_v0.y = vtx.y;
+ mc_v0.z = vtx.z;
mc_v0.t = 0;
std::vector<MCVertex> track_points;
Bool_t decay = kFALSE;
- if ((TMath::Abs(vtx.z) > RS.fMaxZ) || (vtx.x*vtx.x + vtx.y*vtx.y > RS.fMaxR*RS.fMaxR))
+ if ((TMath::Abs(vtx.z) > RS.fMaxZ) || (vtx.x*vtx.x + vtx.y*vtx.y > RS.fMaxR*RS.fMaxR))
goto make_polyline;
-
+
if (TMath::Abs(RS.fMagField) > 1e-5) {
// Charged particle in magnetic field
Float_t a = RS.fgkB2C * RS.fMagField * charge;
-
+
MCHelix helix(fRnrStyle, &mc_v0, TMath::C()*beta, &track_points, a); //m->cm
helix.Init(TMath::Sqrt(px*px+py*py), pz);
-
+
if(!pathMark.empty()){
for(std::vector<TEvePathMark*>::iterator i=pathMark.begin();
i!=pathMark.end(); ++i) {
TEvePathMark* pm = *i;
-
+
if(RS.fFitDaughters && pm->type == TEvePathMark::Daughter){
- if(TMath::Abs(pm->V.z) > RS.fMaxZ
+ if(TMath::Abs(pm->V.z) > RS.fMaxZ
|| TMath::Sqrt(pm->V.x*pm->V.x + pm->V.y*pm->V.y) > RS.fMaxR )
goto helix_bounds;
- //printf("%s fit daughter \n", fName.Data());
+ //printf("%s fit daughter \n", fName.Data());
helix.LoopToVertex(p.x, p.y, p.z, pm->V.x, pm->V.y, pm->V.z);
p.x -= pm->P.x;
p.y -= pm->P.y;
p.z -= pm->P.z;
}
if(RS.fFitDecay && pm->type == TEvePathMark::Decay){
-
- if(TMath::Abs(pm->V.z) > RS.fMaxZ
+
+ if(TMath::Abs(pm->V.z) > RS.fMaxZ
|| TMath::Sqrt(pm->V.x*pm->V.x + pm->V.y*pm->V.y) > RS.fMaxR )
goto helix_bounds;
helix.LoopToVertex(p.x, p.y, p.z, pm->V.x, pm->V.y, pm->V.z);
// Neutral particle or no field
MCLine line(fRnrStyle, &mc_v0, TMath::C()*beta, &track_points);
-
+
if(!pathMark.empty()) {
for(std::vector<TEvePathMark*>::iterator i=pathMark.begin();
i!=pathMark.end(); ++i) {
TEvePathMark* pm = *i;
if(RS.fFitDaughters && pm->type == TEvePathMark::Daughter){
- if(TMath::Abs(pm->V.z) > RS.fMaxZ
+ if(TMath::Abs(pm->V.z) > RS.fMaxZ
|| TMath::Sqrt(pm->V.x*pm->V.x + pm->V.y*pm->V.y) > RS.fMaxR )
goto line_bounds;
line.GotoVertex(pm->V.x, pm->V.y, pm->V.z);
}
if(RS.fFitDecay && pm->type == TEvePathMark::Decay){
- if(TMath::Abs(pm->V.z) > RS.fMaxZ
+ if(TMath::Abs(pm->V.z) > RS.fMaxZ
|| TMath::Sqrt(pm->V.x*pm->V.x + pm->V.y*pm->V.y) > RS.fMaxR )
goto line_bounds;
line.GotoVertex(pm->V.x, pm->V.y, pm->V.z);
//______________________________________________________________________
void AliEveV0::MakeV0path() {
-
+
MCVertex mc_v0;
mc_v0.x = fV_v0.x;
- mc_v0.y = fV_v0.y;
- mc_v0.z = fV_v0.z;
+ mc_v0.y = fV_v0.y;
+ mc_v0.z = fV_v0.z;
mc_v0.t = 0;
std::vector<MCVertex> track_points;
if ((iHist<0)||(iHist>=fgkNcutVar)) return;
if (! fHist[iHist]) return;
-
+
TString name = fHist[iHist]->GetName();
Int_t nBin = fHist[iHist]->GetXaxis()->GetNbins();
delete fHist[iHist];
for (Int_t i=0; i<fgkNcutVar2D; i++)
fHist2D[i]->Reset();
-
+
AliEveV0* myV0;
for(List_i i=fChildren.begin(); i!=fChildren.end(); ++i) {
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef ALIEVE_V0_H
#define ALIEVE_V0_H
AliEveV0(const AliEveV0&); // Not implemented
AliEveV0& operator=(const AliEveV0&); // Not implemented
-public:
+public:
AliEveV0();
AliEveV0(TEveRecTrack* tNeg, TEveRecTrack* tPos, TEveRecV0* v0,
TEveTrackPropagator* rs);
//______________________________________________________________________
-inline void AliEveV0::SetDaughterDCA(Float_t dca) {
- fDaughterDCA = dca;
+inline void AliEveV0::SetDaughterDCA(Float_t dca) {
+ fDaughterDCA = dca;
}
-inline void AliEveV0::SetCosPointingAngle(Float_t cos) {
- fCosPointingAngle = cos;
+inline void AliEveV0::SetCosPointingAngle(Float_t cos) {
+ fCosPointingAngle = cos;
}
inline void AliEveV0::SetDecayLength(Float_t len) {
virtual void Paint(Option_t* option="");
void SetRnrStyle(TEveTrackPropagator* rst) { fRnrStyle= rst; }
- TEveTrackPropagator* GetPropagator() { return fRnrStyle; }
+ TEveTrackPropagator* GetPropagator() { return fRnrStyle; }
Bool_t GetRnrV0vtx() const { return fRnrV0vtx; }
Bool_t GetRnrV0path() const { return fRnrV0path; }
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
/**************************************************************************
* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
fMainTabB(0)
{
MakeTitle("V0List");
-
+
//TGHorizontalFrame* frame = new TGHorizontalFrame(this);
-
+
// --- Rendering control
fRnrV0path = new TGCheckButton(this, "Render v0 path");
AddFrame(fRnrV0path, new TGLayoutHints(kLHintsTop, 3, 1, 1, 0));
fRnrV0path->Connect("Toggled(Bool_t)",
- "V0ListEditor", this, "DoRnrV0path()");
+ "V0ListEditor", this, "DoRnrV0path()");
fRnrV0vtx = new TGCheckButton(this, "Render v0 vertices");
AddFrame(fRnrV0vtx, new TGLayoutHints(kLHintsTop, 3, 1, 1, 0));
AddFrame(fRnrV0sDaugh, new TGLayoutHints(kLHintsTop, 3, 1, 1, 0));
fRnrV0sDaugh->Connect("Toggled(Bool_t)",
"V0ListEditor", this, "DoRnrDaughters()");
-
+
for (Int_t i=0; i<fgkNRange; i++) fRange[i]=0;
for (Int_t i=0; i<fgkNCanvas; i++) fCanvasA[i]=0;
c1->SetTicks(1,0);
c1->SetGrid();
c1->SetBorderMode(0);
-
+
frameTab->AddFrame(*embeddedCanvas, new TGLayoutHints(kLHintsTop|kLHintsExpandX,
0, 0, 0, 0));
return frameTab;
pMainTab[0]->Connect("Selected(Int_t)", "V0ListEditor", this, "UpdateSelectedTab()");
this->AddFrame(pMainTab[0], new TGLayoutHints( kLHintsTop | kLHintsExpandX,2,2,2,2));
-
+
//------
// container of "Tab1"
TGCompositeFrame *frameTab1 = pMainTab[0]->AddTab("ident.");
frameTab1->SetLayoutManager(new TGVerticalLayout(frameTab1));
-
+
// tab widget
ptab[0] = new TGTab(frameTab1,2,2);
// (it updates every canvas)
ptab[0]->Connect("Selected(Int_t)", "V0ListEditor", this, "UpdateSelectedTab()");
frameTab1->AddFrame(ptab[0], new TGLayoutHints(kLHintsLeft| kLHintsExpandX,0,0,0,0));
-
+
//------
// container of "Tab2"
TGCompositeFrame *frameTab2 = pMainTab[0]->AddTab("v0");
frameTab2->SetLayoutManager(new TGVerticalLayout(frameTab2));
-
+
// tab widget
ptab[1] = new TGTab(frameTab2,440,299);
ptab[1]->Resize(ptab[1]->GetDefaultSize());
ptab[1]->Connect("Selected(Int_t)", "V0ListEditor", this, "UpdateSelectedTab()");
frameTab2->AddFrame(ptab[1], new TGLayoutHints(kLHintsLeft| kLHintsExpandX ,0,0,0,0));
-
+
//------
// container of "Tab3"
TGCompositeFrame *frameTab3 = pMainTab[0]->AddTab("daughters");
frameTab3->SetLayoutManager(new TGVerticalLayout(frameTab3));
-
+
// tab widget
ptab[2] = new TGTab(frameTab3,440,299);
ptab[2]->Resize(ptab[2]->GetDefaultSize());
//------
TGCompositeFrame **frameTab = new TGCompositeFrame*[fgkNCanvas];
-
+
frameTab[0] = AddTab(ptab[0], 0, can, "K0s");
frameTab[1] = AddTab(ptab[0], 1, can, "Lambda");
frameTab[2] = AddTab(ptab[0], 2, can, "Anti-Lambda");
//_________________________________________________________________________
void V0ListEditor::AddSelectTab() {
-
+
TGCompositeFrame** tab = CreateTab(&fMainTabA, fTabA, 1);
AddValuator(tab[0], "mass K0s", 0, 5, 3, "MassK0sRange()", 1);
Float_t min,max;
for (Int_t i=0; i<fgkNRange;i++) {
-
+
if (i==12) continue;
min = fRange[i]->GetLimitMin();
max = fRange[i]->GetLimitMax();
if (is2D) hist2D->Draw("colz"); else hist->Draw();
c1->Modified();
c1->Update();
-
+
c1b = fCanvasB[i]->GetCanvas();
c1b->cd();
if (is2D) hist2D->Draw("colz"); else hist->Draw();
gClient->GetColorByName("yellow", yellow);
gClient->GetColorByName("grey", grey);
- TGTabElement *tabElem;
+ TGTabElement *tabElem;
for (i=0; i<fMainTabA->GetNumberOfTabs(); i++) {
tabElem = fMainTabA->GetTabTab(i);
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "TGLViewer.h"
void MUON_display(Bool_t fromRaw = kFALSE, Bool_t showTracks = kTRUE)
{
-
- if (!AliMpSegmentation::Instance()) AliMpCDB::LoadMpSegmentation();
+
+ if (!AliMpSegmentation::Instance()) AliMpCDB::LoadMpSegmentation();
if (!AliMpDDLStore::Instance()) AliMpCDB::LoadDDLStore();
TTree* dt = 0;
AliRunLoader* rl = AliEveEventManager::AssertRunLoader();
g_muon_data = new AliEveMUONData;
-
+
if (!fromRaw) {
rl->LoadDigits("MUON");
dt = rl->GetTreeD("MUON", false);
g_muon_data->LoadRaw(dataPath.Data());
}
}
-
+
rl->LoadRecPoints("MUON");
ct = rl->GetTreeR("MUON", false);
g_muon_data->LoadRecPoints(ct);
-
+
rl->LoadHits("MUON");
ht = rl->GetTreeH("MUON", false);
g_muon_data->LoadHits(ht);
-
+
g_muon_last_event = gEvent;
-
+
g_currentEvent = g_muon_last_event->GetEventId();
-
+
gStyle->SetPalette(1, 0);
gEve->DisableRedraw();
-
+
TEveElementList* l = new TEveElementList("MUONChambers");
l->SetTitle("MUON chambers");
l->SetMainColor(Color_t(2));
gEve->AddElement(l);
-
+
for (Int_t ic = 0; ic < 14; ic++) {
AliEveMUONChamber* mucha = new AliEveMUONChamber(ic);
-
+
mucha->SetFrameColor(2);
mucha->SetChamberID(ic);
-
+
mucha->SetDataSource(g_muon_data);
gEve->AddElement(mucha, l);
Int_t ntracks = tracks->GetEntriesFast();
//printf("Found %d tracks. \n",ntracks);
- TEveTrackList* lt = new TEveTrackList("M-Tracks");
+ TEveTrackList* lt = new TEveTrackList("M-Tracks");
lt->SetMainColor(Color_t(6));
- //lt->SetMUON();
+ //lt->SetMUON();
gEve->AddElement(lt);
Float_t xRec, xRec0;
Float_t yRec, yRec0;
Float_t zRec, zRec0;
-
+
Float_t zg[4] = { -1603.5, -1620.5, -1703.5, -1720.5 };
- AliMUONTrack *mt;
+ AliMUONTrack *mt;
TEveRecTrack rt;
Int_t count;
for (Int_t n = 0; n < ntracks; n++) {
-
+
count = 0;
mt = (AliMUONTrack*) tracks->At(n);
Int_t ntracks = tracks->GetEntriesFast();
//printf("Found %d tracks. \n",ntracks);
- TEveTrackList* lt = new TEveTrackList("MT-Tracks");
+ TEveTrackList* lt = new TEveTrackList("MT-Tracks");
lt->SetMainColor(Color_t(4));
- //lt->SetMUON();
+ //lt->SetMUON();
gEve->AddElement(lt);
Float_t xRec, xRec0;
Float_t yRec, yRec0;
Float_t zRec, zRec0;
-
+
Float_t zg[4] = { -1603.5, -1620.5, -1703.5, -1720.5 };
- AliMUONTriggerTrack *mt;
+ AliMUONTriggerTrack *mt;
TEveRecTrack rt;
Int_t count;
for (Int_t n = 0; n < ntracks; n++) {
-
+
count = 0;
mt = (AliMUONTriggerTrack*) tracks->At(n);
AliESDEvent* esd = AliEveEventManager::AssertESD();
- TEveTrackList* lt = new TEveTrackList("ESD-Tracks");
+ TEveTrackList* lt = new TEveTrackList("ESD-Tracks");
lt->SetMainColor(Color_t(6));
//lt->SetMUON();
AliMUONVTrackStore* trackRefStore = recoCheck.ReconstructibleTracks(gEvent->GetEventId());
TIter next(trackRefStore->CreateIterator());
AliMUONTrack* trackRef;
-
- TEveTrackList* lt = new TEveTrackList("Ref-Tracks");
+
+ TEveTrackList* lt = new TEveTrackList("Ref-Tracks");
lt->SetMainColor(Color_t(6));
gEve->AddElement(lt);
TEveRecTrack rt;
- Int_t i = 0;
+ Int_t i = 0;
while ( ( trackRef = static_cast<AliMUONTrack*>(next()) ) ) {
rt.label = i++;
Int_t nPrimary = stack->GetNprimary();
Int_t nTracks = stack->GetNtrack();
- TEveTrackList* lt = new TEveTrackList("MC-Tracks");
+ TEveTrackList* lt = new TEveTrackList("MC-Tracks");
lt->SetMainColor(Color_t(6));
//lt->SetMUON();
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
void MUON_geom()
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
void MUON_geomAll()
TEveGeoTopNode* topn_re = new TEveGeoTopNode
(gGeoManager, gGeoManager->GetTopNode());
-
+
gEve->AddGlobalElement(topn_re);
gEve->Redraw3D(kTRUE);
-
+
}
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include <iomanip.h>
AliRunLoader* rl = AliEveEventManager::AssertRunLoader();
TTree* tt = rl->GetTreeT("MUON", false);
-
+
TClonesArray *tracks = 0;
tt->SetBranchAddress("AliEveMUONTrack",&tracks);
tt->GetEntry(0);
Int_t ntracks = tracks->GetEntriesFast();
-
+
if (ntracks <= label) return;
- AliMUONTrack *mt = tracks->At(label);
+ AliMUONTrack *mt = tracks->At(label);
TTree* tr = rl->GetTreeR("MUON", false);
-
+
TClonesArray *lotrig = 0;
tr->SetBranchAddress("MUONLocalTrigger",&lotrig);
tr->GetEntry(0);
AliMUONTrackParam *mtp = (AliMUONTrackParam*)mt->GetTrackParamAtVertex();
Float_t pt = TMath::Sqrt(mtp->Px()*mtp->Px()+mtp->Py()*mtp->Py());
- cout << " Pt = " <<
+ cout << " Pt = " <<
setw(8) << setprecision(3) <<
pt << " GeV/c" << endl;
-
+
cout << endl;
if (mt->GetLoTrgNum() >= 0) {
}
cout << endl;
cout << "#########################################################################################################################<<<<<" << endl;
-
+
}
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
TEveProjectionManager* NLT_test(TEveElement* top=0)
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
class TEveProjectionManager;
TEveUtil::LoadMacro("tpc_clusters.C+");
TEveViewer* nv = gEve->SpawnNewViewer("NLT Projected");
- TEveScene* ns = gEve->SpawnNewScene("NLT");
+ TEveScene* ns = gEve->SpawnNewScene("NLT");
nv->AddScene(ns);
TGLViewer* v = nv->GetGLViewer();
v->SetCurrentCamera(TGLViewer::kCameraOrthoXOY);
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
TEvePointSet*
rl->LoadHits("ACORDE");
TTree* ht = rl->GetTreeH("ACORDE", false);
-
+
//PH The line below is replaced waiting for a fix in Root
//PH which permits to use variable siza arguments in CINT
//PH on some platforms (alphalinuxgcc, solariscc5, etc.)
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
TEvePointSet* clusters_from_index(Int_t index=0, TEveElement* cont=0)
pArr->GetPoint(*atp, i);
clusters->SetPointId(atp); }
-
+
if(clusters->Size() == 0 && gEve->GetKeepEmptyCont() == kFALSE) {
Warning("clusters_from_index", Form("No clusters for index '%d'", index));
delete clusters;
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
TEvePointSet* clusters_from_label(Int_t label=0, TEveElement* cont=0)
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
void emcal_digits()
{
cout<<"Cell ID "<<id<<" Amp "<<amp<<endl;//" time "<<time<<endl;
- //Geometry methods
- geom->GetCellIndex(id,iSupMod,iTower,iIphi,iIeta);
+ //Geometry methods
+ geom->GetCellIndex(id,iSupMod,iTower,iIphi,iIeta);
//Gives SuperModule and Tower numbers
geom->GetCellPhiEtaIndexInSModule(iSupMod,iTower,
iIphi, iIeta,iphi,ieta);
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
TEvePointSet*
rl->LoadHits("EMCAL");
TTree* ht = rl->GetTreeH("EMCAL", false);
-
+
//PH The line below is replaced waiting for a fix in Root
//PH which permits to use variable siza arguments in CINT
//PH on some platforms (alphalinuxgcc, solariscc5, etc.)
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
// #include "EVE/Alieve/EventAlieve.h"
// #include "TEveManager.h"
-AliEveCascade* esd_make_cas(TEveTrackPropagator* rnrStyle, AliESDVertex* primVtx,
+AliEveCascade* esd_make_cas(TEveTrackPropagator* rnrStyle, AliESDVertex* primVtx,
AliESDcascade* cas, AliESDtrack* neg, AliESDtrack* pos,
AliESDtrack* bach,Int_t i) {
AliESDEvent* esd = AliEveEventManager::AssertESD();
AliESDVertex* primVertex =(AliESDVertex*) esd->GetVertex();
- CascadeList* cont = new CascadeList("ESD cascade");
+ CascadeList* cont = new CascadeList("ESD cascade");
cont->SetMainColor(Color_t(3)); // green
TEveTrackPropagator* rnrStyle = cont->GetPropagator();
rnrStyle->SetMagField( esd->GetMagneticField() );
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
// printf(" %f %f %f / %f %f %f %i\n",p[0], p[1], p[2],
// v[0], v[1], v[2], v0->GetOnFlyStatus());
- rcV0.V_neg.Set(v); //original track vertices at dca not stored
+ rcV0.V_neg.Set(v); //original track vertices at dca not stored
rcV0.V_pos.Set(v);
rcV0.V_ca.Set(v);
AliEveV0* myV0 = new AliEveV0(&rcNeg, &rcPos, &rcV0, rnrStyle);
char ch[50];
- // sprintf(ch,"ESDv0%i",i);
+ // sprintf(ch,"ESDv0%i",i);
// myV0->SetName(ch);
// myV0->SetTitle(ch);
myV0->SetESDIndex(i);
AliESDEvent* esd = AliEveEventManager::AssertESD();
AliESDVertex* primVertex =(AliESDVertex*) esd->GetVertex();
- V0List* cont = new V0List("ESD v0");
+ V0List* cont = new V0List("ESD v0");
cont->SetMainColor(Color_t(3)); // green
TEveTrackPropagator* rnrStyle = cont->GetPropagator();
rnrStyle->SetMagField( esd->GetMagneticField() );
Int_t posInd = v0->GetPindex();
AliESDtrack* negTr = esd->GetTrack(negInd);
AliESDtrack* posTr = esd->GetTrack(posInd);
-
+
AliEveV0* myV0 = esd_make_v0(rnrStyle, primVertex, negTr,posTr, v0, n);
if (myV0) {
gEve->AddElement(myV0, cont);
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
TEvePointSet*
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
// To use when per-line id is supported
class TrackletId : public TObject
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
TEveTrack* esd_make_track(TEveTrackPropagator* rnrStyle,
rt.fP.Set(pbuf);
Double_t ep = at->GetP(), mc = at->GetMass();
rt.fBeta = ep/TMath::Sqrt(ep*ep + mc*mc);
-
+
TEveTrack* track = new TEveTrack(&rt, rnrStyle);
//PH The line below is replaced waiting for a fix in Root
//PH which permits to use variable siza arguments in CINT
Double_t maxptsq = max_pt*max_pt;
Double_t ptsq;
- TEveTrackList* cont = new TEveTrackList("ESD Tracks");
+ TEveTrackList* cont = new TEveTrackList("ESD Tracks");
cont->SetMainColor(Color_t(6));
TEveTrackPropagator* rnrStyle = cont->GetPropagator();
rnrStyle->SetMagField( esd->GetMagneticField() );
if (esd == 0) esd = AliEveEventManager::AssertESD();
- TEveTrackList* cont = new TEveTrackList("ESD Tracks");
+ TEveTrackList* cont = new TEveTrackList("ESD Tracks");
cont->SetMainColor(Color_t(6));
TEveTrackPropagator* rnrStyle = cont->GetPropagator();
rnrStyle->SetMagField( esd->GetMagneticField() );
++count;
TEveTrack* track = esd_make_track(tlist->GetPropagator(), n, at, tp);
- track->SetAttLineAttMarker(tlist);
+ track->SetAttLineAttMarker(tlist);
//PH The line below is replaced waiting for a fix in Root
//PH which permits to use variable siza arguments in CINT
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
void event_goto(Int_t event=0)
{
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
void event_next()
{
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
void event_prev()
{
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
TEvePointSet*
rl->LoadHits("FMD");
TTree* ht = rl->GetTreeH("FMD", false);
-
+
//PH The line below is replaced waiting for a fix in Root
//PH which permits to use variable siza arguments in CINT
//PH on some platforms (alphalinuxgcc, solariscc5, etc.)
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
void geom_acorde()
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
void geom_all()
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
void geom_ddip()
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
void geom_emcal()
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
void geom_fmd()
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
TEveGeoShape* geom_gentle()
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
void geom_hmpid()
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
void geom_its()
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
void geom_phos()
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
void geom_pmd()
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
void geom_simple()
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
void geom_t0()
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
void geom_tpc()
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
void geom_trd_tof()
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
void geom_vzero()
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
void hits_from_label(Int_t label=0, TEveElement* cont)
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifdef __CINT__
clusters->SetOwnIds(kTRUE);
AliEveEventManager::AssertGeometry();
-
+
AliRunLoader* rl = AliEveEventManager::AssertRunLoader();
rl->LoadRecPoints("HMPID");
TBranch *br=cTree->GetBranch(name[k]);
if (!br) return 0;
br->SetAddress(&(cl[k]));
- }
+ }
if (!cTree->GetEvent(0)) return 0;
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
void init_trd()
{
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifdef __CINT__
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
// Load ITS digits.
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
TEvePointSet*
rl->LoadHits("ITS");
TTree* ht = rl->GetTreeH("ITS", false);
-
+
//PH The line below is replaced waiting for a fix in Root
//PH which permits to use variable siza arguments in CINT
//PH on some platforms (alphalinuxgcc, solariscc5, etc.)
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
void its_hits_layer_split(const char *varexp = "fX:fY:fZ:GetLayer()",
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "TGLViewer.h"
namespace Alieve
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
void its_raw(const char *input = "rawdata.root",
Int_t mode = 63,
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
AliEveJetPlane* jetplane(Int_t iev)
-{
+{
TFile* f = new TFile("aod.root");
TTree* treeAOD = (TTree*) f->Get("AOD");
AliAODEvent* aod = new AliAODEvent();
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
// Import tracks from kinematics-tree / particle-stack.
// Preliminary/minimal solution.
}
gEve->DisableRedraw();
-
- TEveTrackList* cont = new TEveTrackList("Kine Tracks");
+
+ TEveTrackList* cont = new TEveTrackList("Kine Tracks");
cont->SetMainColor(Color_t(3));
TEveTrackPropagator* rnrStyle = cont->GetPropagator();
// !!! Watch the '-', apparently different sign convention then for ESD.
gEve->AddElement(cont);
Int_t count = 0;
Int_t N = stack->GetNtrack();
- for (Int_t i=0; i<N; ++i)
+ for (Int_t i=0; i<N; ++i)
{
- if(stack->IsPhysicalPrimary(i))
+ if(stack->IsPhysicalPrimary(i))
{
TParticle* p = stack->Particle(i);
if (p->Pt() < min_pt && p->P() < min_p) continue;
++count;
TEveTrack* track = new TEveTrack(p, i, rnrStyle);
-
+
//PH The line below is replaced waiting for a fix in Root
//PH which permits to use variable siza arguments in CINT
//PH on some platforms (alphalinuxgcc, solariscc5, etc.)
}
// set path marks
- AliEveKineTools kt;
+ AliEveKineTools kt;
kt.SetDaughterPathMarks(cont, stack, recurse);
if (use_track_refs && rl->LoadTrackRefs() == 0)
{
Bool_t pdg_col, Bool_t recurse)
{
TParticle *p = stack->Particle(parent->GetLabel());
- if (p->GetNDaughters() > 0)
+ if (p->GetNDaughters() > 0)
{
TEveTrackPropagator* rs = parent->GetPropagator();
- for (int d=p->GetFirstDaughter(); d>0 && d<=p->GetLastDaughter(); ++d)
- {
+ for (int d=p->GetFirstDaughter(); d>0 && d<=p->GetLastDaughter(); ++d)
+ {
TParticle* dp = stack->Particle(d);
if (dp->Pt() < min_pt && dp->P() < min_p) continue;
- TEveTrack* dtrack = new TEveTrack(dp, d, rs);
+ TEveTrack* dtrack = new TEveTrack(dp, d, rs);
char form[1000];
sprintf(form,"%s [%d]", dp->GetName(), d);
dtrack->SetName(form);
static const Color_t DefCol = 30;
static const Color_t ECol = 5;
static const Color_t MuCol = 6;
- static const Color_t GammaCol = 7;
+ static const Color_t GammaCol = 7;
static const Color_t MesCol1 = 3;
static const Color_t MesCol2 = 38;
static const Color_t BarCol = 10;
// elementary particles
if (pdga < 100) {
switch (pdga) {
- case 11:
- col = ECol; break;
+ case 11:
+ col = ECol; break;
case 12:
col = MuCol; break;
case 22:
else if (pdga < 100000) {
Int_t i = pdga;
Int_t i0 = i%10; i /= 10;
- Int_t i1 = i%10; i /= 10;
- Int_t i2 = i%10; i /= 10;
- Int_t i3 = i%10; i /= 10;
+ Int_t i1 = i%10; i /= 10;
+ Int_t i2 = i%10; i /= 10;
+ Int_t i3 = i%10; i /= 10;
Int_t i4 = i%10;
//printf("pdg(%d) quark indices (%d,%d,%d,%d,%d) \n",pdg, i4,i3,i2, i1, i0);
// meson
Warning("kine_track", "label not set.");
return 0;
}
-
+
AliRunLoader* rl = AliEveEventManager::AssertRunLoader();
rl->LoadKinematics();
AliStack* stack = rl->Stack();
if (import_mother || (import_daughters && p->GetNDaughters()))
{
TEveTrack* toptrack = 0;
- TEveTrackList* tracklist = 0;
+ TEveTrackList* tracklist = 0;
TEveTrackPropagator* rs = 0;
if (cont == 0)
if (import_mother)
{
- TEveTrack* track = new TEveTrack(p, label, rs);
+ TEveTrack* track = new TEveTrack(p, label, rs);
char form[1000];
sprintf(form,"%s [%d]", p->GetName(), label);
track->SetName(form);
cont = track;
}
- if (import_daughters && p->GetNDaughters())
+ if (import_daughters && p->GetNDaughters())
{
- for (int d=p->GetFirstDaughter(); d>0 && d<=p->GetLastDaughter(); ++d)
- {
+ for (int d=p->GetFirstDaughter(); d>0 && d<=p->GetLastDaughter(); ++d)
+ {
TParticle* dp = stack->Particle(d);
- TEveTrack* track = new TEveTrack(dp, d, rs);
+ TEveTrack* track = new TEveTrack(dp, d, rs);
char form[1000];
sprintf(form,"%s [%d]", dp->GetName(), d);
track->SetName(form);
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
TEvePointSet* phos_clusters(TEveElement* cont=0)
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
// ---------------------------------------------------------------------- //
void pmd_digits(Int_t mode = 0)
iendDDL = 6;
zpos = 360.;
}
-
+
TEveElementList* lplane = new TEveElementList(spl.Data());
// l->SetMainColor((Color_t)3);
gEve->AddElement(lplane, l);
-
+
for (Int_t iddl = istartDDL; iddl < iendDDL; iddl++)
{
sddl = bsddl;
for (Int_t ism = 0; ism < NSM; ism++)
{
-
+
AliEvePMDModule *lmodule = new AliEvePMDModule();
lmodule->SetPosition(0.,0.,zpos);
lmodule->DisplayDigitsData(modnumber, pmdt);
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
TEvePointSet*
rl->LoadHits("PMD");
TTree* ht = rl->GetTreeH("PMD", false);
-
+
//PH The line below is replaced waiting for a fix in Root
//PH which permits to use variable siza arguments in CINT
//PH on some platforms (alphalinuxgcc, solariscc5, etc.)
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
// ---------------------------------------------------------------------- //
void pmd_raw(Int_t mode = 0)
// l->SetTitle("PMD");
// l->SetMainColor((Color_t)3);
gEve->AddElement(l);
-
+
Int_t NSM = 0;
Int_t istartDDL = 0;
Int_t iendDDL = 0;
iendPlane = 1;
printf("--- Visualization is set for PREshower Plane ---\n");
break;
-
+
case 1:
istartPlane = 1;
iendPlane = 2;
iendPlane = 2;
printf("--- Visualization is set for both the Plane ---\n");
break;
-
+
default:
printf("--- Not set for any Plane ---\n");
}
iendDDL = 6;
zpos = 360.;
}
-
+
TEveElementList* lplane = new TEveElementList(spl.Data());
// l->SetMainColor((Color_t)3);
gEve->AddElement(lplane, l);
-
+
for (Int_t iddl = istartDDL; iddl < iendDDL; iddl++)
//for (Int_t iddl = 0; iddl < 1; iddl++)
{
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
TPolyMarker3D* make_vertex_marker(AliESDVertex* v, const Text_t* name )
/**************************************************************************/
TEveStraightLineSet* ESDvertex_lineset(AliESDVertex* v, const Text_t* name)
-{
+{
Double_t x[3], e[3];
v->GetXYZ(x); v->GetSigmaXYZ(e);
printf("%16s: %f %f %f - %f %f %f\n", name,
// dimensions
TEveStraightLineSet* ls = new TEveStraightLineSet();
ls->SetName(name);
- ls->AddLine(e[0], 0, 0, -e[0], 0, 0);
+ ls->AddLine(e[0], 0, 0, -e[0], 0, 0);
ls->AddLine(0, e[1], 0, 0, -e[1], 0);
ls->AddLine(0, 0, e[2], 0, 0, -e[2]);
for(Int_t i =0; i < 3; i++)
// centre marker
ls->AddMarker(0, 0.5);
ls->RefHMTrans().SetPos(x);
- return ls;
+ return ls;
}
void make_vertex_ellipses(TEveStraightLineSet* ls, AliESDVertex* v, Bool_t ellipseUseSigma)
a = e[0]; b = e[1];
for (Int_t i = 0; i<N; i++)
- ls->AddLine(a*TMath::Cos(i*S) , b*TMath::Sin(i*S) , 0,
+ ls->AddLine(a*TMath::Cos(i*S) , b*TMath::Sin(i*S) , 0,
a*TMath::Cos(i*S+S), b*TMath::Sin(i*S+S), 0);
a = e[0]; b = e[2];
for (Int_t i = 0; i<N; i++)
- ls->AddLine(a*TMath::Cos(i*S) , 0, b*TMath::Sin(i*S),
+ ls->AddLine(a*TMath::Cos(i*S) , 0, b*TMath::Sin(i*S),
a*TMath::Cos(i*S+S), 0, b*TMath::Sin(i*S+S));
a = e[1]; b = e[2];
for (Int_t i = 0; i<N; i++)
- ls->AddLine(0, a*TMath::Cos(i*S) , b*TMath::Sin(i*S),
+ ls->AddLine(0, a*TMath::Cos(i*S) , b*TMath::Sin(i*S),
0, a*TMath::Cos(i*S+S), b*TMath::Sin(i*S+S));
}
void primary_vertex(Bool_t showSPD=kTRUE, Bool_t rnrEllipse=kTRUE)
-{
+{
AliESDEvent* esd = AliEveEventManager::AssertESD();
TEveStraightLineSet* ls;
if (rnrEllipse) make_vertex_ellipses(ls, PV, kTRUE);
gEve->AddElement(ls);
- if (showSPD)
+ if (showSPD)
{
AliESDVertex* SPDV = esd->GetVertex();
ls = ESDvertex_lineset(SPDV, "SPD Vertex");
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
TEveTrackList* primary_vertex_tracks()
{
AliESDEvent *esd = AliEveEventManager::AssertESD();
AliESDVertex *pv = esd->GetPrimaryVertex();
- TEveTrackList* cont = new TEveTrackList("Tracks for Primary Vertex");
+ TEveTrackList* cont = new TEveTrackList("Tracks for Primary Vertex");
cont->SetMainColor(Color_t(7));
TEveTrackPropagator* rnrStyle = cont->GetPropagator();
rnrStyle->SetMagField( esd->GetMagneticField() );
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
void print_kine_from_label(Int_t label)
{
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
void region_marker(Float_t a=10, Float_t b=10, Float_t c=20,
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
namespace Alieve {
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
TEvePointSet*
Int_t nTracks = ht->GetEntries();
// printf("Found %d tracks. \n",nTracks);
for (Int_t it = 0; it < nTracks; it++) {
-
+
TClonesArray *hits = 0;
ht->SetBranchAddress("T0",&hits);
-
+
ht->GetEvent(it);
// Int_t nHits = hits->GetEntriesFast();
// printf("Found %d hits in track %d.\n", nHits, it);
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
namespace Alieve {
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
void tof_digits()
-{
+{
TClonesArray *array = 0x0;
Int_t nDigitsInVolume[3] = {-1, -1, -1};
di->Dump();
AliTOFGeometry* g = di->fGeom;
-
+
gStyle->SetPalette(1, 0);
gEve->DisableRedraw();
gEve->AddElement(ll);
for(Int_t iSector=0; iSector<g->NSectors(); iSector++) {
-
+
array = di->GetDigits(iSector);
-
+
AliEveTOFSector* m = new AliEveTOFSector(localGeoManager,iSector,array);
gEve->AddElement(m, ll);
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
void tof_digits_sector(Int_t sector=0)
{
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
void tof_digits_strips()
{
TString bsPadZ="PadZ";
TString sPadX;
TString bsPadX="PadX";
-
+
Char_t sectorName[100];
Char_t sectorTitle[200];
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
TEvePointSet*
rl->LoadHits("TOF");
TTree* ht = rl->GetTreeH("TOF", false);
-
+
//PH The line below is replaced waiting for a fix in Root
//PH which permits to use variable siza arguments in CINT
//PH on some platforms (alphalinuxgcc, solariscc5, etc.)
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
void tpc_calib_viewer(const char* file="CalibTree.root")
{
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifdef __CINT__
cTree->SetBranchAddress("Segment", &clrow);
Float_t maxRsqr = maxR*maxR;
- TClonesArray *cl=clrow->GetArray();
+ TClonesArray *cl=clrow->GetArray();
Int_t nentr=(Int_t)cTree->GetEntries();
for (Int_t i=0; i<nentr; i++) {
if (!cTree->GetEvent(i)) continue;
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include "TGLViewer.h"
//TGLViewer* cam = gEve->GetGLViewer();
//cam->SetCurrentCamera(TGLViewer::kCameraOrthoXOY) ;
- //cam->SetOrthoCamera(TGLViewer::kCameraOrthoXOY, 2*left, 2*right, 2*top, bottom);
+ //cam->SetOrthoCamera(TGLViewer::kCameraOrthoXOY, 2*left, 2*right, 2*top, bottom);
//printf("%f %f %f %f\n", left, right, top, bottom);
break;
l->SetTitle("TPC Plate");
l->SetMainColor(Color_t(col));
gEve->AddElement(l);
-
+
for(Int_t i = 0; i<18; i++) {
AliEveTPCSector2D* s = new AliEveTPCSector2D(Form("AliEveTPCSector2D %d", i));
s->SetSectorID(i);
l->SetTitle("TPC Plate");
l->SetMainColor(Color_t(col));
gEve->AddElement(l);
-
+
for(Int_t i = 0; i<18; i++) {
AliEveTPCSector3D* s = new AliEveTPCSector3D(Form("AliEveTPCSector3D %d", i));
s->SetSectorID(i);
TEveElementList* l = new TEveElementList("TPC sectors");
l->SetMainColor(Color_t(col));
gEve->AddElement(l);
-
+
for(Int_t i=start; i<=end; i++) {
AliEveTPCSector2D* s = new AliEveTPCSector2D();
s->SetSectorID(i);
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
TEvePointSet*
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
void tpc_hits_charge_split(const char *varexp =
l->SetMarkerColor((Color_t)3);
l->SetMarkerStyle(20); // full circle
l->SetMarkerSize(.5);
-
+
gEve->AddElement(l);
l->InitBins("Log Charge", 20, 0, 5);
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
void tpc_hits_eta_split(const char *varexp =
l->SetMarkerColor((Color_t)3);
l->SetMarkerStyle(20); // full circle
l->SetMarkerSize(.5);
-
+
gEve->AddElement(l);
l->InitBins("Eta", 20, -2, 2);
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
TEvePointSet*
rl->LoadHits("TRD");
TTree* ht = rl->GetTreeH("TRD", false);
-
+
//PH The line below is replaced waiting for a fix in Root
//PH which permits to use variable siza arguments in CINT
//PH on some platforms (alphalinuxgcc, solariscc5, etc.)
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
void trd_hits_z_split(const char *varexp = "fX:fY:fZ:fZ",
l->SetMarkerColor((Color_t)7);
l->SetMarkerStyle(20); // full circle
l->SetMarkerSize(.5);
-
+
gEve->AddElement(l);
l->InitBins("Z", 20, -360, 360);
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
// fV0CHeight1 = 2.5; // height of cell 1
// fV0CHeight2 = 4.4; // height of cell 2
TEveQuadSet* modL = new TEveQuadSet("V0L");
modL->Reset(TEveQuadSet::kQT_FreeQuad, kFALSE, 32);
-
+
Int_t numEntr = dca->GetEntriesFast();
for (Int_t entr=0; entr<numEntr; ++entr)
{
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
TEvePointSet*
rl->LoadHits("VZERO");
TTree* ht = rl->GetTreeH("VZERO", false);
-
+
//PH The line below is replaced waiting for a fix in Root
//PH which permits to use variable siza arguments in CINT
//PH on some platforms (alphalinuxgcc, solariscc5, etc.)
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include <TObject.h>
#include <TList.h>
#include <TRandom.h>
-void make_crap(void* arg)
+void make_crap(void* arg)
{
Int_t num = 1024;
TRandom rnd(0);
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#include <Rtypes.h>
//Int_t fTrackID[3];
//#endif
Float_t fX; //==fPadRow in local system
- Float_t fY;
+ Float_t fY;
Float_t fZ;
UInt_t fID; //contains slice patch and number
UChar_t fPadRow;
Float_t fSigmaY2; //error (former width) of the clusters
Float_t fSigmaZ2; //error (former width) of the clusters
UInt_t fCharge;
- Bool_t fUsed; // only used in AliHLTTPCDisplay
- Int_t fTrackN; // only used in AliHLTTPCDisplay
+ Bool_t fUsed; // only used in AliHLTTPCDisplay
+ Int_t fTrackN; // only used in AliHLTTPCDisplay
};
struct AliHLTTPCClusterData
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
// Functions to read data from HOMER.
homerM->SelectESDTPC();
homerM->ConnectHOMER();
- memreader = new AliRawReaderMemory(0, 0);
+ memreader = new AliRawReaderMemory(0, 0);
gStyle->SetPalette(1, 0);
loader = new AliEveTPCLoader;
rt.P.Set(pbuf);
Double_t ep = at->GetP(), mc = at->GetMass();
rt.beta = ep/TMath::Sqrt(ep*ep + mc*mc);
-
+
TEveTrack* track = new TEveTrack(&rt, rnrStyle);
//PH The line below is replaced waiting for a fix in Root
//PH which permits to use variable siza arguments in CINT
root [11] tpc_trk->MakeTracks(
void MakeTracks(Bool_t recurse = kTRUE)
root [11] tpc_trk->MakeTracks()
-root [12]
+root [12]
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
{
-
+
cout << "Setting include path ..." << endl;
TString includePath = "-I${ALICE_ROOT}/include ";
includePath += "-I${ALICE_ROOT}/EVE ";
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
void alieve_create_vsd()
{
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
#ifndef __CINT_
gSystem->cd(hack);
// TEveUtil::AssertMacro("region_marker.C");
-
+
gSystem->ProcessEvents();
// Open event
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
-void alieve_loadlibs ()
+void alieve_loadlibs ()
{
// Macro which loads the libraries needed for simulation and reconstruction
gSystem->Load("libESD");
gSystem->Load("libSTEER");
-
+
gSystem->Load("libRAWDatabase");
gSystem->Load("libRAWDatarec");
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
// Cause ROOT to properly crash and dump core on SigSEGV.
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
void trackcount_init()
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
class TTree;
AliSimDigits *digit = 0;
tree->GetBranch("Segment")->SetAddress(&digit);
-
+
Int_t sbr = (Int_t) tree->GetEntries();
for (Int_t ent=0; ent<sbr; ent++) {
tree->GetEntry(ent);
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
// Function to spawn a gui for reading rootified raw-data from TPC sector test.
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
// Function to spawn a gui for reading rootified raw-data from TPC sector test.
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
class AliRawReaderFile;
/**************************************************************************
* Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
* See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
- * full copyright notice. *
+ * full copyright notice. *
**************************************************************************/
// Functions to read rootified raw-data from TPC sector test.