Not sure if this is the right forum, but here goes.
I've been struggling to create a very simple DirectShow application that will display a live video stream in a window of our choosing with text overlay. I can get the video stream to show, but always in its own window, not the main form. Also, the attempts at text overlay have met with limited success, either not displaying or only showing the text in the main window sans video.
The test project that's attached will show you what I'm talking about. The commented sections, such as the VMR stuff, are part of the myriad tests I've been doing.
Does anyone understand DirectShow?
I've been trying to learn, but I think I'm missing something and I really can't figure out what I'm doing wrong.
I've been stuck on this problem for 2 months now with almost no progress.
I attempt to output video in windowless mode to my window, but it always draws to its own window. And when I attempt to overlay text, either the text show up on my window over a "black" image (obviously not my input video source), or nothing is displayed at all.
Perhaps I'm misreading your question, but my understanding of DirectX is that the window is superfluous. It is only used for its rectangle as an indicator to the area reserved for DirectX output. Any GDI, etc, graphics operations using the windows handle will necessarily fail because the area is already reserved for direct screen memory access.
Can anyone help me?
I attempt to draw text text to a windowless vmr9, and I am able to get text overlay but my text either only shows up in white or not at all.
The funny thing is that I can only draw white text. There appears to be a problem with the offscreen bitmap I am drawing the text to because any color other than white DOES NOT SHOW UP AT ALL.
My code is attached in my previous post. It compiles in Visual Studio 2008.
Does anyone know why drawing text to an offscreen bitmap to a Windowless VMR only allows white text?
The DirectShow overlay samples seem to work with various colors, and I just can't understand why attempting to draw text to my offscreen bitmap only shows up if the text is white.
Her is a link to my project (not sure what the link TAG is). It compiles in Visual Studio 2008.
* The Best Reasons to Target Windows 8
Learn some of the best reasons why you should seriously consider bringing your Android mobile development expertise to bear on the Windows 8 platform.