Elbeem: Use pragma directive instead of overriding number of omp threads
[blender.git] / intern / elbeem / intern / solver_main.cpp
index 99278657fd9cbfd3d3244289b2370df84f450814..46af6740cf1580ed5a365a4e6c609316c93263de 100644 (file)
@@ -378,7 +378,7 @@ LbmFsgrSolver::mainLoop(int lev)
        const int gridLoopBound=1;
        GRID_REGION_INIT();
 #if PARALLEL==1
-#pragma omp parallel default(shared) \
+#pragma omp parallel default(shared) num_threads(mNumOMPThreads) \
   reduction(+: \
          calcCurrentMass,calcCurrentVolume, \
                calcCellsFilled,calcCellsEmptied, \
@@ -1119,7 +1119,7 @@ LbmFsgrSolver::preinitGrids()
        
                GRID_REGION_INIT();
 #if PARALLEL==1
-#pragma omp parallel default(shared) \
+#pragma omp parallel default(shared) num_threads(mNumOMPThreads) \
   reduction(+: \
          calcCurrentMass,calcCurrentVolume, \
                calcCellsFilled,calcCellsEmptied, \
@@ -1156,7 +1156,7 @@ LbmFsgrSolver::standingFluidPreinit()
 
        GRID_REGION_INIT();
 #if PARALLEL==1
-#pragma omp parallel default(shared) \
+#pragma omp parallel default(shared) num_threads(mNumOMPThreads) \
   reduction(+: \
          calcCurrentMass,calcCurrentVolume, \
                calcCellsFilled,calcCellsEmptied, \