bass.h 46 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161
  1. /*
  2. BASS 2.4 C/C++ header file
  3. Copyright (c) 1999-2019 Un4seen Developments Ltd.
  4. See the BASS.CHM file for more detailed documentation
  5. */
  6. #ifndef BASS_H
  7. #define BASS_H
  8. #ifdef _WIN32
  9. #include <wtypes.h>
  10. typedef unsigned __int64 QWORD;
  11. #else
  12. #include <stdint.h>
  13. #define WINAPI
  14. #define CALLBACK
  15. typedef uint8_t BYTE;
  16. typedef uint16_t WORD;
  17. typedef uint32_t DWORD;
  18. typedef uint64_t QWORD;
  19. #ifdef __OBJC__
  20. #include <objc/objc.h>
  21. #else
  22. typedef int BOOL;
  23. #endif
  24. #ifndef TRUE
  25. #define TRUE 1
  26. #define FALSE 0
  27. #endif
  28. #define LOBYTE(a) (BYTE)(a)
  29. #define HIBYTE(a) (BYTE)((a)>>8)
  30. #define LOWORD(a) (WORD)(a)
  31. #define HIWORD(a) (WORD)((a)>>16)
  32. #define MAKEWORD(a,b) (WORD)(((a)&0xff)|((b)<<8))
  33. #define MAKELONG(a,b) (DWORD)(((a)&0xffff)|((b)<<16))
  34. #endif
  35. #ifdef __cplusplus
  36. extern "C" {
  37. #endif
  38. #define BASSVERSION 0x204 // API version
  39. #define BASSVERSIONTEXT "2.4"
  40. #ifndef BASSDEF
  41. #define BASSDEF(f) WINAPI f
  42. #else
  43. #define NOBASSOVERLOADS
  44. #endif
  45. typedef DWORD HMUSIC; // MOD music handle
  46. typedef DWORD HSAMPLE; // sample handle
  47. typedef DWORD HCHANNEL; // playing sample's channel handle
  48. typedef DWORD HSTREAM; // sample stream handle
  49. typedef DWORD HRECORD; // recording handle
  50. typedef DWORD HSYNC; // synchronizer handle
  51. typedef DWORD HDSP; // DSP handle
  52. typedef DWORD HFX; // DX8 effect handle
  53. typedef DWORD HPLUGIN; // Plugin handle
  54. // Error codes returned by BASS_ErrorGetCode
  55. #define BASS_OK 0 // all is OK
  56. #define BASS_ERROR_MEM 1 // memory error
  57. #define BASS_ERROR_FILEOPEN 2 // can't open the file
  58. #define BASS_ERROR_DRIVER 3 // can't find a free/valid driver
  59. #define BASS_ERROR_BUFLOST 4 // the sample buffer was lost
  60. #define BASS_ERROR_HANDLE 5 // invalid handle
  61. #define BASS_ERROR_FORMAT 6 // unsupported sample format
  62. #define BASS_ERROR_POSITION 7 // invalid position
  63. #define BASS_ERROR_INIT 8 // BASS_Init has not been successfully called
  64. #define BASS_ERROR_START 9 // BASS_Start has not been successfully called
  65. #define BASS_ERROR_SSL 10 // SSL/HTTPS support isn't available
  66. #define BASS_ERROR_ALREADY 14 // already initialized/paused/whatever
  67. #define BASS_ERROR_NOTAUDIO 17 // file does not contain audio
  68. #define BASS_ERROR_NOCHAN 18 // can't get a free channel
  69. #define BASS_ERROR_ILLTYPE 19 // an illegal type was specified
  70. #define BASS_ERROR_ILLPARAM 20 // an illegal parameter was specified
  71. #define BASS_ERROR_NO3D 21 // no 3D support
  72. #define BASS_ERROR_NOEAX 22 // no EAX support
  73. #define BASS_ERROR_DEVICE 23 // illegal device number
  74. #define BASS_ERROR_NOPLAY 24 // not playing
  75. #define BASS_ERROR_FREQ 25 // illegal sample rate
  76. #define BASS_ERROR_NOTFILE 27 // the stream is not a file stream
  77. #define BASS_ERROR_NOHW 29 // no hardware voices available
  78. #define BASS_ERROR_EMPTY 31 // the MOD music has no sequence data
  79. #define BASS_ERROR_NONET 32 // no internet connection could be opened
  80. #define BASS_ERROR_CREATE 33 // couldn't create the file
  81. #define BASS_ERROR_NOFX 34 // effects are not available
  82. #define BASS_ERROR_NOTAVAIL 37 // requested data/action is not available
  83. #define BASS_ERROR_DECODE 38 // the channel is/isn't a "decoding channel"
  84. #define BASS_ERROR_DX 39 // a sufficient DirectX version is not installed
  85. #define BASS_ERROR_TIMEOUT 40 // connection timedout
  86. #define BASS_ERROR_FILEFORM 41 // unsupported file format
  87. #define BASS_ERROR_SPEAKER 42 // unavailable speaker
  88. #define BASS_ERROR_VERSION 43 // invalid BASS version (used by add-ons)
  89. #define BASS_ERROR_CODEC 44 // codec is not available/supported
  90. #define BASS_ERROR_ENDED 45 // the channel/file has ended
  91. #define BASS_ERROR_BUSY 46 // the device is busy
  92. #define BASS_ERROR_UNSTREAMABLE 47 // unstreamable file
  93. #define BASS_ERROR_UNKNOWN -1 // some other mystery problem
  94. // BASS_SetConfig options
  95. #define BASS_CONFIG_BUFFER 0
  96. #define BASS_CONFIG_UPDATEPERIOD 1
  97. #define BASS_CONFIG_GVOL_SAMPLE 4
  98. #define BASS_CONFIG_GVOL_STREAM 5
  99. #define BASS_CONFIG_GVOL_MUSIC 6
  100. #define BASS_CONFIG_CURVE_VOL 7
  101. #define BASS_CONFIG_CURVE_PAN 8
  102. #define BASS_CONFIG_FLOATDSP 9
  103. #define BASS_CONFIG_3DALGORITHM 10
  104. #define BASS_CONFIG_NET_TIMEOUT 11
  105. #define BASS_CONFIG_NET_BUFFER 12
  106. #define BASS_CONFIG_PAUSE_NOPLAY 13
  107. #define BASS_CONFIG_NET_PREBUF 15
  108. #define BASS_CONFIG_NET_PASSIVE 18
  109. #define BASS_CONFIG_REC_BUFFER 19
  110. #define BASS_CONFIG_NET_PLAYLIST 21
  111. #define BASS_CONFIG_MUSIC_VIRTUAL 22
  112. #define BASS_CONFIG_VERIFY 23
  113. #define BASS_CONFIG_UPDATETHREADS 24
  114. #define BASS_CONFIG_DEV_BUFFER 27
  115. #define BASS_CONFIG_REC_LOOPBACK 28
  116. #define BASS_CONFIG_VISTA_TRUEPOS 30
  117. #define BASS_CONFIG_IOS_SESSION 34
  118. #define BASS_CONFIG_IOS_MIXAUDIO 34
  119. #define BASS_CONFIG_DEV_DEFAULT 36
  120. #define BASS_CONFIG_NET_READTIMEOUT 37
  121. #define BASS_CONFIG_VISTA_SPEAKERS 38
  122. #define BASS_CONFIG_IOS_SPEAKER 39
  123. #define BASS_CONFIG_MF_DISABLE 40
  124. #define BASS_CONFIG_HANDLES 41
  125. #define BASS_CONFIG_UNICODE 42
  126. #define BASS_CONFIG_SRC 43
  127. #define BASS_CONFIG_SRC_SAMPLE 44
  128. #define BASS_CONFIG_ASYNCFILE_BUFFER 45
  129. #define BASS_CONFIG_OGG_PRESCAN 47
  130. #define BASS_CONFIG_MF_VIDEO 48
  131. #define BASS_CONFIG_AIRPLAY 49
  132. #define BASS_CONFIG_DEV_NONSTOP 50
  133. #define BASS_CONFIG_IOS_NOCATEGORY 51
  134. #define BASS_CONFIG_VERIFY_NET 52
  135. #define BASS_CONFIG_DEV_PERIOD 53
  136. #define BASS_CONFIG_FLOAT 54
  137. #define BASS_CONFIG_NET_SEEK 56
  138. #define BASS_CONFIG_AM_DISABLE 58
  139. #define BASS_CONFIG_NET_PLAYLIST_DEPTH 59
  140. #define BASS_CONFIG_NET_PREBUF_WAIT 60
  141. #define BASS_CONFIG_ANDROID_SESSIONID 62
  142. #define BASS_CONFIG_WASAPI_PERSIST 65
  143. #define BASS_CONFIG_REC_WASAPI 66
  144. #define BASS_CONFIG_ANDROID_AAUDIO 67
  145. #define BASS_CONFIG_MP3_OLDGAPS 68
  146. // BASS_SetConfigPtr options
  147. #define BASS_CONFIG_NET_AGENT 16
  148. #define BASS_CONFIG_NET_PROXY 17
  149. #define BASS_CONFIG_IOS_NOTIFY 46
  150. #define BASS_CONFIG_LIBSSL 64
  151. // BASS_CONFIG_IOS_SESSION flags
  152. #define BASS_IOS_SESSION_MIX 1
  153. #define BASS_IOS_SESSION_DUCK 2
  154. #define BASS_IOS_SESSION_AMBIENT 4
  155. #define BASS_IOS_SESSION_SPEAKER 8
  156. #define BASS_IOS_SESSION_DISABLE 16
  157. // BASS_Init flags
  158. #define BASS_DEVICE_8BITS 1 // 8 bit
  159. #define BASS_DEVICE_MONO 2 // mono
  160. #define BASS_DEVICE_3D 4 // enable 3D functionality
  161. #define BASS_DEVICE_16BITS 8 // limit output to 16 bit
  162. #define BASS_DEVICE_LATENCY 0x100 // calculate device latency (BASS_INFO struct)
  163. #define BASS_DEVICE_CPSPEAKERS 0x400 // detect speakers via Windows control panel
  164. #define BASS_DEVICE_SPEAKERS 0x800 // force enabling of speaker assignment
  165. #define BASS_DEVICE_NOSPEAKER 0x1000 // ignore speaker arrangement
  166. #define BASS_DEVICE_DMIX 0x2000 // use ALSA "dmix" plugin
  167. #define BASS_DEVICE_FREQ 0x4000 // set device sample rate
  168. #define BASS_DEVICE_STEREO 0x8000 // limit output to stereo
  169. #define BASS_DEVICE_HOG 0x10000 // hog/exclusive mode
  170. #define BASS_DEVICE_AUDIOTRACK 0x20000 // use AudioTrack output
  171. #define BASS_DEVICE_DSOUND 0x40000 // use DirectSound output
  172. // DirectSound interfaces (for use with BASS_GetDSoundObject)
  173. #define BASS_OBJECT_DS 1 // IDirectSound
  174. #define BASS_OBJECT_DS3DL 2 // IDirectSound3DListener
  175. // Device info structure
  176. typedef struct {
  177. #if defined(_WIN32_WCE) || (WINAPI_FAMILY && WINAPI_FAMILY!=WINAPI_FAMILY_DESKTOP_APP)
  178. const wchar_t *name; // description
  179. const wchar_t *driver; // driver
  180. #else
  181. const char *name; // description
  182. const char *driver; // driver
  183. #endif
  184. DWORD flags;
  185. } BASS_DEVICEINFO;
  186. // BASS_DEVICEINFO flags
  187. #define BASS_DEVICE_ENABLED 1
  188. #define BASS_DEVICE_DEFAULT 2
  189. #define BASS_DEVICE_INIT 4
  190. #define BASS_DEVICE_LOOPBACK 8
  191. #define BASS_DEVICE_TYPE_MASK 0xff000000
  192. #define BASS_DEVICE_TYPE_NETWORK 0x01000000
  193. #define BASS_DEVICE_TYPE_SPEAKERS 0x02000000
  194. #define BASS_DEVICE_TYPE_LINE 0x03000000
  195. #define BASS_DEVICE_TYPE_HEADPHONES 0x04000000
  196. #define BASS_DEVICE_TYPE_MICROPHONE 0x05000000
  197. #define BASS_DEVICE_TYPE_HEADSET 0x06000000
  198. #define BASS_DEVICE_TYPE_HANDSET 0x07000000
  199. #define BASS_DEVICE_TYPE_DIGITAL 0x08000000
  200. #define BASS_DEVICE_TYPE_SPDIF 0x09000000
  201. #define BASS_DEVICE_TYPE_HDMI 0x0a000000
  202. #define BASS_DEVICE_TYPE_DISPLAYPORT 0x40000000
  203. // BASS_GetDeviceInfo flags
  204. #define BASS_DEVICES_AIRPLAY 0x1000000
  205. typedef struct {
  206. DWORD flags; // device capabilities (DSCAPS_xxx flags)
  207. DWORD hwsize; // size of total device hardware memory
  208. DWORD hwfree; // size of free device hardware memory
  209. DWORD freesam; // number of free sample slots in the hardware
  210. DWORD free3d; // number of free 3D sample slots in the hardware
  211. DWORD minrate; // min sample rate supported by the hardware
  212. DWORD maxrate; // max sample rate supported by the hardware
  213. BOOL eax; // device supports EAX? (always FALSE if BASS_DEVICE_3D was not used)
  214. DWORD minbuf; // recommended minimum buffer length in ms (requires BASS_DEVICE_LATENCY)
  215. DWORD dsver; // DirectSound version
  216. DWORD latency; // delay (in ms) before start of playback (requires BASS_DEVICE_LATENCY)
  217. DWORD initflags; // BASS_Init "flags" parameter
  218. DWORD speakers; // number of speakers available
  219. DWORD freq; // current output rate
  220. } BASS_INFO;
  221. // BASS_INFO flags (from DSOUND.H)
  222. #define DSCAPS_CONTINUOUSRATE 0x00000010 // supports all sample rates between min/maxrate
  223. #define DSCAPS_EMULDRIVER 0x00000020 // device does NOT have hardware DirectSound support
  224. #define DSCAPS_CERTIFIED 0x00000040 // device driver has been certified by Microsoft
  225. #define DSCAPS_SECONDARYMONO 0x00000100 // mono
  226. #define DSCAPS_SECONDARYSTEREO 0x00000200 // stereo
  227. #define DSCAPS_SECONDARY8BIT 0x00000400 // 8 bit
  228. #define DSCAPS_SECONDARY16BIT 0x00000800 // 16 bit
  229. // Recording device info structure
  230. typedef struct {
  231. DWORD flags; // device capabilities (DSCCAPS_xxx flags)
  232. DWORD formats; // supported standard formats (WAVE_FORMAT_xxx flags)
  233. DWORD inputs; // number of inputs
  234. BOOL singlein; // TRUE = only 1 input can be set at a time
  235. DWORD freq; // current input rate
  236. } BASS_RECORDINFO;
  237. // BASS_RECORDINFO flags (from DSOUND.H)
  238. #define DSCCAPS_EMULDRIVER DSCAPS_EMULDRIVER // device does NOT have hardware DirectSound recording support
  239. #define DSCCAPS_CERTIFIED DSCAPS_CERTIFIED // device driver has been certified by Microsoft
  240. // defines for formats field of BASS_RECORDINFO (from MMSYSTEM.H)
  241. #ifndef WAVE_FORMAT_1M08
  242. #define WAVE_FORMAT_1M08 0x00000001 /* 11.025 kHz, Mono, 8-bit */
  243. #define WAVE_FORMAT_1S08 0x00000002 /* 11.025 kHz, Stereo, 8-bit */
  244. #define WAVE_FORMAT_1M16 0x00000004 /* 11.025 kHz, Mono, 16-bit */
  245. #define WAVE_FORMAT_1S16 0x00000008 /* 11.025 kHz, Stereo, 16-bit */
  246. #define WAVE_FORMAT_2M08 0x00000010 /* 22.05 kHz, Mono, 8-bit */
  247. #define WAVE_FORMAT_2S08 0x00000020 /* 22.05 kHz, Stereo, 8-bit */
  248. #define WAVE_FORMAT_2M16 0x00000040 /* 22.05 kHz, Mono, 16-bit */
  249. #define WAVE_FORMAT_2S16 0x00000080 /* 22.05 kHz, Stereo, 16-bit */
  250. #define WAVE_FORMAT_4M08 0x00000100 /* 44.1 kHz, Mono, 8-bit */
  251. #define WAVE_FORMAT_4S08 0x00000200 /* 44.1 kHz, Stereo, 8-bit */
  252. #define WAVE_FORMAT_4M16 0x00000400 /* 44.1 kHz, Mono, 16-bit */
  253. #define WAVE_FORMAT_4S16 0x00000800 /* 44.1 kHz, Stereo, 16-bit */
  254. #endif
  255. // Sample info structure
  256. typedef struct {
  257. DWORD freq; // default playback rate
  258. float volume; // default volume (0-1)
  259. float pan; // default pan (-1=left, 0=middle, 1=right)
  260. DWORD flags; // BASS_SAMPLE_xxx flags
  261. DWORD length; // length (in bytes)
  262. DWORD max; // maximum simultaneous playbacks
  263. DWORD origres; // original resolution
  264. DWORD chans; // number of channels
  265. DWORD mingap; // minimum gap (ms) between creating channels
  266. DWORD mode3d; // BASS_3DMODE_xxx mode
  267. float mindist; // minimum distance
  268. float maxdist; // maximum distance
  269. DWORD iangle; // angle of inside projection cone
  270. DWORD oangle; // angle of outside projection cone
  271. float outvol; // delta-volume outside the projection cone
  272. DWORD vam; // voice allocation/management flags (BASS_VAM_xxx)
  273. DWORD priority; // priority (0=lowest, 0xffffffff=highest)
  274. } BASS_SAMPLE;
  275. #define BASS_SAMPLE_8BITS 1 // 8 bit
  276. #define BASS_SAMPLE_FLOAT 256 // 32 bit floating-point
  277. #define BASS_SAMPLE_MONO 2 // mono
  278. #define BASS_SAMPLE_LOOP 4 // looped
  279. #define BASS_SAMPLE_3D 8 // 3D functionality
  280. #define BASS_SAMPLE_SOFTWARE 16 // not using hardware mixing
  281. #define BASS_SAMPLE_MUTEMAX 32 // mute at max distance (3D only)
  282. #define BASS_SAMPLE_VAM 64 // DX7 voice allocation & management
  283. #define BASS_SAMPLE_FX 128 // old implementation of DX8 effects
  284. #define BASS_SAMPLE_OVER_VOL 0x10000 // override lowest volume
  285. #define BASS_SAMPLE_OVER_POS 0x20000 // override longest playing
  286. #define BASS_SAMPLE_OVER_DIST 0x30000 // override furthest from listener (3D only)
  287. #define BASS_STREAM_PRESCAN 0x20000 // enable pin-point seeking/length (MP3/MP2/MP1)
  288. #define BASS_STREAM_AUTOFREE 0x40000 // automatically free the stream when it stop/ends
  289. #define BASS_STREAM_RESTRATE 0x80000 // restrict the download rate of internet file streams
  290. #define BASS_STREAM_BLOCK 0x100000 // download/play internet file stream in small blocks
  291. #define BASS_STREAM_DECODE 0x200000 // don't play the stream, only decode (BASS_ChannelGetData)
  292. #define BASS_STREAM_STATUS 0x800000 // give server status info (HTTP/ICY tags) in DOWNLOADPROC
  293. #define BASS_MP3_IGNOREDELAY 0x200 // ignore LAME/Xing/VBRI/iTunes delay & padding info
  294. #define BASS_MP3_SETPOS BASS_STREAM_PRESCAN
  295. #define BASS_MUSIC_FLOAT BASS_SAMPLE_FLOAT
  296. #define BASS_MUSIC_MONO BASS_SAMPLE_MONO
  297. #define BASS_MUSIC_LOOP BASS_SAMPLE_LOOP
  298. #define BASS_MUSIC_3D BASS_SAMPLE_3D
  299. #define BASS_MUSIC_FX BASS_SAMPLE_FX
  300. #define BASS_MUSIC_AUTOFREE BASS_STREAM_AUTOFREE
  301. #define BASS_MUSIC_DECODE BASS_STREAM_DECODE
  302. #define BASS_MUSIC_PRESCAN BASS_STREAM_PRESCAN // calculate playback length
  303. #define BASS_MUSIC_CALCLEN BASS_MUSIC_PRESCAN
  304. #define BASS_MUSIC_RAMP 0x200 // normal ramping
  305. #define BASS_MUSIC_RAMPS 0x400 // sensitive ramping
  306. #define BASS_MUSIC_SURROUND 0x800 // surround sound
  307. #define BASS_MUSIC_SURROUND2 0x1000 // surround sound (mode 2)
  308. #define BASS_MUSIC_FT2PAN 0x2000 // apply FastTracker 2 panning to XM files
  309. #define BASS_MUSIC_FT2MOD 0x2000 // play .MOD as FastTracker 2 does
  310. #define BASS_MUSIC_PT1MOD 0x4000 // play .MOD as ProTracker 1 does
  311. #define BASS_MUSIC_NONINTER 0x10000 // non-interpolated sample mixing
  312. #define BASS_MUSIC_SINCINTER 0x800000 // sinc interpolated sample mixing
  313. #define BASS_MUSIC_POSRESET 0x8000 // stop all notes when moving position
  314. #define BASS_MUSIC_POSRESETEX 0x400000 // stop all notes and reset bmp/etc when moving position
  315. #define BASS_MUSIC_STOPBACK 0x80000 // stop the music on a backwards jump effect
  316. #define BASS_MUSIC_NOSAMPLE 0x100000 // don't load the samples
  317. // Speaker assignment flags
  318. #define BASS_SPEAKER_FRONT 0x1000000 // front speakers
  319. #define BASS_SPEAKER_REAR 0x2000000 // rear/side speakers
  320. #define BASS_SPEAKER_CENLFE 0x3000000 // center & LFE speakers (5.1)
  321. #define BASS_SPEAKER_REAR2 0x4000000 // rear center speakers (7.1)
  322. #define BASS_SPEAKER_N(n) ((n)<<24) // n'th pair of speakers (max 15)
  323. #define BASS_SPEAKER_LEFT 0x10000000 // modifier: left
  324. #define BASS_SPEAKER_RIGHT 0x20000000 // modifier: right
  325. #define BASS_SPEAKER_FRONTLEFT BASS_SPEAKER_FRONT|BASS_SPEAKER_LEFT
  326. #define BASS_SPEAKER_FRONTRIGHT BASS_SPEAKER_FRONT|BASS_SPEAKER_RIGHT
  327. #define BASS_SPEAKER_REARLEFT BASS_SPEAKER_REAR|BASS_SPEAKER_LEFT
  328. #define BASS_SPEAKER_REARRIGHT BASS_SPEAKER_REAR|BASS_SPEAKER_RIGHT
  329. #define BASS_SPEAKER_CENTER BASS_SPEAKER_CENLFE|BASS_SPEAKER_LEFT
  330. #define BASS_SPEAKER_LFE BASS_SPEAKER_CENLFE|BASS_SPEAKER_RIGHT
  331. #define BASS_SPEAKER_REAR2LEFT BASS_SPEAKER_REAR2|BASS_SPEAKER_LEFT
  332. #define BASS_SPEAKER_REAR2RIGHT BASS_SPEAKER_REAR2|BASS_SPEAKER_RIGHT
  333. #define BASS_ASYNCFILE 0x40000000
  334. #define BASS_UNICODE 0x80000000
  335. #define BASS_RECORD_PAUSE 0x8000 // start recording paused
  336. #define BASS_RECORD_ECHOCANCEL 0x2000
  337. #define BASS_RECORD_AGC 0x4000
  338. // DX7 voice allocation & management flags
  339. #define BASS_VAM_HARDWARE 1
  340. #define BASS_VAM_SOFTWARE 2
  341. #define BASS_VAM_TERM_TIME 4
  342. #define BASS_VAM_TERM_DIST 8
  343. #define BASS_VAM_TERM_PRIO 16
  344. // Channel info structure
  345. typedef struct {
  346. DWORD freq; // default playback rate
  347. DWORD chans; // channels
  348. DWORD flags; // BASS_SAMPLE/STREAM/MUSIC/SPEAKER flags
  349. DWORD ctype; // type of channel
  350. DWORD origres; // original resolution
  351. HPLUGIN plugin; // plugin
  352. HSAMPLE sample; // sample
  353. const char *filename; // filename
  354. } BASS_CHANNELINFO;
  355. #define BASS_ORIGRES_FLOAT 0x10000
  356. // BASS_CHANNELINFO types
  357. #define BASS_CTYPE_SAMPLE 1
  358. #define BASS_CTYPE_RECORD 2
  359. #define BASS_CTYPE_STREAM 0x10000
  360. #define BASS_CTYPE_STREAM_VORBIS 0x10002
  361. #define BASS_CTYPE_STREAM_OGG 0x10002
  362. #define BASS_CTYPE_STREAM_MP1 0x10003
  363. #define BASS_CTYPE_STREAM_MP2 0x10004
  364. #define BASS_CTYPE_STREAM_MP3 0x10005
  365. #define BASS_CTYPE_STREAM_AIFF 0x10006
  366. #define BASS_CTYPE_STREAM_CA 0x10007
  367. #define BASS_CTYPE_STREAM_MF 0x10008
  368. #define BASS_CTYPE_STREAM_AM 0x10009
  369. #define BASS_CTYPE_STREAM_DUMMY 0x18000
  370. #define BASS_CTYPE_STREAM_DEVICE 0x18001
  371. #define BASS_CTYPE_STREAM_WAV 0x40000 // WAVE flag, LOWORD=codec
  372. #define BASS_CTYPE_STREAM_WAV_PCM 0x50001
  373. #define BASS_CTYPE_STREAM_WAV_FLOAT 0x50003
  374. #define BASS_CTYPE_MUSIC_MOD 0x20000
  375. #define BASS_CTYPE_MUSIC_MTM 0x20001
  376. #define BASS_CTYPE_MUSIC_S3M 0x20002
  377. #define BASS_CTYPE_MUSIC_XM 0x20003
  378. #define BASS_CTYPE_MUSIC_IT 0x20004
  379. #define BASS_CTYPE_MUSIC_MO3 0x00100 // MO3 flag
  380. typedef struct {
  381. DWORD ctype; // channel type
  382. #if defined(_WIN32_WCE) || (WINAPI_FAMILY && WINAPI_FAMILY!=WINAPI_FAMILY_DESKTOP_APP)
  383. const wchar_t *name; // format description
  384. const wchar_t *exts; // file extension filter (*.ext1;*.ext2;etc...)
  385. #else
  386. const char *name; // format description
  387. const char *exts; // file extension filter (*.ext1;*.ext2;etc...)
  388. #endif
  389. } BASS_PLUGINFORM;
  390. typedef struct {
  391. DWORD version; // version (same form as BASS_GetVersion)
  392. DWORD formatc; // number of formats
  393. const BASS_PLUGINFORM *formats; // the array of formats
  394. } BASS_PLUGININFO;
  395. // 3D vector (for 3D positions/velocities/orientations)
  396. typedef struct BASS_3DVECTOR {
  397. #ifdef __cplusplus
  398. BASS_3DVECTOR() {};
  399. BASS_3DVECTOR(float _x, float _y, float _z) : x(_x), y(_y), z(_z) {};
  400. #endif
  401. float x; // +=right, -=left
  402. float y; // +=up, -=down
  403. float z; // +=front, -=behind
  404. } BASS_3DVECTOR;
  405. // 3D channel modes
  406. #define BASS_3DMODE_NORMAL 0 // normal 3D processing
  407. #define BASS_3DMODE_RELATIVE 1 // position is relative to the listener
  408. #define BASS_3DMODE_OFF 2 // no 3D processing
  409. // software 3D mixing algorithms (used with BASS_CONFIG_3DALGORITHM)
  410. #define BASS_3DALG_DEFAULT 0
  411. #define BASS_3DALG_OFF 1
  412. #define BASS_3DALG_FULL 2
  413. #define BASS_3DALG_LIGHT 3
  414. // EAX environments, use with BASS_SetEAXParameters
  415. enum
  416. {
  417. EAX_ENVIRONMENT_GENERIC,
  418. EAX_ENVIRONMENT_PADDEDCELL,
  419. EAX_ENVIRONMENT_ROOM,
  420. EAX_ENVIRONMENT_BATHROOM,
  421. EAX_ENVIRONMENT_LIVINGROOM,
  422. EAX_ENVIRONMENT_STONEROOM,
  423. EAX_ENVIRONMENT_AUDITORIUM,
  424. EAX_ENVIRONMENT_CONCERTHALL,
  425. EAX_ENVIRONMENT_CAVE,
  426. EAX_ENVIRONMENT_ARENA,
  427. EAX_ENVIRONMENT_HANGAR,
  428. EAX_ENVIRONMENT_CARPETEDHALLWAY,
  429. EAX_ENVIRONMENT_HALLWAY,
  430. EAX_ENVIRONMENT_STONECORRIDOR,
  431. EAX_ENVIRONMENT_ALLEY,
  432. EAX_ENVIRONMENT_FOREST,
  433. EAX_ENVIRONMENT_CITY,
  434. EAX_ENVIRONMENT_MOUNTAINS,
  435. EAX_ENVIRONMENT_QUARRY,
  436. EAX_ENVIRONMENT_PLAIN,
  437. EAX_ENVIRONMENT_PARKINGLOT,
  438. EAX_ENVIRONMENT_SEWERPIPE,
  439. EAX_ENVIRONMENT_UNDERWATER,
  440. EAX_ENVIRONMENT_DRUGGED,
  441. EAX_ENVIRONMENT_DIZZY,
  442. EAX_ENVIRONMENT_PSYCHOTIC,
  443. EAX_ENVIRONMENT_COUNT // total number of environments
  444. };
  445. // EAX presets, usage: BASS_SetEAXParameters(EAX_PRESET_xxx)
  446. #define EAX_PRESET_GENERIC EAX_ENVIRONMENT_GENERIC,0.5F,1.493F,0.5F
  447. #define EAX_PRESET_PADDEDCELL EAX_ENVIRONMENT_PADDEDCELL,0.25F,0.1F,0.0F
  448. #define EAX_PRESET_ROOM EAX_ENVIRONMENT_ROOM,0.417F,0.4F,0.666F
  449. #define EAX_PRESET_BATHROOM EAX_ENVIRONMENT_BATHROOM,0.653F,1.499F,0.166F
  450. #define EAX_PRESET_LIVINGROOM EAX_ENVIRONMENT_LIVINGROOM,0.208F,0.478F,0.0F
  451. #define EAX_PRESET_STONEROOM EAX_ENVIRONMENT_STONEROOM,0.5F,2.309F,0.888F
  452. #define EAX_PRESET_AUDITORIUM EAX_ENVIRONMENT_AUDITORIUM,0.403F,4.279F,0.5F
  453. #define EAX_PRESET_CONCERTHALL EAX_ENVIRONMENT_CONCERTHALL,0.5F,3.961F,0.5F
  454. #define EAX_PRESET_CAVE EAX_ENVIRONMENT_CAVE,0.5F,2.886F,1.304F
  455. #define EAX_PRESET_ARENA EAX_ENVIRONMENT_ARENA,0.361F,7.284F,0.332F
  456. #define EAX_PRESET_HANGAR EAX_ENVIRONMENT_HANGAR,0.5F,10.0F,0.3F
  457. #define EAX_PRESET_CARPETEDHALLWAY EAX_ENVIRONMENT_CARPETEDHALLWAY,0.153F,0.259F,2.0F
  458. #define EAX_PRESET_HALLWAY EAX_ENVIRONMENT_HALLWAY,0.361F,1.493F,0.0F
  459. #define EAX_PRESET_STONECORRIDOR EAX_ENVIRONMENT_STONECORRIDOR,0.444F,2.697F,0.638F
  460. #define EAX_PRESET_ALLEY EAX_ENVIRONMENT_ALLEY,0.25F,1.752F,0.776F
  461. #define EAX_PRESET_FOREST EAX_ENVIRONMENT_FOREST,0.111F,3.145F,0.472F
  462. #define EAX_PRESET_CITY EAX_ENVIRONMENT_CITY,0.111F,2.767F,0.224F
  463. #define EAX_PRESET_MOUNTAINS EAX_ENVIRONMENT_MOUNTAINS,0.194F,7.841F,0.472F
  464. #define EAX_PRESET_QUARRY EAX_ENVIRONMENT_QUARRY,1.0F,1.499F,0.5F
  465. #define EAX_PRESET_PLAIN EAX_ENVIRONMENT_PLAIN,0.097F,2.767F,0.224F
  466. #define EAX_PRESET_PARKINGLOT EAX_ENVIRONMENT_PARKINGLOT,0.208F,1.652F,1.5F
  467. #define EAX_PRESET_SEWERPIPE EAX_ENVIRONMENT_SEWERPIPE,0.652F,2.886F,0.25F
  468. #define EAX_PRESET_UNDERWATER EAX_ENVIRONMENT_UNDERWATER,1.0F,1.499F,0.0F
  469. #define EAX_PRESET_DRUGGED EAX_ENVIRONMENT_DRUGGED,0.875F,8.392F,1.388F
  470. #define EAX_PRESET_DIZZY EAX_ENVIRONMENT_DIZZY,0.139F,17.234F,0.666F
  471. #define EAX_PRESET_PSYCHOTIC EAX_ENVIRONMENT_PSYCHOTIC,0.486F,7.563F,0.806F
  472. typedef DWORD (CALLBACK STREAMPROC)(HSTREAM handle, void *buffer, DWORD length, void *user);
  473. /* User stream callback function.
  474. handle : The stream that needs writing
  475. buffer : Buffer to write the samples in
  476. length : Number of bytes to write
  477. user : The 'user' parameter value given when calling BASS_StreamCreate
  478. RETURN : Number of bytes written. Set the BASS_STREAMPROC_END flag to end the stream. */
  479. #define BASS_STREAMPROC_END 0x80000000 // end of user stream flag
  480. // special STREAMPROCs
  481. #define STREAMPROC_DUMMY (STREAMPROC*)0 // "dummy" stream
  482. #define STREAMPROC_PUSH (STREAMPROC*)-1 // push stream
  483. #define STREAMPROC_DEVICE (STREAMPROC*)-2 // device mix stream
  484. #define STREAMPROC_DEVICE_3D (STREAMPROC*)-3 // device 3D mix stream
  485. // BASS_StreamCreateFileUser file systems
  486. #define STREAMFILE_NOBUFFER 0
  487. #define STREAMFILE_BUFFER 1
  488. #define STREAMFILE_BUFFERPUSH 2
  489. // User file stream callback functions
  490. typedef void (CALLBACK FILECLOSEPROC)(void *user);
  491. typedef QWORD (CALLBACK FILELENPROC)(void *user);
  492. typedef DWORD (CALLBACK FILEREADPROC)(void *buffer, DWORD length, void *user);
  493. typedef BOOL (CALLBACK FILESEEKPROC)(QWORD offset, void *user);
  494. typedef struct {
  495. FILECLOSEPROC *close;
  496. FILELENPROC *length;
  497. FILEREADPROC *read;
  498. FILESEEKPROC *seek;
  499. } BASS_FILEPROCS;
  500. // BASS_StreamPutFileData options
  501. #define BASS_FILEDATA_END 0 // end & close the file
  502. // BASS_StreamGetFilePosition modes
  503. #define BASS_FILEPOS_CURRENT 0
  504. #define BASS_FILEPOS_DECODE BASS_FILEPOS_CURRENT
  505. #define BASS_FILEPOS_DOWNLOAD 1
  506. #define BASS_FILEPOS_END 2
  507. #define BASS_FILEPOS_START 3
  508. #define BASS_FILEPOS_CONNECTED 4
  509. #define BASS_FILEPOS_BUFFER 5
  510. #define BASS_FILEPOS_SOCKET 6
  511. #define BASS_FILEPOS_ASYNCBUF 7
  512. #define BASS_FILEPOS_SIZE 8
  513. #define BASS_FILEPOS_BUFFERING 9
  514. typedef void (CALLBACK DOWNLOADPROC)(const void *buffer, DWORD length, void *user);
  515. /* Internet stream download callback function.
  516. buffer : Buffer containing the downloaded data... NULL=end of download
  517. length : Number of bytes in the buffer
  518. user : The 'user' parameter value given when calling BASS_StreamCreateURL */
  519. // BASS_ChannelSetSync types
  520. #define BASS_SYNC_POS 0
  521. #define BASS_SYNC_END 2
  522. #define BASS_SYNC_META 4
  523. #define BASS_SYNC_SLIDE 5
  524. #define BASS_SYNC_STALL 6
  525. #define BASS_SYNC_DOWNLOAD 7
  526. #define BASS_SYNC_FREE 8
  527. #define BASS_SYNC_SETPOS 11
  528. #define BASS_SYNC_MUSICPOS 10
  529. #define BASS_SYNC_MUSICINST 1
  530. #define BASS_SYNC_MUSICFX 3
  531. #define BASS_SYNC_OGG_CHANGE 12
  532. #define BASS_SYNC_DEV_FAIL 14
  533. #define BASS_SYNC_DEV_FORMAT 15
  534. #define BASS_SYNC_THREAD 0x20000000 // flag: call sync in other thread
  535. #define BASS_SYNC_MIXTIME 0x40000000 // flag: sync at mixtime, else at playtime
  536. #define BASS_SYNC_ONETIME 0x80000000 // flag: sync only once, else continuously
  537. typedef void (CALLBACK SYNCPROC)(HSYNC handle, DWORD channel, DWORD data, void *user);
  538. /* Sync callback function.
  539. handle : The sync that has occured
  540. channel: Channel that the sync occured in
  541. data : Additional data associated with the sync's occurance
  542. user : The 'user' parameter given when calling BASS_ChannelSetSync */
  543. typedef void (CALLBACK DSPPROC)(HDSP handle, DWORD channel, void *buffer, DWORD length, void *user);
  544. /* DSP callback function.
  545. handle : The DSP handle
  546. channel: Channel that the DSP is being applied to
  547. buffer : Buffer to apply the DSP to
  548. length : Number of bytes in the buffer
  549. user : The 'user' parameter given when calling BASS_ChannelSetDSP */
  550. typedef BOOL (CALLBACK RECORDPROC)(HRECORD handle, const void *buffer, DWORD length, void *user);
  551. /* Recording callback function.
  552. handle : The recording handle
  553. buffer : Buffer containing the recorded sample data
  554. length : Number of bytes
  555. user : The 'user' parameter value given when calling BASS_RecordStart
  556. RETURN : TRUE = continue recording, FALSE = stop */
  557. // BASS_ChannelIsActive return values
  558. #define BASS_ACTIVE_STOPPED 0
  559. #define BASS_ACTIVE_PLAYING 1
  560. #define BASS_ACTIVE_STALLED 2
  561. #define BASS_ACTIVE_PAUSED 3
  562. #define BASS_ACTIVE_PAUSED_DEVICE 4
  563. // Channel attributes
  564. #define BASS_ATTRIB_FREQ 1
  565. #define BASS_ATTRIB_VOL 2
  566. #define BASS_ATTRIB_PAN 3
  567. #define BASS_ATTRIB_EAXMIX 4
  568. #define BASS_ATTRIB_NOBUFFER 5
  569. #define BASS_ATTRIB_VBR 6
  570. #define BASS_ATTRIB_CPU 7
  571. #define BASS_ATTRIB_SRC 8
  572. #define BASS_ATTRIB_NET_RESUME 9
  573. #define BASS_ATTRIB_SCANINFO 10
  574. #define BASS_ATTRIB_NORAMP 11
  575. #define BASS_ATTRIB_BITRATE 12
  576. #define BASS_ATTRIB_BUFFER 13
  577. #define BASS_ATTRIB_GRANULE 14
  578. #define BASS_ATTRIB_MUSIC_AMPLIFY 0x100
  579. #define BASS_ATTRIB_MUSIC_PANSEP 0x101
  580. #define BASS_ATTRIB_MUSIC_PSCALER 0x102
  581. #define BASS_ATTRIB_MUSIC_BPM 0x103
  582. #define BASS_ATTRIB_MUSIC_SPEED 0x104
  583. #define BASS_ATTRIB_MUSIC_VOL_GLOBAL 0x105
  584. #define BASS_ATTRIB_MUSIC_ACTIVE 0x106
  585. #define BASS_ATTRIB_MUSIC_VOL_CHAN 0x200 // + channel #
  586. #define BASS_ATTRIB_MUSIC_VOL_INST 0x300 // + instrument #
  587. // BASS_ChannelSlideAttribute flags
  588. #define BASS_SLIDE_LOG 0x1000000
  589. // BASS_ChannelGetData flags
  590. #define BASS_DATA_AVAILABLE 0 // query how much data is buffered
  591. #define BASS_DATA_FIXED 0x20000000 // flag: return 8.24 fixed-point data
  592. #define BASS_DATA_FLOAT 0x40000000 // flag: return floating-point sample data
  593. #define BASS_DATA_FFT256 0x80000000 // 256 sample FFT
  594. #define BASS_DATA_FFT512 0x80000001 // 512 FFT
  595. #define BASS_DATA_FFT1024 0x80000002 // 1024 FFT
  596. #define BASS_DATA_FFT2048 0x80000003 // 2048 FFT
  597. #define BASS_DATA_FFT4096 0x80000004 // 4096 FFT
  598. #define BASS_DATA_FFT8192 0x80000005 // 8192 FFT
  599. #define BASS_DATA_FFT16384 0x80000006 // 16384 FFT
  600. #define BASS_DATA_FFT32768 0x80000007 // 32768 FFT
  601. #define BASS_DATA_FFT_INDIVIDUAL 0x10 // FFT flag: FFT for each channel, else all combined
  602. #define BASS_DATA_FFT_NOWINDOW 0x20 // FFT flag: no Hanning window
  603. #define BASS_DATA_FFT_REMOVEDC 0x40 // FFT flag: pre-remove DC bias
  604. #define BASS_DATA_FFT_COMPLEX 0x80 // FFT flag: return complex data
  605. #define BASS_DATA_FFT_NYQUIST 0x100 // FFT flag: return extra Nyquist value
  606. // BASS_ChannelGetLevelEx flags
  607. #define BASS_LEVEL_MONO 1
  608. #define BASS_LEVEL_STEREO 2
  609. #define BASS_LEVEL_RMS 4
  610. #define BASS_LEVEL_VOLPAN 8
  611. // BASS_ChannelGetTags types : what's returned
  612. #define BASS_TAG_ID3 0 // ID3v1 tags : TAG_ID3 structure
  613. #define BASS_TAG_ID3V2 1 // ID3v2 tags : variable length block
  614. #define BASS_TAG_OGG 2 // OGG comments : series of null-terminated UTF-8 strings
  615. #define BASS_TAG_HTTP 3 // HTTP headers : series of null-terminated ANSI strings
  616. #define BASS_TAG_ICY 4 // ICY headers : series of null-terminated ANSI strings
  617. #define BASS_TAG_META 5 // ICY metadata : ANSI string
  618. #define BASS_TAG_APE 6 // APE tags : series of null-terminated UTF-8 strings
  619. #define BASS_TAG_MP4 7 // MP4/iTunes metadata : series of null-terminated UTF-8 strings
  620. #define BASS_TAG_WMA 8 // WMA tags : series of null-terminated UTF-8 strings
  621. #define BASS_TAG_VENDOR 9 // OGG encoder : UTF-8 string
  622. #define BASS_TAG_LYRICS3 10 // Lyric3v2 tag : ASCII string
  623. #define BASS_TAG_CA_CODEC 11 // CoreAudio codec info : TAG_CA_CODEC structure
  624. #define BASS_TAG_MF 13 // Media Foundation tags : series of null-terminated UTF-8 strings
  625. #define BASS_TAG_WAVEFORMAT 14 // WAVE format : WAVEFORMATEEX structure
  626. #define BASS_TAG_AM_MIME 15 // Android Media MIME type : ASCII string
  627. #define BASS_TAG_AM_NAME 16 // Android Media codec name : ASCII string
  628. #define BASS_TAG_RIFF_INFO 0x100 // RIFF "INFO" tags : series of null-terminated ANSI strings
  629. #define BASS_TAG_RIFF_BEXT 0x101 // RIFF/BWF "bext" tags : TAG_BEXT structure
  630. #define BASS_TAG_RIFF_CART 0x102 // RIFF/BWF "cart" tags : TAG_CART structure
  631. #define BASS_TAG_RIFF_DISP 0x103 // RIFF "DISP" text tag : ANSI string
  632. #define BASS_TAG_RIFF_CUE 0x104 // RIFF "cue " chunk : TAG_CUE structure
  633. #define BASS_TAG_RIFF_SMPL 0x105 // RIFF "smpl" chunk : TAG_SMPL structure
  634. #define BASS_TAG_APE_BINARY 0x1000 // + index #, binary APE tag : TAG_APE_BINARY structure
  635. #define BASS_TAG_MUSIC_NAME 0x10000 // MOD music name : ANSI string
  636. #define BASS_TAG_MUSIC_MESSAGE 0x10001 // MOD message : ANSI string
  637. #define BASS_TAG_MUSIC_ORDERS 0x10002 // MOD order list : BYTE array of pattern numbers
  638. #define BASS_TAG_MUSIC_AUTH 0x10003 // MOD author : UTF-8 string
  639. #define BASS_TAG_MUSIC_INST 0x10100 // + instrument #, MOD instrument name : ANSI string
  640. #define BASS_TAG_MUSIC_SAMPLE 0x10300 // + sample #, MOD sample name : ANSI string
  641. // ID3v1 tag structure
  642. typedef struct {
  643. char id[3];
  644. char title[30];
  645. char artist[30];
  646. char album[30];
  647. char year[4];
  648. char comment[30];
  649. BYTE genre;
  650. } TAG_ID3;
  651. // Binary APE tag structure
  652. typedef struct {
  653. const char *key;
  654. const void *data;
  655. DWORD length;
  656. } TAG_APE_BINARY;
  657. // BWF "bext" tag structure
  658. #ifdef _MSC_VER
  659. #pragma warning(push)
  660. #pragma warning(disable:4200)
  661. #endif
  662. #pragma pack(push,1)
  663. typedef struct {
  664. char Description[256]; // description
  665. char Originator[32]; // name of the originator
  666. char OriginatorReference[32]; // reference of the originator
  667. char OriginationDate[10]; // date of creation (yyyy-mm-dd)
  668. char OriginationTime[8]; // time of creation (hh-mm-ss)
  669. QWORD TimeReference; // first sample count since midnight (little-endian)
  670. WORD Version; // BWF version (little-endian)
  671. BYTE UMID[64]; // SMPTE UMID
  672. BYTE Reserved[190];
  673. #if defined(__GNUC__) && __GNUC__<3
  674. char CodingHistory[0]; // history
  675. #elif 1 // change to 0 if compiler fails the following line
  676. char CodingHistory[]; // history
  677. #else
  678. char CodingHistory[1]; // history
  679. #endif
  680. } TAG_BEXT;
  681. #pragma pack(pop)
  682. // BWF "cart" tag structures
  683. typedef struct
  684. {
  685. DWORD dwUsage; // FOURCC timer usage ID
  686. DWORD dwValue; // timer value in samples from head
  687. } TAG_CART_TIMER;
  688. typedef struct
  689. {
  690. char Version[4]; // version of the data structure
  691. char Title[64]; // title of cart audio sequence
  692. char Artist[64]; // artist or creator name
  693. char CutID[64]; // cut number identification
  694. char ClientID[64]; // client identification
  695. char Category[64]; // category ID, PSA, NEWS, etc
  696. char Classification[64]; // classification or auxiliary key
  697. char OutCue[64]; // out cue text
  698. char StartDate[10]; // yyyy-mm-dd
  699. char StartTime[8]; // hh:mm:ss
  700. char EndDate[10]; // yyyy-mm-dd
  701. char EndTime[8]; // hh:mm:ss
  702. char ProducerAppID[64]; // name of vendor or application
  703. char ProducerAppVersion[64]; // version of producer application
  704. char UserDef[64]; // user defined text
  705. DWORD dwLevelReference; // sample value for 0 dB reference
  706. TAG_CART_TIMER PostTimer[8]; // 8 time markers after head
  707. char Reserved[276];
  708. char URL[1024]; // uniform resource locator
  709. #if defined(__GNUC__) && __GNUC__<3
  710. char TagText[0]; // free form text for scripts or tags
  711. #elif 1 // change to 0 if compiler fails the following line
  712. char TagText[]; // free form text for scripts or tags
  713. #else
  714. char TagText[1]; // free form text for scripts or tags
  715. #endif
  716. } TAG_CART;
  717. // RIFF "cue " tag structures
  718. typedef struct
  719. {
  720. DWORD dwName;
  721. DWORD dwPosition;
  722. DWORD fccChunk;
  723. DWORD dwChunkStart;
  724. DWORD dwBlockStart;
  725. DWORD dwSampleOffset;
  726. } TAG_CUE_POINT;
  727. typedef struct
  728. {
  729. DWORD dwCuePoints;
  730. #if defined(__GNUC__) && __GNUC__<3
  731. TAG_CUE_POINT CuePoints[0];
  732. #elif 1 // change to 0 if compiler fails the following line
  733. TAG_CUE_POINT CuePoints[];
  734. #else
  735. TAG_CUE_POINT CuePoints[1];
  736. #endif
  737. } TAG_CUE;
  738. // RIFF "smpl" tag structures
  739. typedef struct
  740. {
  741. DWORD dwIdentifier;
  742. DWORD dwType;
  743. DWORD dwStart;
  744. DWORD dwEnd;
  745. DWORD dwFraction;
  746. DWORD dwPlayCount;
  747. } TAG_SMPL_LOOP;
  748. typedef struct
  749. {
  750. DWORD dwManufacturer;
  751. DWORD dwProduct;
  752. DWORD dwSamplePeriod;
  753. DWORD dwMIDIUnityNote;
  754. DWORD dwMIDIPitchFraction;
  755. DWORD dwSMPTEFormat;
  756. DWORD dwSMPTEOffset;
  757. DWORD cSampleLoops;
  758. DWORD cbSamplerData;
  759. #if defined(__GNUC__) && __GNUC__<3
  760. TAG_SMPL_LOOP SampleLoops[0];
  761. #elif 1 // change to 0 if compiler fails the following line
  762. TAG_SMPL_LOOP SampleLoops[];
  763. #else
  764. TAG_SMPL_LOOP SampleLoops[1];
  765. #endif
  766. } TAG_SMPL;
  767. #ifdef _MSC_VER
  768. #pragma warning(pop)
  769. #endif
  770. // CoreAudio codec info structure
  771. typedef struct {
  772. DWORD ftype; // file format
  773. DWORD atype; // audio format
  774. const char *name; // description
  775. } TAG_CA_CODEC;
  776. #ifndef _WAVEFORMATEX_
  777. #define _WAVEFORMATEX_
  778. #pragma pack(push,1)
  779. typedef struct tWAVEFORMATEX
  780. {
  781. WORD wFormatTag;
  782. WORD nChannels;
  783. DWORD nSamplesPerSec;
  784. DWORD nAvgBytesPerSec;
  785. WORD nBlockAlign;
  786. WORD wBitsPerSample;
  787. WORD cbSize;
  788. } WAVEFORMATEX, *PWAVEFORMATEX, *LPWAVEFORMATEX;
  789. typedef const WAVEFORMATEX *LPCWAVEFORMATEX;
  790. #pragma pack(pop)
  791. #endif
  792. // BASS_ChannelGetLength/GetPosition/SetPosition modes
  793. #define BASS_POS_BYTE 0 // byte position
  794. #define BASS_POS_MUSIC_ORDER 1 // order.row position, MAKELONG(order,row)
  795. #define BASS_POS_OGG 3 // OGG bitstream number
  796. #define BASS_POS_RESET 0x2000000 // flag: reset user file buffers
  797. #define BASS_POS_RELATIVE 0x4000000 // flag: seek relative to the current position
  798. #define BASS_POS_INEXACT 0x8000000 // flag: allow seeking to inexact position
  799. #define BASS_POS_DECODE 0x10000000 // flag: get the decoding (not playing) position
  800. #define BASS_POS_DECODETO 0x20000000 // flag: decode to the position instead of seeking
  801. #define BASS_POS_SCAN 0x40000000 // flag: scan to the position
  802. // BASS_ChannelSetDevice/GetDevice option
  803. #define BASS_NODEVICE 0x20000
  804. // BASS_RecordSetInput flags
  805. #define BASS_INPUT_OFF 0x10000
  806. #define BASS_INPUT_ON 0x20000
  807. #define BASS_INPUT_TYPE_MASK 0xff000000
  808. #define BASS_INPUT_TYPE_UNDEF 0x00000000
  809. #define BASS_INPUT_TYPE_DIGITAL 0x01000000
  810. #define BASS_INPUT_TYPE_LINE 0x02000000
  811. #define BASS_INPUT_TYPE_MIC 0x03000000
  812. #define BASS_INPUT_TYPE_SYNTH 0x04000000
  813. #define BASS_INPUT_TYPE_CD 0x05000000
  814. #define BASS_INPUT_TYPE_PHONE 0x06000000
  815. #define BASS_INPUT_TYPE_SPEAKER 0x07000000
  816. #define BASS_INPUT_TYPE_WAVE 0x08000000
  817. #define BASS_INPUT_TYPE_AUX 0x09000000
  818. #define BASS_INPUT_TYPE_ANALOG 0x0a000000
  819. // BASS_ChannelSetFX effect types
  820. #define BASS_FX_DX8_CHORUS 0
  821. #define BASS_FX_DX8_COMPRESSOR 1
  822. #define BASS_FX_DX8_DISTORTION 2
  823. #define BASS_FX_DX8_ECHO 3
  824. #define BASS_FX_DX8_FLANGER 4
  825. #define BASS_FX_DX8_GARGLE 5
  826. #define BASS_FX_DX8_I3DL2REVERB 6
  827. #define BASS_FX_DX8_PARAMEQ 7
  828. #define BASS_FX_DX8_REVERB 8
  829. #define BASS_FX_VOLUME 9
  830. typedef struct {
  831. float fWetDryMix;
  832. float fDepth;
  833. float fFeedback;
  834. float fFrequency;
  835. DWORD lWaveform; // 0=triangle, 1=sine
  836. float fDelay;
  837. DWORD lPhase; // BASS_DX8_PHASE_xxx
  838. } BASS_DX8_CHORUS;
  839. typedef struct {
  840. float fGain;
  841. float fAttack;
  842. float fRelease;
  843. float fThreshold;
  844. float fRatio;
  845. float fPredelay;
  846. } BASS_DX8_COMPRESSOR;
  847. typedef struct {
  848. float fGain;
  849. float fEdge;
  850. float fPostEQCenterFrequency;
  851. float fPostEQBandwidth;
  852. float fPreLowpassCutoff;
  853. } BASS_DX8_DISTORTION;
  854. typedef struct {
  855. float fWetDryMix;
  856. float fFeedback;
  857. float fLeftDelay;
  858. float fRightDelay;
  859. BOOL lPanDelay;
  860. } BASS_DX8_ECHO;
  861. typedef struct {
  862. float fWetDryMix;
  863. float fDepth;
  864. float fFeedback;
  865. float fFrequency;
  866. DWORD lWaveform; // 0=triangle, 1=sine
  867. float fDelay;
  868. DWORD lPhase; // BASS_DX8_PHASE_xxx
  869. } BASS_DX8_FLANGER;
  870. typedef struct {
  871. DWORD dwRateHz; // Rate of modulation in hz
  872. DWORD dwWaveShape; // 0=triangle, 1=square
  873. } BASS_DX8_GARGLE;
  874. typedef struct {
  875. int lRoom; // [-10000, 0] default: -1000 mB
  876. int lRoomHF; // [-10000, 0] default: 0 mB
  877. float flRoomRolloffFactor; // [0.0, 10.0] default: 0.0
  878. float flDecayTime; // [0.1, 20.0] default: 1.49s
  879. float flDecayHFRatio; // [0.1, 2.0] default: 0.83
  880. int lReflections; // [-10000, 1000] default: -2602 mB
  881. float flReflectionsDelay; // [0.0, 0.3] default: 0.007 s
  882. int lReverb; // [-10000, 2000] default: 200 mB
  883. float flReverbDelay; // [0.0, 0.1] default: 0.011 s
  884. float flDiffusion; // [0.0, 100.0] default: 100.0 %
  885. float flDensity; // [0.0, 100.0] default: 100.0 %
  886. float flHFReference; // [20.0, 20000.0] default: 5000.0 Hz
  887. } BASS_DX8_I3DL2REVERB;
  888. typedef struct {
  889. float fCenter;
  890. float fBandwidth;
  891. float fGain;
  892. } BASS_DX8_PARAMEQ;
  893. typedef struct {
  894. float fInGain; // [-96.0,0.0] default: 0.0 dB
  895. float fReverbMix; // [-96.0,0.0] default: 0.0 db
  896. float fReverbTime; // [0.001,3000.0] default: 1000.0 ms
  897. float fHighFreqRTRatio; // [0.001,0.999] default: 0.001
  898. } BASS_DX8_REVERB;
  899. #define BASS_DX8_PHASE_NEG_180 0
  900. #define BASS_DX8_PHASE_NEG_90 1
  901. #define BASS_DX8_PHASE_ZERO 2
  902. #define BASS_DX8_PHASE_90 3
  903. #define BASS_DX8_PHASE_180 4
  904. typedef struct {
  905. float fTarget;
  906. float fCurrent;
  907. float fTime;
  908. DWORD lCurve;
  909. } BASS_FX_VOLUME_PARAM;
  910. typedef void (CALLBACK IOSNOTIFYPROC)(DWORD status);
  911. /* iOS notification callback function.
  912. status : The notification (BASS_IOSNOTIFY_xxx) */
  913. #define BASS_IOSNOTIFY_INTERRUPT 1 // interruption started
  914. #define BASS_IOSNOTIFY_INTERRUPT_END 2 // interruption ended
  915. BOOL BASSDEF(BASS_SetConfig)(DWORD option, DWORD value);
  916. DWORD BASSDEF(BASS_GetConfig)(DWORD option);
  917. BOOL BASSDEF(BASS_SetConfigPtr)(DWORD option, const void *value);
  918. void *BASSDEF(BASS_GetConfigPtr)(DWORD option);
  919. DWORD BASSDEF(BASS_GetVersion)();
  920. int BASSDEF(BASS_ErrorGetCode)();
  921. BOOL BASSDEF(BASS_GetDeviceInfo)(DWORD device, BASS_DEVICEINFO *info);
  922. #if defined(_WIN32) && !defined(_WIN32_WCE) && !(WINAPI_FAMILY && WINAPI_FAMILY!=WINAPI_FAMILY_DESKTOP_APP)
  923. BOOL BASSDEF(BASS_Init)(int device, DWORD freq, DWORD flags, HWND win, const GUID *dsguid);
  924. #else
  925. BOOL BASSDEF(BASS_Init)(int device, DWORD freq, DWORD flags, void *win, void *dsguid);
  926. #endif
  927. BOOL BASSDEF(BASS_SetDevice)(DWORD device);
  928. DWORD BASSDEF(BASS_GetDevice)();
  929. BOOL BASSDEF(BASS_Free)();
  930. #if defined(_WIN32) && !defined(_WIN32_WCE) && !(WINAPI_FAMILY && WINAPI_FAMILY!=WINAPI_FAMILY_DESKTOP_APP)
  931. void *BASSDEF(BASS_GetDSoundObject)(DWORD object);
  932. #endif
  933. BOOL BASSDEF(BASS_GetInfo)(BASS_INFO *info);
  934. BOOL BASSDEF(BASS_Update)(DWORD length);
  935. float BASSDEF(BASS_GetCPU)();
  936. BOOL BASSDEF(BASS_Start)();
  937. BOOL BASSDEF(BASS_Stop)();
  938. BOOL BASSDEF(BASS_Pause)();
  939. BOOL BASSDEF(BASS_IsStarted)();
  940. BOOL BASSDEF(BASS_SetVolume)(float volume);
  941. float BASSDEF(BASS_GetVolume)();
  942. HPLUGIN BASSDEF(BASS_PluginLoad)(const char *file, DWORD flags);
  943. BOOL BASSDEF(BASS_PluginFree)(HPLUGIN handle);
  944. const BASS_PLUGININFO *BASSDEF(BASS_PluginGetInfo)(HPLUGIN handle);
  945. BOOL BASSDEF(BASS_Set3DFactors)(float distf, float rollf, float doppf);
  946. BOOL BASSDEF(BASS_Get3DFactors)(float *distf, float *rollf, float *doppf);
  947. BOOL BASSDEF(BASS_Set3DPosition)(const BASS_3DVECTOR *pos, const BASS_3DVECTOR *vel, const BASS_3DVECTOR *front, const BASS_3DVECTOR *top);
  948. BOOL BASSDEF(BASS_Get3DPosition)(BASS_3DVECTOR *pos, BASS_3DVECTOR *vel, BASS_3DVECTOR *front, BASS_3DVECTOR *top);
  949. void BASSDEF(BASS_Apply3D)();
  950. #if defined(_WIN32) && !defined(_WIN32_WCE) && !(WINAPI_FAMILY && WINAPI_FAMILY!=WINAPI_FAMILY_DESKTOP_APP)
  951. BOOL BASSDEF(BASS_SetEAXParameters)(int env, float vol, float decay, float damp);
  952. BOOL BASSDEF(BASS_GetEAXParameters)(DWORD *env, float *vol, float *decay, float *damp);
  953. #endif
  954. HMUSIC BASSDEF(BASS_MusicLoad)(BOOL mem, const void *file, QWORD offset, DWORD length, DWORD flags, DWORD freq);
  955. BOOL BASSDEF(BASS_MusicFree)(HMUSIC handle);
  956. HSAMPLE BASSDEF(BASS_SampleLoad)(BOOL mem, const void *file, QWORD offset, DWORD length, DWORD max, DWORD flags);
  957. HSAMPLE BASSDEF(BASS_SampleCreate)(DWORD length, DWORD freq, DWORD chans, DWORD max, DWORD flags);
  958. BOOL BASSDEF(BASS_SampleFree)(HSAMPLE handle);
  959. BOOL BASSDEF(BASS_SampleSetData)(HSAMPLE handle, const void *buffer);
  960. BOOL BASSDEF(BASS_SampleGetData)(HSAMPLE handle, void *buffer);
  961. BOOL BASSDEF(BASS_SampleGetInfo)(HSAMPLE handle, BASS_SAMPLE *info);
  962. BOOL BASSDEF(BASS_SampleSetInfo)(HSAMPLE handle, const BASS_SAMPLE *info);
  963. HCHANNEL BASSDEF(BASS_SampleGetChannel)(HSAMPLE handle, BOOL onlynew);
  964. DWORD BASSDEF(BASS_SampleGetChannels)(HSAMPLE handle, HCHANNEL *channels);
  965. BOOL BASSDEF(BASS_SampleStop)(HSAMPLE handle);
  966. HSTREAM BASSDEF(BASS_StreamCreate)(DWORD freq, DWORD chans, DWORD flags, STREAMPROC *proc, void *user);
  967. HSTREAM BASSDEF(BASS_StreamCreateFile)(BOOL mem, const void *file, QWORD offset, QWORD length, DWORD flags);
  968. HSTREAM BASSDEF(BASS_StreamCreateURL)(const char *url, DWORD offset, DWORD flags, DOWNLOADPROC *proc, void *user);
  969. HSTREAM BASSDEF(BASS_StreamCreateFileUser)(DWORD system, DWORD flags, const BASS_FILEPROCS *proc, void *user);
  970. BOOL BASSDEF(BASS_StreamFree)(HSTREAM handle);
  971. QWORD BASSDEF(BASS_StreamGetFilePosition)(HSTREAM handle, DWORD mode);
  972. DWORD BASSDEF(BASS_StreamPutData)(HSTREAM handle, const void *buffer, DWORD length);
  973. DWORD BASSDEF(BASS_StreamPutFileData)(HSTREAM handle, const void *buffer, DWORD length);
  974. BOOL BASSDEF(BASS_RecordGetDeviceInfo)(DWORD device, BASS_DEVICEINFO *info);
  975. BOOL BASSDEF(BASS_RecordInit)(int device);
  976. BOOL BASSDEF(BASS_RecordSetDevice)(DWORD device);
  977. DWORD BASSDEF(BASS_RecordGetDevice)();
  978. BOOL BASSDEF(BASS_RecordFree)();
  979. BOOL BASSDEF(BASS_RecordGetInfo)(BASS_RECORDINFO *info);
  980. const char *BASSDEF(BASS_RecordGetInputName)(int input);
  981. BOOL BASSDEF(BASS_RecordSetInput)(int input, DWORD flags, float volume);
  982. DWORD BASSDEF(BASS_RecordGetInput)(int input, float *volume);
  983. HRECORD BASSDEF(BASS_RecordStart)(DWORD freq, DWORD chans, DWORD flags, RECORDPROC *proc, void *user);
  984. double BASSDEF(BASS_ChannelBytes2Seconds)(DWORD handle, QWORD pos);
  985. QWORD BASSDEF(BASS_ChannelSeconds2Bytes)(DWORD handle, double pos);
  986. DWORD BASSDEF(BASS_ChannelGetDevice)(DWORD handle);
  987. BOOL BASSDEF(BASS_ChannelSetDevice)(DWORD handle, DWORD device);
  988. DWORD BASSDEF(BASS_ChannelIsActive)(DWORD handle);
  989. BOOL BASSDEF(BASS_ChannelGetInfo)(DWORD handle, BASS_CHANNELINFO *info);
  990. const char *BASSDEF(BASS_ChannelGetTags)(DWORD handle, DWORD tags);
  991. DWORD BASSDEF(BASS_ChannelFlags)(DWORD handle, DWORD flags, DWORD mask);
  992. BOOL BASSDEF(BASS_ChannelUpdate)(DWORD handle, DWORD length);
  993. BOOL BASSDEF(BASS_ChannelLock)(DWORD handle, BOOL lock);
  994. BOOL BASSDEF(BASS_ChannelPlay)(DWORD handle, BOOL restart);
  995. BOOL BASSDEF(BASS_ChannelStop)(DWORD handle);
  996. BOOL BASSDEF(BASS_ChannelPause)(DWORD handle);
  997. BOOL BASSDEF(BASS_ChannelSetAttribute)(DWORD handle, DWORD attrib, float value);
  998. BOOL BASSDEF(BASS_ChannelGetAttribute)(DWORD handle, DWORD attrib, float *value);
  999. BOOL BASSDEF(BASS_ChannelSlideAttribute)(DWORD handle, DWORD attrib, float value, DWORD time);
  1000. BOOL BASSDEF(BASS_ChannelIsSliding)(DWORD handle, DWORD attrib);
  1001. BOOL BASSDEF(BASS_ChannelSetAttributeEx)(DWORD handle, DWORD attrib, void *value, DWORD size);
  1002. DWORD BASSDEF(BASS_ChannelGetAttributeEx)(DWORD handle, DWORD attrib, void *value, DWORD size);
  1003. BOOL BASSDEF(BASS_ChannelSet3DAttributes)(DWORD handle, int mode, float min, float max, int iangle, int oangle, float outvol);
  1004. BOOL BASSDEF(BASS_ChannelGet3DAttributes)(DWORD handle, DWORD *mode, float *min, float *max, DWORD *iangle, DWORD *oangle, float *outvol);
  1005. BOOL BASSDEF(BASS_ChannelSet3DPosition)(DWORD handle, const BASS_3DVECTOR *pos, const BASS_3DVECTOR *orient, const BASS_3DVECTOR *vel);
  1006. BOOL BASSDEF(BASS_ChannelGet3DPosition)(DWORD handle, BASS_3DVECTOR *pos, BASS_3DVECTOR *orient, BASS_3DVECTOR *vel);
  1007. QWORD BASSDEF(BASS_ChannelGetLength)(DWORD handle, DWORD mode);
  1008. BOOL BASSDEF(BASS_ChannelSetPosition)(DWORD handle, QWORD pos, DWORD mode);
  1009. QWORD BASSDEF(BASS_ChannelGetPosition)(DWORD handle, DWORD mode);
  1010. DWORD BASSDEF(BASS_ChannelGetLevel)(DWORD handle);
  1011. BOOL BASSDEF(BASS_ChannelGetLevelEx)(DWORD handle, float *levels, float length, DWORD flags);
  1012. DWORD BASSDEF(BASS_ChannelGetData)(DWORD handle, void *buffer, DWORD length);
  1013. HSYNC BASSDEF(BASS_ChannelSetSync)(DWORD handle, DWORD type, QWORD param, SYNCPROC *proc, void *user);
  1014. BOOL BASSDEF(BASS_ChannelRemoveSync)(DWORD handle, HSYNC sync);
  1015. HDSP BASSDEF(BASS_ChannelSetDSP)(DWORD handle, DSPPROC *proc, void *user, int priority);
  1016. BOOL BASSDEF(BASS_ChannelRemoveDSP)(DWORD handle, HDSP dsp);
  1017. BOOL BASSDEF(BASS_ChannelSetLink)(DWORD handle, DWORD chan);
  1018. BOOL BASSDEF(BASS_ChannelRemoveLink)(DWORD handle, DWORD chan);
  1019. HFX BASSDEF(BASS_ChannelSetFX)(DWORD handle, DWORD type, int priority);
  1020. BOOL BASSDEF(BASS_ChannelRemoveFX)(DWORD handle, HFX fx);
  1021. BOOL BASSDEF(BASS_FXSetParameters)(HFX handle, const void *params);
  1022. BOOL BASSDEF(BASS_FXGetParameters)(HFX handle, void *params);
  1023. BOOL BASSDEF(BASS_FXReset)(HFX handle);
  1024. BOOL BASSDEF(BASS_FXSetPriority)(HFX handle, int priority);
  1025. #ifdef __cplusplus
  1026. }
  1027. #if defined(_WIN32) && !defined(NOBASSOVERLOADS)
  1028. static inline HPLUGIN BASS_PluginLoad(const WCHAR *file, DWORD flags)
  1029. {
  1030. return BASS_PluginLoad((const char*)file, flags|BASS_UNICODE);
  1031. }
  1032. static inline HMUSIC BASS_MusicLoad(BOOL mem, const WCHAR *file, QWORD offset, DWORD length, DWORD flags, DWORD freq)
  1033. {
  1034. return BASS_MusicLoad(mem, (const void*)file, offset, length, flags|BASS_UNICODE, freq);
  1035. }
  1036. static inline HSAMPLE BASS_SampleLoad(BOOL mem, const WCHAR *file, QWORD offset, DWORD length, DWORD max, DWORD flags)
  1037. {
  1038. return BASS_SampleLoad(mem, (const void*)file, offset, length, max, flags|BASS_UNICODE);
  1039. }
  1040. static inline HSTREAM BASS_StreamCreateFile(BOOL mem, const WCHAR *file, QWORD offset, QWORD length, DWORD flags)
  1041. {
  1042. return BASS_StreamCreateFile(mem, (const void*)file, offset, length, flags|BASS_UNICODE);
  1043. }
  1044. static inline HSTREAM BASS_StreamCreateURL(const WCHAR *url, DWORD offset, DWORD flags, DOWNLOADPROC *proc, void *user)
  1045. {
  1046. return BASS_StreamCreateURL((const char*)url, offset, flags|BASS_UNICODE, proc, user);
  1047. }
  1048. static inline BOOL BASS_SetConfigPtr(DWORD option, const WCHAR *value)
  1049. {
  1050. return BASS_SetConfigPtr(option|BASS_UNICODE, (const void*)value);
  1051. }
  1052. #endif
  1053. #endif
  1054. #endif