Import Geant4 10.5.0.beta source tree

This commit is contained in:
Gabriele Cosmo
2018-06-29 10:58:11 +02:00
parent fe81a77428
commit 6aa23be517
1581 changed files with 124288 additions and 83758 deletions
+5 -1
View File
@@ -7,11 +7,15 @@
#
# Generated on : 24/9/2010
#
# $Id: CMakeLists.txt 66376 2012-12-18 09:42:59Z gcosmo $
# $Id: CMakeLists.txt 108187 2018-01-18 16:03:33Z gcosmo $
#
#------------------------------------------------------------------------------
include(Geant4MacroLibraryTargets)
# Add allocation export symbol for the graphics_reps category
add_definitions(-DG4GREPS_ALLOC_EXPORT)
if(GEANT4_BUILD_GRANULAR_LIBS)
GEANT4_GRANULAR_LIBRARY_TARGET(COMPONENT sources.cmake)
else()
+2 -1
View File
@@ -1,4 +1,4 @@
# $Id: GNUmakefile 66376 2012-12-18 09:42:59Z gcosmo $
# $Id: GNUmakefile 108190 2018-01-18 16:08:46Z gcosmo $
# --------------------------------------------------------------
# GNUmakefile for graphics_reps library. John Allison, 19/7/96.
# --------------------------------------------------------------
@@ -13,6 +13,7 @@ GLOBLIBS = libG4intercoms.lib libG4global.lib
include $(G4INSTALL)/config/architecture.gmk
CPPFLAGS += -DG4GREPS_ALLOC_EXPORT
CPPFLAGS += -I$(G4BASE)/global/management/include
CPPFLAGS += -I$(G4BASE)/global/HEPGeometry/include
CPPFLAGS += -I$(G4BASE)/intercoms/include
+30 -1
View File
@@ -1,4 +1,4 @@
$Id: History 106385 2017-10-09 09:36:33Z gcosmo $
$Id: History 110390 2018-05-22 08:28:07Z gcosmo $
-------------------------------------------------------------------
=========================================================
@@ -20,6 +20,35 @@ committal in the CVS repository !
History file for graphics_reps category
---------------------------------------
22 May 2018 Gabriele Cosmo (greps-V10-04-05)
- Disabled deprecated static data member G4VisAttributes::Invisible for
Windows systems.
24 April 2018 John Allison (greps-V10-04-04)
- Co-works vis-V10-04-04.
- G4VisAttributes: Cosmetic improvements.
23 April 2018 John Allison (greps-V10-04-03)
- Co-works vis-V10-04-04.
- Replaced DBL_MAX by G4VisAttributes::veryLargeTime = 1.e100*CLHEP::ns,
about 1.e75 billion years!! The problem is that DBL_MAX (1.79769e+308)
is dimensionless, so we compromise with something a little less vast,
but which is in G4 internal units.
18th January 2018 Gabriele Cosmo (greps-V10-04-01)
- Updated GNUmakefile to add G4GREPS_ALLOC_EXPORT definition.
18th January 2018 Ben Morgan (greps-V10-04-00)
- Fix unexported global data for WINDOWS_EXPORT_ALL_SYMBOLS
- New DLL build method identified that G4VisAttributes has a
static const member that is not declared dllexport/import.
- graphics_reps_defs.hh: New header to configure the needed
export/import keywords, using a macro G4GREPS_DLL
- CMakeLists.txt: Add -D flag G4GREPS_ALLOC_EXPORT when
building the library to make export mode.
- G4VisAttributes.hh: Mark static const G4VisAttributes data
using G4GREPS_DLL to ensure export/import.
6th October 2017 John Allison (greps-V10-03-07)
- Rationalised:
o Colour map no longer G4ThreadLocal (no need). May be used from
+26 -15
View File
@@ -24,28 +24,28 @@
// ********************************************************************
//
//
// $Id: G4VisAttributes.hh 98730 2016-08-09 10:47:54Z gcosmo $
// $Id: G4VisAttributes.hh 110390 2018-05-22 08:28:07Z gcosmo $
//
//
//
// John Allison 23rd October 1996
// Class Description:
// Visualization attributes are a set of information associated with the
// visualizable objects. This information is necessary only for
// visualization, and is not included in geometrical information such
// as shapes, position, and orientation.
// A typical example of a visualization attribute is "colour".
// For example, in visualizing a box, the Visualization Manager must know
// its colour. If an object to be visualized has not been assigned a set of
// visualization attributes, then a proper default set is used
// automatically. A set of visualization attributes is held by an
// instance of class G4VisAttributes defined in the graphics_reps
// Visualization attributes are a set of information associated with the
// visualizable objects. This information is necessary only for
// visualization, and is not included in geometrical information such
// as shapes, position, and orientation.
// A typical example of a visualization attribute is "colour".
// For example, in visualizing a box, the Visualization Manager must know
// its colour. If an object to be visualized has not been assigned a set of
// visualization attributes, then a proper default set is used
// automatically. A set of visualization attributes is held by an
// instance of class G4VisAttributes defined in the graphics_reps
// category. The followings are commonly-used attributes:
// - visibility
// - visibility of daughters
// - force wireframe style, force solid style
// - force auxiliary edge visibility, force line segments pe circle
// - colour
// - colour
// Class Description - End:
@@ -56,12 +56,16 @@
#include <vector>
#include <map>
#include "graphics_reps_defs.hh"
#include "G4Colour.hh"
#include "G4Color.hh"
class G4AttValue;
class G4AttDef;
#include <CLHEP/Units/SystemOfUnits.h>
class G4VisAttributes {
friend std::ostream& operator << (std::ostream& os, const G4VisAttributes& a);
@@ -70,8 +74,7 @@ public: // With description
enum LineStyle {unbroken, dashed, dotted};
enum ForcedDrawingStyle {wireframe, solid};
enum {fMinLineSegmentsPerCircle = 3}; // number of sides per circle
G4VisAttributes ();
G4VisAttributes (G4bool visibility);
G4VisAttributes (const G4Colour& colour);
@@ -80,12 +83,14 @@ public: // With description
~G4VisAttributes ();
G4VisAttributes& operator= (const G4VisAttributes&);
#ifndef WIN32
// Deprecated 14 July 2016 JA
// Use GetInvisible() instead. E.g.:
// logical_volume->SetVisAttributes(G4VisAttributes::GetInvisible());
// or use one of the above constructors or SetVisibility and
// logical_volume->SetVisAttributes(my_vis_attributes);
static const G4VisAttributes Invisible;
#endif
static const G4VisAttributes& GetInvisible();
@@ -135,6 +140,12 @@ public: // With description
// Returns the orginal long life G4AttDefs...
const std::map<G4String,G4AttDef>* GetAttDefs () const;
static constexpr G4int fMinLineSegmentsPerCircle = 3;
// Minumum number of sides per circle
static constexpr G4double fVeryLongTime = 1.e100 * CLHEP::ns;
// About 1.e75 billion years!! Used as default for start and end time.
private:
G4bool fVisible; // Visibility flag
@@ -0,0 +1,47 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
// Defines for Windows DLLs import/export
//
#ifndef G4GRAPHICSREPSDEFS_HH
#define G4GRAPHICSREPSDEFS_HH
#include "G4Types.hh"
#ifdef WIN32
//
// Unique identifier for graphics_reps module
//
#if defined G4GREPS_ALLOC_EXPORT
#define G4GREPS_DLL G4DLLEXPORT
#else
#define G4GREPS_DLL G4DLLIMPORT
#endif
#else
#define G4GREPS_DLL
#endif
#endif /* G4GRAPHICSREPSDEFS_HH */
+2 -1
View File
@@ -11,7 +11,7 @@
#
# Generated on : 24/9/2010
#
# $Id: sources.cmake 66376 2012-12-18 09:42:59Z gcosmo $
# $Id: sources.cmake 108187 2018-01-18 16:03:33Z gcosmo $
#
#------------------------------------------------------------------------------
@@ -73,6 +73,7 @@ GEANT4_DEFINE_MODULE(NAME G4graphics_reps
G4Visible.icc
HepPolyhedron.h
HepPolyhedronProcessor.h
graphics_reps_defs.hh
SOURCES
BooleanProcessor.src
G4AttCheck.cc
+11 -9
View File
@@ -24,7 +24,7 @@
// ********************************************************************
//
//
// $Id: G4VisAttributes.cc 98730 2016-08-09 10:47:54Z gcosmo $
// $Id: G4VisAttributes.cc 110390 2018-05-22 08:28:07Z gcosmo $
//
//
// John Allison 23rd October 1996
@@ -45,8 +45,8 @@ fForcedStyle (wireframe),
fForceAuxEdgeVisible (false),
fForcedAuxEdgeVisible(false),
fForcedLineSegmentsPerCircle (0), // <=0 means not forced.
fStartTime (-DBL_MAX),
fEndTime (DBL_MAX),
fStartTime (-fVeryLongTime),
fEndTime (fVeryLongTime),
fAttValues (0),
fAttDefs (0)
{}
@@ -62,8 +62,8 @@ fForcedStyle (wireframe),
fForceAuxEdgeVisible (false),
fForcedAuxEdgeVisible(false),
fForcedLineSegmentsPerCircle (0), // <=0 means not forced.
fStartTime (-DBL_MAX),
fEndTime (DBL_MAX),
fStartTime (-fVeryLongTime),
fEndTime (fVeryLongTime),
fAttValues (0),
fAttDefs (0)
{}
@@ -79,8 +79,8 @@ fForcedStyle (wireframe),
fForceAuxEdgeVisible (false),
fForcedAuxEdgeVisible(false),
fForcedLineSegmentsPerCircle (0), // <=0 means not forced.
fStartTime (-DBL_MAX),
fEndTime (DBL_MAX),
fStartTime (-fVeryLongTime),
fEndTime (fVeryLongTime),
fAttValues (0),
fAttDefs (0)
{}
@@ -97,8 +97,8 @@ fForcedStyle (wireframe),
fForceAuxEdgeVisible (false),
fForcedAuxEdgeVisible(false),
fForcedLineSegmentsPerCircle (0), // <=0 means not forced.
fStartTime (-DBL_MAX),
fEndTime (DBL_MAX),
fStartTime (-fVeryLongTime),
fEndTime (fVeryLongTime),
fAttValues (0),
fAttDefs (0)
{}
@@ -153,8 +153,10 @@ G4VisAttributes& G4VisAttributes::operator= (const G4VisAttributes& rhs)
return *this;
}
#ifndef WIN32
// Deprecated 14 July 2016 JA
const G4VisAttributes G4VisAttributes::Invisible = G4VisAttributes (false);
#endif
const G4VisAttributes& G4VisAttributes::GetInvisible() {
static const G4VisAttributes invisible = G4VisAttributes(false);