Problem 2371 - it looks like there are quite a few mismatches compared to the enums defined in: G4SurfaceProperty.hh and G4OpticalSurface.hh
Summary: it looks like there are quite a few mismatches compared to the enums defined ...
Status: RESOLVED FIXED
Alias: None
Product: Geant4
Classification: Unclassified
Component: persistency/gdml (show other problems)
Version: 10.7
Hardware: All All
: P4 normal
Assignee: Gabriele Cosmo
URL:
Depends on:
Blocks:
 
Reported: 2021-05-20 18:19 CEST by Hans Wenzel
Modified: 2021-05-21 08:58 CEST (History)
3 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this problem.
Description Hans Wenzel 2021-05-20 18:19:29 CEST
types and other properties assigned in 

G4GDMLReadSolids.cc


it looks like there are quite a few mismatches compared to the enums defined in: G4SurfaceProperty.hh and G4OpticalSurface.hh


an example is:
  else if((stype == "dielectric_dichroic") || (stype == "3"))
  {
    type = dielectric_dichroic;
  }

which is incorrect since in 
source/materials/include/G4SurfaceProperty.hh


enum G4SurfaceType
{
  dielectric_metal,       // dielectric-metal interface
  dielectric_dielectric,  // dielectric-dielectric interface
  dielectric_LUT,         // dielectric-Look-Up-Table interface
  dielectric_LUTDAVIS,    // dielectric-Look-Up-Table DAVIS interface
  dielectric_dichroic,    // dichroic filter interface
  firsov,                 // for Firsov Process
  x_ray                   // for x-ray mirror process
};


"3" corresponds to dielectric_LUTDAVIS not  dielectric_dichroic. 

This mismatch will cause jobs to crash when the file defining dichroic properties can not be found.
Comment 1 Gabriele Cosmo 2021-05-21 08:58:56 CEST
Thanks for reporting this. Surface properties were not updated since relatively recent introduction of the DAVIS model...
The fix will be included in the next release and patch.