Microsoft DirectX 9.0

IDirectMusicTrack8 Interface

The IDirectMusicTrack8 interface represents a track object, which can store any kind of data for a segment.

The methods of this interface are typically not called directly by applications. However, if you want to install your own data playback mechanism in DirectMusic, you must create a track object to represent it. The track object must also support the IPersistStream interface for loading its data.

IDirectMusicTrack8 supersedes the IDirectMusicTrack interface and adds new methods.

Note   When implementing methods of the IDirectMusicTrack8 interface, be sure not to hold onto references to objects passed in. For example, if IDirectMusicTrack8::Init adds a reference to the IDirectMusicSegment interface that it receives as a parameter, ensure that this reference is released.

In addition to the methods inherited from IUnknown, the IDirectMusicTrack8 interface exposes the following methods, arranged by category.

Notification

Method Description
AddNotificationType Adds a type of event for which notifications are required.
RemoveNotificationType Removes a type of event for which notifications are required.

Parameters

Method Description
GetParam Retrieves data from a track, in music time.
GetParamEx Retrieves data from a track, in either music time or reference time.
IsParamSupported Ascertains whether the track supports a given data type.
SetParam Sets data on a track, in music time.
SetParamEx Sets data on a track, in either clock or music time.

Playback

Method Description
EndPlay Called when the object that originally called IDirectMusicTrack8::InitPlay is destroyed.
InitPlay Called when a track is ready to start playing.
Play Called when the object that originally called IDirectMusicTrack8::InitPlay is destroyed.
PlayEx Causes the track to play in clock time.

Miscellaneous

Method Description
Clone Makes a copy of the track.
Compose Recomposes the track based on data from a segment.
Init Initializes the track.
Join Appends one track to another.

Requirements

  Header: Declared in dmplugin.h.

See Also