views:

349

answers:

1

I am looking to create a very simple C# application which runs Full-Screen in Direct3D, and is able to grab the Desktop 'scene', mapping each Window from the Desktop to a Textured Polygon in my D3D Scene...

I'm hoping to create a simplistic "3D Desktop" type of application as an experiment, and I'm wondering if there is a specific method for doing something like the following:

1)Get a list of all the Windows open on the Desktop (List of HWNDs?).

2)Grab the X,Y position of each Window, as well as the Width and Height.

3)Grab the Rendered image of each Window (magic happens here).

4)Create a new Texture/Surface in D3D using the Width and Height of the Window(s), and apply the Image we grabbed as a Texture.

Is there an efficient 'best practice' for acquiring the actual image(s) being rendered to the Desktop?

Is there also a 'best practice' for "extending the desktop" to a virtual second, third, etc. "desktop" and being able to swap between them, including creating a unique instance of the task-bar for each virtual desktop.

Thanks a million for any suggestions!

A: 

im digging in a similar direction. so far i've found several attempts which show possibilities but dont work 100% as I need, heres the best shot so far: http://www.codeproject.com/KB/cs/csdesktopswitching.aspx let me know if u find any solutions for points 1-3. if i think about it, why not using the DWM and get the "thumbnails" sized to the orogonal size?

stas