Commit in slicPandora on MAIN
examples/sidloi3_pandora.xml+4-41.1 -> 1.2
include/DetectorGeometry.h+2-11.7 -> 1.8
src/CalorimeterHitProcessor.cpp+3-51.4 -> 1.5
   /DetectorGeometry.cpp+26-111.7 -> 1.8
+35-21
4 modified files
add digital setting to slicPandora

slicPandora/examples
sidloi3_pandora.xml 1.1 -> 1.2
diff -u -r1.1 -r1.2
--- sidloi3_pandora.xml	16 Mar 2010 17:15:06 -0000	1.1
+++ sidloi3_pandora.xml	22 Mar 2010 21:51:31 -0000	1.2
@@ -1,7 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <pandoraSetup>
   <calorimeters>
-    <calorimeter type="EM_ENDCAP" innerR="200.0" innerZ="1657.0" innerPhi="0.0" innerSymmetryOrder="12.0" outerR="1264.5" outerZ="1795.5" outerPhi="0.0" outerSymmetryOrder="12.0" collection="EcalEndcapHits" cellSizeU="3.5" cellSizeV="3.5">
+    <calorimeter type="EM_ENDCAP" innerR="200.0" innerZ="1657.0" innerPhi="0.0" innerSymmetryOrder="12.0" outerR="1264.5" outerZ="1795.5" outerPhi="0.0" outerSymmetryOrder="12.0" collection="EcalEndcapHits" cellSizeU="3.5" cellSizeV="3.5" digital="false">
       <id>
         <field name="system" length="6" start="0" signed="false" />
         <field name="barrel" length="3" start="6" signed="false" />
@@ -45,7 +45,7 @@
         <layer distanceToIp="1794.66" radLen="0.75664785" intLen="0.04139102" cellThickness="0.32" samplingFraction="0.0086669" />
       </layers>
     </calorimeter>
-    <calorimeter type="HAD_BARREL" innerR="1419.0" innerZ="-3018.0" innerPhi="0.0" innerSymmetryOrder="12.0" outerR="2494.9999999999995" outerZ="3018.0" outerPhi="0.0" outerSymmetryOrder="12.0" collection="HcalBarrelHits" cellSizeU="10.0" cellSizeV="10.0">
+    <calorimeter type="HAD_BARREL" innerR="1419.0" innerZ="-3018.0" innerPhi="0.0" innerSymmetryOrder="12.0" outerR="2494.9999999999995" outerZ="3018.0" outerPhi="0.0" outerSymmetryOrder="12.0" collection="HcalBarrelHits" cellSizeU="10.0" cellSizeV="10.0" digital="true">
       <id>
         <field name="system" length="6" start="0" signed="false" />
         <field name="barrel" length="3" start="6" signed="false" />
@@ -98,7 +98,7 @@
         <layer distanceToIp="2488.7" radLen="1.62827702" intLen="0.2305608" cellThickness="1.2" samplingFraction="8.6503" />
       </layers>
     </calorimeter>
-    <calorimeter type="HAD_ENDCAP" innerR="200.0" innerZ="1805.0" innerPhi="0.0" innerSymmetryOrder="12.0" outerR="1469.0" outerZ="3015.5" outerPhi="0.0" outerSymmetryOrder="12.0" collection="HcalEndcapHits" cellSizeU="10.0" cellSizeV="10.0">
+    <calorimeter type="HAD_ENDCAP" innerR="200.0" innerZ="1805.0" innerPhi="0.0" innerSymmetryOrder="12.0" outerR="1469.0" outerZ="3015.5" outerPhi="0.0" outerSymmetryOrder="12.0" collection="HcalEndcapHits" cellSizeU="10.0" cellSizeV="10.0" digital="true">
       <id>
         <field name="system" length="6" start="0" signed="false" />
         <field name="barrel" length="3" start="6" signed="false" />
@@ -156,7 +156,7 @@
         <layer distanceToIp="3009.2" radLen="1.62827702" intLen="0.2305608" cellThickness="1.2" samplingFraction="7.5778" />
       </layers>
     </calorimeter>
-    <calorimeter type="EM_BARREL" innerR="1265.0" innerZ="-1765.0" innerPhi="0.0" innerSymmetryOrder="12.0" outerR="1403.5" outerZ="1765.0" outerPhi="0.0" outerSymmetryOrder="12.0" collection="EcalBarrelHits" cellSizeU="3.5" cellSizeV="3.5">
+    <calorimeter type="EM_BARREL" innerR="1265.0" innerZ="-1765.0" innerPhi="0.0" innerSymmetryOrder="12.0" outerR="1403.5" outerZ="1765.0" outerPhi="0.0" outerSymmetryOrder="12.0" collection="EcalBarrelHits" cellSizeU="3.5" cellSizeV="3.5" digital="false">
       <id>
         <field name="system" length="6" start="0" signed="false" />
         <field name="barrel" length="3" start="6" signed="false" />

slicPandora/include
DetectorGeometry.h 1.7 -> 1.8
diff -u -r1.7 -r1.8
--- DetectorGeometry.h	9 Mar 2010 20:13:42 -0000	1.7
+++ DetectorGeometry.h	22 Mar 2010 21:51:32 -0000	1.8
@@ -1,4 +1,4 @@
-// $Id: DetectorGeometry.h,v 1.7 2010/03/09 20:13:42 jeremy Exp $
+// $Id: DetectorGeometry.h,v 1.8 2010/03/22 21:51:32 jeremy Exp $
 
 #ifndef DetectorGeometry_h
 #define DetectorGeometry_h 1
@@ -39,6 +39,7 @@
         pandora::InputHitType m_inputHitType;
         pandora::InputDetectorRegion m_inputDetectorRegion;
         std::vector<pandora::CartesianVector*> m_normalVectors;
