]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - HLT/TPCLib/AliHLTTPCClusterFinderComponent.cxx
updated SampleLib and tutorial, sample macros added
[u/mrichter/AliRoot.git] / HLT / TPCLib / AliHLTTPCClusterFinderComponent.cxx
index 400b122c1b173bc1204dbd0f674c72c79e6643e3..23d6bcaba868a2e8a3c8396aea7aadc54aecd8f5 100644 (file)
@@ -1,42 +1,34 @@
 // $Id$
 
-/**************************************************************************
- * This file is property of and copyright by the ALICE HLT Project        * 
- * ALICE Experiment at CERN, All rights reserved.                         *
- *                                                                        *
- * Primary Authors: Matthias Richter <Matthias.Richter@ift.uib.no>        *
- *                  Timm Steinbeck <timm@kip.uni-heidelberg.de>           *
- *                  Jochen Thaeder <thaeder@kip.uni-heidelberg.de>        *
- *                  for The ALICE HLT Project.                            *
- *                                                                        *
- * Permission to use, copy, modify and distribute this software and its   *
- * documentation strictly for non-commercial purposes is hereby granted   *
- * without fee, provided that the above copyright notice appears in all   *
- * copies and that both the copyright notice and this permission notice   *
- * appear in the supporting documentation. The authors make no claims     *
- * about the suitability of this software for any purpose. It is          *
- * provided "as is" without express or implied warranty.                  *
- **************************************************************************/
+//**************************************************************************
+//* This file is property of and copyright by the ALICE HLT Project        * 
+//* ALICE Experiment at CERN, All rights reserved.                         *
+//*                                                                        *
+//* Primary Authors: Timm Steinbeck, Matthias Richter                      *
+//* Developers:      Kenneth Aamodt <kenneth.aamodt@student.uib.no>        *
+//*                  for The ALICE HLT Project.                            *
+//*                                                                        *
+//* Permission to use, copy, modify and distribute this software and its   *
+//* documentation strictly for non-commercial purposes is hereby granted   *
+//* without fee, provided that the above copyright notice appears in all   *
+//* copies and that both the copyright notice and this permission notice   *
+//* appear in the supporting documentation. The authors make no claims     *
+//* about the suitability of this software for any purpose. It is          *
+//* provided "as is" without express or implied warranty.                  *
+//**************************************************************************
 
 /** @file   AliHLTTPCClusterFinderComponent.cxx
-    @author Timm Steinbeck, Matthias Richter, Jochen Thaeder, Kenneth Aamodt
+    @author Kenneth Aamodt <kenneth.aamodt@student.uib.no>
     @date   
     @brief  The TPC cluster finder processing component
 */
 
-// see header file for class documentation                                   //
-// or                                                                        //
-// refer to README to build package                                          //
-// or                                                                        //
-// visit http://web.ift.uib.no/~kjeks/doc/alice-hlt                          //
-
 #if __GNUC__>= 3
 using namespace std;
 #endif
 #include "AliHLTTPCClusterFinderComponent.h"
 #include "AliHLTTPCDigitReaderPacked.h"
 #include "AliHLTTPCDigitReaderUnpacked.h"
-#include "AliHLTTPCDigitReaderRaw.h"
 #include "AliHLTTPCDigitReaderDecoder.h"
 #include "AliHLTTPCClusterFinder.h"
 #include "AliHLTTPCSpacePointData.h"
@@ -53,13 +45,6 @@ using namespace std;
 #include "TObjString.h"
 #include <sys/time.h>
 
-// this is a global object used for automatic component registration, do not use this
-// use fPackedSwitch = true for packed inputtype "gkDDLPackedRawDataType"
-// use fPackedSwitch = false for unpacked inputtype "gkUnpackedRawDataType"
-AliHLTTPCClusterFinderComponent gAliHLTTPCClusterFinderComponentPacked(AliHLTTPCClusterFinderComponent::kClusterFinderPacked);
-AliHLTTPCClusterFinderComponent gAliHLTTPCClusterFinderComponentUnpacked(AliHLTTPCClusterFinderComponent::kClusterFinderUnpacked);
-AliHLTTPCClusterFinderComponent gAliHLTTPCClusterFinderComponentDecoder(AliHLTTPCClusterFinderComponent::kClusterFinderDecoder);
-
 /** ROOT macro for the implementation of ROOT specific class methods */
 ClassImp(AliHLTTPCClusterFinderComponent)
 
