On Thu, 18 Jul 2002, Preetham wrote:
> Thanx Mark,
> Before i get to clarifying what my last question in the prev mail was
> about, i have another
> doubt.
> I was reading thru the server architecture document and came accross the
> Shadow FB Engine.
> "The Shadow FB engines use Keith Packard's FB drawing procedures wrapped
> with his Shadow layer that allows drawing to an offscreen framebuffer
> with periodic updates of the primary framebuffer."
> What i understood by this is, i can create a copy of the framebuffer in
> the memory(possibly save it to the hard drive) and use it like a windows
> bitmap. This bitmap will have the image of the screen(Eg: a linux
> desktop equivalent to a windows desktop snapshot).
The shadowfb wraps rendering functions and tells you which parts
of the framebuffer has been updated. The common usage is to put
the framebuffer (what all the rendering code thinks is the framebuffer)
in system memory so that all rendering goes into that. Shadowfb's
callbacks telling you which parts have been modified would allow you
to copy those parts from the system memory buffer to another buffer
(such as a video ram buffer) keeping those two buffers in sync.
However, since the X-server is now rendering in system memory you
have eliminated the possibilty of hardware acceleration.
You could do just the opposite though, and have shadowfb wrap
rendering into the video ram framebuffer and you could get informed
of modified areas. A layer that did this could probably be
installed as an extension module and work with all drivers without
any modifications to the core X-server binary.
> What i meant by my last question was: If my preveious inference is
> correct, then can i use this
> Shadow Engine, or write an engine of my own that would capture the
> graphic information of only the active window(top level window) of the
> screen.
> What i am looking to do is, open an appication and only capture the
> graphics related to the
> window the application opens.
You could modify shadowfb to inform you only about updates to particular
windows, yes. Well, a corner case is when somebody draws on a parent
of that window with IncludeInferiors, for example when the window manager
draws XOR'd lines on the root window when placing windows. If you just
trapped for actions on your window you wouldn't see that, but it may
be that you're not interested in capturing that. Other corner cases
are that you won't know about OpenGL rendering because it would be
direct rendered by the client without X-server involvement.
What is the intended purpose? Are you trying to monitor particular
windows remotely? Was the idea to have the X-server notify when there
was new data and provide minimum updates or something?
Mark.
_______________________________________________
Xpert mailing list
[EMAIL PROTECTED]
http://XFree86.Org/mailman/listinfo/xpert