|
27 | 27 | #include "GPUCommonDef.h" |
28 | 28 | #include "ITSMFTTracking/Configuration.h" |
29 | 29 | #include "ITSMFTTracking/IdTypes.h" |
| 30 | +#include "ITSMFTTracking/MathUtils.h" |
30 | 31 |
|
31 | 32 | namespace o2::itsmft |
32 | 33 | { |
33 | 34 |
|
34 | 35 | enum class IndexTableCoordType : uint8_t { PhiZ, |
35 | 36 | PhiR }; |
36 | 37 |
|
37 | | -namespace index_table_utils |
38 | | -{ |
39 | | -GPUhdi() float getNormalizedPhi(float phi) |
40 | | -{ |
41 | | - phi -= o2::constants::math::TwoPI * o2::gpu::GPUCommonMath::Floor(phi * (1.f / o2::constants::math::TwoPI)); |
42 | | - return phi; |
43 | | -} |
44 | | -} // namespace index_table_utils |
45 | | - |
46 | 38 | /// Row/column LUT helper. Charts have periodic phi rows and a |
47 | 39 | /// descriptor-bounded linear column. |
48 | 40 | /// MaxLayoutSurfaces storage keeps GPUhdi() access device-portable; callers |
@@ -211,9 +203,9 @@ GPUhdi() int4 getBinsPhiColumn(float phi, const int layerIndex, |
211 | 203 | } |
212 | 204 |
|
213 | 205 | return int4{o2::gpu::GPUCommonMath::Max(0, utils.getColBinIndex(layerIndex, colRangeMin)), |
214 | | - utils.getRowBinIndex(index_table_utils::getNormalizedPhi(rowRangeMin)), |
| 206 | + utils.getRowBinIndex(o2::its::math_utils::getNormalizedPhi(rowRangeMin)), |
215 | 207 | o2::gpu::GPUCommonMath::Min(utils.getNcolBins() - 1, utils.getColBinIndex(layerIndex, colRangeMax)), |
216 | | - utils.getRowBinIndex(index_table_utils::getNormalizedPhi(rowRangeMax))}; |
| 208 | + utils.getRowBinIndex(o2::its::math_utils::getNormalizedPhi(rowRangeMax))}; |
217 | 209 | } |
218 | 210 |
|
219 | 211 | } // namespace o2::itsmft |
|
0 commit comments