@@ -137,7 +122,6 @@ int AliHLTTPCClusterFinderComponent::GetOutputDataTypes(AliHLTComponentDataTypeL
   // see header file for class documentation
   tgtList.clear();
   tgtList.push_back(AliHLTTPCDefinitions::fgkClustersDataType);
-  tgtList.push_back(AliHLTTPCDefinitions::fgkActivePadsDataType);
   return tgtList.size();
 }
 
@@ -173,7 +157,6 @@ int AliHLTTPCClusterFinderComponent::DoInit( int argc, const char** argv )
 
   fClusterFinder = new AliHLTTPCClusterFinder();
 
-  Int_t rawreadermode =  -1;
   Int_t sigthresh = -1;
   Double_t sigmathresh= -1;
   Float_t occulimit = 1.0;
@@ -197,14 +180,7 @@ int AliHLTTPCClusterFinderComponent::DoInit( int argc, const char** argv )
        return ENOTSUP;
       }
 
-      // Decodes the rawreader mode: either number or string and returns the rawreadermode
-      // -1 on failure, -2 for offline
-      rawreadermode = AliHLTTPCDigitReaderRaw::DecodeMode( argv[i+1] );
-
-      if (rawreadermode == -1 ) {
-       Logging( kHLTLogError, "HLT::TPCClusterFinder::DoInit", "Missing rawreadermode", "Cannot convert rawreadermode specifier '%s'.", argv[i+1] );
-       return EINVAL;
-      }
+      Logging( kHLTLogWarning, "HLT::TPCClusterFinder::DoInit", "parameter rawreadermode is deprecated", "argument scan" );      
 
       i += 2;
       continue;
@@ -304,8 +280,7 @@ int AliHLTTPCClusterFinderComponent::DoInit( int argc, const char** argv )
   }
 
   // Choose reader
-  if (fModeSwitch==kClusterFinderPacked) { 
-    if (rawreadermode == -2) {
+  if (fModeSwitch==kClusterFinderPacked) {
       HLTDebug("using AliHLTTPCDigitReaderPacked");
       fReader = new AliHLTTPCDigitReaderPacked();
       if(oldRCUFormat==1){
@@ -318,17 +293,6 @@ int AliHLTTPCClusterFinderComponent::DoInit( int argc, const char** argv )
        fReader->SetUnsorted(kTRUE);
       }
       fClusterFinder->SetReader(fReader);
-    } 
-    else {
-#if defined(HAVE_TPC_MAPPING)
-      HLTDebug("using AliHLTTPCDigitReaderRaw mode %d", rawreadermode);
-      fReader = new AliHLTTPCDigitReaderRaw(rawreadermode);
-      fClusterFinder->SetReader(fReader);
-#else //! defined(HAVE_TPC_MAPPING)
-      HLTFatal("DigitReaderRaw not available - check your build");
-      return -ENODEV;
-#endif //defined(HAVE_TPC_MAPPING)
-    }
   }
   else if(fModeSwitch==kClusterFinderUnpacked){
     HLTDebug("using AliHLTTPCDigitReaderUnpacked");
@@ -336,6 +300,7 @@ int AliHLTTPCClusterFinderComponent::DoInit( int argc, const char** argv )
     fClusterFinder->SetReader(fReader);
   }
   else if(fModeSwitch==kClusterFinderDecoder){
+    HLTDebug("using AliHLTTPCDigitReaderDecoder");
     fReader = new AliHLTTPCDigitReaderDecoder();
     fClusterFinder->SetReader(fReader);
   }