|Microsoft DirectX 9.0|
The InsertTrack method inserts the specified track into the segment's list of tracks.
HRESULT InsertTrack( IDirectMusicTrack* pTrack, DWORD dwGroupBits );
Track to add to the segment.
Group or groups into which to insert the track. This value cannot be 0.
If the method succeeds, the return value is S_OK.
If it fails, the method can return one of the error values shown in the following table.
Tracks are put in groups to link them correctly. For example, a segment might contain two style tracks and two mute tracks. Each style track would be put in a different group, along with its associated mute track. For more information on track groups, see Identifying the Track.
If the segment is currently playing, the new track is not included in playback because the segment state was not initialized with the new track.
This method initializes the track. However, if the track data is subsequently changed, the application must initialize it again by calling IDirectMusicTrack8::Init.
Header: Declared in dmusici.h.