The IConfigAviMux interface controls how the AVI multiplexer filter writes files out to disk. Microsoft® DirectShow® currently exposes this interface through the property page of the AVI multiplexer filter and you can use it to set the master stream and compatibility indexes.
IConfigAviMux provides backward compatibility with older Video for Windows® Audio-Video Interleaved (AVI) index formats (idx1) as well as extended AVI 2.0 index formats (indx) to allow for file sizes greater than 1 gigabyte (GB). Set and retrieve the compatibility indexes by using the IConfigAviMux::SetOutputCompatibilityIndex and IConfigAviMux::GetOutputCompatibilityIndex methods. See AVI 2.0 File Format Extensions for more information on AVI 2.0.
DirectShow implements this interface and makes its functionality available to anyone through the property page of an AVI multiplexer filter. However, you can implement this interface yourself if you're writing a filter that takes audio and video streams from a capture graph and generates an AVI file.
Use this interface when your application must control how a file is captured.
Methods in Vtable Order
IUnknown methods Description QueryInterface Retrieves pointers to supported interfaces. AddRef Increments the reference count. Release Decrements the reference count. IConfigAviMux methods Description SetMasterStream Sets the master stream that other streams must synchronize to after the file is saved to disk. GetMasterStream Retrieves the master stream that other streams must synchronize to after the file is written out. SetOutputCompatibilityIndex Sets the AVI index format for the file that the multiplexer saves to. GetOutputCompatibilityIndex Retrieves the AVI index format for the file that the multiplexer will write to.
Retrieves the master stream that other streams must synchronize to after the file is written out.
Syntax
HRESULT GetMasterStream(
LONG *pStream
);
Parameters
- pStream
- [out] Pointer to the master stream.
Return Value
Returns an HRESULT value that depends on the implementation of the interface.
Remarks
To eliminate capture drifts that can occur between audio sampling rates and video frame rates, it is recommended that you use combined audio/video cards for capture of large files.
See Also
Retrieves the AVI index format for the file that the multiplexer will write to.
Syntax
HRESULT GetOutputCompatibilityIndex(
BOOL *pfOldIndex
);
Parameters
- pfOldIndex
- [out] Pointer to a value indicating the index format. Returns TRUE if AVI 1.0 (idx1) index format or AVI 2.0 (indx) index format is set; returns FALSE if only AVI 2.0 (indx) index format is set.
Return Value
Returns an HRESULT value that depends on the implementation of the interface.
See Also
Sets the master stream that other streams must synchronize to after the file is saved to disk.
Syntax
HRESULT SetMasterStream(
LONG iStream
);
Parameters
- iStream
- [in] Master input stream. Set to 1 to disable.
Return Value
Returns an HRESULT value that depends on the implementation of the interface.
Remarks
Different streams in the capture scenario can capture at different rates if you are using separate audio and video capture cards. By specifying a master stream that all others must synchronize to, this method adjusts the frame rate or audio sampling rate to account for drifts in the rates.
To eliminate capture drifts that can occur between audio sampling rates and video frame rates, it is recommended that you use combined audio/video cards for capture of large files.
See Also
Sets the AVI index format for the file that the multiplexer saves to.
Syntax
HRESULT SetOutputCompatibilityIndex(
BOOL fOldIndex
);
Parameters
- fOldIndex
- [in] Value specifying the AVI index format. TRUE indicates either AVI 1.0 (idx1) index format or AVI 2.0 (indx) index format; FALSE indicates only AVI 2.0 (indx) index format.
Return Value
Returns an HRESULT value that depends on the implementation of the interface.
Remarks
In addition to backward compatibility with Video for Windows® AVI index formats (idx1), DirectShow also supports extended AVI 2.0 index format (indx), which this method can specify. AVI 2.0 index format allows for increased AVI file size (greater than 1 GB), hierarchical indexing, incremental growth of files, and minimal disk seeks. See AVI 2.0 File Format Extensions for more information on AVI 2.0.
See Also
Top of Page
© 2000 Microsoft and/or its suppliers. All rights reserved. Terms of Use.