+        pandora::InputBool m_isDigital;
         // TODO: Add isDigital setting here.
     };
 

slicPandora/src
CalorimeterHitProcessor.cpp 1.4 -> 1.5
diff -u -r1.4 -r1.5
--- CalorimeterHitProcessor.cpp	11 Mar 2010 19:04:24 -0000	1.4
+++ CalorimeterHitProcessor.cpp	22 Mar 2010 21:51:32 -0000	1.5
@@ -1,4 +1,4 @@
-// $Id: CalorimeterHitProcessor.cpp,v 1.4 2010/03/11 19:04:24 jeremy Exp $
+// $Id: CalorimeterHitProcessor.cpp,v 1.5 2010/03/22 21:51:32 jeremy Exp $
 
 #include "CalorimeterHitProcessor.h"
 
@@ -112,10 +112,8 @@
     // TODO: Calculate MIP equivalent energy.  (How?)
     params.m_mipEquivalentEnergy = 1.0; 
 
-    // Digital calorimeter.
-    // FIXME: Hard-coded to false.  
-    // TODO: Read digital setting from the sampling fraction conditions file for the collection (Ron).
-    params.m_isDigital = false; 
+    // Digital calorimeter setting.
+    params.m_isDigital = xsubdet->m_isDigital; 
 
     // Layer number.
     params.m_layer = layer;

slicPandora/src
DetectorGeometry.cpp 1.7 -> 1.8
diff -u -r1.7 -r1.8
--- DetectorGeometry.cpp	11 Mar 2010 22:18:43 -0000	1.7
+++ DetectorGeometry.cpp	22 Mar 2010 21:51:32 -0000	1.8
@@ -204,6 +204,18 @@
                 phi += dphi;
             }        
         }
+        
+        // Setting for digital or analog calorimeter.
+        std::string isDigital = "false";
+        calElem->QueryValueAttribute("digital", &isDigital);
+        if (isDigital == "true")
+        {
+            extras.m_isDigital = true;
+        }
+        else
+        {
+            extras.m_isDigital = false;
+        }        
 
         // Insert the extra subdetector information into the data map.
         std::string subdetTypeStr(subdetType);
@@ -299,16 +311,16 @@
 void DetectorGeometry::printOut(const char* subdetType, PandoraApi::GeometryParameters::SubDetectorParameters* subdet)
 {
     // Parameters.
-    printf("Subdetector: %s\n",            subdetType);
-    printf("    innerRCoordinate: %f\n",   subdet->m_innerRCoordinate.Get());
-    printf("    innerZCoordinate: %f\n",   subdet->m_innerZCoordinate.Get());
-    printf("    innerPhiCoordinate: %f\n", subdet->m_innerPhiCoordinate.Get());
-    printf("    innerSymmetryOrder: %i\n", subdet->m_innerSymmetryOrder.Get());
-    printf("    outerRCoordinate: %f\n",   subdet->m_outerRCoordinate.Get());
-    printf("    outerZCoordinate: %f\n",   subdet->m_outerZCoordinate.Get());
-    printf("    outerPhiCoordinate: %f\n", subdet->m_outerPhiCoordinate.Get());
-    printf("    outerSymmetryOrder: %i\n", subdet->m_outerSymmetryOrder.Get());
-    printf("    nLayers: %i\n",            subdet->m_nLayers.Get());
+    std::cout << "Subdetector: %s\n" << subdetType << std::endl;
+    std::cout << "    innerRCoordinate: " << subdet->m_innerRCoordinate.Get() << std::endl;
+    std::cout << "    innerZCoordinate: " << subdet->m_innerZCoordinate.Get() << std::endl;
+    std::cout << "    innerPhiCoordinate: " << subdet->m_innerPhiCoordinate.Get() << std::endl;
+    std::cout << "    innerSymmetryOrder: " << subdet->m_innerSymmetryOrder.Get() << std::endl;
+    std::cout << "    outerRCoordinate: " << subdet->m_outerRCoordinate.Get() << std::endl;
+    std::cout << "    outerZCoordinate: " << subdet->m_outerZCoordinate.Get() << std::endl;
+    std::cout << "    outerPhiCoordinate: " << subdet->m_outerPhiCoordinate.Get() << std::endl;
+    std::cout << "    outerSymmetryOrder: " << subdet->m_outerSymmetryOrder.Get() << std::endl;
+    std::cout << "    nLayers: " << subdet->m_nLayers.Get()  << std::endl;
 
     // Layers.
     int cntr = 1;
@@ -317,12 +329,15 @@
          iter++ )
     {
         PandoraApi::GeometryParameters::LayerParameters lp = (*iter);
-        printf("        layer %i - dToIp=%f, radLen=%f, intLen=%f\n", cntr, lp.m_closestDistanceToIp.Get(), lp.m_nRadiationLengths.Get(), lp.m_nInteractionLengths.Get());
+        std::cout << "        layer " << cntr << " - dToIp=" << lp.m_closestDistanceToIp.Get() << ", radLen=" << lp.m_nRadiationLengths.Get() << ", intLen=" << lp.m_nInteractionLengths.Get() << std::endl;
         ++cntr;             
     }
 
     // Extras.
     const DetectorGeometry::ExtraSubDetectorParameters& extras = subdetExtras[subdetType];
+
+    std::cout << "    digital=" << extras.m_isDigital.Get() << std::endl;
+
     IDDecoder* decoder = extras.m_decoder;
     std::cout << "    ID Fields (name, start, length, signed) - " << decoder->getFieldCount() << std::endl;           
     for (int i=0, j=decoder->getFieldCount(); i<j; i++)
CVSspam 0.2.8