Import Geant4 1.1.0 source tree

This commit is contained in:
Gabriele Cosmo
2016-06-08 15:34:16 +02:00
parent ca1c8cb059
commit 103bda00c8
2654 changed files with 29719 additions and 20203 deletions
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4DAWNFILE.hh,v 1.4.8.1 1999/12/07 20:53:08 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
// $Id: G4DAWNFILE.hh,v 1.5 1999/12/15 14:54:00 gunter Exp $
// GEANT4 tag $Name: geant4-01-01 $
//
// Satoshi TANAKA
// DAWNFILE driver factory.
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4DAWNFILESceneHandler.hh,v 1.3.4.1 1999/12/07 20:53:08 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
// $Id: G4DAWNFILESceneHandler.hh,v 1.5 1999/12/16 17:24:48 johna Exp $
// GEANT4 tag $Name: geant4-01-01 $
//
// Satoshi TANAKA
@@ -64,6 +64,12 @@ public:
void AddThis ( const G4Sphere& sphere );
void AddThis ( const G4Para& para );
void AddThis ( const G4Torus& torus );
void AddThis ( const G4Polycone& polycone ) {
G4VSceneHandler::AddThis (polycone);
}
void AddThis ( const G4Polyhedra& polyhedra) {
G4VSceneHandler::AddThis (polyhedra);
}
void AddThis ( const G4VSolid& solid );
void ClearStore (){}
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4DAWNFILEViewer.hh,v 1.4.4.1 1999/12/07 20:53:08 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
// $Id: G4DAWNFILEViewer.hh,v 1.5 1999/12/15 14:54:00 gunter Exp $
// GEANT4 tag $Name: geant4-01-01 $
//
// Satoshi TANAKA
// DAWNFILE viewer - opens window, hard copy, etc.
@@ -44,7 +44,7 @@ public:
const char* GetG4PrimViewer () { return fG4PrimViewer ;}
const char* GetG4PrimViewerInvocation() { return fG4PrimViewerInvocation ;}
const char* GetPSViewer () { return fPSViewer ;}
void SendDrawingStyleToDAWNGUI( ostream& out ) ;
void SendDrawingStyleToDAWNGUI( G4std::ostream& out ) ;
private:
G4DAWNFILESceneHandler& fSceneHandler; // Reference to Graphics Scene for this view.
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4FRClientServer.hh,v 1.2.8.1 1999/12/07 20:53:09 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
// $Id: G4FRClientServer.hh,v 1.3 1999/12/15 14:54:00 gunter Exp $
// GEANT4 tag $Name: geant4-01-01 $
//
// Satoshi TANAKA, Wed Jul 3 14:13:52 JST 1996
////////////////////////////////
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4FRConst.hh,v 1.3.4.1 1999/12/07 20:53:09 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
// $Id: G4FRConst.hh,v 1.4 1999/12/15 14:54:00 gunter Exp $
// GEANT4 tag $Name: geant4-01-01 $
//
// Satoshi TANAKA, Tue Jul 2 15:30:49 JST 1996
///////////////////////////////////
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4FRFeatures.hh,v 1.2.8.1 1999/12/07 20:53:09 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
// $Id: G4FRFeatures.hh,v 1.3 1999/12/15 14:54:00 gunter Exp $
// GEANT4 tag $Name: geant4-01-01 $
//
#if !defined G4_FR_FEATURES_HH
#define G4_FR_FEATURES_HH
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4FRSocketConfig.hh,v 1.2.8.1 1999/12/07 20:53:09 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
// $Id: G4FRSocketConfig.hh,v 1.3 1999/12/15 14:54:00 gunter Exp $
// GEANT4 tag $Name: geant4-01-01 $
//
////////////////////////////////
///// G4FRSocketConfig.h /////
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4FRSocketMacro.hh,v 1.2.8.1 1999/12/07 20:53:09 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
// $Id: G4FRSocketMacro.hh,v 1.3 1999/12/15 14:54:00 gunter Exp $
// GEANT4 tag $Name: geant4-01-01 $
//
///////////////////////////////
///// G4FRSocketMacro.hh /////
@@ -5,10 +5,10 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4FRofstream.hh,v 1.2.8.1 1999/12/07 20:53:10 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
// $Id: G4FRofstream.hh,v 1.3 1999/12/15 14:54:01 gunter Exp $
// GEANT4 tag $Name: geant4-01-01 $
//
#include<fstream.h>
#include"g4std/fstream"
#if !defined G4_FR_OFSTREAM_HH
#define G4_FR_OFSTREAM_HH
@@ -49,7 +49,7 @@ class G4FRofstream {
protected:
G4bool flag_file_open ;
ofstream fout ;
G4std::ofstream fout ;
} ;
@@ -73,7 +73,7 @@ inline void G4FRofstream::Close ()
inline void G4FRofstream::SendLine ( const char* message )
{
if ( IsOpen() ) {
fout << message << endl;
fout << message << G4endl;
}
}
@@ -82,7 +82,7 @@ inline G4bool G4FRofstream::DoesFileExist ( const char* filename )
{
G4bool status = false ;
ifstream fout_tmp( filename ) ;
G4std::ifstream fout_tmp( filename ) ;
if( fout_tmp ) { status = true ; }
fout_tmp.close();
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4FukuiRenderer.hh,v 1.4.8.1 1999/12/07 20:53:10 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
// $Id: G4FukuiRenderer.hh,v 1.5 1999/12/15 14:54:01 gunter Exp $
// GEANT4 tag $Name: geant4-01-01 $
//
//
// Satoshi TANAKA
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4FukuiRendererSceneHandler.hh,v 1.3.4.1 1999/12/07 20:53:10 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
// $Id: G4FukuiRendererSceneHandler.hh,v 1.5 1999/12/16 17:24:49 johna Exp $
// GEANT4 tag $Name: geant4-01-01 $
//
//
// Satoshi TANAKA, Fri Jun 28 11:19:19 JST 1996
@@ -63,6 +63,12 @@ public:
void AddThis ( const G4Sphere& sphere );
void AddThis ( const G4Para& para );
void AddThis ( const G4Torus& torus );
void AddThis ( const G4Polycone& polycone) {
G4VSceneHandler::AddThis (polycone);
}
void AddThis ( const G4Polyhedra& polyhedra) {
G4VSceneHandler::AddThis (polyhedra);
}
void AddThis ( const G4VSolid& solid );
void ClearStore (){}
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4FukuiRendererViewer.hh,v 1.4.4.1 1999/12/07 20:53:10 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
// $Id: G4FukuiRendererViewer.hh,v 1.5 1999/12/15 14:54:01 gunter Exp $
// GEANT4 tag $Name: geant4-01-01 $
//
//
// Satoshi TANAKA, Fri Jun 28 12:10:14 JST 1996
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4DAWNFILE.cc,v 1.4.4.1 1999/12/07 20:53:10 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
// $Id: G4DAWNFILE.cc,v 1.5 1999/12/15 14:54:01 gunter Exp $
// GEANT4 tag $Name: geant4-01-01 $
//
// Satoshi TANAKA
// DAWNFILE factory.
@@ -49,7 +49,7 @@ G4VSceneHandler* G4DAWNFILE::CreateSceneHandler (const G4String& name)
G4VSceneHandler* p = new G4DAWNFILESceneHandler (*this, name);
G4cout << G4DAWNFILESceneHandler::GetSceneCount ()
<< ' ' << fName << " scenes extanct." << endl;
<< ' ' << fName << " scenes extanct." << G4endl;
return p;
}
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4DAWNFILESceneHandler.cc,v 1.2.4.1 1999/12/07 20:53:10 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
// $Id: G4DAWNFILESceneHandler.cc,v 1.3 1999/12/15 14:54:01 gunter Exp $
// GEANT4 tag $Name: geant4-01-01 $
//
// Satoshi TANAKA
// DAWNFILE scene.
@@ -22,7 +22,7 @@
// #define DEBUG_FR_SCENE
//----- header files
#include <fstream.h>
#include "g4std/fstream"
#include <stdlib.h>
#include <string.h>
#include "globals.hh"
@@ -95,7 +95,7 @@ COMMAND_BUF_SIZE (G4FRofstream::SEND_BUFMAX)
G4DAWNFILESceneHandler::~G4DAWNFILESceneHandler ()
{
#if defined DEBUG_FR_SCENE
G4cerr << "***** ~G4DAWNFILESceneHandler" << endl;
G4cerr << "***** ~G4DAWNFILESceneHandler" << G4endl;
#endif
fSceneCount--;
ClearStore (); // clear current scene
@@ -119,13 +119,13 @@ void G4DAWNFILESceneHandler::SetG4PrimFileName()
// Message
if( fMaxFileNum > 1 && i == MAX_FILE_INDEX ) {
G4cerr << "===========================================" << endl;
G4cerr << "WARNING MESSAGE from DAWNFILE driver: " << endl;
G4cerr << " This file name is the final one in the " << endl;
G4cerr << " automatic updation of the output file name." << endl;
G4cerr << " You may overwrite an existing file of " << endl;
G4cerr << " the same name. " << endl;
G4cerr << "===========================================" << endl;
G4cerr << "===========================================" << G4endl;
G4cerr << "WARNING MESSAGE from DAWNFILE driver: " << G4endl;
G4cerr << " This file name is the final one in the " << G4endl;
G4cerr << " automatic updation of the output file name." << G4endl;
G4cerr << " You may overwrite an existing file of " << G4endl;
G4cerr << " the same name. " << G4endl;
G4cerr << "===========================================" << G4endl;
}
// re-determine file to G4DAWNFILE_DEST_DIR/g4_i.prim for i>0
@@ -134,7 +134,7 @@ void G4DAWNFILESceneHandler::SetG4PrimFileName()
}
// check validity of the file name
ifstream fin ;
G4std::ifstream fin ;
fin.open(fG4PrimFileName) ;
if(!fin) {
// new file
@@ -147,11 +147,11 @@ void G4DAWNFILESceneHandler::SetG4PrimFileName()
} // for
G4cerr << "===========================================" << endl;
G4cerr << "Output file: " << fG4PrimFileName << endl;
G4cerr << "Muximal number of file in the destination directory: " << fMaxFileNum << endl;
G4cerr << " (Customizable as: setenv G4DAWNFILE_MAX_FILE_NUM number) " << endl;
G4cerr << "===========================================" << endl;
G4cerr << "===========================================" << G4endl;
G4cerr << "Output file: " << fG4PrimFileName << G4endl;
G4cerr << "Muximal number of file in the destination directory: " << fMaxFileNum << G4endl;
G4cerr << " (Customizable as: setenv G4DAWNFILE_MAX_FILE_NUM number) " << G4endl;
G4cerr << "===========================================" << G4endl;
} // G4DAWNFILESceneHandler::SetG4PrimFileName()
@@ -167,7 +167,7 @@ void G4DAWNFILESceneHandler::BeginSavingG4Prim( void )
{
#if defined DEBUG_FR_SCENE
G4cerr << "***** (started) " ;
G4cerr << "(open g4.prim, ##)" << endl;
G4cerr << "(open g4.prim, ##)" << G4endl;
#endif
SetG4PrimFileName() ; // returned to fG4PrimFileName
fPrimDest.Open(fG4PrimFileName) ;
@@ -186,7 +186,7 @@ void G4DAWNFILESceneHandler::EndSavingG4Prim ( void )
if( IsSavingG4Prim() )
{
#if defined DEBUG_FR_SCENE
G4cerr << "***** (started) (close g4.prim)" << endl;
G4cerr << "***** (started) (close g4.prim)" << G4endl;
#endif
fPrimDest.Close() ;
flag_saving_g4_prim = false ;
@@ -200,7 +200,7 @@ void G4DAWNFILESceneHandler::FRBeginModeling( void )
if( !FRIsInModeling() )
{
#if defined DEBUG_FR_SCENE
G4cerr << "***** G4DAWNFILESceneHandler::FRBeginModeling (called & started)" << endl;
G4cerr << "***** G4DAWNFILESceneHandler::FRBeginModeling (called & started)" << G4endl;
#endif
//----- Send saving command and heading comment
@@ -211,19 +211,19 @@ void G4DAWNFILESceneHandler::FRBeginModeling( void )
//----- send SET_CAMERA command
#if defined DEBUG_FR_SCENE
G4cerr << "***** (!SetCamera in FRBeginModeling())" << endl;
G4cerr << "***** (!SetCamera in FRBeginModeling())" << G4endl;
#endif
SendStr( FR_SET_CAMERA );
//----- open device
#if defined DEBUG_FR_SCENE
G4cerr << "***** (!OpenDevice in FRBeginModeling())" << endl;
G4cerr << "***** (!OpenDevice in FRBeginModeling())" << G4endl;
#endif
SendStr( FR_OPEN_DEVICE );
//----- begin sending primitives
#if defined DEBUG_FR_SCENE
G4cerr << "***** (!BeginModeling in FRBeginModeling())" << endl;
G4cerr << "***** (!BeginModeling in FRBeginModeling())" << G4endl;
#endif
SendStr( FR_BEGIN_MODELING ); FRflag_in_modeling = true ;
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4DAWNFILEViewer.cc,v 1.5.4.1 1999/12/07 20:53:10 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
// $Id: G4DAWNFILEViewer.cc,v 1.6 1999/12/15 14:54:01 gunter Exp $
// GEANT4 tag $Name: geant4-01-01 $
//
// Satoshi TANAKA
// DAWNFILE view - opens window, hard copy, etc.
@@ -81,7 +81,7 @@ G4DAWNFILEViewer::~G4DAWNFILEViewer ()
void G4DAWNFILEViewer::SetView ()
{
#if defined DEBUG_FR_VIEW
G4cerr << "***** G4DAWNFILEViewer::SetView(): No effects" << endl;
G4cerr << "***** G4DAWNFILEViewer::SetView(): No effects" << G4endl;
#endif
// Do nothing, since DAWN is running as a different process.
// SendViewParameters () will do this job instead.
@@ -93,7 +93,7 @@ void
G4DAWNFILEViewer::ClearView( void )
{
#if defined DEBUG_FR_VIEW
G4cerr << "***** G4DAWNFILEViewer::ClearView (): No effects " << endl;
G4cerr << "***** G4DAWNFILEViewer::ClearView (): No effects " << G4endl;
#endif
}
@@ -103,7 +103,7 @@ G4DAWNFILEViewer::ClearView( void )
void G4DAWNFILEViewer::DrawView ()
{
#if defined DEBUG_FR_VIEW
G4cerr << "***** G4DAWNFILEViewer::DrawView () " << endl;
G4cerr << "***** G4DAWNFILEViewer::DrawView () " << G4endl;
#endif
//-----
fSceneHandler.FRBeginModeling() ;
@@ -122,7 +122,7 @@ void G4DAWNFILEViewer::DrawView ()
void G4DAWNFILEViewer::ShowView( void )
{
#if defined DEBUG_FR_VIEW
G4cerr << "***** G4DAWNFILEViewer::ShowView () " << endl;
G4cerr << "***** G4DAWNFILEViewer::ShowView () " << G4endl;
#endif
if( fSceneHandler.FRIsInModeling() )
@@ -151,19 +151,19 @@ void G4DAWNFILEViewer::ShowView( void )
if( false == G4FRofstream::DoesFileExist( fSceneHandler.GetG4PrimFileName() ) )
{
G4cout << "ERROR: Failed to generate file ";
G4cout << fSceneHandler.GetG4PrimFileName() << endl;
G4cout << fSceneHandler.GetG4PrimFileName() << G4endl;
} else if( strcmp( GetG4PrimViewerInvocation(), "" ) )
{
G4cout << "File " << fSceneHandler.GetG4PrimFileName() ;
G4cout << " is generated." << endl;
G4cout << GetG4PrimViewerInvocation() << endl;
G4cout << " is generated." << G4endl;
G4cout << GetG4PrimViewerInvocation() << G4endl;
system( GetG4PrimViewerInvocation() );
} else { // no view, i.e., only file generation
G4cout << "File " << fSceneHandler.GetG4PrimFileName() ;
G4cout << " is generated." << endl;
G4cout << "No viewer is invoked." << endl;
G4cout << " is generated." << G4endl;
G4cout << "No viewer is invoked." << G4endl;
}
}
@@ -171,12 +171,12 @@ void G4DAWNFILEViewer::ShowView( void )
} // G4DAWNFILEViewer::ShowView()
//----- G4DAWNFILEViewer::SendDrawingStyleToDAWNGUI( ostream& out )
void G4DAWNFILEViewer::SendDrawingStyleToDAWNGUI( ostream& out )
//----- G4DAWNFILEViewer::SendDrawingStyleToDAWNGUI( G4std::ostream& out )
void G4DAWNFILEViewer::SendDrawingStyleToDAWNGUI( G4std::ostream& out )
{
///////////////////////
//#if defined DEBUG_FR_VIEW
// G4cerr << "***** G4DAWNFILEViewer::SendDrawingStyleToDAWNGUI()" << endl;
// G4cerr << "***** G4DAWNFILEViewer::SendDrawingStyleToDAWNGUI()" << G4endl;
//#endif
//////////////////////
@@ -188,17 +188,17 @@ void G4DAWNFILEViewer::SendDrawingStyleToDAWNGUI( ostream& out )
switch( style )
{
case G4ViewParameters::wireframe:
out << FR_WIREFRAME << endl;
out << FR_WIREFRAME << G4endl;
break;
case G4ViewParameters::hlr:
out << FR_HID2 << endl; // LINE
out << FR_HID2 << G4endl; // LINE
break;
case G4ViewParameters::hsr:
case G4ViewParameters::hlhsr:
out << FR_HID << endl; // SURFACE
out << FR_HID << G4endl; // SURFACE
break;
default:
out << FR_WIREFRAME << endl;
out << FR_WIREFRAME << G4endl;
break;
}
@@ -215,7 +215,7 @@ void G4DAWNFILEViewer::SendViewParameters ()
#if defined DEBUG_FR_VIEW
G4cerr << "***** G4DAWNFILEViewer::SendViewParameters() ";
G4cerr << "(GUI parameters)" << endl;
G4cerr << "(GUI parameters)" << G4endl;
#endif
//----- Magic number to decide camera distance automatically
@@ -243,8 +243,8 @@ void G4DAWNFILEViewer::SendViewParameters ()
}
if ( camera_distance < radius ) {
G4cerr << "WARNING from DAWNFILE driver:" << endl;
G4cerr << " Camera cannot enter inside objects" << endl;
G4cerr << "WARNING from DAWNFILE driver:" << G4endl;
G4cerr << " Camera cannot enter inside objects" << G4endl;
camera_distance = radius ;
}
@@ -257,27 +257,27 @@ void G4DAWNFILEViewer::SendViewParameters ()
//########### Generation of the file .DAWN.history for DAWN GUI
//-----
ofstream gui_out (".DAWN_1.history") ;
G4std::ofstream gui_out (".DAWN_1.history") ;
// ######### P1
//----- camera position
gui_out << camera_distance << endl;
gui_out << v_angle << endl ;
gui_out << h_angle << endl ;
gui_out << "0" << endl ; // auto target
gui_out << camera_distance << G4endl;
gui_out << v_angle << G4endl ;
gui_out << h_angle << G4endl ;
gui_out << "0" << G4endl ; // auto target
//----- target point
const G4Point3D& target_point = fVP.GetCurrentTargetPoint();
gui_out << target_point.x() << endl ;
gui_out << target_point.y() << endl ;
gui_out << target_point.z() << endl ;
gui_out << target_point.x() << G4endl ;
gui_out << target_point.y() << G4endl ;
gui_out << target_point.z() << G4endl ;
//----- Magnification
const G4double zoom_factor = fVP.GetZoomFactor();
if( half_view_angle < MIN_HALF_ANGLE ) {
gui_out << zoom_factor << endl;
gui_out << zoom_factor << G4endl;
} else {
const G4double FR_HALF_SCREEN_SIZE = 0.5 ;
@@ -285,33 +285,33 @@ void G4DAWNFILEViewer::SendViewParameters ()
= FR_HALF_SCREEN_SIZE / tan( half_view_angle );
focal_distance *= zoom_factor ;
gui_out << "fd" << focal_distance << endl;
gui_out << "fd" << focal_distance << G4endl;
}
SendDrawingStyleToDAWNGUI( gui_out ) ; // gui_out, viewing mode
gui_out << "0.001" << endl ; // 3D Tolerance
gui_out << "0" << endl ; // not display parameters
gui_out << "0.001" << G4endl ; // 3D Tolerance
gui_out << "0" << G4endl ; // not display parameters
// ######### P2
gui_out << 1 << endl; // Source light
gui_out << 1 << endl;
gui_out << 1 << endl;
gui_out << 0.5 << endl; // Ambient light
gui_out << 0.5 << endl;
gui_out << 0.5 << endl;
gui_out << 19.0 << endl; // Light direction (Polar)
gui_out << 71.0 << endl; // Light direction (Azimuthal)
gui_out << 1 << G4endl; // Source light
gui_out << 1 << G4endl;
gui_out << 1 << G4endl;
gui_out << 0.5 << G4endl; // Ambient light
gui_out << 0.5 << G4endl;
gui_out << 0.5 << G4endl;
gui_out << 19.0 << G4endl; // Light direction (Polar)
gui_out << 71.0 << G4endl; // Light direction (Azimuthal)
// ######### P3
gui_out << 0.1 << endl; // Real edge width
gui_out << 0.1 << endl; // outline width
gui_out << 0.1 << endl; // aux edge width
gui_out << 3 << endl; // aux edge style
gui_out << 70.0<< endl; // aux-edge threshold angle
gui_out << 0.1 << endl; // line width
gui_out << 0 << endl; // haloing
gui_out << 1 << endl; // Dashed edged for back faces
gui_out << 0.1 << G4endl; // Real edge width
gui_out << 0.1 << G4endl; // outline width
gui_out << 0.1 << G4endl; // aux edge width
gui_out << 3 << G4endl; // aux edge style
gui_out << 70.0<< G4endl; // aux-edge threshold angle
gui_out << 0.1 << G4endl; // line width
gui_out << 0 << G4endl; // haloing
gui_out << 1 << G4endl; // Dashed edged for back faces
//######### P4
//----- drawing device
@@ -321,14 +321,14 @@ void G4DAWNFILEViewer::SendViewParameters ()
( ( getenv( FR_ENV_MULTI_WINDOW2 ) != NULL ) && \
( strcmp( getenv( FR_ENV_MULTI_WINDOW2 ),"0" ) ) ) )
{
gui_out << 2 << endl; // OpenWindow
gui_out << 2 << G4endl; // OpenWindow
} else {
gui_out << 1 << endl; // Invoke PS viewer
gui_out << 1 << G4endl; // Invoke PS viewer
}
gui_out << GetPSViewer() << endl; // PS viewer
gui_out << 0 << endl ; // Do not add showpage
gui_out << 0 << endl ; // Non-append mode
gui_out << GetPSViewer() << G4endl; // PS viewer
gui_out << 0 << G4endl ; // Do not add showpage
gui_out << 0 << G4endl ; // Non-append mode
gui_out.close();
//########### end of generating file .DAWN.history
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4FRClientServer.cc,v 1.2.8.1 1999/12/07 20:53:11 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
// $Id: G4FRClientServer.cc,v 1.3 1999/12/15 14:54:01 gunter Exp $
// GEANT4 tag $Name: geant4-01-01 $
//
// Satoshi TANAKA, Wed Jul 3 14:14:29 JST 1996
////////////////////////////////
@@ -101,7 +101,7 @@ void G4FRClientServer::Receive()
}
#if defined DEBUG_CLIENT_SERVER
G4cerr << ">>>>> receivedMessage = " << fReceivedMessage << endl;
G4cerr << ">>>>> receivedMessage = " << fReceivedMessage << G4endl;
#endif
}
@@ -132,7 +132,7 @@ void G4FRClientServer::Send()
}
#if defined DEBUG_CLIENT_SERVER
G4cerr << "<<<<< SentMessage = " << fSendingMessage << endl;
G4cerr << "<<<<< SentMessage = " << fSendingMessage << G4endl;
#endif
} // G4FRClientServer::Send()
@@ -253,7 +253,7 @@ int G4FRClientServer::ConnectINET()
// #if defined DEBUG_CLIENT_SERVER
G4cerr << "***** Trying connection to " << server_hostname << endl;
G4cerr << "***** Trying connection to " << server_hostname << G4endl;
// #endif
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4FRSceneFunc.icc,v 1.9.2.1 1999/12/07 20:53:11 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
// $Id: G4FRSceneFunc.icc,v 1.10 1999/12/15 14:54:01 gunter Exp $
// GEANT4 tag $Name: geant4-01-01 $
//
@@ -113,8 +113,8 @@ void G4FRSCENE::AddPrimitive ( const G4Text& text )
//----- create buffer and copy the string there
int MAX_STR_LENGTH = COMMAND_BUF_SIZE - 100 ;
if ( MAX_STR_LENGTH <= 0 ) {
G4cerr << "ERROR (FukuiRenderer) : Not enough buffer size for data transferring." << endl;
G4cerr << " G4Text Visualization is aborted" << endl;
G4cerr << "ERROR (FukuiRenderer) : Not enough buffer size for data transferring." << G4endl;
G4cerr << " G4Text Visualization is aborted" << G4endl;
return ;
}
char* buf = new char [ (MAX_STR_LENGTH + 1) ] ;
@@ -301,7 +301,7 @@ void G4FRSCENE::SendNdiv ( void )
{
//////////////////////////////////////////////////
//#if defined DEBUG_FR_SCENE
// G4cerr << "***** SendNdiv() (/Ndiv)" << endl;
// G4cerr << "***** SendNdiv() (/Ndiv)" << G4endl;
//#endif
//////////////////////////////////////////////////
@@ -315,7 +315,7 @@ void G4FRSCENE::SendNdiv ( void )
#if defined DEBUG_FR_SCENE
G4cerr << "WARNING: GetNoOfSides() failed. " ;
G4cerr << "The default value " << num_division ;
G4cerr << " is assigned." << endl;
G4cerr << " is assigned." << G4endl;
#endif
}
@@ -324,7 +324,7 @@ void G4FRSCENE::SendNdiv ( void )
//////////////////////////////////////////////////
//#if defined DEBUG_FR_SCENE
// G4cerr << "Ndiv = " << num_division << endl;
// G4cerr << "Ndiv = " << num_division << G4endl;
//#endif
//////////////////////////////////////////////////
@@ -339,13 +339,13 @@ void G4FRSCENE::FREndModeling ()
{
//-----
#if defined DEBUG_FR_SCENE
G4cerr << "***** FREndModeling (called)" << endl;
G4cerr << "***** FREndModeling (called)" << G4endl;
#endif
if( FRIsInModeling() ) {
#if defined DEBUG_FR_SCENE
G4cerr << "***** FREndModeling (started) " ;
G4cerr << "(/EndModeling, /DrawAll, /CloseDevice)" << endl;
G4cerr << "(/EndModeling, /DrawAll, /CloseDevice)" << G4endl;
#endif
SendStr( "#--------------------" );
@@ -653,9 +653,9 @@ void G4FRSCENE::AddThis (const G4Para& para)
//----- parameters preprocessing
G4double cosTheta = para.GetSymAxis().z() ;
if( cosTheta < epsilon ) {
G4cerr << "WARNING from FukuiRenderer (DAWN) driver:" << endl;
G4cerr << " Invalid parameter for parallelepiped." << endl;
G4cerr << " Drawing is skipped." << endl;
G4cerr << "WARNING from FukuiRenderer (DAWN) driver:" << G4endl;
G4cerr << " Invalid parameter for parallelepiped." << G4endl;
G4cerr << " Drawing is skipped." << G4endl;
return ;
}
G4double tanTheta_cosPhi_cosTheta = para.GetSymAxis().x() ;
@@ -709,9 +709,9 @@ void G4FRSCENE::AddThis (const G4Trap& trap)
//----- parameters preprocessing
G4double cosTheta = trap.GetSymAxis().z() ;
if( cosTheta < epsilon ) {
G4cerr << "WARNING from FukuiRenderer (DAWN) driver:" << endl;
G4cerr << " Invalid parameter for trap, 1" << endl;
G4cerr << " Drawing is skipped." << endl;
G4cerr << "WARNING from FukuiRenderer (DAWN) driver:" << G4endl;
G4cerr << " Invalid parameter for trap, 1" << G4endl;
G4cerr << " Drawing is skipped." << G4endl;
return ;
}
@@ -897,7 +897,7 @@ G4bool G4FRSCENE::IsVisible()
void G4FRSCENE::SendBoundingBox( void )
{
#if defined DEBUG_FR_SCENE
G4cerr << "***** SendBoundingBox () (/BoundingBox)" << endl;
G4cerr << "***** SendBoundingBox () (/BoundingBox)" << G4endl;
#endif
//----- (1A) CALC bounding box of the bounding sphere
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4FukuiRenderer.cc,v 1.3.8.1 1999/12/07 20:53:11 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
// $Id: G4FukuiRenderer.cc,v 1.4 1999/12/15 14:54:01 gunter Exp $
// GEANT4 tag $Name: geant4-01-01 $
//
//
// Satoshi TANAKA
@@ -77,7 +77,7 @@ G4VSceneHandler* G4FukuiRenderer::CreateSceneHandler (const G4String& name)
if(!flag_connected) { delete p ; p = NULL ; }
G4cout << G4FukuiRendererSceneHandler::GetSceneCount ()
<< ' ' << fName << " scenes extanct." << endl;
<< ' ' << fName << " scenes extanct." << G4endl;
return p;
}
@@ -97,7 +97,7 @@ void G4FukuiRenderer::UseInetDomainAuto()
int pid ;
#if defined DEBUG_FR_SYSTEM
G4cerr << "***** Unix Inet Domain (AUTO mode)" << endl;
G4cerr << "***** Unix Inet Domain (AUTO mode)" << G4endl;
#endif
fIPMode = G4FukuiRenderer::IP_UNIX ;
@@ -127,11 +127,11 @@ void G4FukuiRenderer::UseInetDomainAuto()
}
if(!flag_connected) {
G4cerr << "***** ERROR: Connection failed" << endl;
G4cerr << "***** ERROR: Connection failed" << G4endl;
}
else {
G4cerr << "***** GEANT4 is connected to FukuiRenderer DAWN ";
G4cerr << "in the same host" << endl;
G4cerr << "in the same host" << G4endl;
}
} // G4FukuiRenderer::UseInetDomainAuto()
@@ -142,18 +142,18 @@ void
G4FukuiRenderer::UseInetDomain()
{
#if defined DEBUG_FR_SYSTEM
G4cerr << "***** INET Domain " << endl;
G4cerr << "***** INET Domain " << G4endl;
#endif
fIPMode = G4FukuiRenderer::IP_INET ;
this->ConnectPort();
if(!flag_connected) {
G4cerr << "***** ERROR: Connection failed" << endl;
G4cerr << "***** ERROR: Connection failed" << G4endl;
}
else {
G4cerr << "GEANT4 is connected to FukuiRenderer DAWN via socket" ;
G4cerr << endl;
G4cerr << G4endl;
}
} // G4FukuiRenderer::UseInetDomain()
@@ -166,10 +166,10 @@ G4FukuiRenderer::ConnectPort( int max_port_incr )
while(1) {
if ( ++connect_trial > max_port_incr ) {
this->flag_connected = 0 ;
G4cerr << "***** INET Connection failed." << endl;
G4cerr << " Maybe, you have not invoked DAWN yet," << endl;
G4cerr << " or too many DAWN's are already running" << endl;
G4cerr << " in the server host." << endl;
G4cerr << "***** INET Connection failed." << G4endl;
G4cerr << " Maybe, you have not invoked DAWN yet," << G4endl;
G4cerr << " or too many DAWN's are already running" << G4endl;
G4cerr << " in the server host." << G4endl;
fPrimDest.IncrementPortNumber( (- FR_MAX_PORT_INCR) );
return ;
} else if ( fPrimDest.ConnectINET() ) {
@@ -177,14 +177,14 @@ G4FukuiRenderer::ConnectPort( int max_port_incr )
this->flag_connected = 1 ;
G4cerr << "***** GEANT4 is connected to port " ;
G4cerr << fPrimDest.GetPortNumber() ;
G4cerr << " of server" << endl;
G4cerr << " of server" << G4endl;
break ;
} else {
// Connection failed. Try the next port.
this->flag_connected = 0 ;
fPrimDest.IncrementPortNumber();
G4cerr << "***** GEANT4 incremented targeting port to " ;
G4cerr << fPrimDest.GetPortNumber() << endl;
G4cerr << fPrimDest.GetPortNumber() << G4endl;
} // if-elseif-else
@@ -198,7 +198,7 @@ void G4FukuiRenderer::UseBSDUnixDomainAuto()
int pid ;
#if defined DEBUG_FR_SYSTEM
G4cerr << "***** UseBSDUnixDomainAuto " << endl;
G4cerr << "***** UseBSDUnixDomainAuto " << G4endl;
#endif
fIPMode = G4FukuiRenderer::IP_UNIX ; // Unix domain
@@ -224,10 +224,10 @@ void G4FukuiRenderer::UseBSDUnixDomainAuto()
//----- display status
if(!flag_connected) {
G4cerr << "***** ERROR: Connection failed" << endl;
G4cerr << "***** ERROR: Connection failed" << G4endl;
} else {
G4cerr << "*** GEANT4 is connected to FukuiRenderer DAWN ";
G4cerr << "in the same host" << endl;
G4cerr << "in the same host" << G4endl;
}
} // if--else
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4FukuiRendererSceneHandler.cc,v 1.2.4.1 1999/12/07 20:53:11 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
// $Id: G4FukuiRendererSceneHandler.cc,v 1.3 1999/12/15 14:54:01 gunter Exp $
// GEANT4 tag $Name: geant4-01-01 $
//
//
// Satoshi TANAKA, Fri Jun 28 11:34:24 JST 1996
@@ -23,7 +23,7 @@
// #define DEBUG_FR_SCENE
//----- header files
#include <fstream.h>
#include "g4std/fstream"
//#include <strstream.h>
#include <string.h>
#include "globals.hh"
@@ -96,7 +96,7 @@ COMMAND_BUF_SIZE (G4FRClientServer::SEND_BUFMAX)
G4FukuiRendererSceneHandler::~G4FukuiRendererSceneHandler ()
{
#if defined DEBUG_FR_SCENE
G4cerr << "***** ~G4FukuiRendererSceneHandler" << endl;
G4cerr << "***** ~G4FukuiRendererSceneHandler" << G4endl;
#endif
fSceneCount--;
ClearStore (); // clear current scene
@@ -109,7 +109,7 @@ void G4FukuiRendererSceneHandler::FRBeginModeling( void )
if( !FRIsInModeling() )
{
#if defined DEBUG_FR_SCENE
G4cerr << "***** G4FukuiRendererSceneHandler::FRBeginModeling (called & started)" << endl;
G4cerr << "***** G4FukuiRendererSceneHandler::FRBeginModeling (called & started)" << G4endl;
#endif
//----- Begin Saving g4.prim file
@@ -145,21 +145,21 @@ void G4FukuiRendererSceneHandler::FRBeginModeling( void )
//----- send SET_CAMERA command
// !SetCamera
#if defined DEBUG_FR_SCENE
G4cerr << "***** (!SetCamera in FRBeginModeling())" << endl;
G4cerr << "***** (!SetCamera in FRBeginModeling())" << G4endl;
#endif
SendStr( FR_SET_CAMERA );
//----- open device
// !OpenDevice
#if defined DEBUG_FR_SCENE
G4cerr << "***** (!OpenDevice in FRBeginModeling())" << endl;
G4cerr << "***** (!OpenDevice in FRBeginModeling())" << G4endl;
#endif
SendStr( FR_OPEN_DEVICE );
//----- begin sending primitives
// !BeginModeling
#if defined DEBUG_FR_SCENE
G4cerr << "***** (!BeginModeling in FRBeginModeling())" << endl;
G4cerr << "***** (!BeginModeling in FRBeginModeling())" << G4endl;
#endif
SendStr( FR_BEGIN_MODELING ); FRflag_in_modeling = true ;
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4FukuiRendererViewer.cc,v 1.3.4.1 1999/12/07 20:53:11 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
// $Id: G4FukuiRendererViewer.cc,v 1.4 1999/12/15 14:54:01 gunter Exp $
// GEANT4 tag $Name: geant4-01-01 $
//
//
// Satoshi TANAKA, Fri Jun 28 12:09:11 JST 1996
@@ -53,7 +53,7 @@ G4FukuiRendererViewer::~G4FukuiRendererViewer ()
void G4FukuiRendererViewer::SetView ()
{
#if defined DEBUG_FR_VIEW
G4cerr << "***** G4FukuiRendererViewer::SetView(): No effects" << endl;
G4cerr << "***** G4FukuiRendererViewer::SetView(): No effects" << G4endl;
#endif
// Do nothing, since DAWN is running as a different process.
// SendViewParameters () will do this job instead.
@@ -64,7 +64,7 @@ void
G4FukuiRendererViewer::ClearView( void )
{
#if defined DEBUG_FR_VIEW
G4cerr << "***** G4FukuiRendererViewer::ClearView (): No effects " << endl;
G4cerr << "***** G4FukuiRendererViewer::ClearView (): No effects " << G4endl;
#endif
}
@@ -74,7 +74,7 @@ G4FukuiRendererViewer::ClearView( void )
void G4FukuiRendererViewer::DrawView ()
{
#if defined DEBUG_FR_VIEW
G4cerr << "***** G4FukuiRendererViewer::DrawView () " << endl;
G4cerr << "***** G4FukuiRendererViewer::DrawView () " << G4endl;
#endif
//----- Begin modeling 3D
@@ -93,7 +93,7 @@ void G4FukuiRendererViewer::DrawView ()
void G4FukuiRendererViewer::ShowView( void )
{
#if defined DEBUG_FR_VIEW
G4cerr << "***** G4FukuiRendererViewer::ShowView () " << endl;
G4cerr << "***** G4FukuiRendererViewer::ShowView () " << G4endl;
#endif
if( fSceneHandler.FRIsInModeling() )
@@ -114,12 +114,12 @@ void G4FukuiRendererViewer::ShowView( void )
void G4FukuiRendererViewer::Wait()
{
#if defined DEBUG_FR_VIEW
G4cerr << "***** G4FukuiRendererViewer::Wait () : Begin" << endl;
G4cerr << "***** G4FukuiRendererViewer::Wait () : Begin" << G4endl;
#endif
fSceneHandler.SendStr ( FR_WAIT );
fSceneHandler.GetPrimDest().WaitSendBack( FR_WAIT );
#if defined DEBUG_FR_VIEW
G4cerr << "***** G4FukuiRendererViewer::Wait () : end" << endl;
G4cerr << "***** G4FukuiRendererViewer::Wait () : end" << G4endl;
#endif
}
@@ -130,7 +130,7 @@ void
G4FukuiRendererViewer::SendDevice( FRDEV dev )
{
#if defined DEBUG_FR_VIEW
G4cerr << "***** G4FukuiRendererViewer::SendDevice() " << endl;
G4cerr << "***** G4FukuiRendererViewer::SendDevice() " << G4endl;
#endif
// enum {PS=1, XWIN=2, PS2=3, XWIN2=4, OPEN_GL=5, DEVICE_END=6};
@@ -145,7 +145,7 @@ G4FukuiRendererViewer::SendDevice( FRDEV dev )
void G4FukuiRendererViewer::SendDrawingStyle()
{
#if defined DEBUG_FR_VIEW
G4cerr << "***** G4FukuiRendererViewer::SendDrawingStyle() " << endl;
G4cerr << "***** G4FukuiRendererViewer::SendDrawingStyle() " << G4endl;
#endif
G4int style = fVP.GetDrawingStyle();
@@ -178,7 +178,7 @@ void G4FukuiRendererViewer::SendViewParameters ()
// later due to user interaction via visualization system's GUI.)
#if defined DEBUG_FR_VIEW
G4cerr << "***** G4FukuiRendererViewer::SendViewParameters()" << endl;
G4cerr << "***** G4FukuiRendererViewer::SendViewParameters()" << G4endl;
#endif
//----- Magic number to decide camera distance automatically
@@ -206,8 +206,8 @@ void G4FukuiRendererViewer::SendViewParameters ()
}
if ( camera_distance < radius ) {
G4cerr << "WARNING from FukuiRenderer (DAWN) driver:" << endl;
G4cerr << " Camera cannot enter inside objects" << endl;
G4cerr << "WARNING from FukuiRenderer (DAWN) driver:" << G4endl;
G4cerr << " Camera cannot enter inside objects" << G4endl;
camera_distance = radius ;
}