MCPcopy Create free account
hub / github.com/PCSX2/pcsx2 / StopEncoderThread

Method StopEncoderThread

pcsx2/GS/GSCapture.cpp:980–995  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

978}
979
980void GSCapture::StopEncoderThread(std::unique_lock<std::mutex>& lock)
981{
982 // Thread will exit when s_capturing is false.
983 pxAssert(!s_capturing.load(std::memory_order_acquire));
984
985 if (s_encoder_thread.Joinable())
986 {
987 Console.WriteLn("GSCapture: Stopping encoder thread.");
988
989 // Might be sleeping, so wake it before joining.
990 s_frame_ready_cv.notify_one();
991 lock.unlock();
992 s_encoder_thread.Join();
993 lock.lock();
994 }
995}
996
997bool GSCapture::SendFrame(const PendingFrame& pf)
998{

Callers

nothing calls this directly

Calls 7

JoinableMethod · 0.80
notify_oneMethod · 0.80
unlockMethod · 0.80
loadMethod · 0.45
WriteLnMethod · 0.45
JoinMethod · 0.45
lockMethod · 0.45

Tested by

no test coverage detected