| 94 | } |
| 95 | |
| 96 | void CGraphicsBackend_Threaded::StartProcessor(ICommandProcessor *pProcessor) |
| 97 | { |
| 98 | dbg_assert(m_Shutdown, "Processor was already not shut down."); |
| 99 | m_Shutdown = false; |
| 100 | m_pProcessor = pProcessor; |
| 101 | #if !defined(CONF_PLATFORM_EMSCRIPTEN) |
| 102 | std::unique_lock<std::mutex> Lock(m_BufferSwapMutex); |
| 103 | m_pThread = thread_init(ThreadFunc, this, "Graphics thread"); |
| 104 | // wait for the thread to start |
| 105 | m_BufferSwapCond.wait(Lock, [this]() -> bool { return m_Started; }); |
| 106 | #endif |
| 107 | } |
| 108 | |
| 109 | void CGraphicsBackend_Threaded::StopProcessor() |
| 110 | { |
nothing calls this directly
no test coverage detected