Each gdml file consist five pieces: define, material, solids, structure, and setup. G4GDMLParser uses a G4GDMLReadStucture object to read the structure section. The GDML schema allows a geometry to be broken into separate modules. A lower level module is read in the structure section by defining a physvol with a tag <file name="child.gdml"/>. G4GDMLReadStructure member, ReadFile, recursively call G4GDMLStructure to process this tag. This created object has it's own auxMap. This auxMap data should be inserted in the high level auxMap before the object goes out of scope otherwise G4GDMParser will not have access to it. I used examples/extended/persistancy/gdml/G01/auxilary.gdml in load_gdml to demonstrate the problem. I broke auxilary.gdml into two files auxiliary_a.gdml and auxilary_b.gdml. auxilary_b.gdml continues volume Boxvol which has auxiliary information. auxiliary_a.gdml contines the World volume and load auxililary_b.gdml to define Boxvol. I have attached a zip file containing auxiliary.gdml, auxiliary_a.gdml and auxiliary_b.gdml. Here is the output for auxiliary.gdml followed by output for auxiliary_a.gdml: (Note that no auxiliary information is seen for auxiliary_a.gdml [wattsjw@watts G01]$ load_gdml auxiliary.gdml Usage: load_gdml <intput_gdml_file:mandatory> <output_gdml_file:optional> G4GDML: Reading 'auxiliary.gdml'... G4GDML: Reading definitions... G4GDML: Reading materials... G4GDML: Reading solids... G4GDML: Reading structure... G4GDML: Reading setup... G4GDML: Reading 'auxiliary.gdml' done! Stripping off GDML names of materials, solids and volumes ... ************************************************************* Geant4 version Name: geant4-09-02 (19-December-2008) Copyright : Geant4 Collaboration Reference : NIM A 506 (2003), 250-303 WWW : http://cern.ch/geant4 ************************************************************* Auxiliary Information is found for Logical Volume : Boxvol Name of Auxiliary type is = SensDet Visualization Manager instantiating... Visualization Manager initialising... Registering graphics systems... ............................................................................... [wattsjw@watts G01]$ load_gdml auxiliary_a.gdml Usage: load_gdml <intput_gdml_file:mandatory> <output_gdml_file:optional> G4GDML: Reading 'auxiliary_a.gdml'... G4GDML: Reading definitions... G4GDML: Reading materials... G4GDML: Reading solids... G4GDML: Reading structure... G4GDML: Reading module 'auxiliary_b.gdml'... G4GDML: Reading definitions... G4GDML: Reading materials... G4GDML: Reading solids... G4GDML: Reading structure... G4GDML: Reading setup... G4GDML: Reading module 'auxiliary_b.gdml' done! G4GDML: Reading setup... G4GDML: Reading 'auxiliary_a.gdml' done! Stripping off GDML names of materials, solids and volumes ... ************************************************************* Geant4 version Name: geant4-09-02 (19-December-2008) Copyright : Geant4 Collaboration Reference : NIM A 506 (2003), 250-303 WWW : http://cern.ch/geant4 ************************************************************* Visualization Manager instantiating... Visualization Manager initialising... Registering graphics systems... .............................................................................
Created attachment 37 [details] Compressed zip of example gdml files Problem with attaching zip file??
Thanks for the detailed report and test provided. We could reproduce the problem and identified it in a missing cache of the auxiliary info from the the child module within the G4GDMLStructure class. The fix is under way.
The problem is now fixed. It will be included in the next public patch of Geant4 9.2.