Import Geant4 10.4.0 source tree
This commit is contained in:
@@ -23,7 +23,7 @@
|
||||
// * acceptance of all terms of the Geant4 Software license. *
|
||||
// ********************************************************************
|
||||
//
|
||||
// $Id: pyG4ChordFinder.cc 76884 2013-11-18 12:54:03Z gcosmo $
|
||||
// $Id: pyG4ChordFinder.cc 107590 2017-11-24 11:59:22Z gcosmo $
|
||||
// ====================================================================
|
||||
// pyG4ChordFinder.cc
|
||||
//
|
||||
@@ -54,7 +54,6 @@ void export_G4ChordFinder()
|
||||
class_<G4ChordFinder, G4ChordFinder*, boost::noncopyable>
|
||||
("G4ChordFinder", "chord finder class", no_init)
|
||||
// constructor
|
||||
.def(init<G4MagInt_Driver*>())
|
||||
.def(init<G4MagneticField*>())
|
||||
.def(init<G4MagneticField*, G4double>())
|
||||
.def(init<G4MagneticField*, G4double, G4MagIntegratorStepper*>())
|
||||
|
||||
@@ -23,7 +23,7 @@
|
||||
// * acceptance of all terms of the Geant4 Software license. *
|
||||
// ********************************************************************
|
||||
//
|
||||
// $Id: pyG4FieldManager.cc 76884 2013-11-18 12:54:03Z gcosmo $
|
||||
// $Id: pyG4FieldManager.cc 107590 2017-11-24 11:59:22Z gcosmo $
|
||||
// ====================================================================
|
||||
// pyG4FieldManager.cc
|
||||
//
|
||||
@@ -39,17 +39,6 @@
|
||||
|
||||
using namespace boost::python;
|
||||
|
||||
// ====================================================================
|
||||
// miscs
|
||||
// ====================================================================
|
||||
#if G4VERSION_NUMBER <= 801
|
||||
// What a hell!
|
||||
inline const G4ChordFinder* G4FieldManager::GetChordFinder() const
|
||||
{
|
||||
return fChordFinder;
|
||||
}
|
||||
#endif
|
||||
|
||||
// ====================================================================
|
||||
// thin wrappers
|
||||
// ====================================================================
|
||||
@@ -57,9 +46,13 @@ namespace pyG4FieldManager {
|
||||
|
||||
G4ChordFinder*(G4FieldManager::*f1_GetChordFinder)()
|
||||
= &G4FieldManager::GetChordFinder;
|
||||
|
||||
const G4ChordFinder*(G4FieldManager::*f2_GetChordFinder)() const
|
||||
= &G4FieldManager::GetChordFinder;
|
||||
|
||||
BOOST_PYTHON_MEMBER_FUNCTION_OVERLOADS(f_SetDetectorField,
|
||||
SetDetectorField, 1, 2);
|
||||
|
||||
}
|
||||
|
||||
using namespace pyG4FieldManager;
|
||||
@@ -78,7 +71,8 @@ void export_G4FieldManager()
|
||||
.def(init<G4Field*, G4ChordFinder*, G4bool>())
|
||||
.def(init<G4MagneticField*>())
|
||||
// ---
|
||||
.def("SetDetectorField", &G4FieldManager::SetDetectorField)
|
||||
.def("SetDetectorField", &G4FieldManager::SetDetectorField,
|
||||
f_SetDetectorField())
|
||||
.def("GetDetectorField", &G4FieldManager::GetDetectorField,
|
||||
return_internal_reference<>())
|
||||
.def("DoesFieldExist", &G4FieldManager::DoesFieldExist)
|
||||
@@ -103,4 +97,3 @@ void export_G4FieldManager()
|
||||
.def("SetFieldChangesEnergy", &G4FieldManager::SetFieldChangesEnergy)
|
||||
;
|
||||
}
|
||||
|
||||
|
||||
@@ -23,7 +23,7 @@
|
||||
// * acceptance of all terms of the Geant4 Software license. *
|
||||
// ********************************************************************
|
||||
//
|
||||
// $Id: pyG4RandomDirection.cc 66892 2013-01-17 10:57:59Z gunter $
|
||||
// $Id: pyG4RandomDirection.cc 107590 2017-11-24 11:59:22Z gcosmo $
|
||||
// ====================================================================
|
||||
// pyG4RandomDirection.cc
|
||||
//
|
||||
@@ -34,11 +34,23 @@
|
||||
|
||||
using namespace boost::python;
|
||||
|
||||
// ====================================================================
|
||||
// thin wrappers
|
||||
// ====================================================================
|
||||
namespace pyG4RandomDirection {
|
||||
|
||||
G4ThreeVector(*G4RandomDirection_1)() = G4RandomDirection;
|
||||
G4ThreeVector(*G4RandomDirection_2)(double) = G4RandomDirection;
|
||||
|
||||
}
|
||||
|
||||
using namespace pyG4RandomDirection;
|
||||
|
||||
// ====================================================================
|
||||
// module definition
|
||||
// ====================================================================
|
||||
void export_G4RandomDirection()
|
||||
{
|
||||
def("G4RandomDirection", G4RandomDirection);
|
||||
def("G4RandomDirection", G4RandomDirection_1);
|
||||
def("G4RandomDirection", G4RandomDirection_2);
|
||||
}
|
||||
|
||||
|
||||
@@ -23,7 +23,7 @@
|
||||
// * acceptance of all terms of the Geant4 Software license. *
|
||||
// ********************************************************************
|
||||
//
|
||||
// $Id: pyG4TwoVector.cc 76884 2013-11-18 12:54:03Z gcosmo $
|
||||
// $Id: pyG4TwoVector.cc 107590 2017-11-24 11:59:22Z gcosmo $
|
||||
// ====================================================================
|
||||
// pyG4TwoVector.cc
|
||||
//
|
||||
@@ -31,8 +31,6 @@
|
||||
// ====================================================================
|
||||
#include <boost/python.hpp>
|
||||
#include "G4Version.hh"
|
||||
|
||||
#if G4VERSION_NUMBER >= 830
|
||||
#include "G4TwoVector.hh"
|
||||
|
||||
using namespace boost::python;
|
||||
@@ -53,15 +51,11 @@ BOOST_PYTHON_MEMBER_FUNCTION_OVERLOADS(f_isOrthogonal, isOrthogonal, 1, 2)
|
||||
|
||||
using namespace pyG4TwoVector;
|
||||
|
||||
#endif
|
||||
|
||||
// ====================================================================
|
||||
// module definition
|
||||
// ====================================================================
|
||||
void export_G4TwoVector()
|
||||
{
|
||||
#if G4VERSION_NUMBER >= 830
|
||||
|
||||
class_<G4TwoVector>("G4TwoVector", "general 2-vector")
|
||||
// constructors
|
||||
.def(init<G4double>())
|
||||
@@ -112,8 +106,4 @@ void export_G4TwoVector()
|
||||
.def(self >= self)
|
||||
.def(self <= self)
|
||||
;
|
||||
#endif
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -23,7 +23,7 @@
|
||||
// * acceptance of all terms of the Geant4 Software license. *
|
||||
// ********************************************************************
|
||||
//
|
||||
// $Id: pyglobals.cc 76884 2013-11-18 12:54:03Z gcosmo $
|
||||
// $Id: pyglobals.cc 107590 2017-11-24 11:59:22Z gcosmo $
|
||||
// ====================================================================
|
||||
// pyglobals.cc
|
||||
//
|
||||
@@ -65,9 +65,8 @@ typedef std::vector<G4int> G4intVector;
|
||||
typedef std::vector<G4double> G4doubleVector;
|
||||
typedef std::vector<G4String> G4StringVector;
|
||||
typedef std::vector<G4ThreeVector> G4ThreeVectorVector;
|
||||
#if G4VERSION_NUMBER >= 830
|
||||
typedef std::vector<G4TwoVector> G4TwoVectorVector;
|
||||
#endif
|
||||
|
||||
}
|
||||
|
||||
using namespace pyglobals;
|
||||
@@ -96,11 +95,8 @@ void export_globals()
|
||||
.def(vector_indexing_suite<G4ThreeVectorVector>())
|
||||
;
|
||||
|
||||
#if G4VERSION_NUMBER >= 830
|
||||
class_<G4TwoVectorVector> ("G4StringVector", "2-vector vector")
|
||||
.def(vector_indexing_suite<G4TwoVectorVector>())
|
||||
;
|
||||
#endif
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -7,9 +7,9 @@
|
||||
# This package contains a set of Python interface with Geant4.
|
||||
# ==================================================================
|
||||
"""
|
||||
# $Id: __init__.py 101648 2016-11-21 08:42:14Z gcosmo $
|
||||
__version__ ='10.3'
|
||||
__date__ = 'November/2016'
|
||||
# $Id: __init__.py 107590 2017-11-24 11:59:22Z gcosmo $
|
||||
__version__ ='10.4'
|
||||
__date__ = 'December/2017'
|
||||
__author__ = 'K.Murakami (Koichi.Murakami@kek.jp)'
|
||||
|
||||
# import submodules
|
||||
|
||||
@@ -7,9 +7,9 @@
|
||||
# This package contains a set of Python interface with Geant4.
|
||||
# ==================================================================
|
||||
"""
|
||||
# $Id: __init__.py 101648 2016-11-21 08:42:14Z gcosmo $
|
||||
__version__ ='10.3'
|
||||
__date__ = 'November/2016'
|
||||
# $Id: __init__.py 107590 2017-11-24 11:59:22Z gcosmo $
|
||||
__version__ ='10.4'
|
||||
__date__ = 'December/2017'
|
||||
__author__ = 'K.Murakami (Koichi.Murakami@kek.jp)'
|
||||
|
||||
# import submodules
|
||||
|
||||
Reference in New Issue
Block a user