Alpha-Blended DirectX Overlay
Hi,
I would like to create an overlay with a surface that overlays another surface. The specific application is to take the video rendered from a AX control drawing using DX, then create an menu overlay with another DX surface and have the menu alpha-blended over the video surface.
So far I have tried a transparent dialog box, but the video underneith flickers as the region is invalidated. The overlay box fades in and out perfectly, but only when the overlay menu is completely faded out does the video stop flickering.
I do not have control over the video surface, so I would like to do it as a seperate overlay surface.
Any advice or hints would be greatly appreciated!
Bob Scheffler
negative - I have the same problem here. I have a GDI+ control over the top of an AX control. The GDI+ control uses an SVG library to render SVG via GDI+. The AX control is either Windows Media Player or Quicktime. Basically, the SVG displays fine if the video isn't playing, but once the video is playing, it overlays itself on the GDI control and hides the drawing. Pause the video, click on the control and the GDI shows again. Basically, I would like to to the same thing as the first poster and am wondering if it's at all possible to overlay my own surface over, or mix with, the AX control's overlay?
In Quicktime preferences -> Advanced -> Video
You have two options:
*GDI (which is what you're refering to?)
*Direct X + DirectDraw Acceleration
Are you SURE they don't both render the same way?
Ok. Firstly, the preferences in the player DO affect the control. If I disable DirectX rendering, the GDI drawing stays there fine (same for WMP, by turning off hardware acceleration).
Keeping this in mind, is there any way for me to generate an overlay to keep my GDI control over the top of the overlay (or DirectDraw canvas, in QT's case)?
I know DirectDraw overlays (rather than DirectShow) are deprecated, but is there any way to use that? The problem I ran into when I tried that was that DirectDraw overlays do not have alpha transparencies, as far as I could see.
Failing that, I might just have to use the source code from Media Player Classic to control the playing of Quicktime files myself....
The latest quicktime version does not use DirectShow so no way to use that unless you are going to write a QT decoder filter.
You can use a DirectDraw overlay which is a hardware overlay. You can use the DirectShow playwnd sample.