Microsoft DirectX 8.1 (C++) |
This topic applies to Windows XP Home Edition and Windows XP Professional only.
The main point to remember when you create filter graphs with the VMR is that you must configure the VMR before you connect it. The easiest approach is to create the VMR, add it to the filter graph, and configure it before you call IGraphBuilder::RenderFile. The Filter Graph Manager always tries to connect a filter in the graph before it searches the registry for new filters (see Intelligent Connect).
To build a graph that sends two independent video streams to the VMR, for example, two video files, follow these steps:
Note If the output pin on the decoder and the input pin on the VMR cannot agree on a connection, then a new instance of the VMR with default settings will be created. This will result in a new window with "ActiveMovie" in the title bar. To prevent this from happening, the application should always verify that the correct instance of the VMR is being used by calling a method such as IPin::ConnectedTo.