DMUS_IO_STYLE_ANTICIPATION

DirectMusic

Microsoft DirectX 9.0 SDK Update (Summer 2004)

DMUS_IO_STYLE_ANTICIPATION

The DMUS_IO_STYLE_ANTICIPATION structure describes a resolution anticipation. Used in the Style Form.

Syntax

typedef struct _DMUS_IO_STYLE_ANTICIPATION {
  MUSIC_TIME  mtGridStart;
  DWORD   dwVariation;
  short   nTimeOffset;
  BYTE    bTimeRange;
} DMUS_IO_STYLE_ANTICIPATION;

Members

mtGridStart

Offset within the part, in grids, at which the event is to play. See Remarks.

dwVariation

Variations, where each bit set specifies a valid variation.

nTimeOffset

Offset of the time from mtGridStart.

bTimeRange

Range by which to randomize time. See Remarks.

Remarks

The time of the event can be calculated as follows, where TimeSig is a DMUS_IO_TIMESIG structure containing the time signature:

mtEventTime = nTimeOffset + ((mtGridStart / TimeSig.wGridsPerBeat) * 
((DMUS_PPQ * 4) / TimeSig.bBeat) + (mtGridStart % 
TimeSig.wGridsPerBeat) * (((DMUS_PPQ * 4)/ TimeSig.bBeat) / 
TimeSig.wGridsPerBeat))

The value in bTimeRange is converted to music time when the event occurs, according to the formula given in the Remarks to DMUS_IO_STYLENOTE.

Requirements

  Header: Declared in dmusicf.h.

See Also


© 2004 Microsoft Corporation. All rights reserved.