General Graph-Building Techniques
[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.]
Every DirectShow application starts by building a filter graph. As you read the overview topics in the DirectShow documentation, you will find that most start by describing what kind of filter graph you need. In some cases, there is a method or a helper object specifically designed for building that type of graph. For example, the DVD Graph Builder object builds DVD playback graphs. In other cases, the application must construct the graph by adding filters and connecting them.
This section presents some helper functions that implement basic graph-building operations. They can be used by any DirectShow application that needs to build or modify a filter graph. This section contains the following topics:
- Add a Filter by CLSID
- Find an Unconnected Pin on a Filter
- Connect Two Filters
- Find an Interface on a Filter or Pin
- Find a Filter's Peer
- Remove All the Filters in the Graph
- Building Graphs with the Capture Graph Builder
Related topics