DWM features in Vista

C

Chris Hill

I'm looking for more information about the DWM and associated
technologies. I looked in dwmapi.h and the SDK documentation for
those APIs, but I guess I was expecting more functionality than I am
seeing there. It seems like the features exposed are specifically
related to Microsoft needs (like glass) and Alt+Tab, but that there
isn't much beyond that in terms of generically producing information
for or consuming information from the DWM.

For example:
Can windowed Direct 3D and/or OpenGL rendering be composited with the
desktop using the alpha channel generated using those APIs?

Could I implement my own variant of Flip 3D or is that using private
APIs?

It may be that there just isn't any more functionality that is
publically exposed currently, but I wanted to verify that and make
sure I'm not looking in the wrong place.

Thanks,

Chris
 

My Computer

P

Pablo Fernicola [MS]

An excellent source of information on the DWM is Greg Schechter's blog at
http://blogs.msdn.com/greg_schechter/default.aspx

> Can windowed Direct 3D and/or OpenGL rendering be composited with the
> desktop using the alpha channel generated using those APIs?


Yes, that would happen automatically.

> Could I implement my own variant of Flip 3D or is that using private
> APIs?


You can't replace the behavior in the desktop, but you can write your own
application to do something with the thumbnails of running applications,
like Flip3D.

-Pablo

"Chris Hill" <[email protected]> wrote in message
news:[email protected]
> I'm looking for more information about the DWM and associated
> technologies. I looked in dwmapi.h and the SDK documentation for
> those APIs, but I guess I was expecting more functionality than I am
> seeing there. It seems like the features exposed are specifically
> related to Microsoft needs (like glass) and Alt+Tab, but that there
> isn't much beyond that in terms of generically producing information
> for or consuming information from the DWM.
>
> For example:
> Can windowed Direct 3D and/or OpenGL rendering be composited with the
> desktop using the alpha channel generated using those APIs?
>
> Could I implement my own variant of Flip 3D or is that using private
> APIs?
>
> It may be that there just isn't any more functionality that is
> publically exposed currently, but I wanted to verify that and make
> sure I'm not looking in the wrong place.
>
> Thanks,
>
> Chris
 

My Computer

C

Chris Hill

On Sun, 18 Jun 2006 23:07:37 -0700, "Pablo Fernicola [MS]"
<[email protected]> wrote:

>An excellent source of information on the DWM is Greg Schechter's blog at
>http://blogs.msdn.com/greg_schechter/default.aspx


Thanks, there is a bunch of good information there. I hope this sort
of conceptual overview information makes it to the docs at some point.

>> Can windowed Direct 3D and/or OpenGL rendering be composited with the
>> desktop using the alpha channel generated using those APIs?

>
>Yes, that would happen automatically.


Excellent. I'll write a Direct3D app to test this. You're saying I
don't need to call any API to make this happen, the client area of my
window will automatically be composited with the desktop if I am using
an alpha enabled buffer format?

I'm using Beta 2 x64 if that makes a difference.

>> Could I implement my own variant of Flip 3D or is that using private
>> APIs?

>
>You can't replace the behavior in the desktop, but you can write your own
>application to do something with the thumbnails of running applications,
>like Flip3D.
>
>-Pablo


How can I get the thumbnails? I didn't see an API to do this. I can
have the DWM paint a 2D thumbnail at a cetain location within a given
window for me (like Alt+Tab does), but I don't see a way to get the
raw data so that I can do my own 3D rendering with it.

Thanks,

Chris

>"Chris Hill" <[email protected]> wrote in message
>news:[email protected]
>> I'm looking for more information about the DWM and associated
>> technologies. I looked in dwmapi.h and the SDK documentation for
>> those APIs, but I guess I was expecting more functionality than I am
>> seeing there. It seems like the features exposed are specifically
>> related to Microsoft needs (like glass) and Alt+Tab, but that there
>> isn't much beyond that in terms of generically producing information
>> for or consuming information from the DWM.
>>
>> For example:
>> Can windowed Direct 3D and/or OpenGL rendering be composited with the
>> desktop using the alpha channel generated using those APIs?
>>
>> Could I implement my own variant of Flip 3D or is that using private
>> APIs?
>>
>> It may be that there just isn't any more functionality that is
>> publically exposed currently, but I wanted to verify that and make
>> sure I'm not looking in the wrong place.
>>
>> Thanks,
>>
>> Chris

