Ignore:
Timestamp:
Dec 22, 2010, 3:52:27 PM (14 years ago)
Author:
garnier
Message:

geant4 tag 9.4

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/source/visualization/VRML/src/G4VRML2FileSceneHandler.cc

    r1337 r1347  
    2525//
    2626//
    27 // $Id: G4VRML2FileSceneHandler.cc,v 1.14 2006/06/29 21:26:11 gunter Exp $
    28 // GEANT4 tag $Name: geant4-09-04-beta-01 $
     27// $Id: G4VRML2FileSceneHandler.cc,v 1.15 2010/11/11 00:14:50 akimura Exp $
     28// GEANT4 tag $Name: geant4-09-04-ref-00 $
    2929//
    3030// G4VRML2FileSceneHandler.cc
     
    4343#include "G4VPhysicalVolume.hh"
    4444#include "G4LogicalVolume.hh"
     45#include "G4VisManager.hh"
    4546#include "G4Point3D.hh"
    4647#include "G4VisAttributes.hh"
     
    119120{
    120121#if defined DEBUG_FR_SCENE
    121         G4cerr << "***** ~G4VRML2FileSceneHandler" << G4endl;
     122  if (G4VisManager::GetVerbosity() >= G4VisManager::errors)
     123        G4cout << "***** ~G4VRML2FileSceneHandler" << G4endl;
    122124#endif
    123125        VRMLEndModeling();
     
    149151                if( i == MAX_FILE_INDEX )
    150152                {
    151                   G4cerr << "==========================================="   << G4endl;
    152                   G4cerr << "WARNING MESSAGE from VRML2FILE driver:     "   << G4endl;
    153                   G4cerr << "  This file name is the final one in the   "   << G4endl;
    154                   G4cerr << "  automatic updation of the output file name." << G4endl;
    155                   G4cerr << "  You may overwrite existing files, i.e.   "   << G4endl;
    156                   G4cerr << "  g4_XX.wrl.                               "   << G4endl;
    157                   G4cerr << "==========================================="   << G4endl;
     153                  if (G4VisManager::GetVerbosity() >= G4VisManager::errors) {
     154                    G4cout << "==========================================="   << G4endl;
     155                    G4cout << "WARNING MESSAGE from VRML2FILE driver:     "   << G4endl;
     156                    G4cout << "  This file name is the final one in the   "   << G4endl;
     157                    G4cout << "  automatic updation of the output file name." << G4endl;
     158                    G4cout << "  You may overwrite existing files, i.e.   "   << G4endl;
     159                    G4cout << "  g4_XX.wrl.                               "   << G4endl;
     160                    G4cout << "==========================================="   << G4endl;
     161                  }
    158162                }
    159163
     
    180184
    181185        // open a VRML 2.0 file with determined file name
    182         G4cerr << "==========================================="  << G4endl;
    183         G4cerr << "Output VRML 2.0 file: " <<    fVRMLFileName << G4endl;
    184         G4cerr << "Maximum number of files in the destination directory: " << fMaxFileNum << G4endl;
    185         G4cerr << "  (Customizable with the environment variable: G4VRMLFILE_MAX_FILE_NUM) " << G4endl;
    186         G4cerr << "===========================================" << G4endl;
    187 
     186        if (G4VisManager::GetVerbosity() >= G4VisManager::errors) {
     187          G4cout << "==========================================="  << G4endl;
     188          G4cout << "Output VRML 2.0 file: " <<    fVRMLFileName << G4endl;
     189          G4cout << "Maximum number of files in the destination directory: " << fMaxFileNum << G4endl;
     190          G4cout << "  (Customizable with the environment variable: G4VRMLFILE_MAX_FILE_NUM) " << G4endl;
     191          G4cout << "===========================================" << G4endl;
     192        }
    188193        fDest.open(fVRMLFileName) ;  fFlagDestOpen =  true ;
    189194}
     
    201206        // close VRML file     
    202207        fDest.close();  fFlagDestOpen = false ;
    203         G4cerr << "*** VRML 2.0 File  " << fVRMLFileName << "  is generated." << G4endl;
     208        if (G4VisManager::GetVerbosity() >= G4VisManager::errors)
     209              G4cout << "*** VRML 2.0 File  " << fVRMLFileName << "  is generated." << G4endl;
    204210
    205211       
     
    207213
    208214        if ( !strcmp(viewer, NO_VRML_VIEWER )) {
    209                 G4cerr << "MESSAGE from VRML2FILE driver:"     << G4endl;
    210                 G4cerr << "    Set an environmental variable  " ;
    211                 G4cerr <<      ENV_VRML_VIEWER << G4endl;
    212                 G4cerr << "    if you want to visualize the generated VRML file" << G4endl;
    213                 G4cerr << "    automatically.  For example, " << G4endl;
    214                 G4cerr << "    setenv  " << ENV_VRML_VIEWER << "  vrwave " << G4endl;
     215          if (G4VisManager::GetVerbosity() >= G4VisManager::errors) {
     216                G4cout << "MESSAGE from VRML2FILE driver:"     << G4endl;
     217                G4cout << "    Set an environmental variable  " ;
     218                G4cout <<      ENV_VRML_VIEWER << G4endl;
     219                G4cout << "    if you want to visualize the generated VRML file" << G4endl;
     220                G4cout << "    automatically.  For example, " << G4endl;
     221                G4cout << "    setenv  " << ENV_VRML_VIEWER << "  vrwave " << G4endl;
     222          }
    215223        } else {
    216224                sprintf( command, "%s %s", viewer, fVRMLFileName  );   
Note: See TracChangeset for help on using the changeset viewer.