MCPcopy Create free account
hub / github.com/CMU-Perceptual-Computing-Lab/openpose / stopPusher

Method stopPusher

include/openpose/thread/queueBase.hpp:320–339  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

318
319 template<typename TDatums, typename TQueue>
320 void QueueBase<TDatums, TQueue>::stopPusher()
321 {
322 try
323 {
324 opLog("", Priority::Low, __LINE__, __FUNCTION__, __FILE__);
325 const std::lock_guard<std::mutex> lock{mMutex};
326 mPushers--;
327 if (mPushers == 0)
328 {
329 mPushIsStopped = {true};
330 if (mTQueue.empty())
331 mPopIsStopped = {true};
332 mConditionVariable.notify_all();
333 }
334 }
335 catch (const std::exception& e)
336 {
337 error(e.what(), __LINE__, __FUNCTION__, __FILE__);
338 }
339 }
340
341 template<typename TDatums, typename TQueue>
342 void QueueBase<TDatums, TQueue>::addPopper()

Callers 2

workMethod · 0.80
workMethod · 0.80

Calls 4

whatMethod · 0.80
opLogFunction · 0.50
errorFunction · 0.50
emptyMethod · 0.45

Tested by

no test coverage detected