scrcpy icon indicating copy to clipboard operation
scrcpy copied to clipboard

The pyscrcpy client in python is using 90% of my cpu but the scrcpy.exe only uses 10%

Open mikiboii opened this issue 1 year ago • 5 comments

The pyscrcpy client in python is using 90% of my cpu but the scrcpy.exe only uses 10%

Please can someone show me how to do it in cpp or show me how to fix the pyscrcpy client library

mikiboii avatar Oct 19 '24 17:10 mikiboii

I don't know the pyscrcpy client library. You should ask on their repo maybe?

rom1v avatar Oct 19 '24 18:10 rom1v

But can u show me a simple way to connect to the scrcpy-server.jar in cpp and display the recived frame I have a code that connects to the server and recive the frame but it's h264 encoded and I have tried to use ffmpeg but I keep failing on the decoding and displaying part. Please please help.

mikiboii avatar Oct 19 '24 18:10 mikiboii

The pyscrcpy client in python is using 90% of my cpu but the scrcpy.exe only uses 10%

Please can someone show me how to do it in cpp or show me how to fix the pyscrcpy client library

MYScrcpy may help you. See myscrcpy/core/* With Video/Audio/Control protocol in python with scrcpy V2.7

Thanks to rom1v and scrcpy again for provided such a great tool! :thumbsup: :thumbsup: :thumbsup:

me2sy avatar Oct 27 '24 12:10 me2sy

Thanks alot for your help but I finally decoded the h264 encoded data using pybind11 and using python for the decoding of the frame. But I think a simple example should still exist on just the decoding and displaying it in cpp because there isn't alot of video on how to decode with ffmpeg and it's hard. Thanks

mikiboii avatar Jan 11 '25 10:01 mikiboii

I also use pyscrcpy client in python. I noticed that the delay of pyscrcpy is much higher than that of scrcpy. Have you encountered the same problem?

GreenFinger6 avatar May 26 '25 16:05 GreenFinger6