以设备屏幕截图,同时应用接近 [英] Taking device screenshot while application is close

查看:153
本文介绍了以设备屏幕截图,同时应用接近的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我知道这个问题是问的次数,但等到我问不同的东西。

I know this question is ask number of times but wait i am asking something different.

我按照职位和能够承担的屏幕截图。但有可能当我的应用程序关闭采取截屏。

I follow this post and able to take screen shot. but is it possible to take screen shot when my application is closed.

咋办我设置定时器像后1小时和关闭我的应用程序。然后正好1小时后的设备需要采取截屏无论在屏幕上。

Supposed i set timer like after 1 hour and i close my app. Then exactly after 1 hour device need to take a screen shot whatever on a screen.

这可能与后台服务

我已经跟随code和也做了一些研究,但是这可能吗?结果
是否有必要根设备采取截图。

I already follow code and also did some research but is this possible?
Is it necessary to root device to take screenshot.

请给我任何提示或引用。结果
提前致谢。

Please give me any hint or reference.
Thanks in advance.

推荐答案

尝试使用。调用该库的方法,由服务

Try using : call the methods in this library from service.

HTTP://$c$c.google.com/p / Android的截图库/

Android的屏幕截图库(ASL),可通过编程捕获Android设备的屏幕截图,无需root访问权限的要求。相反,翔升利用在后台运行的本地服务,通过Android调试桥(ADB)每台设备的引导启动一次。

Android Screenshot Library (ASL) enables to programmatically capture screenshots from Android devices without requirement of having root access privileges. Instead, ASL utilizes a native service running in the background, started via the Android Debug Bridge (ADB) once per device boot.

DeveloperGuide

更新:

在参考中提到的方法将无法在这种情况下工作,因为它读取绘制,并在应用程序上下文的看法。在这里,如果应用被关闭,那么你不能得到这方面(AT-至少在非根植电话)。

The method mentioned in your reference will not work in that case, as it reads the view that are drawn and in application context. where as if application is closed then you cant get that context.( at-least on non rooted phone).

在植根设备,您可以阅读完整的帧缓冲所以无需担心应用程序上下文。

On rooted device you can read complete frame-buffer so no need to worry about the application context.

我也试过一次使用ASL和它的工作对我有好处。

I did tried to use the ASL once and it worked out good for me.

这篇关于以设备屏幕截图,同时应用接近的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