diff --git a/DDCore/include/DD4hep/LCDD.h b/DDCore/include/DD4hep/LCDD.h index 1af20d19ef713c668a3da201a6a7ac3861dcb1d1..261cf2252384681b17d019d1dc086ff535754c87 100644 --- a/DDCore/include/DD4hep/LCDD.h +++ b/DDCore/include/DD4hep/LCDD.h @@ -41,7 +41,7 @@ namespace DD4hep { * the accessor to the flag returns BUILD_NONE. */ enum LCDDBuildType { - BUILD_NONE = 0, BUILD_DEFAULT = 1, BUILD_SIMU = BUILD_DEFAULT, BUILD_RECO, BUILD_DISPLAY + BUILD_NONE = 0, BUILD_DEFAULT = 1, BUILD_SIMU = BUILD_DEFAULT, BUILD_RECO, BUILD_DISPLAY, BUILD_ENVELOPE }; /// Namespace for the geometry part of the AIDA detector description toolkit diff --git a/DDCore/src/plugins/StandardPlugins.cpp b/DDCore/src/plugins/StandardPlugins.cpp index 97a4ab816be24188392c435c894404b3cfb893a2..fb84db0ce53f83d917a424a49c90d711d30f101d 100644 --- a/DDCore/src/plugins/StandardPlugins.cpp +++ b/DDCore/src/plugins/StandardPlugins.cpp @@ -42,6 +42,10 @@ static LCDDBuildType build_type(const char* value) { return BUILD_DISPLAY; else if ( strcmp(value,"3")==0 ) return BUILD_DISPLAY; + else if ( strcmp(value,"BUILD_ENVELOPE")==0 ) + return BUILD_ENVELOPE; + else if ( strcmp(value,"4")==0 ) + return BUILD_DISPLAY; throw runtime_error(string("Invalid build type value: ")+value); } diff --git a/UtilityApps/src/dumpdetector.cpp b/UtilityApps/src/dumpdetector.cpp index 1d056b97de77d9c476474da25ad860cc49711fdf..d0c9ce42ddcf2a1dca97932324ee4bfc68af6f0a 100644 --- a/UtilityApps/src/dumpdetector.cpp +++ b/UtilityApps/src/dumpdetector.cpp @@ -69,11 +69,22 @@ int main(int argc, char** argv ){ DetElement de = (*it) ; + DetElement mother = de.parent() ; + unsigned parentCount = 0 ; + while( mother.isValid() ) { + mother = mother.parent() ; + ++parentCount ; + } + SurfaceManager surfMan( de ) ; const SurfaceList& sL = surfMan.surfaceList() ; - std::cout << "DetElement: " << de.name() << "[ path: "<< de.placementPath () << "] \t surfaces : " << ( sL.empty() ? 0 : sL.size() ) << std::endl ; + std::cout << "DetElement: " ; + + for(unsigned i=0 ; i < parentCount ; ++i ) std::cout << "\t" ; + + std::cout << de.name() << "[ path: "<< de.placementPath () << "] \t surfaces : " << ( sL.empty() ? 0 : sL.size() ) << std::endl ; // for( SurfaceList::const_iterator it = sL.begin() ; it != sL.end() ; ++it ){ // Surface* surf = *it ; diff --git a/UtilityApps/src/run_plugin.h b/UtilityApps/src/run_plugin.h index 39598b38d8d8dc770781bc971949e7686d7c1f14..551f78f536cb614618ae05cd106cda8230589c4a 100644 --- a/UtilityApps/src/run_plugin.h +++ b/UtilityApps/src/run_plugin.h @@ -73,7 +73,7 @@ namespace { " -build_type <number/string> Specify the build type \n" " [OPTIONAL] MUST come immediately after the -compact input.\n" " Default for each file is: BUILD_DEFAULT [=1] \n" - " Allowed values: BUILD_SIMU [=1], BUILD_RECO [=2] or BUILD_DISPLAY [=3]\n" + " Allowed values: BUILD_SIMU [=1], BUILD_RECO [=2], BUILD_DISPLAY [=3] or BUILD_ENVELOPE [=4]\n" " -destroy [OPTIONAL] Force destruction of the LCDD instance \n" " before exiting the application \n" " -volmgr [OPTIONAL] Load and populate phys.volume manager to \n" diff --git a/UtilityApps/src/teve_display.cpp b/UtilityApps/src/teve_display.cpp index 0460b6e09c0ff3d6a335a30997d756d2b3b92c02..70c5ff048376e88b80f27f618b7e541f890f7e86 100644 --- a/UtilityApps/src/teve_display.cpp +++ b/UtilityApps/src/teve_display.cpp @@ -70,9 +70,14 @@ static long teve_display(LCDD& lcdd, int /* argc */, char** /* argv */) { TGeoManager* mgr = &lcdd.manager(); TEveManager::Create(); + // mgr->SetVisOption(1) ; + // mgr->SetVisLevel(4) ; + // gEve->fGeometries->Add(new TObjString("DefaultGeometry"),mgr); TEveGeoTopNode* tn = new TEveGeoTopNode(mgr, mgr->GetTopNode()); + // option 0 in TEve seems to correspond to option 1 in TGeo ( used in geoDisplay ...) + tn->SetVisOption(0) ; tn->SetVisLevel(4); /* EvNavHandler *fh = */ new EvNavHandler;