Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Overheating, Gaming problem #5586

Closed
tuevudeptrai opened this issue Dec 2, 2024 · 10 comments
Closed

Overheating, Gaming problem #5586

tuevudeptrai opened this issue Dec 2, 2024 · 10 comments

Comments

@tuevudeptrai
Copy link

LT and RT are now usable when I use LHLaurini Scrcpy, Tho I still have overheating issues can someone help me with it, and why do the LHLaurini able to use LT and RT tho the 3.0 version are not, I've try emulate a ps4 and the gamepad tester said it's a xbox 360, meant that LHlaurini version are emulated another controller so why can't do that on the 3.0 ver, and can you add another setting to change the encoder from phones to PC because it's getting overheating whenever I gaming

Mi 10
Android 13

Window 10

@rom1v
Copy link
Collaborator

rom1v commented Dec 2, 2024

why do the LHLaurini able to use LT and RT tho the 3.0 version are not

The initial version from LHLaurini uses uinput, while scrcpy uses uhid (#2130 (comment)):

The main difference is that it injects events in UHID format to /dev/uhid, while this PR injects events in the UINPUT format to /dev/uinput.

The reason why it is problematic to use uinput is that it requires a call to ioctl(), which cannot be easily performed in Java, so it requires either a native dependency or to add native code, which I would like to avoid in scrcpy.

The gamepad in scrcpy is implemented by #5270:

There was a PR (#2130) implementing gamepad support using uinput on the device. However, this required to add a native dependency or to add native code (cf #2130 (comment)).

This PR uses HID instead, and provides support for AOA and UHID (like for keyboard and mouse).
It does not add any dependency, and it also works in OTG mode (via AOA), so even without USB debugging.

In addition, as I said in #5559 (comment), the implementation in scrcpy by #5270 uses a generic controller, and it turns out that some games do not behave correctly with a generic controller.

To fix that, we would need to add a feature to simulate a well-known controller: #5362 (comment)

Overheating

Running a game and encoding the screen consumes resources, depending on the device hardware it might heat.

You can reduce the resolution/bit rate, or try another encoder/codec (depending on your device): https://github.com/Genymobile/scrcpy/blob/master/doc/video.md

@tuevudeptrai
Copy link
Author

but the LHLaurini version I can't change the encoder, how can I change it

@rom1v
Copy link
Collaborator

rom1v commented Dec 2, 2024

The version you use from LHLaurini was a fork from an old scrcpy version, so it's an old version without all the new features and fixes.

I didn't check, but it migbt be a version where --video-encoder was named --encoder (before audio forwarding was implemented).

@tuevudeptrai
Copy link
Author

I was using scrcpy normally until today (still using scrcpy 3.1 or smth) the phone got overheating, first I thought It's because I tweak the hardware a little bit but then I try to turn off scrcpy it drop from 77 Celcius to 40 Celcius
image
mostly at 70 degrees sometime it'll jump to 77 and almost 80
image
image

I only plug in for like a few sec and It just rapidly jump from 40 to 78

@rom1v
Copy link
Collaborator

rom1v commented Dec 24, 2024

Try reducing the resolution (scrcpy -m1024).

Encoding a video consumes resourced, in general hardware encoders are quite efficient, but game+encoding may be too much (it probably depends on the device hardware).

@tuevudeptrai
Copy link
Author

This literally never happens before I've said before that it overheating but not like this, and my phone hardware is kinda good, it can handle genshin impact max setting at 60fps, I've reduce the resolution to 1366 too but it didn't work

@tuevudeptrai
Copy link
Author

image
idk what's wrong but when I tried to run scrcpy without turn of the screen it do not overheat, but idk why the fps are so low like it's only 10fps or smth

@tuevudeptrai
Copy link
Author

image
it does get stuck at 11 fps

@rom1v
Copy link
Collaborator

rom1v commented Dec 28, 2024

See #3376 #4587.

@tuevudeptrai
Copy link
Author

turn out everything are ok now after I use a replace a new screen on my phone, I've take it off and that's maybe the reason

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants