Import Geant4 10.7.0 source tree

This commit is contained in:
Gabriele Cosmo
2020-12-04 12:30:43 +01:00
parent 67ba86d073
commit dab42d2018
3770 changed files with 226369 additions and 286486 deletions
+2 -1
View File
@@ -8,7 +8,7 @@ ifndef G4INSTALL
G4INSTALL = ../../..
endif
GLOBLIBS = libG4run.lib libG4event.lib
GLOBLIBS = libG4tasking.lib libG4run.lib libG4event.lib
GLOBLIBS += libG4tracking.lib libG4processes.lib libG4digits_hits.lib
GLOBLIBS += libG4track.lib libG4particles.lib libG4geometry.lib
GLOBLIBS += libG4materials.lib libG4graphics_reps.lib
@@ -32,6 +32,7 @@ CPPFLAGS += -I$(G4BASE)/global/HEPRandom/include
CPPFLAGS += -I$(G4BASE)/processes/management/include
CPPFLAGS += -I$(G4BASE)/particles/management/include
CPPFLAGS += -I$(G4BASE)/run/include
CPPFLAGS += -I$(G4BASE)/tasking/include
CPPFLAGS += -I$(G4BASE)/event/include
CPPFLAGS += -I$(G4BASE)/digits_hits/utils/include
CPPFLAGS += -I$(G4BASE)/digits_hits/hits/include
+42 -17
View File
@@ -19,6 +19,31 @@ committal in the CVS repository !
History file for visualization/modeling
---------------------------------------
20 October 2020 Jonathan Madsen (modeling-V10-06-05)
- Implemented G4RunManagerFactory::GetMasterRunManager()
18 September 2020 John Allison (modeling-V10-06-04)
- Part of vis-V10-06-07.
- G4PhysicalVlumeModel.cc:
o Pick up default vis attributes.
o Improve operator<< G4PhysicalVolumeModel::G4PhysicalVolumeNodeID
04 August 2020. John Allison (modeling-V10-06-03)
- G4PhysicalVolumeModel:
o Introduce G4PhysicalVolumeModel::G4PhysicalVolumeNodeID::operator!= and ==.
o G4PhysicalVolumeModel::G4PhysicalVolumeNodeID:
. Change default for flag "drawn" to false. It is set to true in
G4PhysicalVolumeModel::DescribeAndDescend for full path:
fFullPVPath.back().SetDrawn(thisToBeDrawn);
and for drawn path:
fDrawnPVPath.push_back
(G4PhysicalVolumeNodeID
(fpCurrentPV,copyNo,fCurrentDepth,*fpCurrentTransform,thisToBeDrawn));
for volumes that are drawn.
- G4PhysicalVolumesSearchScene.cc:
o G4PhysicalVolumesSearchScene::ProcessVolume:
. Make sure base path is also marked as "not drawn".
07 April 2020. John Allison (modeling-V10-06-02)
* G4BoundingExtentScene.cc:
* Minor tidy: Use G4VisExtent::GetNullExtent (rather than
@@ -57,7 +82,7 @@ History file for visualization/modeling
- Rationalise trajectory line drawing.
o There is a flag - DrawLine - which controls whether a trajectory
should be drawn at all:
/vis/modeling/trajectories/drawByCharge-0/default/setDrawLine
/vis/modeling/trajectories/drawByCharge-0/default/setDrawLine
but there is also a lineVisible command, which should do the same.:
/vis/modeling/trajectories/drawByCharge-0/default/setLineVisible
This is fixed in this tag.
@@ -193,7 +218,7 @@ History file for visualization/modeling
24 October 2018 John Allison (modeling-V10-04-15)
- G4TouchableUtils:
o Remove FindGlobalTransform, introduce FindTouchableProperties. The
global transform is in properties.fTouchableGlobalTransform.
global transform is in properties.fTouchableGlobalTransform.
- Add G4TouchablePropertiesScene.
- Delete G4TouchableDumpScene, G4TouchableGlobalTransformScene.
- sources.cmake: Modify for above additions and deletions.
@@ -364,7 +389,7 @@ History file for visualization/modeling
12th September 2016 John Allison (modeling-V10-02-12)
- G4ModelingParameters.cc:
o Changed output of
o Changed output of
std::ostream& operator <<
(std::ostream& os, const G4ModelingParameters::PVNameCopyNoPath& path)
to correspond to arguments of /vis/set/touchable.
@@ -440,7 +465,7 @@ History file for visualization/modeling
Added G4TrajectoryTouchedVolumeFilterFactory.
o Added new files and classes:
G4TrajectoryDrawByTouchedVolume.hh/cc
G4TrajectoryTouchedVolumeFilter.hh/cc
G4TrajectoryTouchedVolumeFilter.hh/cc
o G4ModelColourMap.hh: Added new access function:
const std::map<T, G4Colour>& GetBasicMap() const;
to allow access to the T objects (which are G4String objects,
@@ -473,7 +498,7 @@ History file for visualization/modeling
o Replaced an assignment by a reference.
19th May 2015 Laurent Garnier (modeling-V10-01-02)
- G4PhysicalVolumeSearchScene: Optimize ProcessVolume() by
- G4PhysicalVolumeSearchScene: Optimize ProcessVolume() by
o setting variables only if needed
o comparing string lenght before comparing all string
@@ -651,7 +676,7 @@ History file for visualization/modeling
11th October 2012 John Allison (modeling-V09-05-21)
- G4PhysicalVolumeModel and G4ModelingParameters:
o Tidying.
o Tidying.
9th October 2012 John Allison (modeling-V09-05-20)
- G4PhysicalVolumeModel and G4ModelingParameters:
@@ -694,7 +719,7 @@ History file for visualization/modeling
volume.
- G4PhysicalVolumeSearchScene:
o Added GetFoundFullPVPath.
1st October 2012 John Allison (modeling-V09-05-13)
- G4PhysicalVolumeModel:: GetAttDefs: Small bug fix.
- G4TrajectoriesModel:
@@ -970,7 +995,7 @@ History file for visualization/modeling
13th September 2006 John Allison
- G4ModelingParameters: Improved setting and access to explode factor.
- G4PhysicalVolumeModel.cc:
- G4PhysicalVolumeModel.cc:
o Implemented explode factor(radial move) feature for top level drawn
volumes.
- G4TrajectoriesModel.cc: Improved debug checking and printing of G4Atts.
@@ -1000,7 +1025,7 @@ History file for visualization/modeling
16th August 2006 John Allison (modeling-V08-01-03)
- G4TrajectoryDrawerUtils.cc: Improved robustness of time slicing.
- G4ModelCommandsT.hh: In class G4ModelCmdSetTimeSliceInterval:
- G4ModelCommandsT.hh: In class G4ModelCmdSetTimeSliceInterval:
cmd->SetUnitCategory("Time").
- G4TrajectoriesModel.cc: Improved debug statement.
@@ -1061,17 +1086,17 @@ History file for visualization/modeling
- Improved protection for null models and parameters.
2nd May 2006 Jane Tinslay
- Add context to trajectory drawers. Intended to replace imode.
Allows to configure default drawing style for lines, step and
auxiliary points. For example, colours, visibility, point sizes,
- Add context to trajectory drawers. Intended to replace imode.
Allows to configure default drawing style for lines, step and
auxiliary points. For example, colours, visibility, point sizes,
fill styles..
- Add generic drawer, G4TrajectoryGenericDrawer. Draws all trajectories
- Add generic drawer, G4TrajectoryGenericDrawer. Draws all trajectories
in the same style, based on its default context.
- Update generic commands
- Add verbose to drawers
21st April 2006 Jane Tinslay (modeling-V08-00-07)
- Get rid of some warning messages from G4ModelCommandsT
- Get rid of some warning messages from G4ModelCommandsT
when compiling on Linux
- Add Print method to G4VModelFactory
@@ -1084,7 +1109,7 @@ History file for visualization/modeling
28th March 2006 Jane Tinslay (jst28032006)
- Add G4TrajectoryFilterFactories and G4TrajectoryParticleFilter
for trajectory filtering.
for trajectory filtering.
- Add more generic commands to G4ModelCommandsT
28th March 2006 John Allison (modeling-V08-00-05)
@@ -1099,9 +1124,9 @@ History file for visualization/modeling
dynamic cast instead).
24th March 2006 Jane Tinslay (jst24032006)
- Add G4bool visibility parameter to trajectory draw
- Add G4bool visibility parameter to trajectory draw
models "Draw" method.
16th March 2006 Jane Tinslay (jst16032006)
- Template commands and colour map used in trajectory models
- Introduce G4TrajectoryDrawByOriginVolume
@@ -95,7 +95,7 @@ public: // With description
G4int iCopyNo = 0,
G4int depth = 0,
const G4Transform3D& transform = G4Transform3D(),
G4bool drawn = true):
G4bool drawn = false):
fpPV(pPV),
fCopyNo(iCopyNo),
fNonCulledDepth(depth),
@@ -108,6 +108,10 @@ public: // With description
G4bool GetDrawn() const {return fDrawn;}
void SetDrawn(G4bool drawn) {fDrawn = drawn;}
G4bool operator< (const G4PhysicalVolumeNodeID& right) const;
G4bool operator!= (const G4PhysicalVolumeNodeID& right) const;
G4bool operator== (const G4PhysicalVolumeNodeID& right) const {
return !operator!= (right);
}
private:
G4VPhysicalVolume* fpPV;
G4int fCopyNo;
@@ -114,6 +114,7 @@ geant4_define_module(NAME G4modeling
G4detutils
G4digits
G4run
G4tasking
G4event
G4geomBoolean
G4geometrymng
@@ -133,6 +134,7 @@ geant4_define_module(NAME G4modeling
GLOBAL_DEPENDENCIES
G4digits_hits
G4run
G4tasking
G4event
G4geometry
G4global
@@ -409,7 +409,11 @@ void G4PhysicalVolumeModel::DescribeAndDescend
// If the volume does not have any vis attributes, create it.
G4VisAttributes* tempVisAtts = nullptr;
if (!pVisAttribs) {
tempVisAtts = new G4VisAttributes; // Default value.
if (fpMP->GetDefaultVisAttributes()) {
tempVisAtts = new G4VisAttributes(*fpMP->GetDefaultVisAttributes());
} else {
tempVisAtts = new G4VisAttributes;
}
// The user may request /vis/viewer/set/colourByDensity.
if (fpMP->GetCBDAlgorithmNumber() == 1) {
// Algorithm 1: 3 parameters: Simple rainbow mapping.
@@ -973,6 +977,17 @@ G4bool G4PhysicalVolumeModel::G4PhysicalVolumeNodeID::operator<
return false;
}
G4bool G4PhysicalVolumeModel::G4PhysicalVolumeNodeID::operator!=
(const G4PhysicalVolumeModel::G4PhysicalVolumeNodeID& right) const
{
if (fpPV != right.fpPV ||
fCopyNo != right.fCopyNo ||
fNonCulledDepth != right.fNonCulledDepth ||
fTransform != right.fTransform ||
fDrawn != right.fDrawn) return true;
return false;
}
std::ostream& operator<<
(std::ostream& os, const G4PhysicalVolumeModel::G4PhysicalVolumeNodeID& node)
{
@@ -987,7 +1002,7 @@ std::ostream& operator<<
// if (!node.GetDrawn()) os << "not ";
// os << "drawn)";
} else {
os << " (Null node)";
os << " (Null PV node)";
}
return os;
}
@@ -56,15 +56,17 @@ void G4PhysicalVolumesSearchScene::ProcessVolume (const G4VSolid&)
if (fMatcher.Match(name)) {
if ((fRequiredCopyNo < 0 || // I.e., ignore negative request
fRequiredCopyNo == copyNo)) {
auto path = fpSearchVolumesModel->GetFullPVPath();
path.pop_back(); // Base node is one up from found node
auto basePath = fpSearchVolumesModel->GetFullPVPath();
basePath.pop_back(); // Base node is one up from found node
// Mark base path nodes as not drawn
for (auto& node: basePath) node.SetDrawn(false);
fFindings.push_back
(Findings
(fpSearchVolumesModel->GetTopPhysicalVolume(),
pCurrentPV,
copyNo,
fpSearchVolumesModel->GetCurrentDepth(),
path,
basePath,
*fpCurrentObjectTransformation));
}
}
@@ -34,9 +34,7 @@
#include "G4ModelingParameters.hh"
#include "G4VGraphicsScene.hh"
#include "G4RunManager.hh"
#ifdef G4MULTITHREADED
#include "G4MTRunManager.hh"
#endif
#include "G4RunManagerFactory.hh"
#include "G4Run.hh"
#include "G4Event.hh"
#include "G4AttDefStore.hh"
@@ -62,15 +60,14 @@ void G4TrajectoriesModelDebugG4AttValues(const G4VTrajectory*);
void G4TrajectoriesModel::DescribeYourselfTo (G4VGraphicsScene& sceneHandler)
{
G4RunManager* runManager = G4RunManager::GetRunManager();
#ifdef G4MULTITHREADED
if(G4Threading::IsMultithreadedApplication())
{ runManager = G4MTRunManager::GetMasterRunManager(); }
#endif
const G4Run* currentRun = runManager->GetCurrentRun();
if (currentRun) {
G4RunManager* runManager = G4RunManagerFactory::GetMasterRunManager();
const G4Run* currentRun = runManager->GetCurrentRun();
if(currentRun)
{
fRunID = currentRun->GetRunID();
} else {
}
else
{
fRunID = -1;
return;
}