IDirectMusicSegment8::SetTrackConfig

DirectMusic

Microsoft DirectX 9.0 SDK Update (Summer 2004)

IDirectMusicSegment8::SetTrackConfig

The SetTrackConfig method sets the configuration of a track for miscellaneous behaviors.

Syntax

HRESULT SetTrackConfig(
  REFGUID rguidTrackClassID,
  DWORD dwGroupBits, 
  DWORD dwIndex,
  DWORD dwFlagsOn,
  DWORD dwFlagsOff
);

Parameters

rguidTrackClassID

Reference to (C++) or address of (C) the identifier of the track class. For a list of values, see Standard Track Types.

dwGroupBits

Groups to which the track belongs.

dwIndex

Index of the track within the group, or DMUS_SEG_ALLTRACKS to set the configuration of all tracks in the group.

dwFlagsOn

Configuration flags to set. See Remarks.

dwFlagsOff

Configuration flags to clear. See Remarks.

Return Values

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.

Return code
DMUS_E_TRACK_NOT_FOUND
E_INVALIDARG

Remarks

If you change a flag on a segment, subsequent instances of segment states inherit the change. However, segment states that are already playing do not change their behavior.

The following flags are defined:

Value Description
DMUS_TRACKCONFIG_COMPOSING Use this track to compose other tracks.
DMUS_TRACKCONFIG_CONTROL_ENABLED Enable IDirectMusicTrack8::GetParamEx.
DMUS_TRACKCONFIG_CONTROL_NOTIFICATION When played in a control segment, override notification of primary segment tracks.
DMUS_TRACKCONFIG_CONTROL_PLAY When played in a control segment, override playback of primary segment tracks.
DMUS_TRACKCONFIG_DEFAULT The combination of DMUS_TRACKCONFIG_CONTROL_ENABLED | DMUS_TRACKCONFIG_PLAY_ENABLED | DMUS_TRACKCONFIG_NOTIFICATION_ENABLED.
DMUS_TRACKCONFIG_FALLBACK The track tries to get parameters from this segment if the primary and control segments don't return the requested information.
DMUS_TRACKCONFIG_LOOP_COMPOSE Regenerate data each time the track repeats.
DMUS_TRACKCONFIG_NOTIFICATION_ENABLED Enable notifications.
DMUS_TRACKCONFIG_OVERRIDE_ALL The track tries to get parameters from this segment before the control and primary segment.
DMUS_TRACKCONFIG_OVERRIDE_PRIMARY The track tries to get parameters from this segment before the primary segment.
DMUS_TRACKCONFIG_PLAY_CLOCKTIME Play in clock time, not music time.
DMUS_TRACKCONFIG_PLAY_COMPOSE Regenerate data each time the track starts playing.
DMUS_TRACKCONFIG_PLAY_ENABLED Enable track to send messages.
DMUS_TRACKCONFIG_TRANS1_FROMSEGCURRENT In composing transitions, get track information from the current place in the first segment.
DMUS_TRACKCONFIG_TRANS1_FROMSEGSTART In composing transitions, get track information from the start of the first segment.
DMUS_TRACKCONFIG_TRANS1_TOSEGSTART In composing transitions, get track information from the start of the second segment.

The following table shows which track configuration flags are valid for standard tracks.

