nesca/Threader.cpp

22 lines
447 B
C++
Raw Normal View History

2015-03-17 14:30:53 +00:00
#include <Threader.h>
std::vector<ThreadStruct> Threader::threadPool;
void Threader::createThreadPool(int poolSize, void *func, ST *st) {
for(int i = 0; i < poolSize; ++i) {
pthread_t thrc;
pthread_create(&thrc, NULL, (void *(*)(void*))func, st);
ThreadStruct threadStruct {
&thrc,
false
};
threadPool.push_back(threadStruct);
}
}
void Threader::fireThread(ST *st) {
}