4 """Read geometry parameters for Pixel
6 dbGeomCursor: AtlasGeoDBInterface instance
11 dbId, dbSwitches, dbParam = dbGeomCursor.GetCurrentLeafContent(
"PixelSwitches")
13 params = {
"VersionName" :
"UNDEFINED",
14 "Layout" :
"UNDEFINED",
19 if "VERSIONNAME" in dbParam:
20 params[
"VersionName"] = dbSwitches[key][dbParam.index(
"VERSIONNAME")]
21 if "LAYOUT" in dbParam :
22 params[
"Layout"] = dbSwitches[key][dbParam.index(
"LAYOUT")]
23 if "BUILDDBM" in dbParam :
24 params[
"DBM"] = (dbSwitches[key][dbParam.index(
"BUILDDBM")] != 0)
29 params[
"IBL"] = (params[
"Layout"] ==
"IBL")
30 params[
"IBLlayout"] =
"noIBL"
33 dbId, dbLayers, dbParam = dbGeomCursor.GetCurrentLeafContent(
"PixelLayer")
39 if "STAVEINDEX" in dbParam
and dbLayers[key][dbParam.index(
"STAVEINDEX")]
not in [
"NULL",
None]:
40 IBLStaveIndex =
int(dbLayers[key][dbParam.index(
"STAVEINDEX")])
42 if IBLStaveIndex > -1:
43 dbId, dbStaves, dbParam = dbGeomCursor.GetCurrentLeafContent(
"PixelStave")
45 if dbId
and IBLStaveIndex <= len(dbStaves.keys()):
46 key = dbId[IBLStaveIndex]
47 if "LAYOUT" in dbParam
and dbStaves[key][dbParam.index(
"LAYOUT")]
not in [
"NULL",
None]:
48 IBLgeoLayout =
int(dbStaves[key][dbParam.index(
"LAYOUT")])
49 if IBLgeoLayout
in [3,4] : params[
"IBLlayout"] =
"planar"
50 elif IBLgeoLayout
in [5] : params[
"IBLlayout"] =
"3D"