>
>
 

My Computer

C

Chris Hill

On Mon, 19 Jun 2006 14:09:07 GMT, [email protected] (Chris Hill) wrote:
>>> Can windowed Direct 3D and/or OpenGL rendering be composited with the
>>> desktop using the alpha channel generated using those APIs?

>>
>>Yes, that would happen automatically.

>
>Excellent. I'll write a Direct3D app to test this. You're saying I
>don't need to call any API to make this happen, the client area of my
>window will automatically be composited with the desktop if I am using
>an alpha enabled buffer format?


I tried it an it didn't work. Do I need to use a particular version
of Direct3D or make a special D3D call? Is there a flag I need to set
on the window or an API call I need to make so that Direct3D knows
that I want it to composite with the desktop? I thought there might
be some special setup required, but I haven't been able to find any
documentation about the subject.

The blog entry seems to indicate that DirectX will handle the
communication with the DWM to configure a shared surface (and that I
don't need to do anything special to get a shared surface).

Is there a sample available of a desktop compositing Direct3D
application?

Chris
 

My Computer

P

Pablo Fernicola [MS]

Any application running on Windows Vista, with DWM/Aero enabled, is
composited, without the application having to make any calls. You don't
have to select any special formats.

You will notice that the application gets the glass looking borders, has
live previews in Alt-Tab and taskbar thumbnails, and its contents show up in
Flip3D. This is indeed done by using a shared surface, between Direct3D and
the DWM.

Perhaps you were after having the application content "blended" with the
desktop's background, like windowless controls? If that was the feature you
were after, that is not something that is enabled by the DWM.

-Pablo


"Chris Hill" <[email protected]> wrote in message
news:[email protected]
> On Mon, 19 Jun 2006 14:09:07 GMT, [email protected] (Chris Hill) wrote:
>>>> Can windowed Direct 3D and/or OpenGL rendering be composited with the
>>>> desktop using the alpha channel generated using those APIs?
>>>
>>>Yes, that would happen automatically.

>>
>>Excellent. I'll write a Direct3D app to test this. You're saying I
>>don't need to call any API to make this happen, the client area of my
>>window will automatically be composited with the desktop if I am using
>>an alpha enabled buffer format?

>
> I tried it an it didn't work. Do I need to use a particular version
> of Direct3D or make a special D3D call? Is there a flag I need to set
> on the window or an API call I need to make so that Direct3D knows
> that I want it to composite with the desktop? I thought there might
> be some special setup required, but I haven't been able to find any
> documentation about the subject.
>
> The blog entry seems to indicate that DirectX will handle the
> communication with the DWM to configure a shared surface (and that I
> don't need to do anything special to get a shared surface).
>
> Is there a sample available of a desktop compositing Direct3D
> application?
>
> Chris
 

My Computer

C

Chris Hill

On Tue, 20 Jun 2006 06:52:41 -0700, "Pablo Fernicola [MS]"
<[email protected]> wrote:
>You will notice that the application gets the glass looking borders, has
>live previews in Alt-Tab and taskbar thumbnails, and its contents show up in
>Flip3D. This is indeed done by using a shared surface, between Direct3D and
>the DWM.


With my user's hat on, I have observed the non-client area glass
styling and shadows as well as Alt+Tab and Flip3D.

With my developer's hat on, I have seen references to shared surfaces
being used by the DWM and noted that there is an updated version of
Direct3D 9 to support them. Is there any way that an application that
I write can access the DWM owned shared surfaces in the same way that
Flip3D does? (Actually I am interested in either consuming or
producing them)

>Perhaps you were after having the application content "blended" with the
>desktop's background, like windowless controls? If that was the feature you
>were after, that is not something that is enabled by the DWM.


Yes, that's correct, I am asking about blending application content
with the desktop. There are DWM APIs to extend the glass effect into
the client area of a window. I'm assuming the Win32 user functions
UpdateLayeredWindow and SetLayeredWindowAttributes (which do support
blending the application content) were reimplemented to use the DWM,
and they work very well. Given that this level of support exists, I
am surprised that there doesn't appear to be a simple flag to enable
to make a window (including the client area) simply blend with the
desktop. This would be very handy for a floating object window with
3D content for instance.

I'm somewhat disappointed that this functionality isn't exposed.

Thanks,

Chris
 

My Computer

Top