tags:

views:

47

answers:

1

I'm not even concerned with the camera per se. I want at the closest thing to the display screen. Meaning: it could even be the desktop the user is looking at, completw w/ the background and the icons she moves back and forth.

Let's say, at time t=1 sec, the app goes to pixel (78, 300) on that display and obtains its value. What may be at (78, 300) could be a portion of the icon or some speck of tree leaf on the photo being used as desktop background.

I'm familiar with BitmapFactory.decodeFile() for getting at the pixel contents of a file. But what about the display?

Thank you for any assistance.

A: 

Perhaps you could use an intent to call this app: http://handheld.softpedia.com/get/Others/Screenshot-Android-71410.shtml

and then process the resulting image file with BitmapFactor.decodeFile() ?

Josiah
Okay, that's an idea, but it might add a layer of cycles that would put a crimp in my performance. Is there any real time pixel acquisition in Android? If BitmapFactory can take from files, streams, and byte-arrays, then is there some real time stream or byte-array issued by the camera before a pict is snapped which I can intercept?
But it's a great idea; thanks. (How did *he* take the screen shot, right? That would be what I'm after.)
Someone who wrote a rough hack that requires root access posted a link to this source code, perhaps it can shed some light on your problem?http://android.git.kernel.org/?p=platform/system/core.git;a=blob_plain;f=adb/framebuffer_service.c;hb=HEAD
Josiah
Thank you very much for pointing to this. It's far and away more than what I had; it's the first code I've seen. I've been reading about how root access is required for most of what few hacks there are (save even more esoteric marshaled C code that I'm not even sure doesn't also require root).