From 765a43b5f7e32baebf5b7ffc346afa341505a2bf Mon Sep 17 00:00:00 2001 From: Frank Gaede <frank.gaede@desy.de> Date: Thu, 20 Jun 2013 11:57:24 +0000 Subject: [PATCH] - add a boolean to steer workaround: bool runDaughterVisibilityWorkaround ( change value in code) --- DDG4/src/Geant4Converter.cpp | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/DDG4/src/Geant4Converter.cpp b/DDG4/src/Geant4Converter.cpp index 6d029722a..1f13ebc09 100644 --- a/DDG4/src/Geant4Converter.cpp +++ b/DDG4/src/Geant4Converter.cpp @@ -385,10 +385,15 @@ void* Geant4Converter::handleVolume(const string& name, const TGeoVolume* volume vis_attr = (G4VisAttributes*)handleVis(vis.name(),vis.ptr()); - printout(WARNING,"Geant4Converter","******************* Workaround for issue with visualization attributes: " - "call vis_attr->SetDaughtersInvisible(false) for all volumes !!!!" ) ; - vis_attr->SetDaughtersInvisible(false) ; + static bool runDaughterVisibilityWorkaround = true ; //FIXME ! + if( runDaughterVisibilityWorkaround ) { + printout(WARNING,"Geant4Converter","******************* Workaround for issue with visualization attributes: " + "call vis_attr->SetDaughtersInvisible(false) for all volumes !!!!" ) ; + + vis_attr->SetDaughtersInvisible(false) ; + + } printout(INFO,"Geant4Converter","************** (G4VisAttributes*)handleVis( %s , 0x%x ) = %d - daughters: %d ", vis.name() , vis.ptr(), vis_attr->IsVisible() , !vis_attr->IsDaughtersInvisible() ) ; -- GitLab