Commit 734d14e0 authored by Jihee Kim's avatar Jihee Kim
Browse files

Merge branch 'master' of eicweb.phy.anl.gov:jihee.kim/NPDet

parents 9bf3fc73 8ef4967c
Pipeline #3033 passed with stage
in 46 seconds
......@@ -169,4 +169,9 @@
<D value="0.186" unit="g / cm3"/>
<fraction n="1.0" ref="SiliconCarbide"/>
</material>
<material name="PlasticScint">
<D type="density" unit="g/cm3" value="1.032"/>
<composite n="9" ref="C"/>
<composite n="10" ref="H"/>
</material>
</materials>
......@@ -1068,7 +1068,7 @@ Gradient [T/m] 0.0 0.0 -72.608 -66.180 40.737
</detector>
<!-- Define Zero Degree Calorimeter detector -->
<detector id="61" name="ZDC" type="ZeroDegreeCAL" readout="ZDCHits" vis="RedVis">
<detector id="61" name="ZDC" type="ZeroDegreeCAL" readout="ZDCHits" vis="GreenVis">
<position x="CrossingSlope*34.0*m" y="0.0" z="34.0*m"/>
<module name="diamond_module" side="40*mm" layers="16">
<slice name="Tungsten_slice" thickness="7*mm" number="0" material="TungstenDens24"/>
......
......@@ -14,6 +14,7 @@
#include "TMath.h"
#include "DDRec/Surface.h"
#include "DDRec/DetectorData.h"
#include "XML/Layering.h"
using namespace std;
using namespace dd4hep;
......@@ -33,6 +34,11 @@ static Ref_t createDetector(Detector& description, xml_h e, SensitiveDetector se
Assembly bar_assembly("bar_assembly");
PlacedVolume pv_bar;
xml_dim_t pos = x_det.position();
double x_pos = dd4hep::getAttrOrDefault(pos, _Unicode(x),0.0);
double y_pos = dd4hep::getAttrOrDefault(pos, _Unicode(y),0.0);
double z_pos = dd4hep::getAttrOrDefault(pos, _Unicode(z),0.0);
// Dimensions of RHICf/LHCf detector
double small_tower_length = 20*mm;
double large_tower_length = 40*mm;
......@@ -734,7 +740,7 @@ static Ref_t createDetector(Detector& description, xml_h e, SensitiveDetector se
l_tungsten_layer_Vol.setSensitiveDetector(sens);
////////////////////////////////////////////////////////////////////////////////////////////////////////
module_PV = assembly.placeVolume(module_assembly, Position(0.0,0.0,0.0));
module_PV = assembly.placeVolume(module_assembly, Position(x_pos,y_pos,z_pos));
module_PV.addPhysVolID("module", 0);
Volume motherVol = description.pickMotherVolume(det);
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment