00001 //<<<<<< INCLUDES >>>>>> 00002 00003 #include "VisSimulation/VisSimBase/interface/VisG4TracksContent.h" 00004 #include "VisSimulation/VisSimBase/interface/VisG4TracksTwig.h" 00005 #include "Iguana/Studio/interface/IgDocumentData.h" 00006 #include "Iguana/Framework/interface/IgRepSet.h" 00007 #include "Iguana/Studio/interface/IgQtLock.h" 00008 #include <classlib/utils/Callback.h> 00009 00010 //<<<<<< PRIVATE DEFINES >>>>>> 00011 //<<<<<< PRIVATE CONSTANTS >>>>>> 00012 //<<<<<< PRIVATE TYPES >>>>>> 00013 //<<<<<< PRIVATE VARIABLE DEFINITIONS >>>>>> 00014 //<<<<<< PUBLIC VARIABLE DEFINITIONS >>>>>> 00015 //<<<<<< CLASS STRUCTURE INITIALIZATION >>>>>> 00016 00017 IG_DEFINE_STATE_ELEMENT (VisG4TracksContent, "Data/Simulation/Tracks"); 00018 00019 //<<<<<< PRIVATE FUNCTION DEFINITIONS >>>>>> 00020 //<<<<<< PUBLIC FUNCTION DEFINITIONS >>>>>> 00021 //<<<<<< MEMBER FUNCTION DEFINITIONS >>>>>> 00022 00024 VisG4TracksContent::VisG4TracksContent (IgState *state) 00025 : VisContent (state, s_key, MAIN_THREAD, 00026 lat::CreateCallback (this, &VisG4TracksContent::init)) 00027 {} 00028 00031 void 00032 VisG4TracksContent::init (void) 00033 { 00034 IgQtLock (); 00035 00036 IgTwig *rootTwig = IgDocumentData::get (state ())->root (); 00037 IgTwig *topTwig = 0; 00038 IgTwig *eventTwig = 0; 00039 00040 topTwig = rootTwig->lookup ("CMS Event and Detector"); 00041 if (!topTwig) topTwig = new IgSimpleTwig (rootTwig, "CMS Event and Detector"); 00042 00043 eventTwig = topTwig->lookup ("CMS Sim Event"); 00044 if (!eventTwig) eventTwig = new IgSimpleTwig (topTwig, "CMS Sim Event"); 00045 00046 new VisG4TracksTwig (state (), eventTwig); 00047 }