Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
D
DD4hep
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
cepc
externals
mirroring
DD4hep
Commits
c589be1b
Commit
c589be1b
authored
9 years ago
by
Frank Gaede
Browse files
Options
Downloads
Patches
Plain Diff
only set gentstat=- if particle created in simulationwq
parent
d1a5da11
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
DDG4/lcio/Geant4Output2LCIO.cpp
+3
-1
3 additions, 1 deletion
DDG4/lcio/Geant4Output2LCIO.cpp
with
3 additions
and
1 deletion
DDG4/lcio/Geant4Output2LCIO.cpp
+
3
−
1
View file @
c589be1b
...
...
@@ -190,6 +190,7 @@ lcio::LCCollectionVec* Geant4Output2LCIO::saveParticles(Geant4ParticleMap* parti
int
id
=
(
*
i
).
first
;
const
Geant4ParticleHandle
p
=
(
*
i
).
second
;
PropertyMask
mask
(
p
->
status
);
// std::cout << " ********** mcp status : 0x" << std::hex << p->status << ", mask.isSet(G4PARTICLE_GEN_STABLE) x" << std::dec << mask.isSet(G4PARTICLE_GEN_STABLE) <<std::endl ;
const
G4ParticleDefinition
*
def
=
p
.
definition
();
MCParticleImpl
*
q
=
new
lcio
::
MCParticleImpl
();
q
->
setPDG
(
p
->
pdgID
);
...
...
@@ -212,6 +213,7 @@ lcio::LCCollectionVec* Geant4Output2LCIO::saveParticles(Geant4ParticleMap* parti
if
(
mask
.
isSet
(
G4PARTICLE_GEN_STABLE
)
)
q
->
setGeneratorStatus
(
1
);
else
if
(
mask
.
isSet
(
G4PARTICLE_GEN_DECAYED
)
)
q
->
setGeneratorStatus
(
2
);
else
if
(
mask
.
isSet
(
G4PARTICLE_GEN_DOCUMENTATION
)
)
q
->
setGeneratorStatus
(
3
);
// std::cout << " ********** mcp genstatus : " << q->getGeneratorStatus() << std::endl ;
// Set simulation status
q
->
setCreatedInSimulation
(
mask
.
isSet
(
G4PARTICLE_SIM_CREATED
)
);
...
...
@@ -224,7 +226,7 @@ lcio::LCCollectionVec* Geant4Output2LCIO::saveParticles(Geant4ParticleMap* parti
q
->
setOverlay
(
false
);
//fg: if simstatus !=0 we have to set the generator status to 0:
if
(
q
->
getSimulatorStatus
()
!=
0
)
if
(
q
->
isCreatedInSimulation
()
)
q
->
setGeneratorStatus
(
0
)
;
q
->
setSpin
(
p
->
spin
);
...
...
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