34 #ifdef G4VIS_BUILD_VRML_DRIVER
79 G4VRML1SceneHandler::~G4VRML1SceneHandler()
81 #if defined DEBUG_FR_SCENE
89 #define G4VRML1SCENEHANDLER G4VRML1SceneHandler
90 #define IS_CONNECTED fDest.isConnected()
91 #include "G4VRML1SceneHandlerFunc.icc"
93 #undef G4VRML1SCENEHANDLER
96 void G4VRML1SceneHandler::connectPort(
G4int max_trial)
99 int port = fSystem.getPort();
100 for (trial = 0; !fDest.isConnected()&& trial < max_trial; trial++, port++ ) {
101 if (fDest.connect( (
const char * )fSystem.getHostName(), port)) {
104 G4cout <<
"*** GEANT4 is connected to port ";
105 G4cout << fDest.getPort();
106 G4cout <<
" of server " << fSystem.getHostName() <<
G4endl;
112 G4cout <<
"*** GEANT4 incremented targeting port to ";
121 if (!fDest.isConnected()) {
124 G4cout <<
" Maybe, you have not invoked viewer g4vrmlview yet, " <<
G4endl;
125 G4cout <<
" or too many viewers are already running in the " <<
G4endl;
126 G4cout <<
" server host(" << fSystem.getHostName() <<
"). " <<
G4endl;
131 void G4VRML1SceneHandler::closePort()
139 G4int G4VRML1SceneHandler::fSceneIdCount = 0;