mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-10-24 09:11:23 -06:00
New supports now do rafts at least to the extent the test cases run through.
New supports enabled, old supports will go away soon.
This commit is contained in:
parent
5614e997a4
commit
955bc957ba
17 changed files with 279 additions and 308 deletions
|
|
@ -123,7 +123,7 @@ parallelize(std::queue<T> queue, boost::function<void(T)> func,
|
|||
if (threads_count == 0) threads_count = 2;
|
||||
boost::mutex queue_mutex;
|
||||
boost::thread_group workers;
|
||||
for (int i = 0; i < fminf(threads_count, queue.size()); i++)
|
||||
for (int i = 0; i < std::min(threads_count, int(queue.size())); ++ i)
|
||||
workers.add_thread(new boost::thread(&_parallelize_do<T>, &queue, &queue_mutex, func));
|
||||
workers.join_all();
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue