Sign in to follow this  
Liquidream

How can I render to Windows desktop?

Recommended Posts

Hi all, I am very interested in being able to render in 3D to the windows desktop. Basically I want to create a "3D desktop replacement" which covers the screen, but leaves the Taskbar visible. From looking around here & the Net, it looks like this can be done in (at least) two ways: 1) Having the application render to the Active Desktop (ActiveX?) layer when Active Desktop is enabled in windows. This seems to be preferred, but seemd to require a "Hook?" to avoid flickers/losing screen when pressing "Show Desktop" icon? (This seems to be the PREFERRED way of doing this) 2) Creating a window the same size of the desktop, then forcing the windows z-order to the "bottom of the pile" and intercept all window-ordering messages to KEEP IT at the farthest back. Not sure how this will work with the "Show Desktop" icon, may still get minimised (when I don't want it too). I have seen very little source code on the Net for how to accompligh either method above, and unfortunately have very little Win32 coding experience. I can figure the rest out once I know how to actually CREATE the window how I want it. If anyone has any code or ideas that could help achieve this, I'd very much appreciate it. Thanks in advance! Paul

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
I downloaded a code example on how to do this while back.

The code essentially hooked onto the background DC? And was able to render underneath the icons.

However, the code caused the icons to flicker. In addition, the icons have shaded borders to the background, so if you draw something underneath them, the borders of the icons are gonna clash with whatever your drawing under them.

But.. if you don't have icons on your desktop, this won't be a problem. [razz]

Sorry, I forget the address to the site, a google search should be able to find it again though.

Share this post


Link to post
Share on other sites
i worked a bit on this topic. you can find a thread here that may be of some help : http://www.gamedev.net/community/forums/topic.asp?topic_id=263025
obtaining a "perfect" result is tricky, a lot of things need to be taken care of, and there's not a lot of informations available.
anyway, all in all, it's not that hard.. good luck.

Share this post


Link to post
Share on other sites
The GetDesktopWindow() API call returns a handle to the desktop window. With that you can get the desktop DC, etc.

That's all I know about it.

Share this post


Link to post
Share on other sites
you can do some nice things with GetDesktopWindow() & FindWindow() APIs.
to get a perfect result it won't be enough though, you'll have to look into dll injection (the simpler solution for this is to use windows hooks), and windows subclassing (in order to prevent some of the messages sent to the desktop window to reach its destination).

Share this post


Link to post
Share on other sites
Quote:
Original post by Eddycharly
to get a perfect result it won't be enough though, you'll have to look into dll injection (the simpler solution for this is to use windows hooks), and windows subclassing (in order to prevent some of the messages sent to the desktop window to reach its destination).


Do you know more about this? Maybe you can drop me an advice here I would really aprecciate if you could.

Thanks.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this