opengate icon indicating copy to clipboard operation
opengate copied to clipboard

Add InitializeG4PreInitState step in Actors

Open alexis-pereda opened this issue 11 months ago • 0 comments

This commit adds the possibility for actors to execute code near the end of the Geant4 PreInit state, before entering in Idle, but after main simulation elements are initialised (physics, …).

This can be used for example to retrieve particle definitions at actor level.

C++ side: GateVActor exposes a new virtual function (void InitializeG4PreInitState()). Python side: the actor_engine provides initialize_preinit called in initialize of SimulationEngine which calls the C++ side function.

alexis-pereda avatar Mar 21 '25 16:03 alexis-pereda