|Microsoft DirectX 9.0|
When the WM ASF Writer filter is created, it is configured automatically with a default system profile. System profiles are discussed in detail in the Windows Media Format SDK; basically, they describe various attributes of a Windows Media Format file such as bit rate, number and type of streams, compression quality, and so on. If the default profile is not suitable, an application can modify it using the filter's IConfigAsfWriter interface methods. The filter uses the profile to determine what kind of Windows Media Format file to write, how many input pins it must set up, and what media types they can accept. The filter must be added to the graph before it can be configured, and it must be configured before it can be connected to upstream filters.
There are various ways to specify a profile to the WM ASF Writer. The WM ASF Writer has a property page that lists the profiles available on the system. This list shows what kinds of streams the filter can create based on the specified input streams. The profile descriptions appear as human-readable strings such as "250 VideoCreates video content for clients with 250 Kbps network connections, such as cable modems, DSL, and LAN connections" or "128 CD Quality Audiocreates CD transparency quality audio content for clients with high-speed Internet and LAN connections. Also suited for local playback." An application can expose this property page to the end user to enable the user to select a profile. For information on how to display a filter's property page, see Displaying a Filter's Property Pages. If you don't want to use the property page, you can get the list of profiles directly by using the Windows Media Format SDK and present these to the end user in your user interface. You can also create a custom profile and pass it directly to the filter, or pass the filter a globally unique identifier (GUID) for a profile from the Wmsysprf.h header file in the Windows Media Format SDK.
The DirectX 9.0 SDK provides a utility program called Profile Enumerator that displays information about system profiles installed on your machine. This program is located in [SDK root]\bin\DXUtils.
The filter allows profiles to be reset while its input pins are connected, but if the profile is changedfor example, from a one-input audio stream profile to a two-input audio and video profileonly the previously connected audio stream is reconnected.
Because the Windows Media Format SDK requires an audio stream to work, the WM ASF Writer must always have an input audio pin, even if it is for a dummy streamthat is, a muted, low-bit-rate audio stream. All input data must be time-stamped, and all input pins must be connected before the filter can be run or paused.