GDML import doesn't draw


I’m beginning to use the GDML tools in ROOT, but I’m having difficulty getting started. I’ve created a simple GDML file containing a cylinder as a start, but only get a blank canvas when drawing. I’m using ROOT 6.12.04 on macOS 10.13.2 with the Cocoa backend if that matters.

$ root
root [0] TGeoManager::Import("root-test.gdml")
Info in <TGeoManager::Import>: Reading geometry from file: root-test.gdml
Info in <TGeoManager::TGeoManager>: Geometry GDMLImport, Geometry imported from GDML created
Info in <TGeoManager::SetTopVolume>: Top volume is My_Vol. Master volume is My_Vol
Info in <TGeoNavigator::BuildCache>: --- Maximum geometry depth set to 100
Info in <TGeoManager::CheckGeometry>: Fixing runtime shapes...
Info in <TGeoManager::CheckGeometry>: ...Nothing to fix
Warning in <TGeoManager::CheckGeometry>: Volume "My_Vol" has no medium: assigned dummy medium and material
Info in <TGeoManager::CloseGeometry>: Counting nodes...
Info in <TGeoManager::Voxelize>: Voxelizing...
Info in <TGeoManager::CloseGeometry>: Building cache...
Info in <TGeoManager::CountLevels>: max level = 1, max placements = 0
Info in <TGeoManager::CloseGeometry>: 1 nodes/ 1 volume UID's in Geometry imported from GDML
Info in <TGeoManager::CloseGeometry>: ----------------modeler ready----------------
(TGeoManager *) 0x7fb19c8f2600
root [1] gGeoManager->GetTopVolume()->Draw("ogle")
Info in <TCanvas::MakeDefCanvas>:  created default TCanvas with name c1
root [2]

The GDMl file:

<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE gdml [
<!ENTITY common_materials SYSTEM "../common/common-materials.xml">
<!ENTITY common_defines   SYSTEM "../common/common-defines.xml">
<gdml xmlns:gdml=""



   <tube name="solid" rmin="1" rmax="4" z="20" deltaphi="360." aunit="deg" />

   <volume name="My_Vol">
      <solidref ref="solid"/>

<setup name="Default" version="1.0"> <world ref="My_Vol"/></setup>

Hello I am also seeing this error, and it worked in the previous version of ROOT. There is a JIRA ticket here:

Let’s hope it gets fixed soon, because I am usually very impressed with the robustness of ROOT’s GDML visualisation (compared to Geant4 that is…)!!!

1 Like

Thanks for the ticket. Ill be sure to keep an eye on it.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.