-
-
Notifications
You must be signed in to change notification settings - Fork 10.9k
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
How can I run scrcpy with screen turned off and phone never to go to sleep until I close scrcpy? #1310
Comments
As a workaround, you could temporarily change that in your device display settings.
No.
Probably.
I don't know.
You can't.
No idea, check the settings of these specific apps.
Yes.
And put your device in landscape mode. If your content is rotated because the camera "lies" to the system about the orientation (for performances/glitchs reasons) (#218), the next release have new options (check the
Enable your system flashlight.
https://github.com/rom1v/autoadb
Create a shell/batch script where you start your app before starting scrcpy: |
Thank you I have no coding skills "As a workaround, you could temporarily change that in your device display settings." how do I run autoadb? I'd like to either to auto open scrcpy when I plug in USB or open the camera app and screen off so that I can record directly on OBS.. do you think screen recording is draining the battery less than recording video with the phone and also is less heating? "#241" "Create a shell/batch script where you start your app before starting scrcpy:" I select only PC speaker and microphone as input and output but OBS still takes input from my studio condenser microphone, do you know why it could be so? Also OBS has wave 44.1 settings also 321 mp3 settings which its confusing why we set both but cant choose one, and by default it records 200kb mp3, but for my podcast, to have headroom for editing I need wave, if I record wave on a separate saw as I record video, do you think it would put too much stress on CPU and makes the video recording laggish? What is your suggestion? Thank you |
Hello, I'd really appreciate it if I could receive a response to the points I've shared in my post. Thank you |
Open a terminal ( Note that you could also switch fullscreen at any time via https://github.com/Genymobile/scrcpy/blob/master/README.md#fullscreen
That was just a workaround suggestion, with limitations… Another workaround:
I plan to implement a "stay awake" feature in the future (but it requires to implement a cleanup mechanism on the server executed on the device first).
Please read the README: https://github.com/rom1v/autoadb You need to build and execute the commands documented. Sorry, I have to time to make you a tutorial step by step.
It's the same I guess, the main consuming part is probably the video encoding (used in both cases).
Because for now there is none.
Please search "create batch file" in a search engine.
I have no idea.
Recording wave takes no CPU. Video recording from scrcpy takes almost no CPU on the computer. Capturing and encoding by OBS probably consumes a bit, but I can't tell, just test. Regards |
Thank you, Romain, for the quick response. I don't want to take too much of your time or this conversation to last forever so I'll summarize my main goals with scrcpy in a compiled way to make my goals more transparent and hence easier to follow. I appreciate your time spent on this. Thank you. CRITICAL PRIORITY: 1- I'm using scrcpy to project the camera to a bigger screen, recording the projected view on the screen as a replacement of recording video with the phone to overcome the limit of 4gb file and thus video duration limit. Do you think the quality of the screen recording will be similar to recording with phone video? What are your suggestions that would maximize the quality and still yield smooth non-laggy videos without the time and file size limit using scrcpy and OBS together with my Samsung S7 and Thinkpad X230? I aim for a 20k bit rate rather than the OBS's or Screencastify's 3k video-rate outputs thinking increased bit rate might increase the overall quality, would you agree? (Is OBS the best for my purpose (capturing phone camera app projection on screen or are there better apps that you can recommend that would produce more quality videos with better bitrates?) What parameters among these would maximize the output video quality?
2- Is there any way I can use my phone as a webcam on my PC using scrcpy, OBS virtual cam didn't recognize the phone. Do you know how this can be done? Would recording videos using the phone as webcam via scrcpy on OBS would yield higher quality videos over recording the projected camera view on a PC monitor? If yes how can I make this happen? NORMAL PRIORITY: 3- I'd like to have a shortcut of scrcpy such that as soon as I run scrcpy I'd like the phone to be awake until I close the scrcpy and its screen automatically turned off to save phone battery. How can this be done? (so that no command prompt code will be necessary each time) 4- I'd like to have a shortcut of scrcpy such that as soon as I run it, it will go into full screen and open the last app before I closed scrcpy last time so that I can right away start recording camera screen via OBS as this is my sole purpose of using scrcpy. Opening last app is more crucial than the full screen. How can this be done? (so that no command prompt code will be necessary each time) 5- What are hte most popular uses of scrcpy by its users? It's a very lightweight, smooth program as far as I see and I like that it uses cable so the connection is probably faster than probably laggy wireless ways.. Most apps on phone can be accessed on pc browsers. If for Instagram messaging even there is extension for that on chrome browser. So what are some creative uses people find with scrcpy so that I can be inspired by these.. LOW PRIORITY: 6- When recording the projected view of the camera app of the phone on PC screen, is there any encoding on phone end? I guess the phone does not drain much battery because it doesnt record video but only projects the screen which doesnt involve encoding I guess right? 7- "Video recording from scrcpy takes almost no CPU on the computer." P.S: I'm using open camera thereby removing the buttons and yellow focus circles of S7 native app These are the other 2 threads I also commented on that are related to this topic and I thought you might want to know or check out: https://obsproject.com/forum/threads/obs-virtualcam.71741/page-21#post-451347 All the best and peace, Ceyhun |
Hello Romain Could you please confirm that you've received a notification to my latest message here because I can't be sure as the topic is closed whether you receive a notification. I wanted to confirm you've received this message so that I won't need to open a new ticket. Thank you |
Yes, I receive notifications on closed issues. I will read the message later. |
Thank you. I took extra care to write them as concisely as possible to make the exchange smoother. I wonder about your opinion to those points and would love to read your responses soon
Thank you Romain
Ceyhun
…________________________________
From: Romain Vimont <[email protected]>
Sent: Thursday, April 30, 2020 18:59
To: Genymobile/scrcpy <[email protected]>
Cc: ceyhun242 <[email protected]>; Author <[email protected]>
Subject: Re: [Genymobile/scrcpy] How can I run scrcpy with screen turned off and phone never to go to sleep until I close scrcpy? (#1310)
Yes, I receive notifications on closed issues. I will read the message later.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub<#1310 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/APJUQDPLEHDNUKB5VQOXQMLRPGN6XANCNFSM4MOVJE2A>.
|
If the surface has a definition different from your camera, then the result will not be the same. Technically, it would probably be better to create an Android application which could access the device webcam (since scrcpy cannot do it yet #241).
If you just want to record (without broadcasting), why do you need OBS? Just use
Increase encoding bitrate (
No. #776
Create a .bat file in the scrcpy folder containing:
Then double-click on it.
You need some mechanism to know which app was launched. I don't know.
I guess testing apps during Android development, typing text, presentations...
Yes, the device does the whole encoding, it uses a dedicated hardware chip. It could not transmit the whole raw unencoded video, the bitrate would be huge.
Both, encoding is always done on the Android device. The computer decodes the video to display it (typically with a hardware decoder). |
The future is now: #631 (comment) |
this was a tremendous help thanks a lot |
@blitznats Please, could you show me how the code was inside your txt.bat file? |
Hello, sorry for my late feedback i didnt check my emails if any help is need let me know |
@blitznats FYI, you could use |
Thanks for this great app. So smooth, simple and effective. I'm using Samsung S7
How can I run scrcpy with screen turned off and phone never to go to sleep until I close scrcpy so that when I record its camera screen (using it as a webcam/camera) the recording would never stop until I stop it. Also is there a time limit to recording screen of the phone's camera view via scrcpy?
Also If I set my phone resolution to by WDHQ instead of FHD, would that increase my camera view quality when I open the camera app to screen record or use it as a webcam? If I enable video enhancer mode would that also enhance my camera view so that when I screen record on my PC the quality would be better?
When I use screen recording apps and record s7 camera, there are yellow circles and AF notification when I move swiftly on the screen and the recording app captures these, how can I not see them in the record or prevent them from popping up?
Is there a way to have scrcpy work in full screen in landscape mode?
Also the flash is opened only when I hit record on the phone app, how can I force the flash to be on even if I dont press recording on the native camera app so that my screen recorder can record me under good light?
Finally how can I use scrcpy as a webcam on windows? Also scrcpy can work via wifi as well? Would the ocnnection be more laggish and screen recording the video camera would have inferior quality over wifi compared to usb?
Also is there a way I can get my computer to run scrcpy as soon as I plug it into my PC?
Also can I set a default app to open when I run scrcpy so that it can right away open camera for OBS to start recording it. Or if I can set my camera to be webcam, there may be no need for this default app feature..
Thank you
The text was updated successfully, but these errors were encountered: