【问题标题】:good and bad alpha-blank screenshot catching好的和坏的 alpha-blank screenshot 捕捉
【发布时间】:2018-01-29 09:19:07
【问题描述】:

我有几个电视盒,在不同的城市点通过 wi-fi 工作 - 显示视频广告。为了检查它们是否正确显示视频,我决定每隔一段时间截取屏幕截图并进行比较。好的,我通过这个命令截图:

adb shell screencap -p /sdcard/screen.png && adb pull /sdcard/screen.png

有时我会得到很好的屏幕截图:像这样的屏幕截图 Good screen 但有时我会得到这个: like alpha-channel
图片来自桌面monitor view 我在办公室测试了一个盒子,它有同样的错误。视频以这种方式播放:

Intent localIntent = new Intent(getBaseContext(), MediaObjectPlayerActivity.class);
                localIntent.putExtra("path", localPath);
                localIntent.putExtra("name", mCurrentPlay);
                localIntent.setFlags(FLAG_ACTIVITY_NEW_TASK);
                startActivity(localIntent);

有什么问题吗?什么是异常行为?谢谢。

【问题讨论】:

    标签: android adb wifi screenshot alpha


    【解决方案1】:

    所以,如果你想从 VideoView 中截取视频,你需要使用 MediaMetadataRetriever。这是一个很好的例子http://android-er.blogspot.ru/2016/04/capture-frames-in-videoview-using.html

    【讨论】:

      猜你喜欢
      • 2018-07-28
      • 1970-01-01
      • 2017-07-15
      • 1970-01-01
      • 1970-01-01
      • 2015-09-14
      • 1970-01-01
      • 1970-01-01
      • 2018-10-21
      相关资源
      最近更新 更多