|
Celeritas 0.7.0-dev.194+develop.0df4cab59
|
Offload tracks to Celeritas via G4VFastSimulationModel interface. More...
#include <FastSimulationModel.hh>

Public Member Functions | |
| FastSimulationModel (G4Envelope *region) | |
| Construct using the FastSimulationIntegration for all regions. | |
| FastSimulationModel (G4String const &name, SharedParams const *params, LocalTransporter *local) | |
| Construct without attaching to a region. | |
| FastSimulationModel (G4String const &name, G4Envelope *region, SharedParams const *params, LocalTransporter *local) | |
| Construct and build a fast sim manager for the given region. | |
| G4bool | IsApplicable (G4ParticleDefinition const &particle) final |
Return true if this model can be applied to the input G4ParticleDefinition . | |
| G4bool | ModelTrigger (G4FastTrack const &track) final |
Return true if model can be applied given dynamic particle state in G4FastTrack . | |
| void | DoIt (G4FastTrack const &track, G4FastStep &step) final |
| Offload the incoming track to Celeritas. | |
| void | Flush () |
| Complete processing of any buffered tracks. | |
Offload tracks to Celeritas via G4VFastSimulationModel interface.
This class must be constructed locally on each worker thread/task, typically within the application's concrete implementation of G4VUserDetectorConstruction::ConstructSDandField().
Note that the argument G4Envelope is a type alias to G4Region.
| celeritas::FastSimulationModel::FastSimulationModel | ( | G4String const & | name, |
| G4Envelope * | region, | ||
| SharedParams const * | params, | ||
| LocalTransporter * | local | ||
| ) |
Construct and build a fast sim manager for the given region.
The envelope cannot be nullptr as this will cause a segmentation fault in the G4VFastSimulation base class constructor.
| void celeritas::FastSimulationModel::Flush | ( | ) |
Complete processing of any buffered tracks.
Note that this is called in G4EventManager::DoProcessing(G4Event*) by G4GlobalFastSimulationManager after the main tracking loop has completed. That is done to allow for models that may add "onload" particles back to Geant4.
|
final |
Return true if this model can be applied to the input G4ParticleDefinition .
Purely checks if the particle is one that Celeritas has been setup to handle.
|
final |
Return true if model can be applied given dynamic particle state in G4FastTrack .
Always returns true because we only make the decision to offload to Celeritas based on geometric region and particle type.