DirectShow sample apps
[The feature associated with this page, DirectShow, is a legacy feature. It has been superseded by MediaPlayer, IMFMediaEngine, and Audio/Video Capture in Media Foundation. Those features have been optimized for Windows 10 and Windows 11. Microsoft strongly recommends that new code use MediaPlayer, IMFMediaEngine and Audio/Video Capture in Media Foundation instead of DirectShow, when possible. Microsoft suggests that existing code that uses the legacy APIs be rewritten to use the new APIs if possible.]
You can find the DirectShow sample apps in the Windows-classic-samples repository on GitHub.
The table below lists all of the DirectShow samples provided in that repo. For instructions on how to build the samples, refer to the documentation provided in the Windows SDK. If a topic exists describing a sample, then the first column of this table links to it.
|DirectShow Base Classes||Base class library||C++ classes and utility functions designed for implementing DirectShow filters.|
|AmCap Sample||Capture||Video capture application.||strmbase.lib|
|DVApp Sample||Capture||Digital Video (DV) capture application.|
|PlayCap Sample||Capture||Simple capture application.|
|DMO Demo Sample||DMO||Streams audio data from a WAV file through an audio effect DMO.||DirectX SDK|
|DVD Sample||DVD||Demonstrates basic DVD playback and navigation, plus advanced features such as parental level management, bookmarks, karaoke, and command synchronization.|
|InfTee Filter Sample||Filters, miscellaneous||Sample implementation of the Infinite Pin Tee filter.||strmbase.lib|
|Metronome Filter Sample||Filters, miscellaneous||Shows how to implement a reference clock.||strmbase.lib|
|PSI Parser Filter Sample||Filters, miscellaneous||Receives Program Specific Information (PSI) tables from an MPEG-2 transport stream and extracts program information.||strmbase.lib|
|Dump Filter Sample||Filters, renderer||Writes media samples receives to a text file.||strmbase.lib|
|SampVid Filter||Filters, renderer||Video renderer filter.||strmbase.lib|
|Scope Filter Sample||Filters, renderer||Displays sound data as wave forms.||strmbase.lib|
|Async Filter Sample||Filters, source||File reader filter that supports progressive download.||strmbase.lib|
|Ball Filter Sample||Filters, source||Video source filter that produces an image of a bouncing ball.||strmbase.lib|
|Push Source Filters Sample||Filters, source||Source filters that provide the following data as a video stream: A single bitmap, a set of bitmaps, a copy of the current desktop image.||strmbase.lib|
|Synth Filter Sample||Filters, source||Source filter that generates audio waveforms. This sample demonstrates dynamic graph building.||strmbase.lib|
|EZRGB24 Filter Sample||Filters, transform||Image processing filter.||strmbase.lib|
|Gargle Filter Sample||Filters, transform||Audio effect filter.||strmbase.lib|
|WavDest Filter Sample||Filters, transform||Writes an audio stream to a WAV file.||strmbase.lib|
|DMOEnum Sample||Miscellaneous||Shows how to enumerate DirectX Media Objects (DMOs).|
|Mapper Sample||Miscellaneous||Shows how to use the Filter Mapper to find filters in the registry.|
|SysEnum Sample||Miscellaneous||Demonstrates using the System Device Enumerator to enumerate devices and filters.|
|CutScene Sample||Playback||Plays a video file in full-screen mode.|
|DDrawXCL Sample||Playback||Plays video in DirectDraw exclusive full-screen mode, using the IDDrawExclModeVideo interface on the Overlay Mixer filter.|
|DShowPlayer Sample||Playback||Video playback application.|
|EVRPlayer Sample||Playback||Demonstrates how to use the DirectShow EVR filter. Note: Requires Windows Vista or later.
This sample is available in the Windows SDK for Windows Server 2008 or later.
|Texture3D9 Sample||Playback||Draws video on a Microsoft DirectX 9.0 texture surface.||strmbase.lib, DirectX SDK|
|Ticker Sample||VMR-9||Uses the VMR-9 to blend video and text.|
|VMR9Allocator Sample||VMR-9||Implements a custom allocator-presenter for the VMR-9.||strmbase.lib|
|VMR9Compositor Sample||VMR-9||Implements a custom mixer for the VMR-9.|
|VMRPlayer Sample||VMR-9||Uses the VMR-9 to blend one or two running videos and a static image.|
|Watermark Sample||VMR-9||Blends a static bitmap onto a video during playback, using the VMR-9.|
|Windowless Sample||VMR-9||Demonstrates windowless mode in the VMR-9.|
Some of the samples link to the DirectShow base class library. To build those samples, first build the base class library. For more information, see DirectShow base classes. The base class library is required for all of the sample filters.
A few of the samples also require the DirectX SDK, in addition to the Windows SDK. To build those samples, you must install the DirectX SDK, and set the
%DXSDK\_DIR% environment variable equal to your DirectX SDK installation path.
Many of the DirectShow samples use a set of common headers and source files located in the directrory
\[SDK Root\]Samples\Multimedia\DirectShow\Common. If you copy a sample folder to another directory, then make sure to copy the
Common folder as well.