Reading framebuffer at lowest level possible under X
Daniele Tessaro
tessaro.daniele at gmail.com
Mon Apr 16 02:33:42 PDT 2012
Hello everybody,
I hope this is the right place for this kind of questions. Otherwise I
apologize for
bothering!
I've been searching a lot but I couldn't figure this out completely,
as I wasn't able to find
any documentation.
So this is my problem:
I want to read the framebuffer of the videocard at the lowest level
possible for a security application I'm writing.
I want to be as sure as possible that what I'm reading is exactly what
will be finally put on the bits of the hardware lighting the pixels of
the screen, and that no software layer is in the middle (or at least I
want to have the lowest number possible of layers in the middle, and I
want exactly to know who they are).
I've seen it's pretty easy to use X to grab the screen in a precise
moment, but that call is still passing through the X server (even if I
use shm).
Or I can grab /dev/fb0 using the framebuffer device, but that would
disable the HW acceleration, if I'm not
wrong. Also I can't actually figure out what exactly happen in the
kernel for managing /dev/fb0, and I need a very clear view of where my
data are being taken.
3D HW acceleration is not really necessary for the kind of application
I need, but I need the window manager to
run smoothly (I don't need special effects...a very simple wm is ok,
but for example moving a window around using fbdev is incredibly
slow!!).
I would like to have something really low level, even if this means
messing up with some ioctl with the video card and using libDRI and/or
libDRM. I haven't found any documentation of the API of these
libraries but for what I've understood they should fit my need.
Anything would be appreciated! Documentation, suggestions,
schemes...anything that would help me make a clear picture of this
problem.
Thanks a lot!
Daniele
More information about the dri-devel
mailing list