溫馨提示×

溫馨提示×

您好,登錄后才能下訂單哦!

密碼登錄×
登錄注冊×
其他方式登錄
點擊 登錄注冊 即表示同意《億速云用戶服務(wù)條款》

android設(shè)置adb自帶screenrecord錄屏命令

發(fā)布時間:2020-09-09 18:44:24 來源:腳本之家 閱讀:259 作者:lidx0714 欄目:移動開發(fā)

android 設(shè)置system/bin目錄類似linux,該目錄下有許多實用命令,類似

adb,sh,top,app_process,chmod,chown,dmesg,reboot,screenrecord等等。

錄屏作用:qa測試過程中有的bug需要還原現(xiàn)場,此時用手機(jī)拍攝有諸多不便,此時可以利用錄屏命令自動完成錄屏,然后上傳bug視頻。

其中screenrecord命令錄制視頻到內(nèi)部存儲:

錄制命令:

adb shell screenrecord --size 1920x480 /storage/sdcard0/demorecord.mp4

時間設(shè)置:

adb shell screenrecord --time-limit 100 /storage/sdcard0/demorecord.mp4

停止錄制:

Ctrl + C會停止命令,自動停止錄制。

參數(shù)設(shè)置:

$ adb shell screenrecord --help
Usage: screenrecord [options]
Records the device's display to a .mp4 file.
Options:
–size WIDTHxHEIGHT 設(shè)置屏幕寬高,一般根據(jù)自己手機(jī)設(shè)置,最大支持1920x480。
Set the video size, e.g. “1280x720”. Default is the device's main
display resolution (if supported), 1280x720 if not. For best results,
use a size supported by the AVC encoder.
–bit-rate RATE 設(shè)置bit率
Set the video bit rate, in megabits per second. Default 4Mbps.
–time-limit TIME 設(shè)置錄制時間,默認(rèn)最大時長180秒
Set the maximum recording time, in seconds. Default / maximum is 180.
–rotate 旋轉(zhuǎn)輸出
Rotate the output 90 degrees.
–verbose
Display interesting information on stdout.
–help
Show this message.
Recording continues until Ctrl-C is hit or the time limit is reached.

總結(jié)

以上所述是小編給大家介紹的android設(shè)置adb自帶screenrecord錄屏命令,希望對大家有所幫助,如果大家有任何疑問請給我留言,小編會及時回復(fù)大家的。在此也非常感謝大家對億速云網(wǎng)站的支持!

向AI問一下細(xì)節(jié)

免責(zé)聲明:本站發(fā)布的內(nèi)容(圖片、視頻和文字)以原創(chuàng)、轉(zhuǎn)載和分享為主,文章觀點不代表本網(wǎng)站立場,如果涉及侵權(quán)請聯(lián)系站長郵箱:is@yisu.com進(jìn)行舉報,并提供相關(guān)證據(jù),一經(jīng)查實,將立刻刪除涉嫌侵權(quán)內(nèi)容。

AI