mirror of
https://github.com/dgirardeau/q3DMASC.git
synced 2026-08-29 16:40:49 +08:00
use ccQtHelpers::GetMaxThreadCount
This commit is contained in:
+4
-1
@@ -89,6 +89,9 @@ constexpr const char* LAS_FIELD_NAMES[22] = {"X",
|
||||
//CCLib
|
||||
#include <WeibullDistribution.h>
|
||||
|
||||
//CCPluginAPI
|
||||
#include <ccQtHelpers.h>
|
||||
|
||||
//system
|
||||
#include <assert.h>
|
||||
|
||||
@@ -424,7 +427,7 @@ static bool ComputeMathOpWithNearestNeighbor( const CorePoints& corePoints,
|
||||
error.clear();
|
||||
#ifndef _DEBUG
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for num_threads(std::max(1, omp_get_max_threads() - 2))
|
||||
#pragma omp parallel for num_threads(ccQtHelpers::GetMaxThreadCount(omp_get_max_threads()))
|
||||
#endif
|
||||
#endif
|
||||
for (int i = 0; i < static_cast<int>(pointCount); ++i)
|
||||
|
||||
Reference in New Issue
Block a user