adb shell screenrecord --time-limit 20 /sdcard/test.mp4

–time-limit 设置时间长度,默认180秒
Ctrl+C 结束录屏

通过screenrecod --help帮助命令查看提示选项:

 $ screenrecord --helpUsage: screenrecord [options] Android screenrecord v1.2.  Records the device's display to a .mp4 file.Options:--size WIDTHxHEIGHT    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    Set the video bit rate, in bits per second.  Value may be specified as    bits or megabits, e.g. '4000000' is equivalent to '4M'.  Default 20Mbps.--bugreport    Add additional information, such as a timestamp overlay, that is helpful    in videos captured to illustrate bugs.--time-limit TIME    Set the maximum recording time, in seconds.  Default / maximum is 180.--verbose    Display interesting information on stdout.--help    Show this message.Recording continues until Ctrl-C is hit or the time limit is reached.

更多相关文章

  1. android 8.0 开发者选项,默认打开 使用HW叠加层(关闭硬件加速)
  2. 阅读《Android 从入门到精通》(28)——使用 XML 的选项菜单
  3. Android 选项卡功能的实现
  4. android之首选项相关 Preferences(一) (转)
  5. android 对话框之——带单选列表、带多选项列表、按钮等问题
  6. android Fragment FragmentActivity 选项卡 replace add hide sh
  7. android:设计一个具有3个选项的菜单程序,当单击每个选项时分别跳
  8. 2.4.7 选项卡的功能和用法
  9. 选项卡TabHost

随机推荐

  1. android的小疑点:You need to use a Theme
  2. 在eclipse右键new菜单项中添加android ap
  3. 检测手机类型正则表达式
  4. android代码常识
  5. ArcGIS API for Android(安卓)案例教程 1
  6. Android requires compiler compliance l
  7. 学习网址
  8. Android 6.0 PowerManagerService 一
  9. Activity 的Managing Tasks属性
  10. Android的settings命令