1 #ifndef OPENPOSE_THREAD_THREAD_QUEUE_OUT_HPP
2 #define OPENPOSE_THREAD_THREAD_QUEUE_OUT_HPP
11 template<
typename TDatums,
typename TWorker = std::shared_ptr<Worker<TDatums>>,
typename TQueue = Queue<TDatums>>
15 SubThreadQueueOut(
const std::vector<TWorker>& tWorkers,
const std::shared_ptr<TQueue>& tQueueOut);
20 std::shared_ptr<TQueue> spTQueueOut;
33 template<
typename TDatums,
typename TWorker,
typename TQueue>
35 const std::shared_ptr<TQueue>& tQueueOut) :
42 template<
typename TDatums,
typename TWorker,
typename TQueue>
58 const auto workersAreRunning = this->workTWorkers(tDatums,
true);
60 if (workersAreRunning)
62 if (tDatums !=
nullptr)
68 return workersAreRunning;
72 std::this_thread::sleep_for(std::chrono::microseconds{100});
77 catch (
const std::exception& e)
79 error(e.what(), __LINE__, __FUNCTION__, __FILE__);
88 #endif // OPENPOSE_THREAD_THREAD_QUEUE_OUT_HPP
Definition: subThread.hpp:10
OP_API void error(const std::string &message, const int line=-1, const std::string &function="", const std::string &file="")
spTQueueOut
Definition: subThreadQueueInOut.hpp:39
Definition: subThreadQueueOut.hpp:12
COMPILE_TEMPLATE_DATUM(WPoseTriangulation)
SubThreadQueueOut(const std::vector< TWorker > &tWorkers, const std::shared_ptr< TQueue > &tQueueOut)
Definition: subThreadQueueOut.hpp:34