Skip to content

Commit cf7d568

Browse files
committed
GPU Display: Add option to tie TPC clusters to nominal x of pad rows
1 parent 586bcc9 commit cf7d568

2 files changed

Lines changed: 3 additions & 1 deletion

File tree

GPU/GPUTracking/Base/GPUSettingsList.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -142,6 +142,7 @@ EndConfig()
142142
// Settings concerning the event display
143143
BeginSubConfig(GPUSettingsDisplay, GL, configStandalone, "GL", 'g', "OpenGL display settings")
144144
AddOption(clustersOnly, bool, false, "", 0, "Visualize clusters only")
145+
AddOption(clustersOnNominalRow, bool, false, "", 0, "Show clusters at nominal x of pad row for early-transformed data")
145146
AddHelp("help", 'h')
146147
EndConfig()
147148

GPU/GPUTracking/Standalone/display/GPUDisplay.cxx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1268,6 +1268,7 @@ int GPUDisplay::DrawGLScene_internal(bool mixAnimation, float mAnimateTime)
12681268
if (mMerger.Param().par.earlyTpcTransform) {
12691269
const auto& cl = ioptrs().clusterData[iSlice][i];
12701270
cid = cl.id;
1271+
row = cl.row;
12711272
} else {
12721273
cid = ioptrs().clustersNative->clusterOffset[iSlice][0] + i;
12731274
while (row < GPUCA_ROW_COUNT && ioptrs().clustersNative->clusterOffset[iSlice][row + 1] <= (unsigned int)cid) {
@@ -1282,7 +1283,7 @@ int GPUDisplay::DrawGLScene_internal(bool mixAnimation, float mAnimateTime)
12821283
float4* ptr = &mGlobalPos[cid];
12831284
if (mMerger.Param().par.earlyTpcTransform) {
12841285
const auto& cl = ioptrs().clusterData[iSlice][i];
1285-
mChain->GetParam().Slice2Global(iSlice, cl.x + mXadd, cl.y, cl.z, &ptr->x, &ptr->y, &ptr->z);
1286+
mChain->GetParam().Slice2Global(iSlice, (mConfig.clustersOnNominalRow ? mMerger.Param().tpcGeometry.Row2X(row) : cl.x) + mXadd, cl.y, cl.z, &ptr->x, &ptr->y, &ptr->z);
12861287
} else {
12871288
float x, y, z;
12881289
const auto& cln = ioptrs().clustersNative->clusters[iSlice][0][i];

0 commit comments

Comments
 (0)