Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
CEPCSW_OTE_development
Manage
Activity
Members
Labels
Plan
Issues
0
Issue boards
Milestones
Wiki
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
yudian2002@sjtu.edu.cn
CEPCSW_OTE_development
Commits
3df38359
Commit
3df38359
authored
3 years ago
by
FU Chengdong
Browse files
Options
Downloads
Patches
Plain Diff
change vis input and volume prefix
parent
019f1a98
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
Detector/DetCEPCv4/src/tracker/SIT_Simple_Pixel_geo.cpp
+17
-9
17 additions, 9 deletions
Detector/DetCEPCv4/src/tracker/SIT_Simple_Pixel_geo.cpp
with
17 additions
and
9 deletions
Detector/DetCEPCv4/src/tracker/SIT_Simple_Pixel_geo.cpp
+
17
−
9
View file @
3df38359
...
...
@@ -126,7 +126,11 @@ static dd4hep::Ref_t create_element(dd4hep::Detector& theDetector, xml_h e, dd4h
dd4hep
::
Material
sensitiveMat
=
theDetector
.
material
(
db
->
fetchString
(
"sensitive_mat"
));
dd4hep
::
Material
supportMat
=
theDetector
.
material
(
db
->
fetchString
(
"support_mat"
));
db
=
XMLHandlerDB
(
x_det
.
child
(
_Unicode
(
display
)
)
)
;
std
::
string
ladderVis
=
db
->
fetchString
(
"ladder"
);
std
::
string
supportVis
=
db
->
fetchString
(
"support"
);
std
::
string
sensEnvVis
=
db
->
fetchString
(
"sens_env"
);
std
::
string
sensVis
=
db
->
fetchString
(
"sens"
);
// // // setup the encoder
// // UTIL::BitField64 encoder( LCTrackerCellID::encoding_string() ) ;
...
...
@@ -286,7 +290,7 @@ static dd4hep::Ref_t create_element(dd4hep::Detector& theDetector, xml_h e, dd4h
layer_geom
.
ladder_width
/
2.0
,
layer_geom
.
half_z
);
dd4hep
::
Volume
sitLadderLogical
(
dd4hep
::
_toString
(
layer_id
,
"
SIT
_LadderLogical_%02d"
),
sitLadderSolid
,
air
)
;
dd4hep
::
Volume
sitLadderLogical
(
name
+
dd4hep
::
_toString
(
layer_id
,
"_LadderLogical_%02d"
),
sitLadderSolid
,
air
)
;
// now create an envelope volume to represent the sensitive area, which will be divided up into individual sensors
...
...
@@ -295,7 +299,7 @@ static dd4hep::Ref_t create_element(dd4hep::Detector& theDetector, xml_h e, dd4h
layer_geom
.
half_z
);
//fixme: material ??? Volume sitSenEnvelopeLogical( _toString( layer_id,"SIT_SenEnvelopeLogical_%02d"), sitSenEnvelopeSolid, sensitiveMat ) ;
dd4hep
::
Volume
sitSenEnvelopeLogical
(
dd4hep
::
_toString
(
layer_id
,
"
SIT
_SenEnvelopeLogical_%02d"
),
dd4hep
::
Volume
sitSenEnvelopeLogical
(
name
+
dd4hep
::
_toString
(
layer_id
,
"_SenEnvelopeLogical_%02d"
),
sitSenEnvelopeSolid
,
air
)
;
// create the sensor volumes and place them in the senstive envelope volume
...
...
@@ -304,7 +308,7 @@ static dd4hep::Ref_t create_element(dd4hep::Detector& theDetector, xml_h e, dd4h
layer_geom
.
ladder_width
/
2.0
,
(
layer_geom
.
sensor_length
/
2.0
)
-
1.e-06
*
dd4hep
::
mm
);
// added tolerance to avoid false overlap detection
dd4hep
::
Volume
sitSenLogical
(
dd4hep
::
_toString
(
layer_id
,
"
SIT
_SenLogical_%02d"
),
sitSenSolid
,
sensitiveMat
)
;
dd4hep
::
Volume
sitSenLogical
(
name
+
dd4hep
::
_toString
(
layer_id
,
"_SenLogical_%02d"
),
sitSenSolid
,
sensitiveMat
)
;
sitSenLogical
.
setSensitiveDetector
(
sens
);
...
...
@@ -371,10 +375,10 @@ static dd4hep::Ref_t create_element(dd4hep::Detector& theDetector, xml_h e, dd4h
pvV
[
isensor
]
=
pv
;
}
sit
.
setVisAttributes
(
theDetector
,
"SeeThrough"
,
sitLadderLogical
)
;
sit
.
setVisAttributes
(
theDetector
,
"SeeThrough"
,
sitSenEnvelopeLogical
)
;
sit
.
setVisAttributes
(
theDetector
,
ladderVis
,
sitLadderLogical
)
;
sit
.
setVisAttributes
(
theDetector
,
sensEnvVis
,
sitSenEnvelopeLogical
)
;
sit
.
setVisAttributes
(
theDetector
,
"Blue
Vis
"
,
sitSenLogical
)
;
sit
.
setVisAttributes
(
theDetector
,
sens
Vis
,
sitSenLogical
)
;
// encoder.reset() ; // reset to 0
...
...
@@ -398,10 +402,10 @@ static dd4hep::Ref_t create_element(dd4hep::Detector& theDetector, xml_h e, dd4h
layer_geom
.
ladder_width
/
2.0
,
layer_geom
.
half_z
);
Volume
sitSupLogical
(
_toString
(
layer_id
,
"
SIT
_SupLogical_%02d"
),
sitSupSolid
,
supportMat
)
;
Volume
sitSupLogical
(
name
+
_toString
(
layer_id
,
"_SupLogical_%02d"
),
sitSupSolid
,
supportMat
)
;
sit
.
setVisAttributes
(
theDetector
,
"Red
Vis
"
,
sitSupLogical
)
;
sit
.
setVisAttributes
(
theDetector
,
support
Vis
,
sitSupLogical
)
;
pv
=
sitLadderLogical
.
placeVolume
(
sitSupLogical
,
Transform3D
(
RotationY
(
0.
),
...
...
@@ -472,6 +476,10 @@ static dd4hep::Ref_t create_element(dd4hep::Detector& theDetector, xml_h e, dd4h
//--------------------------------------
sit
.
setVisAttributes
(
theDetector
,
x_det
.
visStr
(),
envelope
);
if
(
x_det
.
hasAttr
(
_U
(
combineHits
))
)
{
sit
.
setCombineHits
(
x_det
.
attr
<
bool
>
(
_U
(
combineHits
)),
sens
);
}
return
sit
;
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment