Drawing "on top of" the desktop (what to use? overlay?)
Posted on 2003-03-15
I'm looking for a means to do the following. I need to create a layer infront the windows desktop in which I can draw over top of the desktop, and have it stay there, not interfering any apps below. It has to cover top most windows and everything.
I would really like to find a way of doing this that uses the video card rather than CPU time. The first thing I tried was creating a full screen regular window, and using a tranparency:
SetWindowLong(m_hWnd, GWL_EXSTYLE, GetWindowLong(m_hWnd, GWL_EXSTYLE) | WS_EX_LAYERED);
SetLayeredWindowAttributes(RGB(255,0,255),255, LWA_COLORKEY | LWA_ALPHA);
This sort of works, but it seems pretty slow, and other Top Most windows will cover it if they are clicked. I would also like clicks to go "through" the drawing, which they obviously don't.
I'm looking for other ways that I can do this. Is it possible to do this with DirectDraw somehow? It would be great if I could create a surface that is mostly trasparent, but covers the whole desktop.
Thanks in advance!