home *** CD-ROM | disk | FTP | other *** search
/ Programming Tool Box / SIMS_2.iso / vb_code2 / simon / simon.gbl < prev    next >
Text File  |  1995-02-27  |  4KB  |  99 lines

  1.  
  2. Declare Function OpenSound Lib "Sound" () As Integer
  3. Declare Sub CloseSound Lib "Sound" ()
  4. Declare Function SetVoiceQueueSize Lib "Sound" (ByVal nVoice As Integer, ByVal nBytes As Integer) As Integer
  5. Declare Function SetVoiceNote Lib "Sound" (ByVal nVoice As Integer, ByVal nValue As Integer, ByVal nLength As Integer, ByVal nCdots As Integer) As Integer
  6. Declare Function SetVoiceAccent Lib "Sound" (ByVal nVoice As Integer, ByVal nTempo As Integer, ByVal nVolume As Integer, ByVal nMode As Integer, ByVal nPitch As Integer) As Integer
  7. Declare Function SetVoiceEnvelope Lib "Sound" (ByVal nVoice As Integer, ByVal nShape As Integer, ByVal nRepeat As Integer) As Integer
  8. Declare Function SetSoundNoise Lib "Sound" (ByVal nSource As Integer, ByVal nDuration As Integer) As Integer
  9. Declare Function SetVoiceSound Lib "Sound" (ByVal nVoice As Integer, ByVal lFrequency As Long, ByVal nDuration As Integer) As Integer
  10. Declare Function StartSound Lib "Sound" () As Integer
  11. Declare Function StopSound Lib "Sound" () As Integer
  12. Declare Function WaitSoundState Lib "Sound" (ByVal nState As Integer) As Integer
  13. Declare Function SyncAllVoices Lib "Sound" () As Integer
  14. Declare Function CountVoiceNotes Lib "Sound" (ByVal nVoice As Integer) As Integer
  15. Declare Function GetThresholdEvent Lib "Sound" () As Integer
  16. Declare Function GetThresholdStatus Lib "Sound" () As Integer
  17. Declare Function SetVoiceThreshold Lib "Sound" (ByVal nVoice As Integer, ByVal nNotes As Integer) As Integer
  18.  
  19. '  WaitSoundState() Constants
  20. Global Const S_QUEUEEMPTY = 0
  21. Global Const S_THRESHOLD = 1
  22. Global Const S_ALLTHRESHOLD = 2
  23.  
  24. '  Accent Modes
  25. Global Const S_NORMAL = 0
  26. Global Const S_LEGATO = 1
  27. Global Const S_STACCATO = 2
  28.  
  29. '  SetSoundNoise() Sources
  30. Global Const S_PERIOD512 = 0    '  Freq = N/512 high pitch, less coarse hiss
  31. Global Const S_PERIOD1024 = 1   '  Freq = N/1024
  32. Global Const S_PERIOD2048 = 2   '  Freq = N/2048 low pitch, more coarse hiss
  33. Global Const S_PERIODVOICE = 3  '  Source is frequency from voice channel (3)
  34. Global Const S_WHITE512 = 4 '  Freq = N/512 high pitch, less coarse hiss
  35. Global Const S_WHITE1024 = 5    '  Freq = N/1024
  36. Global Const S_WHITE2048 = 6    '  Freq = N/2048 low pitch, more coarse hiss
  37. Global Const S_WHITEVOICE = 7   '  Source is frequency from voice channel (3)
  38.  
  39. Global Const S_SERDVNA = (-1)   '  Device not available
  40. Global Const S_SEROFM = (-2)    '  Out of memory
  41. Global Const S_SERMACT = (-3)   '  Music active
  42. Global Const S_SERQFUL = (-4)   '  Queue full
  43. Global Const S_SERBDNT = (-5)   '  Invalid note
  44. Global Const S_SERDLN = (-6)    '  Invalid note length
  45. Global Const S_SERDCC = (-7)    '  Invalid note count
  46. Global Const S_SERDTP = (-8)    '  Invalid tempo
  47. Global Const S_SERDVL = (-9)    '  Invalid volume
  48. Global Const S_SERDMD = (-10)   '  Invalid mode
  49. Global Const S_SERDSH = (-11)   '  Invalid shape
  50. Global Const S_SERDPT = (-12)   '  Invalid pitch
  51. Global Const S_SERDFQ = (-13)   '  Invalid frequency
  52. Global Const S_SERDDR = (-14)   '  Invalid duration
  53. Global Const S_SERDSR = (-15)   '  Invalid source
  54. Global Const S_SERDST = (-16)   '  Invalid state
  55.  
  56.  
  57. Global Const BREAD = &HFF&
  58. Global Const BBROWN = &H80FF&
  59. Global Const BYELLOW = &HFFFF&
  60. Global Const BGREEN = &HFF00&
  61. Global Const BPURPLE = &HFF00FF
  62. Global Const BBLUE = &HFF0000
  63. Global Const bkaki = &H4040&
  64.  
  65. Global Const lread = &H8080FF
  66. Global Const lbrown = &H80C0FF
  67. Global Const lyellow = &H80FFFF
  68. Global Const lgreen = &HC0FFC0
  69. Global Const lpurple = &HFF80FF
  70. Global Const lblue = &HFF8080
  71.  
  72. Global Const lkaki = &H8080&
  73.  
  74.  
  75. Global Const modal = 1
  76. Global Const modeless = 0
  77.  
  78.  
  79. Global parray(132) As Integer
  80. Global uarray(132) As Integer
  81. Global match%
  82. Global startup%
  83. Global stepper%
  84. Global del%
  85. Global lev%
  86. Global t_int%
  87. Global won%
  88. Global i%
  89. Global r%
  90. Global note%
  91. Global delay%
  92. Global dots%
  93. Global StartDir$
  94. Global NL$
  95. Global errnum%
  96.  
  97.   
  98.  
  99.