mirror of
https://github.com/moonlight-stream/moonlight-qt
synced 2024-12-14 21:32:27 +00:00
Avoid using direct submit for video decoding because FFmpeg can delay for a fairly significant period of time within avcodec_send_packet() and avcodec_receive_frame(), even for software decoding. This is particularly apparent when streaming well above hardware capabilities and leads to packet loss.
This commit is contained in:
parent
b1de66d878
commit
afb2b465a8
1 changed files with 0 additions and 3 deletions
|
@ -294,9 +294,6 @@ void Session::initialize()
|
||||||
m_VideoCallbacks.setup = drSetup;
|
m_VideoCallbacks.setup = drSetup;
|
||||||
m_VideoCallbacks.submitDecodeUnit = drSubmitDecodeUnit;
|
m_VideoCallbacks.submitDecodeUnit = drSubmitDecodeUnit;
|
||||||
|
|
||||||
// Submit for decode without using a separate thread
|
|
||||||
m_VideoCallbacks.capabilities |= CAPABILITY_DIRECT_SUBMIT;
|
|
||||||
|
|
||||||
// Slice up to 4 times for parallel decode, once slice per core
|
// Slice up to 4 times for parallel decode, once slice per core
|
||||||
int slices = qMin(MAX_SLICES, SDL_GetCPUCount());
|
int slices = qMin(MAX_SLICES, SDL_GetCPUCount());
|
||||||
m_VideoCallbacks.capabilities |= CAPABILITY_SLICES_PER_FRAME(slices);
|
m_VideoCallbacks.capabilities |= CAPABILITY_SLICES_PER_FRAME(slices);
|
||||||
|
|
Loading…
Reference in a new issue