]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - STEER/AliCluster.cxx
Switching off the QA in preparation for the new 900GeV data
[u/mrichter/AliRoot.git] / STEER / AliCluster.cxx
index 0db69921975789b561710bddafb0a6fc853ece2e..b9a3b738ba6011c613f9add895d1b8c53d32d732 100644 (file)
@@ -144,6 +144,19 @@ AliCluster & AliCluster::operator=(const AliCluster& cluster)
   return *this;
 }
 
+//______________________________________________________________________________
+void AliCluster::Print(Option_t* /*option*/) const
+{
+  // Print cluster information.
+  
+  printf("AliCluster pos=(%.4f, %.4f, %.4f), s_y2=%f, s_z2=%f, s_yz=%f, vol=%hu\n",
+         fX, fY, fZ, fSigmaY2, fSigmaZ2, fSigmaYZ, fVolumeId);
+  Float_t g[3];
+  if (GetGlobalXYZ(g))
+    printf("    global_pos=(%.4f, %.4f, %.4f)\n", g[0], g[1], g[2]);
+
+}
+
 //______________________________________________________________________________
 Bool_t AliCluster::GetGlobalXYZ(Float_t xyz[3]) const
 {
@@ -275,28 +288,10 @@ TGeoHMatrix* AliCluster::GetMatrix(Bool_t original) const
   // can be used to force the calculation of the ideal
   // matrix.
   if (!fIsMisaligned && (original == kFALSE)) {
-    TGeoPNEntry *pne = GetPNEntry();
-    if (!pne) return NULL;
-
-    TGeoPhysicalNode *pnode = pne->GetPhysicalNode();
-    if (pnode) return pnode->GetMatrix();
-
-    const char* path = pne->GetTitle();
-    if (!gGeoManager->cd(path)) {
-      AliError(Form("Volume path %s not valid!",path));
-      return NULL;
-    }
-    return gGeoManager->GetCurrentMatrix();
+    return AliGeomManager::GetMatrix(fVolumeId);
   }
   else {
-    const char* symname = AliAlignObj::SymName(fVolumeId);
-    if (!symname) return NULL;
-
-    static TGeoHMatrix m;
-    if (AliAlignObj::GetOrigGlobalMatrix(symname,m))
-      return &m;
-    else
-      return NULL;
+    return AliGeomManager::GetOrigGlobalMatrix(fVolumeId);
   }
 }
 
@@ -305,35 +300,7 @@ const TGeoHMatrix* AliCluster::GetTracking2LocalMatrix() const
 {
   // Get the matrix which is stored with the PN entries in TGeo.
   // The matrix makes the transformation from the tracking c.s. to
-  // global one.
-  TGeoPNEntry *pne = GetPNEntry();
-  if (!pne) return NULL;
-
-  const TGeoHMatrix *m = pne->GetMatrix();
-  if (!m)
-    AliError(Form("TGeoPNEntry (%s) contains no matrix !",pne->GetName()));
-
-  return m;
+  // the local one.
+  return AliGeomManager::GetTracking2LocalMatrix(fVolumeId);
 }
 
-//______________________________________________________________________________
-TGeoPNEntry* AliCluster::GetPNEntry() const
-{
-  // Get a pointer to the physical node entry
-  // corresponding to the alignable volume to
-  // which the cluster belongs
-
-  if (!gGeoManager || !gGeoManager->IsClosed()) {
-    AliError("Can't get the PN entry! gGeoManager doesn't exist or it is still opened!");
-    return NULL;
-  }
-
-  const char* symname = AliAlignObj::SymName(fVolumeId);
-  if (!symname) return NULL;
-
-  TGeoPNEntry* pne = gGeoManager->GetAlignableEntry(symname);
-  if (!pne)
-    AliError(Form("The symbolic volume name %s does not correspond to a physical entry!",
-                 symname));
-  return pne;
-}