couvill
February 9, 2007, 23:13:48
Hi:
I'm writing a C++ DirectShow app in Visual Studio.NET. I'm trying to construct a graph with an MVIPCameraSource filter, connected to an MVMJPEGDecompressor, the output of the latter to go to a samplegrabber filter.
I've created filters using CoCreateInstance, and then gotten the IMVIPCameraSource interface using IBaseFilter::QueryInterface. I use that to set the URL of the camera to the same value I used in the WorkBench graph, which does display an image.
Unfortunately, when I go to connect the output pin of the IPCameraSource to the MJPEGDecompressor, I get an error. I suspect that this is because the camera's not initialized. The documentation says to call IMVIPCameraSource::Initialize, but Visual Studio doesn't see that method. I can call IMVIPCameraSource::Reconnect, but that doesn't seem to do any good.
Does setting the URL initialize the camera filter, like it does in the workbench? If not how do you initialize IP cameras? Why doesn't VisualStudio see the Initialize method?
Has anybody else had this problem? Any help would be appreciated.
I'm writing a C++ DirectShow app in Visual Studio.NET. I'm trying to construct a graph with an MVIPCameraSource filter, connected to an MVMJPEGDecompressor, the output of the latter to go to a samplegrabber filter.
I've created filters using CoCreateInstance, and then gotten the IMVIPCameraSource interface using IBaseFilter::QueryInterface. I use that to set the URL of the camera to the same value I used in the WorkBench graph, which does display an image.
Unfortunately, when I go to connect the output pin of the IPCameraSource to the MJPEGDecompressor, I get an error. I suspect that this is because the camera's not initialized. The documentation says to call IMVIPCameraSource::Initialize, but Visual Studio doesn't see that method. I can call IMVIPCameraSource::Reconnect, but that doesn't seem to do any good.
Does setting the URL initialize the camera filter, like it does in the workbench? If not how do you initialize IP cameras? Why doesn't VisualStudio see the Initialize method?
Has anybody else had this problem? Any help would be appreciated.