Skip to content

Commit 81de64c

Browse files
committed
OpenMP for loop fix
1 parent 25a6d53 commit 81de64c

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/Modules/Mapper.cpp

+3-1
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,9 @@ extern struct Params Config;
4444

4545
omp_set_num_threads(MP_PROC_NUM);
4646
#pragma omp parallel for
47-
for (Point p : points) {
47+
for (int pi = 0; pi < points.size(); ++pi) {
48+
Point p = points[pi];
49+
4850
// Direct approach: we match the point with a plane on the map
4951
Match match = this->match_plane(X * X.I_Rt_L() * p);
5052
if (match.is_chosen()) matches.push_back(match);

0 commit comments

Comments
 (0)