Track Valid flags
Band DMUS_TRACKCONFIG_CONTROL_ENABLED
DMUS_TRACKCONFIG_CONTROL_PLAY
DMUS_TRACKCONFIG_PLAY_CLOCKTIME
DMUS_TRACKCONFIG_PLAY_ENABLED
DMUS_TRACKCONFIG_TRANS1_FROMSEGCURRENT
DMUS_TRACKCONFIG_TRANS1_FROMSEGSTART
DMUS_TRACKCONFIG_TRANS1_TOSEGSTART
Chord DMUS_TRACKCONFIG_CONTROL_ENABLED
DMUS_TRACKCONFIG_CONTROL_NOTIFICATION
DMUS_TRACKCONFIG_NOTIFICATION_ENABLED
DMUS_TRACKCONFIG_TRANS1_FROMSEGCURRENT
DMUS_TRACKCONFIG_TRANS1_FROMSEGSTART
DMUS_TRACKCONFIG_TRANS1_TOSEGSTART
Chordmap DMUS_TRACKCONFIG_CONTROL_ENABLED
DMUS_TRACKCONFIG_TRANS1_FROMSEGCURRENT
DMUS_TRACKCONFIG_TRANS1_FROMSEGSTART
DMUS_TRACKCONFIG_TRANS1_TOSEGSTART
Command DMUS_TRACKCONFIG_CONTROL_ENABLED
DMUS_TRACKCONFIG_CONTROL_NOTIFICATION
DMUS_TRACKCONFIG_NOTIFICATION_ENABLED
DMUS_TRACKCONFIG_TRANS1_FROMSEGCURRENT
DMUS_TRACKCONFIG_TRANS1_FROMSEGSTART
DMUS_TRACKCONFIG_TRANS1_TOSEGSTART
Lyrics DMUS_TRACKCONFIG_PLAY_CLOCKTIME
DMUS_TRACKCONFIG_PLAY_ENABLED
Marker DMUS_TRACKCONFIG_CONTROL_ENABLED
Melody formulation
(Not implemented for this release)
DMUS_TRACKCONFIG_COMPOSING
DMUS_TRACKCONFIG_CONTROL_ENABLED
DMUS_TRACKCONFIG_CONTROL_NOTIFICATION
DMUS_TRACKCONFIG_CONTROL_PLAY
DMUS_TRACKCONFIG_LOOP_COMPOSE
DMUS_TRACKCONFIG_NOTIFICATION_ENABLED
DMUS_TRACKCONFIG_PLAY_COMPOSE
DMUS_TRACKCONFIG_PLAY_ENABLED
DMUS_TRACKCONFIG_TRANS1_FROMSEGCURRENT
DMUS_TRACKCONFIG_TRANS1_FROMSEGSTART
DMUS_TRACKCONFIG_TRANS1_TOSEGSTART
Motif DMUS_TRACKCONFIG_CONTROL_ENABLED
DMUS_TRACKCONFIG_CONTROL_NOTIFICATION
DMUS_TRACKCONFIG_CONTROL_PLAY
DMUS_TRACKCONFIG_FALLBACK
DMUS_TRACKCONFIG_NOTIFICATION_ENABLED
DMUS_TRACKCONFIG_OVERRIDE_ALL
DMUS_TRACKCONFIG_OVERRIDE_PRIMARY
DMUS_TRACKCONFIG_PLAY_CLOCKTIME
DMUS_TRACKCONFIG_PLAY_ENABLED
Mute DMUS_TRACKCONFIG_CONTROL_ENABLED
Parameter control DMUS_TRACKCONFIG_PLAY_CLOCKTIME
DMUS_TRACKCONFIG_PLAY_ENABLED
Pattern DMUS_TRACKCONFIG_CONTROL_ENABLED
DMUS_TRACKCONFIG_CONTROL_NOTIFICATION
DMUS_TRACKCONFIG_CONTROL_PLAY
DMUS_TRACKCONFIG_FALLBACK
DMUS_TRACKCONFIG_NOTIFICATION_ENABLED
DMUS_TRACKCONFIG_OVERRIDE_ALL
DMUS_TRACKCONFIG_OVERRIDE_PRIMARY
DMUS_TRACKCONFIG_PLAY_CLOCKTIME
DMUS_TRACKCONFIG_PLAY_ENABLED
Script DMUS_TRACKCONFIG_PLAY_CLOCKTIME
DMUS_TRACKCONFIG_PLAY_ENABLED
Segment Trigger DMUS_TRACKCONFIG_PLAY_CLOCKTIME
DMUS_TRACKCONFIG_PLAY_ENABLED
Sequence DMUS_TRACKCONFIG_CONTROL_PLAY
DMUS_TRACKCONFIG_FALLBACK
DMUS_TRACKCONFIG_OVERRIDE_ALL
DMUS_TRACKCONFIG_OVERRIDE_PRIMARY
DMUS_TRACKCONFIG_PLAY_CLOCKTIME
DMUS_TRACKCONFIG_PLAY_ENABLED
Signpost DMUS_TRACKCONFIG_COMPOSING
DMUS_TRACKCONFIG_CONTROL_NOTIFICATION
DMUS_TRACKCONFIG_CONTROL_PLAY
DMUS_TRACKCONFIG_LOOP_COMPOSE
DMUS_TRACKCONFIG_NOTIFICATION_ENABLED
DMUS_TRACKCONFIG_PLAY_COMPOSE
DMUS_TRACKCONFIG_PLAY_ENABLED
DMUS_TRACKCONFIG_TRANS1_FROMSEGCURRENT
DMUS_TRACKCONFIG_TRANS1_FROMSEGSTART
DMUS_TRACKCONFIG_TRANS1_TOSEGSTART
Style DMUS_TRACKCONFIG_CONTROL_ENABLED
DMUS_TRACKCONFIG_CONTROL_NOTIFICATION
DMUS_TRACKCONFIG_CONTROL_PLAY
DMUS_TRACKCONFIG_FALLBACK
DMUS_TRACKCONFIG_NOTIFICATION_ENABLED
DMUS_TRACKCONFIG_OVERRIDE_ALL
DMUS_TRACKCONFIG_OVERRIDE_PRIMARY
DMUS_TRACKCONFIG_PLAY_ENABLED
DMUS_TRACKCONFIG_TRANS1_FROMSEGCURRENT
DMUS_TRACKCONFIG_TRANS1_FROMSEGSTART
DMUS_TRACKCONFIG_TRANS1_TOSEGSTART
Sysex DMUS_TRACKCONFIG_CONTROL_PLAY
DMUS_TRACKCONFIG_PLAY_CLOCKTIME
DMUS_TRACKCONFIG_PLAY_ENABLED
Tempo DMUS_TRACKCONFIG_CONTROL_ENABLED
DMUS_TRACKCONFIG_CONTROL_PLAY
DMUS_TRACKCONFIG_PLAY_CLOCKTIME
DMUS_TRACKCONFIG_PLAY_ENABLED
DMUS_TRACKCONFIG_TRANS1_FROMSEGCURRENT
DMUS_TRACKCONFIG_TRANS1_FROMSEGSTART
DMUS_TRACKCONFIG_TRANS1_TOSEGSTART
Time signature DMUS_TRACKCONFIG_CONTROL_ENABLED
DMUS_TRACKCONFIG_CONTROL_NOTIFICATION
DMUS_TRACKCONFIG_CONTROL_PLAY
DMUS_TRACKCONFIG_NOTIFICATION_ENABLED
DMUS_TRACKCONFIG_PLAY_ENABLED
Wave DMUS_TRACKCONFIG_CONTROL_PLAY
DMUS_TRACKCONFIG_FALLBACK
DMUS_TRACKCONFIG_OVERRIDE_ALL
DMUS_TRACKCONFIG_OVERRIDE_PRIMARY
DMUS_TRACKCONFIG_PLAY_CLOCKTIME
DMUS_TRACKCONFIG_PLAY_ENABLED

Requirements

  Header: Declared in dmusici.h.

See Also


© 2004 Microsoft Corporation. All rights reserved.