* provided "as is" without express or implied warranty. *
**************************************************************************/
/**
- * @file AliHLTPHOSClusterizer.cxx
+ * @file AliHLTPHOSDigitMaker.cxx
* @author Oystein Djuvsland
* @date
* @brief Digit maker for PHOS HLT
// visit http://web.ift.uib.no/~kjeks/doc/alice-hlt
#include "AliHLTPHOSDigitMaker.h"
+#include "AliHLTLogging.h"
#include "AliHLTPHOSConstants.h"
#include "AliHLTPHOSMapper.h"
#include "AliPHOSEMCAGeometry.h"
#include "TH2F.h"
+
ClassImp(AliHLTPHOSDigitMaker);
using namespace PhosHLTConst;
AliHLTPHOSDigitMaker::AliHLTPHOSDigitMaker() :
- // AliHLTPHOSBase(),
+ AliHLTLogging(),
fShmPtr(0),
fDigitStructPtr(0),
fDigitCount(0),
AliHLTPHOSChannelDataStruct* currentchannel = 0;
AliHLTPHOSChannelDataStruct* currentchannelLG = 0;
AliHLTPHOSChannelDataStruct* tmpchannel = 0;
-
+
fShmPtr->SetMemory(channelDataHeader);
currentchannel = fShmPtr->NextChannel();
-
+
while(currentchannel != 0)
{
- if(availableSize < totSize) return -1;
+ if(availableSize < totSize) return -1;
AliHLTPHOSMapper::GetChannelCoord(currentchannel->fChannelID, coord1);
if(coord1[2] == HIGHGAIN) // We got a completely new crystal
{
-
if(currentchannel->fEnergy < MAXBINVALUE) // Make sure we don't have signal overflow
{
AliHLTPHOSMapper::GetLocalCoord(currentchannel->fChannelID, locCoord);
else // Ooops, overflow, we try the next channel...
{
-
currentchannel = fShmPtr->NextChannel();
if(currentchannel != 0) // There was a next channel
{
}
else //Fine, no more channels, better add this one...
{
- AliHLTPHOSMapper::GetLocalCoord(currentchannel->fChannelID, locCoord);
+ AliHLTPHOSMapper::GetLocalCoord(currentchannelLG->fChannelID, locCoord);
AddDigit(currentchannelLG, coord1, locCoord);
j++;
totSize += sizeof(AliHLTPHOSDigitDataStruct);
#include "AliHLTPHOSDigitDataStruct.h"
#include "AliHLTPHOSChannelDataStruct.h"
#include "AliHLTDataTypes.h"
+#include "AliHLTLogging.h"
/**
* @class AliHLTPHOSDigitMaker
using namespace PhosHLTConst;
//class AliHLTPHOSDigitMaker : public AliHLTPHOSBase
-class AliHLTPHOSDigitMaker
+class AliHLTPHOSDigitMaker : public AliHLTLogging
{
public:
/** Copy constructor */
AliHLTPHOSDigitMaker(const AliHLTPHOSDigitMaker &) :
- // AliHLTPHOSBase(),
+ AliHLTLogging(),
fShmPtr(0),
fDigitStructPtr(0),
fDigitCount(0),
if(channelCoordinates[2] == HIGHGAIN)
{
fDigitStructPtr->fEnergy = channelData->fEnergy*fHighGainFactors[channelCoordinates[0]][channelCoordinates[1]];
- // printf("HG channel (x = %d, z = %d) with amplitude: %f --> Digit with energy: %f \n", channelCoordinates[0], channelCoordinates[1], channelData->fEnergy, fDigitStructPtr->fEnergy);
+ // HLTDebug("HG channel (x = %d, z = %d) with amplitude: %f --> Digit with energy: %f \n", channelCoordinates[0], channelCoordinates[1], channelData->fEnergy, fDigitStructPtr->fEnergy);
}
else
{
fDigitStructPtr->fEnergy = channelData->fEnergy*fLowGainFactors[channelCoordinates[0]][channelCoordinates[1]];
- // printf("LG channel (x = %d, z = %d) with amplitude: %f --> Digit with energy: %f\n", channelCoordinates[0], channelCoordinates[1], channelData->fEnergy, fDigitStructPtr->fEnergy);
+ // HLTDebug("LG channel (x = %d, z = %d) with amplitude: %f --> Digit with energy: %f\n", channelCoordinates[0], channelCoordinates[1], channelData->fEnergy, fDigitStructPtr->fEnergy);
}
fDigitStructPtr->fTime = channelData->fTime * 0.0000001; //TODO
fDigitStructPtr->fCrazyness = channelData->fCrazyness;