This project is read-only.

Needed Prerequistes

Apr 5, 2008 at 12:52 PM

I'm having a bit of trouble figuring out what the need prerequistes are for building the source.

I have the platform SDK installed, as well as, DirectShowLib.

But the default setup with VS08 was not able to find "streams.h" in the default include paths.

I would greatly appreciate a listing of all needed includes and linker locations to get the project built.

Thanks again,

Apr 5, 2008 at 9:51 PM

In VS, Tools -> Options ->Projects And Solutions -> VC++ Directories:

Add these directories for the include files (may have to adjust if directory is different):
C:\Program Files\Microsoft SDKs\Windows\v6.0\Samples\Multimedia\DirectShow\BaseClasses
C:\Program Files\Microsoft SDKs\Windows\v6.0\Include

For library files add:
C:\Program Files\Microsoft SDKs\Windows\v6.0\Samples\Multimedia\DirectShow\BaseClasses\Debug
C:\Program Files\Microsoft SDKs\Windows\v6.0\Samples\Multimedia\DirectShow\BaseClasses\Release
C:\Program Files\Microsoft SDKs\Windows\v6.0\Lib
C:\Program Files\Microsoft SDKs\Windows\v6.0\Lib\x86

Hope this helps.

I have included a compiled version of the .ax file in case people don't want to mess with this. Don't forget to regsvr32 the .ax file :)

Jun 12, 2008 at 3:09 PM
I added those directories, and when I tried to compile, got a long list of compiler errors.

I was trying to build the ActiveX project to see if it would fix the problem I see when running the sample app: The demo application does nothing when you press any of the test buttons. I tracked it down to the 'Initialized' event never being fired subsequent to the call to Play on the MediaElement.

Jun 12, 2008 at 3:22 PM
Did you run a regsvr32 on the .ax file?  That is a common reason why the VRE does not run.
Jun 12, 2008 at 6:16 PM
Yep, I did register the ax file.
Jun 24, 2008 at 8:39 PM
Hello Jer & confuzatron. I recently downloaded the latest files and I had a little problem building as well. However, all I did to correct the vcproj was to add the include and lib paths Jer mentioned. Note that you have to build the DirectShow BaseClasses project.

To get the C# projects to build, I had to re-reference the DirectShowLib-2005 reference.. I also installed NET 3.5 SP-1 (beta) which I thought I saw somewhere in the requoirements
For testing, I had a Logitech web cam attached. The sample ran but somewhat inconsistently. At times I got no results, no matter which button I pressed. At other times, the (webcam) video froze after a few seconds. I hope to have some additional detail in a day or so. The code looks very nice but I suspect that there is a subtle problem somewhere.  
Jun 24, 2008 at 11:47 PM
Hi BCostello,

Thanks for the feedback.  Unfortunately, I never found a simply way to redistribute C++ code in a way that will work right away on everyone's devel environment.  I do include the compiled filter just in case.

All the sample code is very sloppy, including the web-cam.  I really just wanted to show usage of the VRE in a few scenarios.  I think the best way to test the VRE stability is to use the simplest of examples, which is the GDI or JPEG ones.  The web-cam sample is a bit more complicated and poorly written, so I would rewrite your own code for production usesage.  Overall I have not see any major bugs in the VRE itself, but I kept that as clean as possible, so if there is a problem it would be easier to find. :)

Jun 27, 2008 at 9:39 PM
I got a new laptop at work and re-installed and retested. I have not yet reproduced the problem with consistentcy for the web cam function I noticed before. The only differences in the systems I know of are the video card, the OS (XP Pro (previous) versus Vista business) and I did not install NET 3.5 SP1 on the new system. I used VS 2008 in each case. I also registered the supplied ax rather than the one I built (a crude look at the binaries indicated they were the same). 
In the coming weeks, I may actually try the control on some functioanlity that needs to be migrated from WinForms to WPF. I will be sure to keep you posted if and when I discover anything. Many thanks for sharing your work with others. 

Bob Costello 
Aug 30, 2008 at 10:08 PM

At least on my system, I needed to put the includes jmorrill refers to in this order:

  C:\Program Files\Microsoft SDKs\Windows\v6.0\Samples\Multimedia\DirectShow\BaseClasses
  C:\Program Files\Microsoft SDKs\Windows\v6.0\Include

If they're switched, you can get the wrong Schedule.h....


Aug 30, 2008 at 10:40 PM

And after some futzing to get strmbase.lib in place, I've got everything building cleanly from scratch -- I think -- but now I'm getting a System.Deployment.Application.InvalidDeploymentException from m_mediaElement.Play().  The prebuilt binary does work for me, though, so it's clearly a misconfiguration somewhere in my code...