Computes triple index to a world space position x.
| 44 | |
| 45 | // Computes triple index to a world space position x. |
| 46 | HashKey |
| 47 | NeighborhoodSearch::cell_index(Real const* x) const |
| 48 | { |
| 49 | HashKey ret; |
| 50 | for (unsigned int i = 0; i < 3; ++i) |
| 51 | { |
| 52 | if (x[i] >= 0.0) ret.k[i] = static_cast<int>(m_inv_cell_size * x[i]); |
| 53 | else ret.k[i] = static_cast<int>(m_inv_cell_size * x[i]) - 1; |
| 54 | } |
| 55 | return ret; |
| 56 | } |
| 57 | |
| 58 | // Determines permutation table for point array. |
| 59 | void |
nothing calls this directly
no outgoing calls
no test coverage detected