【Server Core Audio Client On Win】【WIP】feat: add server core audio client for windows#134
【Server Core Audio Client On Win】【WIP】feat: add server core audio client for windows#134Jamlee wants to merge 2 commits intomkckr0:mainfrom
Conversation
|
You use Instead, you should use the receiving UDP packet as the timeline. They are directly controlled by IAudioCaptureClient. You can use condition variable to notify the playback thread when receive the UDP packet. |
|
@mkckr0 At first, using UDP packets as the timeline causes high CPU usage. On an 8 - core machine, the CPU utilization can reach 12%. This is not good for a small tool. I'm very curious about why RDP has such low resource consumption and can play real - time audio without any problems. |
|
The high CPU usage is always caused by busy waiting. Use condition variable to avoid it. The |
|
I test your branch. It seems like |

English Version
This is a flawed PR. I feel that it's quite challenging for me to tackle the last problem on my own, so I've opened this PR to ask for help. The current code can be compiled successfully. The usage is as follows:
I've spent approximately three weeks of my free time on this. During the implementation process, I've resolved the following issues:
pAudioClient->SetEventHandle(hEvent)event, I addressed the problem where CPU usage during playback reached up to12%.pAudioClient->IsFormatSupportedmethod to achieve comparable playback.WAVEFORMATEXformat while others support theWAVEFORMATEXTENSIBLEformat.In the end, there's still one problem remaining:
The efforts I've made are as follows:
中文版本(Chinese Version)
这是1个有缺陷的PR,最后的一个问题我感觉只凭我自己难以处理了,所以才开启这个PR,以寻求帮助。当前代码是完全可以编译的,使用方式如下:
我大概花了3周的业余时间,在实现的过程中解决了如下问题:
pAudioClient->SetEventHandle(hEvent)事件,解决播放过程占用 CPU 高达12%的问题。pAudioClient->IsFormatSupported。WAVEFORMATEX格式,而有的是WAVEFORMATEXTENSIBLE的问题。最终剩余下1个问题:
我做出的努力如下: