IDirectMusicPatternTrack8::SetPatternByName
Sets the pattern to be played by the track. The pattern comes from a style.
HRESULT SetPatternByName(
IDirectMusicSegmentState* pSegState,
WCHAR* wszName,
IDirectMusicStyle* pStyle,
DWORD dwPatternType,
DWORD* pdwLength
);
Parameters
- pSegState
- Address of the IDirectMusicSegmentState8 interface of the segment state that is playing the track.
- wszName
- Name of the pattern to set. The name can be obtained by using IDirectMusicStyle8::EnumPattern.
- pStyle
- Address of the IDirectMusicStyle or IDirectMusicStyle8 interface of the style containing the pattern.
- dwPatternType
- One of the DMUS_STYLET_TYPES enumeration that specifies the type of pattern.
- pdwLength
- Address of a variable that receives the length of the pattern, in music time ticks.
Return Values
If the method succeeds, the return value is S_OK.
If it fails, the method can return one of the following error values.
Header: Declared in dmusici.h.