Filter install/uninstall
A) Invoking the filter from the TVideoGrabber SDK, without installer neither filter registration
Although TVideoGrabber can use the filter registered in DirectShow with the B) and C) methods described below, it can be more convenient to just copy the filter binaries to a folder, so TVideoGrabber can invoke them without having to run the installer or registering the binaries with regsvr32.exe.
Case 1: if the application targets only x86 or x64, it is possible to just copy the corresponding filter binaries (.dll and .ax) into the folder where is located the application's executable (.exe).
Case 2: if the application targets both x86 and x64 (e.g. C#, VB.NET, etc...), copy the x86 and x64 folders containing the filter binaries under the folder where is located the application executable (.exe) — so, under the application folder, we will find two "x86" and "x64" subfolders containing the respective filter binaries.
Case 3: it is possible to copy both the "x86" and "x64" folders containing the filter binaries to any folder, and to specify this folder to TVideoGrabber with the VideoGrabber.ExtraDLLPath property.
E.g. if the x86 and x64 folders have been copied under "c:\rtspfolder", set:
VideoGrabber.ExtraDLLPath = "c:\rtspfolder"
B) Installing the filter as a standard DirectShow filter with the self installer (DatasteadRTSPFilterInstall.exe)
The installer will install and register automatically the x86 filter on a 32bit OS, and both the x86 and x64 filters on a 64bit OS.
To install the package automatically from the command line
DatasteadRTSPFilterInstaller.exe /silent
or
DatasteadRTSPFilterInstaller.exe /verysilent
To uninstall the package automatically from the command line
"C:\Program Files\Datastead\Rtsp\unins000.exe"
To install the package manually
Double-click on DatasteadRTSPFilterInstaller.exe, accept each confirmation dialog.
To uninstall the package manually
Control panel → Add/Remove program → uninstall the Datastead RTSP/RTMP/HTTP/ONVIF DirectShow source filter.
C) Registering the filter manually
To install the filter manually:
- run vcredist_86.exe and/or vcredist_64.exe,
- copy the x86 and/or x64 folders to the target location,
- register the DatasteadRtspSource_x86.ax or DatasteadRtspSource_x64.ax file with regsvr32.exe (the DLLs must be located in the .ax folder).
E.g.:
regsvr32.exe c:\filtersfolder\x86\DatasteadRtspSource_x86.ax
regsvr32.exe c:\filtersfolder\x64\DatasteadRtspSource_x64.ax
To uninstall it, run regsvr32.exe /u, then delete the files. E.g.:
regsvr32.exe /u c:\filtersfolder\x86\DatasteadRtspSource_x86.ax
regsvr32.exe /u c:\filtersfolder\x64\DatasteadRtspSource_x64.ax
If you are using a third-party installer, it should include an option that lets COM-register the .ax binaries.
Note 1:
- to run an application compiled for x86 only, register only the x86 filter, it can run on both 32bit and 64bit OS without problem,
- to run an application compiled for both x86 and x64: on a 32bit PC, register only the x86 filter; on a 64bit PC, register both the x86 and x64 filters.
Note 2: the x86 DLLs must be copied in the folder where is located DatasteadRtspSource_x86.ax, and the x64 DLLs in the folder where is located DatasteadRtspSource_x64.ax.
Demo projects
Using the filter through the TVideoGrabber SDK
The filter is natively supported by our TVideoGrabber SDK, that builds and handles the DirectShow graphs automatically.
To use the filter from the TVideoGrabber SDK:
- install the filter as explained above,
- download and unzip the TVideoGrabber SDK,
- quick verify the filter installation by running the pre-compiled MainDemo.exe → "IP camera" tab, enter a RTSP URL and click "Start preview": if you see the preview the filter is correctly installed, exit MainDemo.exe,
- locate the MainDemo project corresponding to your development language,
- open the MainDemo project and compile it,
- run it and go to the "IP Camera" tab, enter the RTSP URL and click "Start preview" to verify all is working correctly.
The TVideoGrabber sample code to start the preview and MP4 recording of RTSP URLs is explained in the Using from TVideoGrabber chapter.
Building the DirectShow graph
This package includes several demo projects that are provided as sample code and can be reused:
Microsoft DirectShow SDK (C++): a simple C++ demo project derived from PlayCap, with synchronous connection.
C# with DirectShow .NET: the package includes a C# demo project based on DirectShow.NET and derived from PlayCap, with asynchronous connection (the filter does not block the main thread while connecting; for more information see DirectShow configuration).