Share via


Windows Media Player 11 SDK Implementing Other Functions 

Windows Media Player SDK banner art

Previous Next

Implementing Other Functions

You will definitely want to write your own implementation of the Render function. Several other functions that are also member functions of the IWMPEffects interface are provided. Some will provide you with extra information that you can choose to use and others will automatically provide Windows Media Player with information that was generated by the wizard, such as the name of your visualization.

The IWMPEffects interface supports the following functions in addition to Render:

Function Description
DisplayPropertyPage Default implementation not supplied by wizard.
GetCapabilities Gets the capabilities of your visualization and passes them to Windows Media Player.
GetCurrentPreset The wizard created two presets when it generated the code for your visualization. This function is called when the skin developer wants to get the index of the current preset. You will not want to change the implementation of this function because it just uses information set by other functions.
GetPresetCount The wizard created two presets when it generated the code for your visualization. You can change the count by changing the implementation of GetPresetCount. See Presets for more information about changing the presets.
GetPresetTitle The wizard created two presets when it generated the code for your visualization. You can change the titles used by changing the implementation of GetPresetTitle. See Presets for more information about changing the presets.
GetTitle Gets the title of your visualization and passes it to Windows Media Player. The wizard used the name of your project to generate the name that is passed back.
GoFullscreen Default implementation not supplied by wizard.
MediaInfo Retrieves the number of audio channels and the sample rate of the audio currently playing.
RenderFullScreen Default implementation not supplied by wizard.
SetCurrentPreset The wizard created two presets when it generated the code for your visualization. This function is called when Windows Media Player wants to change to a named preset.

The IWMPEffects2 interface supports the following additional functions:

Function Description
Create When rendering in a window, Windows Media Player calls this function to allow you to create a new window for rendering.
Destroy When rendering in a window, Windows Media Player calls this function to permit you to destroy the window you created when Create was called.
NotifyNewMedia This function allows your visualization to respond when a new media item has been loaded by the Player.
OnWindowMessage This function receives windows messages from the Player when rendering in windowless mode.
RenderWindowed This function is called by the Player instead of IWMPEffects::Render when the Player is rendering in windowed mode.
SetCore This function receives a pointer to the IWMPCore interface.

See Also

Previous Next