84{
86 G4cout <<
"G4OpticalPhysics:: Add Optical Physics Processes" <<
G4endl;
87
89
90
91
92 G4ProcessManager* pManager =
94 if(!pManager)
95 {
97 ed << "Optical Photon without a Process Manager";
99 return;
100 }
101
102 G4OpAbsorption* absorption = new G4OpAbsorption();
103 if(params->GetProcessActivation("OpAbsorption"))
105
106 G4OpRayleigh* rayleigh = new G4OpRayleigh();
107 if(params->GetProcessActivation("OpRayleigh"))
109
110 G4OpMieHG* mie = new G4OpMieHG();
111 if(params->GetProcessActivation("OpMieHG"))
113
114 G4OpBoundaryProcess* boundary = new G4OpBoundaryProcess();
115 if(params->GetProcessActivation("OpBoundary"))
117
118 G4OpWLS* wls = new G4OpWLS();
119 if(params->GetProcessActivation("OpWLS"))
121
122 G4OpWLS2* wls2 = new G4OpWLS2();
123 if(params->GetProcessActivation("OpWLS2"))
125
126 G4Scintillation* scint = new G4Scintillation();
129
130 G4Cerenkov* cerenkov = new G4Cerenkov();
131
133 myParticleIterator->reset();
134
135 while((*myParticleIterator)())
136 {
137 G4ParticleDefinition* particle = myParticleIterator->value();
139
141 if(!pManager)
142 {
144 ed << "Particle " << particleName << "without a Process Manager";
146 ed);
147 return;
148 }
149
151 params->GetProcessActivation("Cerenkov"))
152 {
155 }
157 params->GetProcessActivation("Scintillation"))
158 {
162 }
164 params->GetProcessActivation("OpBoundary"))
165 {
167 }
168 }
169
174}
void G4Exception(const char *originOfException, const char *exceptionCode, G4ExceptionSeverity severity, const char *description)
std::ostringstream G4ExceptionDescription
G4GLOB_DLL std::ostream G4cout
G4bool IsApplicable(const G4ParticleDefinition &aParticleType) override
static G4LossTableManager * Instance()
G4EmSaturation * EmSaturation()
virtual G4bool IsApplicable(const G4ParticleDefinition &aParticleType) override
static G4OpticalPhoton * OpticalPhoton()
void PrintStatistics() const
G4ProcessManager * GetProcessManager() const
const G4String & GetParticleName() const
void SetProcessOrdering(G4VProcess *aProcess, G4ProcessVectorDoItIndex idDoIt, G4int ordDoIt=ordDefault)
G4int AddDiscreteProcess(G4VProcess *aProcess, G4int ord=ordDefault)
G4int AddProcess(G4VProcess *aProcess, G4int ordAtRestDoIt=ordInActive, G4int ordAlongSteptDoIt=ordInActive, G4int ordPostStepDoIt=ordInActive)
void SetProcessOrderingToLast(G4VProcess *aProcess, G4ProcessVectorDoItIndex idDoIt)
void AddSaturation(G4EmSaturation *sat)
G4bool IsApplicable(const G4ParticleDefinition &aParticleType) override
G4ParticleTable::G4PTblDicIterator * GetParticleIterator() const