IDvdGraphBuilder::GetDvdInterface method (strmif.h)

[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.]

The GetDvdInterface method retrieves interfaces from the DVD-Video playback graph to make DVD-Video playback development easier.

Syntax

HRESULT GetDvdInterface(
  [in]  REFIID riid,
  [out] void   **ppvIF
);

Parameters

[in] riid

IID of the requested interface.

[out] ppvIF

Receives a pointer to the interface. The application must release the interface.

Return value

Returns an HRESULT value. Possible values include the following.

Return code Description
E_INVALIDARG
The ppvIF parameter is invalid. This parameter must not be NULL.
E_NOINTERFACE
The requested interface could not be returned.
VFW_E_DVD_GRAPHNOTREADY
The graph is not built yet. See Remarks.

Remarks

You can use this method to select and configure a video renderer filter before you build the filter graph for DVD playback. The following interfaces are available:

If you call GetDvdInterface to get any of these interfaces before you build the filter graph, the DVD Graph Builder creates the appropriate video renderer. It will use this renderer later when you build the graph. After the video renderer has been selected, you can no longer retrieve the interfaces for the other video renderers. (The GetDvdInterface method will return E_NOINTERFACE.)

Before the DVD playback graph is built, if you request any interfaces that are not on the previous list, the method returns VFW_E_DVD_GRAPHNOTREADY. To build the DVD graph, call IDvdGraphBuilder::RenderDvdVideoVolume. After you build the graph, you can use GetDvdInterface to retrieve some additional interfaces:

To get other interfaces, call IDvdGraphBuilder::GetFiltergraph. Query the returned IGraphBuilder interface or use EnumFilters to enumerate the filters.

Requirements

Requirement Value
Minimum supported client Windows 2000 Professional [desktop apps only]
Minimum supported server Windows 2000 Server [desktop apps only]
Target Platform Windows
Header strmif.h (include Dshow.h)
Library Strmiids.lib

See also

DVD Applications

Error and Success Codes

IDvdGraphBuilder Interface