#include <NeighArr.h>
|
| constexpr int | get_total_number_of_neighbours (const int cell) const |
| constexpr int | get_neighbour (const int cell, const int neigh_number) const |
| constexpr void | set_neighbour (const int cell, const int neigh_number, const int neigh_v) |
| constexpr int | get_neighbours (const unsigned int neigh_options, const int cell, int *neigh_arr) const |
| | Places the neighbours according to the option(s) in neigh_options in the array and returns the number of such neighbours (not the total number of neighbours of the cell).
|
| constexpr int | get_number_of_neighbours (const unsigned int neigh_options, const int cell) const |
Definition at line 170 of file NeighArr.h.
◆ get_neighbour()
| int CaloRecGPU::NeighArr::get_neighbour |
( |
const int | cell, |
|
|
const int | neigh_number ) const |
|
inlineconstexpr |
Definition at line 187 of file NeighArr.h.
188 {
190 }
int cells[NCaloCells][NMaxNeighbours]
◆ get_neighbours()
| int CaloRecGPU::NeighArr::get_neighbours |
( |
const unsigned int | neigh_options, |
|
|
const int | cell, |
|
|
int * | neigh_arr ) const |
|
inlineconstexpr |
Places the neighbours according to the option(s) in neigh_options in the array and returns the number of such neighbours (not the total number of neighbours of the cell).
We're using C arrays for more immediate CUDA compatibility.
Definition at line 202 of file NeighArr.h.
203 {
205
206 int neigh_arr_len = 0;
208 int neigh = 0;
209
211 {
212 limit = neigh_off.get_end_cell(i);
213 if ( neigh_options & (1U << i) )
214 {
215 for (; neigh <
limit; ++neigh)
216 {
217 neigh_arr[neigh_arr_len] =
cells[
cell][neigh];
218 ++neigh_arr_len;
219 }
220 }
222 }
223 return neigh_arr_len;
224 }
constexpr int NumNeighOptions
NeighOffset::carrier offsets[NCaloCells]
◆ get_number_of_neighbours()
| int CaloRecGPU::NeighArr::get_number_of_neighbours |
( |
const unsigned int | neigh_options, |
|
|
const int | cell ) const |
|
inlineconstexpr |
Definition at line 226 of file NeighArr.h.
227 {
229 int ret = 0;
231 {
232 if ( neigh_options & (1U << i) )
233 {
234 ret += neigh_off.get_num_cells(i);
235 }
236 }
237 return ret;
238 }
◆ get_total_number_of_neighbours()
| int CaloRecGPU::NeighArr::get_total_number_of_neighbours |
( |
const int | cell | ) |
const |
|
inlineconstexpr |
Definition at line 181 of file NeighArr.h.
182 {
184 return neigh_off.get_total_number();
185 }
◆ set_neighbour()
| void CaloRecGPU::NeighArr::set_neighbour |
( |
const int | cell, |
|
|
const int | neigh_number, |
|
|
const int | neigh_v ) |
|
inlineconstexpr |
◆ cells
◆ offsets
The documentation for this struct was generated from the following file: