Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

245 lines
8.5 KiB

  1. //+-------------------------------------------------------------------------
  2. //
  3. // Microsoft Windows
  4. //
  5. // Copyright (c) 1998-1998 Microsoft Corporation
  6. //
  7. // File: iostru.h
  8. //
  9. //--------------------------------------------------------------------------
  10. // ioStructs.h
  11. //
  12. #ifndef __IOSTRUCTS_H__
  13. #define __IOSTRUCTS_H__
  14. #pragma pack(2)
  15. #define FOURCC_BAND_FORM mmioFOURCC('A','A','B','N')
  16. #define FOURCC_CLICK_LIST mmioFOURCC('A','A','C','L')
  17. #define FOURCC_KEYBOARD_FORM mmioFOURCC('S','J','K','B')
  18. #define FOURCC_PATTERN_FORM mmioFOURCC('A','A','P','T')
  19. #define FOURCC_SECTION_FORM mmioFOURCC('A','A','S','E')
  20. #define FOURCC_SONG_FORM mmioFOURCC('A','A','S','O')
  21. #define FOURCC_STYLE_FORM mmioFOURCC('A','A','S','Y')
  22. #define FOURCC_AUTHOR mmioFOURCC('a','u','t','h')
  23. #define FOURCC_BAND mmioFOURCC('b','a','n','d')
  24. #define FOURCC_CHORD mmioFOURCC('c','h','r','d')
  25. #define FOURCC_CLICK mmioFOURCC('c','l','i','k')
  26. #define FOURCC_COMMAND mmioFOURCC('c','m','n','d')
  27. #define FOURCC_COPYRIGHT mmioFOURCC('c','p','y','r')
  28. #define FOURCC_CURVE mmioFOURCC('c','u','r','v')
  29. #define FOURCC_KEYBOARD mmioFOURCC('k','y','b','d')
  30. #define FOURCC_LYRIC mmioFOURCC('l','y','r','c')
  31. #define FOURCC_MUTE mmioFOURCC('m','u','t','e')
  32. #define FOURCC_NOTE mmioFOURCC('n','o','t','e')
  33. #define FOURCC_PATTERN mmioFOURCC('p','a','t','t')
  34. #define FOURCC_PERSONALITYNAME mmioFOURCC('p','r','n','m')
  35. #define FOURCC_PERSONALITYREF mmioFOURCC('p','r','e','f')
  36. #define FOURCC_PHRASE mmioFOURCC('p','h','r','s')
  37. #define FOURCC_PPQN mmioFOURCC('p','p','q','n')
  38. #define FOURCC_SECTION mmioFOURCC('s','e','c','n')
  39. #define FOURCC_SECTIONUI mmioFOURCC('s','c','u','i')
  40. #define FOURCC_STYLE mmioFOURCC('s','t','y','l')
  41. #define FOURCC_STYLEINFO mmioFOURCC('i','n','f','o')
  42. #define FOURCC_STYLEREF mmioFOURCC('s','r','e','f')
  43. #define FOURCC_TITLE mmioFOURCC('t','i','t','l')
  44. typedef struct ioNoteEvent
  45. {
  46. long lTime; // When this event occurs.
  47. BYTE bStatus; // MIDI status.
  48. BYTE bNote; // Note value.
  49. BYTE bVelocity; // Note velocity.
  50. BYTE bVoiceID; // Band member who will play note
  51. WORD wDuration; // Lead line note duration. (Song)
  52. BYTE bEventType; // Type of event
  53. } ioNoteEvent;
  54. typedef struct ioNote
  55. {
  56. BYTE bEventType; // Type of event
  57. BYTE bVoiceID; // Instrument identifier.
  58. short nTime; // Time from center of beat.
  59. WORD wVariation; // 16 variation bits.
  60. BYTE bScaleValue; // Position in scale.
  61. BYTE bBits; // Various bits.
  62. BYTE bValue; // Note value.
  63. BYTE bVelocity; // Note velocity.
  64. WORD nMusicValue; // Description of note in chord and key.
  65. short nDuration; // Duration
  66. BYTE bTimeRange; // Range to randomize time.
  67. BYTE bDurRange; // Range to randomize duration.
  68. BYTE bVelRange; // Range to randomize velocity.
  69. BYTE bPlayMode;
  70. } ioNote;
  71. typedef struct ioCurveEvent
  72. {
  73. long lTime;
  74. WORD wVariation;
  75. BYTE bVoiceID;
  76. BYTE bVelocity;
  77. BYTE bEventType;
  78. } ioCurveEvent;
  79. typedef struct ioCurve
  80. {
  81. BYTE bEventType;
  82. BYTE bVoiceID;
  83. short nTime;
  84. WORD wVariation;
  85. BYTE bCCData;
  86. } ioCurve;
  87. typedef struct ioSubCurve
  88. {
  89. BYTE bCurveType; // defines the shape of the curve
  90. char fFlipped; // flaggs defining the flipped state: not, vertical, or horizontal
  91. short nMinTime; // left lower corner of bounding box.
  92. short nMinValue; // also used by the ECT_INSTANT curve type.
  93. short nMaxTime; // right upper corner of bounding box.
  94. short nMaxValue;
  95. } ioSubCurve;
  96. typedef struct ioMute
  97. {
  98. long lTime; // Time in clocks.
  99. WORD wMuteBits; // Which instruments to mute.
  100. WORD wLock; // Lock flag
  101. } ioMute;
  102. typedef struct ioCommand
  103. {
  104. long lTime; // Time, in clocks.
  105. DWORD dwCommand; // Command type.
  106. } ioCommand;
  107. typedef struct ioChord
  108. {
  109. long lChordPattern; // pattern that defines chord
  110. long lScalePattern; // scale pattern for the chord
  111. long lInvertPattern; // inversion pattern
  112. BYTE bRoot; // root note of chord
  113. BYTE bReserved; // expansion room
  114. WORD wCFlags; // bit flags
  115. long lReserved; // expansion room
  116. } ioChord;
  117. enum
  118. {
  119. CSF_KEYDOWN = 1, // key currently held down in sjam kybd
  120. CSF_INSCALE = 2, // member of scale
  121. CSF_FLAT = 4, // display with flat
  122. CSF_SIMPLE = 8, // simple chord, display at top of sjam list
  123. };
  124. typedef struct ioChordSelection
  125. {
  126. wchar_t wstrName[16]; // text for display
  127. BYTE fCSFlags; // ChordSelection flags
  128. BYTE bBeat; // beat this falls on
  129. WORD wMeasure; // measure this falls on
  130. ioChord aChord[4]; // array of chords: levels
  131. BYTE bClick; // click this falls on
  132. } ioChordSelection;
  133. #define KEY_FLAT 0x80
  134. typedef struct ioSect
  135. {
  136. long lTime; // Time this section starts.
  137. wchar_t wstrName[16]; // Each section has a name.
  138. WORD wTempo; // Tempo.
  139. WORD wRepeats; // Number of repeats.
  140. WORD wMeasureLength; // Length, in measures.
  141. WORD wClocksPerMeasure; // Length of each measure.
  142. WORD wClocksPerBeat; // Length of each beat.
  143. WORD wTempoFract; // Tempo fraction. (0-65536) (Score only)
  144. DWORD dwFlags; // Currently not used in SuperJAM!
  145. char chKey; // key sig. High bit is flat bit, the rest is root.
  146. char chPad[3];
  147. GUID guidStyle;
  148. GUID guidPersonality;
  149. wchar_t wstrCategory[16];
  150. } ioSection;
  151. typedef struct ioBand
  152. {
  153. wchar_t wstrName[20]; // Band name
  154. BYTE abPatch[16];
  155. BYTE abVolume[16];
  156. BYTE abPan[16];
  157. signed char achOctave[16];
  158. char fDefault; // This band is the style's default band
  159. char chPad;
  160. WORD awDLSBank[16];
  161. BYTE abDLSPatch[16];
  162. GUID guidCollection;
  163. // wchar_t wstrCollection[16];
  164. char szCollection[32]; // this only needs to be single-wide chars
  165. } ioBand;
  166. typedef struct ioLyric
  167. {
  168. long lTime; // Time, in clocks
  169. } ioLyric;
  170. typedef struct ioPhrase
  171. {
  172. long lTime;
  173. BYTE bID; // which phrase it is. Index starting at 0.
  174. } ioPhrase;
  175. typedef struct ioClick
  176. {
  177. short lTime; // Index into grid.
  178. } ioClick;
  179. typedef struct ioPattern
  180. {
  181. long lTime; // Time this starts.
  182. DWORD dwLength; // Pattern length in clocks.
  183. DWORD fFlags; // Various flags.
  184. WORD wClocksPerClick; // Size of each click.
  185. WORD wBeat; // What note gets the beat.
  186. WORD wClocksPerBeat; // Size of each beat.
  187. WORD wMeasures; // Number of measures.
  188. wchar_t wstrName[16]; // Name of pattern.
  189. DWORD dwKeyPattern; // Key for defining in.
  190. DWORD dwChordPattern; // Defining chord.
  191. BYTE abInvertUpper[16]; // Inversion upper limit.
  192. BYTE abInvertLower[16]; // Inversion upper limit.
  193. WORD wInvert; // Activate inversion flags.
  194. WORD awVarFlags[16][16]; // Var flags for all musicians.
  195. WORD wAutoInvert; // Automatically set inversion limits
  196. BYTE bRoot; // Root for defining.
  197. char achChordChoice[16];
  198. } ioPattern;
  199. typedef struct ioStyle
  200. {
  201. wchar_t wstrName[16]; // Each style has a name.
  202. WORD wBPM; // Beats per measure.
  203. WORD wBeat; // Beat note.
  204. WORD wClocksPerClick; // Clocks per click in patterns.
  205. WORD wClocksPerBeat; // Clocks per beat.
  206. WORD wClocksPerMeasure; // Clocks per measure.
  207. WORD wTempo; // Tempo.
  208. WORD wTempoFract;
  209. GUID guid;
  210. wchar_t wstrCategory[16];
  211. } ioStyle;
  212. typedef struct ioPersonalityRef
  213. {
  214. wchar_t wstrName[20]; // Internal name stored in personality
  215. char fDefault; // 1=Default personality
  216. char achPad[3];
  217. GUID guid;
  218. } ioPersonalityRef;
  219. #pragma pack()
  220. #endif// __IOSTRUCTS_H__