Subversion Repositories pentevo

Rev

Rev 796 | Blame | Compare with Previous | Last modification | View Log | Download | RSS feed | ?url?

  1. /*
  2.         BASS 2.4 C/C++ header file
  3.         Copyright (c) 1999-2008 Un4seen Developments Ltd.
  4.  
  5.         See the BASS.CHM file for more detailed documentation
  6. */
  7.  
  8. #ifndef BASS_H
  9. #define BASS_H
  10.  
  11. #ifdef _WIN32 // Windows
  12. #include <wtypes.h>
  13. typedef unsigned __int64 QWORD;
  14. #else // OSX
  15. #include <stdint.h>
  16. #define WINAPI
  17. #define CALLBACK
  18. typedef uint8_t BYTE;
  19. typedef uint16_t WORD;
  20. typedef uint32_t DWORD;
  21. typedef uint64_t QWORD;
  22. #ifndef __OBJC__
  23. typedef int BOOL;
  24. #endif
  25. #define TRUE 1
  26. #define FALSE 0
  27. #define LOBYTE(a) (BYTE)(a)
  28. #define HIBYTE(a) (BYTE)((a)>>8)
  29. #define LOWORD(a) (WORD)(a)
  30. #define HIWORD(a) (WORD)((a)>>16)
  31. #define MAKEWORD(a,b) (WORD)(((a)&0xff)|((b)<<8))
  32. #define MAKELONG(a,b) (DWORD)(((a)&0xffff)|((b)<<16))
  33. #endif
  34.  
  35. #ifdef __cplusplus
  36. extern "C" {
  37. #endif
  38.  
  39. #define BASSVERSION 0x204       // API version
  40. #define BASSVERSIONTEXT "2.4"
  41.  
  42. #ifndef BASSDEF
  43. #define BASSDEF(f) WINAPI f
  44. #endif
  45.  
  46. typedef DWORD HMUSIC;           // MOD music handle
  47. typedef DWORD HSAMPLE;          // sample handle
  48. typedef DWORD HCHANNEL;         // playing sample's channel handle
  49. typedef DWORD HSTREAM;          // sample stream handle
  50. typedef DWORD HRECORD;          // recording handle
  51. typedef DWORD HSYNC;            // synchronizer handle
  52. typedef DWORD HDSP;                     // DSP handle
  53. typedef DWORD HFX;                      // DX8 effect handle
  54. typedef DWORD HPLUGIN;          // Plugin handle
  55.  
  56. // Error codes returned by BASS_ErrorGetCode
  57. #define BASS_OK                         0       // all is OK
  58. #define BASS_ERROR_MEM          1       // memory error
  59. #define BASS_ERROR_FILEOPEN     2       // can't open the file
  60. #define BASS_ERROR_DRIVER       3       // can't find a free/valid driver
  61. #define BASS_ERROR_BUFLOST      4       // the sample buffer was lost
  62. #define BASS_ERROR_HANDLE       5       // invalid handle
  63. #define BASS_ERROR_FORMAT       6       // unsupported sample format
  64. #define BASS_ERROR_POSITION     7       // invalid position
  65. #define BASS_ERROR_INIT         8       // BASS_Init has not been successfully called
  66. #define BASS_ERROR_START        9       // BASS_Start has not been successfully called
  67. #define BASS_ERROR_ALREADY      14      // already initialized/paused/whatever
  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 is not available
  83. #define BASS_ERROR_DECODE       38      // the channel is 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_UNKNOWN      -1      // some other mystery problem
  92.  
  93. // BASS_SetConfig options
  94. #define BASS_CONFIG_BUFFER                      0
  95. #define BASS_CONFIG_UPDATEPERIOD        1
  96. #define BASS_CONFIG_GVOL_SAMPLE         4
  97. #define BASS_CONFIG_GVOL_STREAM         5
  98. #define BASS_CONFIG_GVOL_MUSIC          6
  99. #define BASS_CONFIG_CURVE_VOL           7
  100. #define BASS_CONFIG_CURVE_PAN           8
  101. #define BASS_CONFIG_FLOATDSP            9
  102. #define BASS_CONFIG_3DALGORITHM         10
  103. #define BASS_CONFIG_NET_TIMEOUT         11
  104. #define BASS_CONFIG_NET_BUFFER          12
  105. #define BASS_CONFIG_PAUSE_NOPLAY        13
  106. #define BASS_CONFIG_NET_PREBUF          15
  107. #define BASS_CONFIG_NET_PASSIVE         18
  108. #define BASS_CONFIG_REC_BUFFER          19
  109. #define BASS_CONFIG_NET_PLAYLIST        21
  110. #define BASS_CONFIG_MUSIC_VIRTUAL       22
  111. #define BASS_CONFIG_VERIFY                      23
  112. #define BASS_CONFIG_UPDATETHREADS       24
  113.  
  114. // BASS_SetConfigPtr options
  115. #define BASS_CONFIG_NET_AGENT           16
  116. #define BASS_CONFIG_NET_PROXY           17
  117.  
  118. // Initialization flags
  119. #define BASS_DEVICE_8BITS               1       // use 8 bit resolution, else 16 bit
  120. #define BASS_DEVICE_MONO                2       // use mono, else stereo
  121. #define BASS_DEVICE_3D                  4       // enable 3D functionality
  122. #define BASS_DEVICE_LATENCY             256     // calculate device latency (BASS_INFO struct)
  123. #define BASS_DEVICE_CPSPEAKERS  1024 // detect speakers via Windows control panel
  124. #define BASS_DEVICE_SPEAKERS    2048 // force enabling of speaker assignment
  125. #define BASS_DEVICE_NOSPEAKER   4096 // ignore speaker arrangement
  126.  
  127. // DirectSound interfaces (for use with BASS_GetDSoundObject)
  128. #define BASS_OBJECT_DS          1       // IDirectSound
  129. #define BASS_OBJECT_DS3DL       2       // IDirectSound3DListener
  130.  
  131. // Device info structure
  132. typedef struct {
  133.         const char *name;       // description
  134.         const char *driver;     // driver
  135.         DWORD flags;
  136. } BASS_DEVICEINFO;
  137.  
  138. // BASS_DEVICEINFO flags
  139. #define BASS_DEVICE_ENABLED             1
  140. #define BASS_DEVICE_DEFAULT             2
  141. #define BASS_DEVICE_INIT                4
  142.  
  143. typedef struct {
  144.         DWORD flags;    // device capabilities (DSCAPS_xxx flags)
  145.         DWORD hwsize;   // size of total device hardware memory
  146.         DWORD hwfree;   // size of free device hardware memory
  147.         DWORD freesam;  // number of free sample slots in the hardware
  148.         DWORD free3d;   // number of free 3D sample slots in the hardware
  149.         DWORD minrate;  // min sample rate supported by the hardware
  150.         DWORD maxrate;  // max sample rate supported by the hardware
  151.         BOOL eax;               // device supports EAX? (always FALSE if BASS_DEVICE_3D was not used)
  152.         DWORD minbuf;   // recommended minimum buffer length in ms (requires BASS_DEVICE_LATENCY)
  153.         DWORD dsver;    // DirectSound version
  154.         DWORD latency;  // delay (in ms) before start of playback (requires BASS_DEVICE_LATENCY)
  155.         DWORD initflags;// BASS_Init "flags" parameter
  156.         DWORD speakers; // number of speakers available
  157.         DWORD freq;             // current output rate (Vista/OSX only)
  158. } BASS_INFO;
  159.  
  160. // BASS_INFO flags (from DSOUND.H)
  161. #define DSCAPS_CONTINUOUSRATE   0x00000010      // supports all sample rates between min/maxrate
  162. #define DSCAPS_EMULDRIVER               0x00000020      // device does NOT have hardware DirectSound support
  163. #define DSCAPS_CERTIFIED                0x00000040      // device driver has been certified by Microsoft
  164. #define DSCAPS_SECONDARYMONO    0x00000100      // mono
  165. #define DSCAPS_SECONDARYSTEREO  0x00000200      // stereo
  166. #define DSCAPS_SECONDARY8BIT    0x00000400      // 8 bit
  167. #define DSCAPS_SECONDARY16BIT   0x00000800      // 16 bit
  168.  
  169. // Recording device info structure
  170. typedef struct {
  171.         DWORD flags;    // device capabilities (DSCCAPS_xxx flags)
  172.         DWORD formats;  // supported standard formats (WAVE_FORMAT_xxx flags)
  173.         DWORD inputs;   // number of inputs
  174.         BOOL singlein;  // TRUE = only 1 input can be set at a time
  175.         DWORD freq;             // current input rate (Vista/OSX only)
  176. } BASS_RECORDINFO;
  177.  
  178. // BASS_RECORDINFO flags (from DSOUND.H)
  179. #define DSCCAPS_EMULDRIVER      DSCAPS_EMULDRIVER       // device does NOT have hardware DirectSound recording support
  180. #define DSCCAPS_CERTIFIED       DSCAPS_CERTIFIED        // device driver has been certified by Microsoft
  181.  
  182. // defines for formats field of BASS_RECORDINFO (from MMSYSTEM.H)
  183. #ifndef WAVE_FORMAT_1M08
  184. #define WAVE_FORMAT_1M08       0x00000001       /* 11.025 kHz, Mono,   8-bit  */
  185. #define WAVE_FORMAT_1S08       0x00000002       /* 11.025 kHz, Stereo, 8-bit  */
  186. #define WAVE_FORMAT_1M16       0x00000004       /* 11.025 kHz, Mono,   16-bit */
  187. #define WAVE_FORMAT_1S16       0x00000008       /* 11.025 kHz, Stereo, 16-bit */
  188. #define WAVE_FORMAT_2M08       0x00000010       /* 22.05  kHz, Mono,   8-bit  */
  189. #define WAVE_FORMAT_2S08       0x00000020       /* 22.05  kHz, Stereo, 8-bit  */
  190. #define WAVE_FORMAT_2M16       0x00000040       /* 22.05  kHz, Mono,   16-bit */
  191. #define WAVE_FORMAT_2S16       0x00000080       /* 22.05  kHz, Stereo, 16-bit */
  192. #define WAVE_FORMAT_4M08       0x00000100       /* 44.1   kHz, Mono,   8-bit  */
  193. #define WAVE_FORMAT_4S08       0x00000200       /* 44.1   kHz, Stereo, 8-bit  */
  194. #define WAVE_FORMAT_4M16       0x00000400       /* 44.1   kHz, Mono,   16-bit */
  195. #define WAVE_FORMAT_4S16       0x00000800       /* 44.1   kHz, Stereo, 16-bit */
  196. #endif
  197.  
  198. // Sample info structure
  199. typedef struct {
  200.         DWORD freq;             // default playback rate
  201.         float volume;   // default volume (0-1)
  202.         float pan;              // default pan (-1=left, 0=middle, 1=right)
  203.         DWORD flags;    // BASS_SAMPLE_xxx flags
  204.         DWORD length;   // length (in bytes)
  205.         DWORD max;              // maximum simultaneous playbacks
  206.         DWORD origres;  // original resolution bits
  207.         DWORD chans;    // number of channels
  208.         DWORD mingap;   // minimum gap (ms) between creating channels
  209.         DWORD mode3d;   // BASS_3DMODE_xxx mode
  210.         float mindist;  // minimum distance
  211.         float maxdist;  // maximum distance
  212.         DWORD iangle;   // angle of inside projection cone
  213.         DWORD oangle;   // angle of outside projection cone
  214.         float outvol;   // delta-volume outside the projection cone
  215.         DWORD vam;              // voice allocation/management flags (BASS_VAM_xxx)
  216.         DWORD priority; // priority (0=lowest, 0xffffffff=highest)
  217. } BASS_SAMPLE;
  218.  
  219. #define BASS_SAMPLE_8BITS               1       // 8 bit
  220. #define BASS_SAMPLE_FLOAT               256     // 32-bit floating-point
  221. #define BASS_SAMPLE_MONO                2       // mono
  222. #define BASS_SAMPLE_LOOP                4       // looped
  223. #define BASS_SAMPLE_3D                  8       // 3D functionality
  224. #define BASS_SAMPLE_SOFTWARE    16      // not using hardware mixing
  225. #define BASS_SAMPLE_MUTEMAX             32      // mute at max distance (3D only)
  226. #define BASS_SAMPLE_VAM                 64      // DX7 voice allocation & management
  227. #define BASS_SAMPLE_FX                  128     // old implementation of DX8 effects
  228. #define BASS_SAMPLE_OVER_VOL    0x10000 // override lowest volume
  229. #define BASS_SAMPLE_OVER_POS    0x20000 // override longest playing
  230. #define BASS_SAMPLE_OVER_DIST   0x30000 // override furthest from listener (3D only)
  231.  
  232. #define BASS_STREAM_PRESCAN             0x20000 // enable pin-point seeking/length (MP3/MP2/MP1)
  233. #define BASS_MP3_SETPOS                 BASS_STREAM_PRESCAN
  234. #define BASS_STREAM_AUTOFREE    0x40000 // automatically free the stream when it stop/ends
  235. #define BASS_STREAM_RESTRATE    0x80000 // restrict the download rate of internet file streams
  236. #define BASS_STREAM_BLOCK               0x100000 // download/play internet file stream in small blocks
  237. #define BASS_STREAM_DECODE              0x200000 // don't play the stream, only decode (BASS_ChannelGetData)
  238. #define BASS_STREAM_STATUS              0x800000 // give server status info (HTTP/ICY tags) in DOWNLOADPROC
  239.  
  240. #define BASS_MUSIC_FLOAT                BASS_SAMPLE_FLOAT
  241. #define BASS_MUSIC_MONO                 BASS_SAMPLE_MONO
  242. #define BASS_MUSIC_LOOP                 BASS_SAMPLE_LOOP
  243. #define BASS_MUSIC_3D                   BASS_SAMPLE_3D
  244. #define BASS_MUSIC_FX                   BASS_SAMPLE_FX
  245. #define BASS_MUSIC_AUTOFREE             BASS_STREAM_AUTOFREE
  246. #define BASS_MUSIC_DECODE               BASS_STREAM_DECODE
  247. #define BASS_MUSIC_PRESCAN              BASS_STREAM_PRESCAN     // calculate playback length
  248. #define BASS_MUSIC_CALCLEN              BASS_MUSIC_PRESCAN
  249. #define BASS_MUSIC_RAMP                 0x200   // normal ramping
  250. #define BASS_MUSIC_RAMPS                0x400   // sensitive ramping
  251. #define BASS_MUSIC_SURROUND             0x800   // surround sound
  252. #define BASS_MUSIC_SURROUND2    0x1000  // surround sound (mode 2)
  253. #define BASS_MUSIC_FT2MOD               0x2000  // play .MOD as FastTracker 2 does
  254. #define BASS_MUSIC_PT1MOD               0x4000  // play .MOD as ProTracker 1 does
  255. #define BASS_MUSIC_NONINTER             0x10000 // non-interpolated sample mixing
  256. #define BASS_MUSIC_SINCINTER    0x800000 // sinc interpolated sample mixing
  257. #define BASS_MUSIC_POSRESET             0x8000  // stop all notes when moving position
  258. #define BASS_MUSIC_POSRESETEX   0x400000 // stop all notes and reset bmp/etc when moving position
  259. #define BASS_MUSIC_STOPBACK             0x80000 // stop the music on a backwards jump effect
  260. #define BASS_MUSIC_NOSAMPLE             0x100000 // don't load the samples
  261.  
  262. // Speaker assignment flags
  263. #define BASS_SPEAKER_FRONT      0x1000000       // front speakers
  264. #define BASS_SPEAKER_REAR       0x2000000       // rear/side speakers
  265. #define BASS_SPEAKER_CENLFE     0x3000000       // center & LFE speakers (5.1)
  266. #define BASS_SPEAKER_REAR2      0x4000000       // rear center speakers (7.1)
  267. #define BASS_SPEAKER_N(n)       ((n)<<24)       // n'th pair of speakers (max 15)
  268. #define BASS_SPEAKER_LEFT       0x10000000      // modifier: left
  269. #define BASS_SPEAKER_RIGHT      0x20000000      // modifier: right
  270. #define BASS_SPEAKER_FRONTLEFT  BASS_SPEAKER_FRONT|BASS_SPEAKER_LEFT
  271. #define BASS_SPEAKER_FRONTRIGHT BASS_SPEAKER_FRONT|BASS_SPEAKER_RIGHT
  272. #define BASS_SPEAKER_REARLEFT   BASS_SPEAKER_REAR|BASS_SPEAKER_LEFT
  273. #define BASS_SPEAKER_REARRIGHT  BASS_SPEAKER_REAR|BASS_SPEAKER_RIGHT
  274. #define BASS_SPEAKER_CENTER             BASS_SPEAKER_CENLFE|BASS_SPEAKER_LEFT
  275. #define BASS_SPEAKER_LFE                BASS_SPEAKER_CENLFE|BASS_SPEAKER_RIGHT
  276. #define BASS_SPEAKER_REAR2LEFT  BASS_SPEAKER_REAR2|BASS_SPEAKER_LEFT
  277. #define BASS_SPEAKER_REAR2RIGHT BASS_SPEAKER_REAR2|BASS_SPEAKER_RIGHT
  278.  
  279. #define BASS_UNICODE                    0x80000000
  280.  
  281. #define BASS_RECORD_PAUSE               0x8000  // start recording paused
  282.  
  283. // DX7 voice allocation & management flags
  284. #define BASS_VAM_HARDWARE               1
  285. #define BASS_VAM_SOFTWARE               2
  286. #define BASS_VAM_TERM_TIME              4
  287. #define BASS_VAM_TERM_DIST              8
  288. #define BASS_VAM_TERM_PRIO              16
  289.  
  290. // Channel info structure
  291. typedef struct {
  292.         DWORD freq;             // default playback rate
  293.         DWORD chans;    // channels
  294.         DWORD flags;    // BASS_SAMPLE/STREAM/MUSIC/SPEAKER flags
  295.         DWORD ctype;    // type of channel
  296.         DWORD origres;  // original resolution
  297.         HPLUGIN plugin; // plugin
  298.         HSAMPLE sample; // sample
  299.         const char *filename; // filename
  300. } BASS_CHANNELINFO;
  301.  
  302. // BASS_CHANNELINFO types
  303. #define BASS_CTYPE_SAMPLE               1
  304. #define BASS_CTYPE_RECORD               2
  305. #define BASS_CTYPE_STREAM               0x10000
  306. #define BASS_CTYPE_STREAM_OGG   0x10002
  307. #define BASS_CTYPE_STREAM_MP1   0x10003
  308. #define BASS_CTYPE_STREAM_MP2   0x10004
  309. #define BASS_CTYPE_STREAM_MP3   0x10005
  310. #define BASS_CTYPE_STREAM_AIFF  0x10006
  311. #define BASS_CTYPE_STREAM_WAV   0x40000 // WAVE flag, LOWORD=codec
  312. #define BASS_CTYPE_STREAM_WAV_PCM       0x50001
  313. #define BASS_CTYPE_STREAM_WAV_FLOAT     0x50003
  314. #define BASS_CTYPE_MUSIC_MOD    0x20000
  315. #define BASS_CTYPE_MUSIC_MTM    0x20001
  316. #define BASS_CTYPE_MUSIC_S3M    0x20002
  317. #define BASS_CTYPE_MUSIC_XM             0x20003
  318. #define BASS_CTYPE_MUSIC_IT             0x20004
  319. #define BASS_CTYPE_MUSIC_MO3    0x00100 // MO3 flag
  320.  
  321. typedef struct {
  322.         DWORD ctype;            // channel type
  323.         const char *name;       // format description
  324.         const char *exts;       // file extension filter (*.ext1;*.ext2;etc...)
  325. } BASS_PLUGINFORM;
  326.  
  327. typedef struct {
  328.         DWORD version;                                  // version (same form as BASS_GetVersion)
  329.         DWORD formatc;                                  // number of formats
  330.         const BASS_PLUGINFORM *formats; // the array of formats
  331. } BASS_PLUGININFO;
  332.  
  333. // 3D vector (for 3D positions/velocities/orientations)
  334. typedef struct BASS_3DVECTOR {
  335. #ifdef __cplusplus
  336.         BASS_3DVECTOR() {}
  337.         BASS_3DVECTOR(float _x, float _y, float _z) : x(_x), y(_y), z(_z) {}
  338. #endif
  339.         float x;        // +=right, -=left
  340.         float y;        // +=up, -=down
  341.         float z;        // +=front, -=behind
  342. } BASS_3DVECTOR;
  343.  
  344. // 3D channel modes
  345. #define BASS_3DMODE_NORMAL              0       // normal 3D processing
  346. #define BASS_3DMODE_RELATIVE    1       // position is relative to the listener
  347. #define BASS_3DMODE_OFF                 2       // no 3D processing
  348.  
  349. // software 3D mixing algorithms (used with BASS_CONFIG_3DALGORITHM)
  350. #define BASS_3DALG_DEFAULT      0
  351. #define BASS_3DALG_OFF          1
  352. #define BASS_3DALG_FULL         2
  353. #define BASS_3DALG_LIGHT        3
  354.  
  355. #ifdef _WIN32
  356. // EAX environments, use with BASS_SetEAXParameters
  357. enum
  358. {
  359.     EAX_ENVIRONMENT_GENERIC,
  360.     EAX_ENVIRONMENT_PADDEDCELL,
  361.     EAX_ENVIRONMENT_ROOM,
  362.     EAX_ENVIRONMENT_BATHROOM,
  363.     EAX_ENVIRONMENT_LIVINGROOM,
  364.     EAX_ENVIRONMENT_STONEROOM,
  365.     EAX_ENVIRONMENT_AUDITORIUM,
  366.     EAX_ENVIRONMENT_CONCERTHALL,
  367.     EAX_ENVIRONMENT_CAVE,
  368.     EAX_ENVIRONMENT_ARENA,
  369.     EAX_ENVIRONMENT_HANGAR,
  370.     EAX_ENVIRONMENT_CARPETEDHALLWAY,
  371.     EAX_ENVIRONMENT_HALLWAY,
  372.     EAX_ENVIRONMENT_STONECORRIDOR,
  373.     EAX_ENVIRONMENT_ALLEY,
  374.     EAX_ENVIRONMENT_FOREST,
  375.     EAX_ENVIRONMENT_CITY,
  376.     EAX_ENVIRONMENT_MOUNTAINS,
  377.     EAX_ENVIRONMENT_QUARRY,
  378.     EAX_ENVIRONMENT_PLAIN,
  379.     EAX_ENVIRONMENT_PARKINGLOT,
  380.     EAX_ENVIRONMENT_SEWERPIPE,
  381.     EAX_ENVIRONMENT_UNDERWATER,
  382.     EAX_ENVIRONMENT_DRUGGED,
  383.     EAX_ENVIRONMENT_DIZZY,
  384.     EAX_ENVIRONMENT_PSYCHOTIC,
  385.  
  386.     EAX_ENVIRONMENT_COUNT                       // total number of environments
  387. };
  388.  
  389. // EAX presets, usage: BASS_SetEAXParameters(EAX_PRESET_xxx)
  390. #define EAX_PRESET_GENERIC         EAX_ENVIRONMENT_GENERIC,0.5F,1.493F,0.5F
  391. #define EAX_PRESET_PADDEDCELL      EAX_ENVIRONMENT_PADDEDCELL,0.25F,0.1F,0.0F
  392. #define EAX_PRESET_ROOM            EAX_ENVIRONMENT_ROOM,0.417F,0.4F,0.666F
  393. #define EAX_PRESET_BATHROOM        EAX_ENVIRONMENT_BATHROOM,0.653F,1.499F,0.166F
  394. #define EAX_PRESET_LIVINGROOM      EAX_ENVIRONMENT_LIVINGROOM,0.208F,0.478F,0.0F
  395. #define EAX_PRESET_STONEROOM       EAX_ENVIRONMENT_STONEROOM,0.5F,2.309F,0.888F
  396. #define EAX_PRESET_AUDITORIUM      EAX_ENVIRONMENT_AUDITORIUM,0.403F,4.279F,0.5F
  397. #define EAX_PRESET_CONCERTHALL     EAX_ENVIRONMENT_CONCERTHALL,0.5F,3.961F,0.5F
  398. #define EAX_PRESET_CAVE            EAX_ENVIRONMENT_CAVE,0.5F,2.886F,1.304F
  399. #define EAX_PRESET_ARENA           EAX_ENVIRONMENT_ARENA,0.361F,7.284F,0.332F
  400. #define EAX_PRESET_HANGAR          EAX_ENVIRONMENT_HANGAR,0.5F,10.0F,0.3F
  401. #define EAX_PRESET_CARPETEDHALLWAY EAX_ENVIRONMENT_CARPETEDHALLWAY,0.153F,0.259F,2.0F
  402. #define EAX_PRESET_HALLWAY         EAX_ENVIRONMENT_HALLWAY,0.361F,1.493F,0.0F
  403. #define EAX_PRESET_STONECORRIDOR   EAX_ENVIRONMENT_STONECORRIDOR,0.444F,2.697F,0.638F
  404. #define EAX_PRESET_ALLEY           EAX_ENVIRONMENT_ALLEY,0.25F,1.752F,0.776F
  405. #define EAX_PRESET_FOREST          EAX_ENVIRONMENT_FOREST,0.111F,3.145F,0.472F
  406. #define EAX_PRESET_CITY            EAX_ENVIRONMENT_CITY,0.111F,2.767F,0.224F
  407. #define EAX_PRESET_MOUNTAINS       EAX_ENVIRONMENT_MOUNTAINS,0.194F,7.841F,0.472F
  408. #define EAX_PRESET_QUARRY          EAX_ENVIRONMENT_QUARRY,1.0F,1.499F,0.5F
  409. #define EAX_PRESET_PLAIN           EAX_ENVIRONMENT_PLAIN,0.097F,2.767F,0.224F
  410. #define EAX_PRESET_PARKINGLOT      EAX_ENVIRONMENT_PARKINGLOT,0.208F,1.652F,1.5F
  411. #define EAX_PRESET_SEWERPIPE       EAX_ENVIRONMENT_SEWERPIPE,0.652F,2.886F,0.25F
  412. #define EAX_PRESET_UNDERWATER      EAX_ENVIRONMENT_UNDERWATER,1.0F,1.499F,0.0F
  413. #define EAX_PRESET_DRUGGED         EAX_ENVIRONMENT_DRUGGED,0.875F,8.392F,1.388F
  414. #define EAX_PRESET_DIZZY           EAX_ENVIRONMENT_DIZZY,0.139F,17.234F,0.666F
  415. #define EAX_PRESET_PSYCHOTIC       EAX_ENVIRONMENT_PSYCHOTIC,0.486F,7.563F,0.806F
  416. #endif
  417.  
  418. typedef DWORD (CALLBACK STREAMPROC)(HSTREAM handle, void *buffer, DWORD length, void *user);
  419. /* User stream callback function. NOTE: A stream function should obviously be as quick
  420. as possible, other streams (and MOD musics) can't be mixed until it's finished.
  421. handle : The stream that needs writing
  422. buffer : Buffer to write the samples in
  423. length : Number of bytes to write
  424. user   : The 'user' parameter value given when calling BASS_StreamCreate
  425. RETURN : Number of bytes written. Set the BASS_STREAMPROC_END flag to end
  426.          the stream. */
  427.  
  428. #define BASS_STREAMPROC_END             0x80000000      // end of user stream flag
  429.  
  430. // special STREAMPROCs
  431. #define STREAMPROC_DUMMY                (STREAMPROC*)0          // "dummy" stream
  432. #define STREAMPROC_PUSH                 (STREAMPROC*)-1         // push stream
  433.  
  434. // BASS_StreamCreateFileUser file systems
  435. #define STREAMFILE_NOBUFFER             0
  436. #define STREAMFILE_BUFFER               1
  437. #define STREAMFILE_BUFFERPUSH   2
  438.  
  439. // User file stream callback functions
  440. typedef void (CALLBACK FILECLOSEPROC)(void *user);
  441. typedef QWORD (CALLBACK FILELENPROC)(void *user);
  442. typedef DWORD (CALLBACK FILEREADPROC)(void *buffer, DWORD length, void *user);
  443. typedef BOOL (CALLBACK FILESEEKPROC)(QWORD offset, void *user);
  444.  
  445. typedef struct {
  446.         FILECLOSEPROC *close;
  447.         FILELENPROC *length;
  448.         FILEREADPROC *read;
  449.         FILESEEKPROC *seek;
  450. } BASS_FILEPROCS;
  451.  
  452. // BASS_StreamPutFileData options
  453. #define BASS_FILEDATA_END               0       // end & close the file
  454.  
  455. // BASS_StreamGetFilePosition modes
  456. #define BASS_FILEPOS_CURRENT    0
  457. #define BASS_FILEPOS_DECODE             BASS_FILEPOS_CURRENT
  458. #define BASS_FILEPOS_DOWNLOAD   1
  459. #define BASS_FILEPOS_END                2
  460. #define BASS_FILEPOS_START              3
  461. #define BASS_FILEPOS_CONNECTED  4
  462. #define BASS_FILEPOS_BUFFER             5
  463. #define BASS_FILEPOS_SOCKET             6
  464.  
  465. typedef void (CALLBACK DOWNLOADPROC)(const void *buffer, DWORD length, void *user);
  466. /* Internet stream download callback function.
  467. buffer : Buffer containing the downloaded data... NULL=end of download
  468. length : Number of bytes in the buffer
  469. user   : The 'user' parameter value given when calling BASS_StreamCreateURL */
  470.  
  471. // BASS_ChannelSetSync types
  472. #define BASS_SYNC_POS                   0
  473. #define BASS_SYNC_END                   2
  474. #define BASS_SYNC_META                  4
  475. #define BASS_SYNC_SLIDE                 5
  476. #define BASS_SYNC_STALL                 6
  477. #define BASS_SYNC_DOWNLOAD              7
  478. #define BASS_SYNC_FREE                  8
  479. #define BASS_SYNC_SETPOS                11
  480. #define BASS_SYNC_MUSICPOS              10
  481. #define BASS_SYNC_MUSICINST             1
  482. #define BASS_SYNC_MUSICFX               3
  483. #define BASS_SYNC_OGG_CHANGE    12
  484. #define BASS_SYNC_MIXTIME               0x40000000      // FLAG: sync at mixtime, else at playtime
  485. #define BASS_SYNC_ONETIME               0x80000000      // FLAG: sync only once, else continuously
  486.  
  487. typedef void (CALLBACK SYNCPROC)(HSYNC handle, DWORD channel, DWORD data, void *user);
  488. /* Sync callback function. NOTE: a sync callback function should be very
  489. quick as other syncs can't be processed until it has finished. If the sync
  490. is a "mixtime" sync, then other streams and MOD musics can't be mixed until
  491. it's finished either.
  492. handle : The sync that has occured
  493. channel: Channel that the sync occured in
  494. data   : Additional data associated with the sync's occurance
  495. user   : The 'user' parameter given when calling BASS_ChannelSetSync */
  496.  
  497. typedef void (CALLBACK DSPPROC)(HDSP handle, DWORD channel, void *buffer, DWORD length, void *user);
  498. /* DSP callback function. NOTE: A DSP function should obviously be as quick as
  499. possible... other DSP functions, streams and MOD musics can not be processed
  500. until it's finished.
  501. handle : The DSP handle
  502. channel: Channel that the DSP is being applied to
  503. buffer : Buffer to apply the DSP to
  504. length : Number of bytes in the buffer
  505. user   : The 'user' parameter given when calling BASS_ChannelSetDSP */
  506.  
  507. typedef BOOL (CALLBACK RECORDPROC)(HRECORD handle, const void *buffer, DWORD length, void *user);
  508. /* Recording callback function.
  509. handle : The recording handle
  510. buffer : Buffer containing the recorded sample data
  511. length : Number of bytes
  512. user   : The 'user' parameter value given when calling BASS_RecordStart
  513. RETURN : TRUE = continue recording, FALSE = stop */
  514.  
  515. // BASS_ChannelIsActive return values
  516. #define BASS_ACTIVE_STOPPED     0
  517. #define BASS_ACTIVE_PLAYING     1
  518. #define BASS_ACTIVE_STALLED     2
  519. #define BASS_ACTIVE_PAUSED      3
  520.  
  521. // Channel attributes
  522. #define BASS_ATTRIB_FREQ                        1
  523. #define BASS_ATTRIB_VOL                         2
  524. #define BASS_ATTRIB_PAN                         3
  525. #define BASS_ATTRIB_EAXMIX                      4
  526. #define BASS_ATTRIB_MUSIC_AMPLIFY       0x100
  527. #define BASS_ATTRIB_MUSIC_PANSEP        0x101
  528. #define BASS_ATTRIB_MUSIC_PSCALER       0x102
  529. #define BASS_ATTRIB_MUSIC_BPM           0x103
  530. #define BASS_ATTRIB_MUSIC_SPEED         0x104
  531. #define BASS_ATTRIB_MUSIC_VOL_GLOBAL 0x105
  532. #define BASS_ATTRIB_MUSIC_VOL_CHAN      0x200 // + channel #
  533. #define BASS_ATTRIB_MUSIC_VOL_INST      0x300 // + instrument #
  534.  
  535. // BASS_ChannelGetData flags
  536. #define BASS_DATA_AVAILABLE     0                       // query how much data is buffered
  537. #define BASS_DATA_FLOAT         0x40000000      // flag: return floating-point sample data
  538. #define BASS_DATA_FFT256        0x80000000      // 256 sample FFT
  539. #define BASS_DATA_FFT512        0x80000001      // 512 FFT
  540. #define BASS_DATA_FFT1024       0x80000002      // 1024 FFT
  541. #define BASS_DATA_FFT2048       0x80000003      // 2048 FFT
  542. #define BASS_DATA_FFT4096       0x80000004      // 4096 FFT
  543. #define BASS_DATA_FFT8192       0x80000005      // 8192 FFT
  544. #define BASS_DATA_FFT_INDIVIDUAL 0x10   // FFT flag: FFT for each channel, else all combined
  545. #define BASS_DATA_FFT_NOWINDOW  0x20    // FFT flag: no Hanning window
  546.  
  547. // BASS_ChannelGetTags types : what's returned
  548. #define BASS_TAG_ID3            0       // ID3v1 tags : TAG_ID3 structure
  549. #define BASS_TAG_ID3V2          1       // ID3v2 tags : variable length block
  550. #define BASS_TAG_OGG            2       // OGG comments : series of null-terminated UTF-8 strings
  551. #define BASS_TAG_HTTP           3       // HTTP headers : series of null-terminated ANSI strings
  552. #define BASS_TAG_ICY            4       // ICY headers : series of null-terminated ANSI strings
  553. #define BASS_TAG_META           5       // ICY metadata : ANSI string
  554. #define BASS_TAG_VENDOR         9       // OGG encoder : UTF-8 string
  555. #define BASS_TAG_LYRICS3        10      // Lyric3v2 tag : ASCII string
  556. #define BASS_TAG_RIFF_INFO      0x100 // RIFF "INFO" tags : series of null-terminated ANSI strings
  557. #define BASS_TAG_RIFF_BEXT      0x101 // RIFF/BWF Broadcast Audio Extension tags : TAG_BEXT structure
  558. #define BASS_TAG_MUSIC_NAME             0x10000 // MOD music name : ANSI string
  559. #define BASS_TAG_MUSIC_MESSAGE  0x10001 // MOD message : ANSI string
  560. #define BASS_TAG_MUSIC_INST             0x10100 // + instrument #, MOD instrument name : ANSI string
  561. #define BASS_TAG_MUSIC_SAMPLE   0x10300 // + sample #, MOD sample name : ANSI string
  562.  
  563. // ID3v1 tag structure
  564. typedef struct {
  565.         char id[3];
  566.         char title[30];
  567.         char artist[30];
  568.         char album[30];
  569.         char year[4];
  570.         char comment[30];
  571.         BYTE genre;
  572. } TAG_ID3;
  573.  
  574. // BWF Broadcast Audio Extension tag structure
  575. #pragma pack(push,1)
  576. typedef struct {
  577.         char Description[256];                  // description
  578.         char Originator[32];                    // name of the originator
  579.         char OriginatorReference[32];   // reference of the originator
  580.         char OriginationDate[10];               // date of creation (yyyy-mm-dd)
  581.         char OriginationTime[8];                // time of creation (hh-mm-ss)
  582.         QWORD TimeReference;                    // first sample count since midnight (little-endian)
  583.         WORD Version;                                   // BWF version (little-endian)
  584.         BYTE UMID[64];                                  // SMPTE UMID
  585.         BYTE Reserved[190];
  586. #ifdef __cplusplus
  587. #pragma warning(push)
  588. #pragma warning(disable: 4200)
  589.         char CodingHistory[];                   // history
  590. #pragma warning(pop)
  591. #else
  592.         char CodingHistory[1];                  // history
  593. #endif
  594. } TAG_BEXT;
  595. #pragma pack(pop)
  596.  
  597. // BASS_ChannelGetLength/GetPosition/SetPosition modes
  598. #define BASS_POS_BYTE                   0               // byte position
  599. #define BASS_POS_MUSIC_ORDER    1               // order.row position, MAKELONG(order,row)
  600.  
  601. // BASS_RecordSetInput flags
  602. #define BASS_INPUT_OFF          0x10000
  603. #define BASS_INPUT_ON           0x20000
  604.  
  605. #define BASS_INPUT_TYPE_MASK            0xff000000
  606. #define BASS_INPUT_TYPE_UNDEF           0x00000000
  607. #define BASS_INPUT_TYPE_DIGITAL         0x01000000
  608. #define BASS_INPUT_TYPE_LINE            0x02000000
  609. #define BASS_INPUT_TYPE_MIC                     0x03000000
  610. #define BASS_INPUT_TYPE_SYNTH           0x04000000
  611. #define BASS_INPUT_TYPE_CD                      0x05000000
  612. #define BASS_INPUT_TYPE_PHONE           0x06000000
  613. #define BASS_INPUT_TYPE_SPEAKER         0x07000000
  614. #define BASS_INPUT_TYPE_WAVE            0x08000000
  615. #define BASS_INPUT_TYPE_AUX                     0x09000000
  616. #define BASS_INPUT_TYPE_ANALOG          0x0a000000
  617.  
  618. // DX8 effect types, use with BASS_ChannelSetFX
  619. enum
  620. {
  621.         BASS_FX_DX8_CHORUS,
  622.         BASS_FX_DX8_COMPRESSOR,
  623.         BASS_FX_DX8_DISTORTION,
  624.         BASS_FX_DX8_ECHO,
  625.         BASS_FX_DX8_FLANGER,
  626.         BASS_FX_DX8_GARGLE,
  627.         BASS_FX_DX8_I3DL2REVERB,
  628.         BASS_FX_DX8_PARAMEQ,
  629.         BASS_FX_DX8_REVERB
  630. };
  631.  
  632. typedef struct {
  633.     float       fWetDryMix;
  634.     float       fDepth;
  635.     float       fFeedback;
  636.     float       fFrequency;
  637.     DWORD       lWaveform;      // 0=triangle, 1=sine
  638.     float       fDelay;
  639.     DWORD       lPhase;         // BASS_DX8_PHASE_xxx
  640. } BASS_DX8_CHORUS;
  641.  
  642. typedef struct {
  643.     float   fGain;
  644.     float   fAttack;
  645.     float   fRelease;
  646.     float   fThreshold;
  647.     float   fRatio;
  648.     float   fPredelay;
  649. } BASS_DX8_COMPRESSOR;
  650.  
  651. typedef struct {
  652.     float   fGain;
  653.     float   fEdge;
  654.     float   fPostEQCenterFrequency;
  655.     float   fPostEQBandwidth;
  656.     float   fPreLowpassCutoff;
  657. } BASS_DX8_DISTORTION;
  658.  
  659. typedef struct {
  660.     float   fWetDryMix;
  661.     float   fFeedback;
  662.     float   fLeftDelay;
  663.     float   fRightDelay;
  664.     BOOL    lPanDelay;
  665. } BASS_DX8_ECHO;
  666.  
  667. typedef struct {
  668.     float       fWetDryMix;
  669.     float       fDepth;
  670.     float       fFeedback;
  671.     float       fFrequency;
  672.     DWORD       lWaveform;      // 0=triangle, 1=sine
  673.     float       fDelay;
  674.     DWORD       lPhase;         // BASS_DX8_PHASE_xxx
  675. } BASS_DX8_FLANGER;
  676.  
  677. typedef struct {
  678.     DWORD       dwRateHz;               // Rate of modulation in hz
  679.     DWORD       dwWaveShape;            // 0=triangle, 1=square
  680. } BASS_DX8_GARGLE;
  681.  
  682. typedef struct {
  683.     int     lRoom;                  // [-10000, 0]      default: -1000 mB
  684.     int     lRoomHF;                // [-10000, 0]      default: 0 mB
  685.     float   flRoomRolloffFactor;    // [0.0, 10.0]      default: 0.0
  686.     float   flDecayTime;            // [0.1, 20.0]      default: 1.49s
  687.     float   flDecayHFRatio;         // [0.1, 2.0]       default: 0.83
  688.     int     lReflections;           // [-10000, 1000]   default: -2602 mB
  689.     float   flReflectionsDelay;     // [0.0, 0.3]       default: 0.007 s
  690.     int     lReverb;                // [-10000, 2000]   default: 200 mB
  691.     float   flReverbDelay;          // [0.0, 0.1]       default: 0.011 s
  692.     float   flDiffusion;            // [0.0, 100.0]     default: 100.0 %
  693.     float   flDensity;              // [0.0, 100.0]     default: 100.0 %
  694.     float   flHFReference;          // [20.0, 20000.0]  default: 5000.0 Hz
  695. } BASS_DX8_I3DL2REVERB;
  696.  
  697. typedef struct {
  698.     float   fCenter;
  699.     float   fBandwidth;
  700.     float   fGain;
  701. } BASS_DX8_PARAMEQ;
  702.  
  703. typedef struct {
  704.     float   fInGain;                // [-96.0,0.0]            default: 0.0 dB
  705.     float   fReverbMix;             // [-96.0,0.0]            default: 0.0 db
  706.     float   fReverbTime;            // [0.001,3000.0]         default: 1000.0 ms
  707.     float   fHighFreqRTRatio;       // [0.001,0.999]          default: 0.001
  708. } BASS_DX8_REVERB;
  709.  
  710. #define BASS_DX8_PHASE_NEG_180        0
  711. #define BASS_DX8_PHASE_NEG_90         1
  712. #define BASS_DX8_PHASE_ZERO           2
  713. #define BASS_DX8_PHASE_90             3
  714. #define BASS_DX8_PHASE_180            4
  715.  
  716. BOOL BASSDEF(BASS_SetConfig)(DWORD option, DWORD value);
  717. DWORD BASSDEF(BASS_GetConfig)(DWORD option);
  718. BOOL BASSDEF(BASS_SetConfigPtr)(DWORD option, void *value);
  719. void *BASSDEF(BASS_GetConfigPtr)(DWORD option);
  720. DWORD BASSDEF(BASS_GetVersion)();
  721. int BASSDEF(BASS_ErrorGetCode)();
  722. BOOL BASSDEF(BASS_GetDeviceInfo)(DWORD device, BASS_DEVICEINFO *info);
  723. #ifdef _WIN32
  724. BOOL BASSDEF(BASS_Init)(int device, DWORD freq, DWORD flags, HWND win, const GUID *dsguid);
  725. #else
  726. BOOL BASSDEF(BASS_Init)(int device, DWORD freq, DWORD flags, void *win, void *dsguid);
  727. #endif
  728. BOOL BASSDEF(BASS_SetDevice)(DWORD device);
  729. DWORD BASSDEF(BASS_GetDevice)();
  730. BOOL BASSDEF(BASS_Free)();
  731. #ifdef _WIN32
  732. void *BASSDEF(BASS_GetDSoundObject)(DWORD object);
  733. #endif
  734. BOOL BASSDEF(BASS_GetInfo)(BASS_INFO *info);
  735. BOOL BASSDEF(BASS_Update)(DWORD length);
  736. float BASSDEF(BASS_GetCPU)();
  737. BOOL BASSDEF(BASS_Start)();
  738. BOOL BASSDEF(BASS_Stop)();
  739. BOOL BASSDEF(BASS_Pause)();
  740. BOOL BASSDEF(BASS_SetVolume)(float volume);
  741. float BASSDEF(BASS_GetVolume)();
  742.  
  743. HPLUGIN BASSDEF(BASS_PluginLoad)(const char *file, DWORD flags);
  744. BOOL BASSDEF(BASS_PluginFree)(HPLUGIN handle);
  745. const BASS_PLUGININFO *BASSDEF(BASS_PluginGetInfo)(HPLUGIN handle);
  746.  
  747. BOOL BASSDEF(BASS_Set3DFactors)(float distf, float rollf, float doppf);
  748. BOOL BASSDEF(BASS_Get3DFactors)(float *distf, float *rollf, float *doppf);
  749. BOOL BASSDEF(BASS_Set3DPosition)(const BASS_3DVECTOR *pos, const BASS_3DVECTOR *vel, const BASS_3DVECTOR *front, const BASS_3DVECTOR *top);
  750. BOOL BASSDEF(BASS_Get3DPosition)(BASS_3DVECTOR *pos, BASS_3DVECTOR *vel, BASS_3DVECTOR *front, BASS_3DVECTOR *top);
  751. void BASSDEF(BASS_Apply3D)();
  752. #ifdef _WIN32
  753. BOOL BASSDEF(BASS_SetEAXParameters)(int env, float vol, float decay, float damp);
  754. BOOL BASSDEF(BASS_GetEAXParameters)(DWORD *env, float *vol, float *decay, float *damp);
  755. #endif
  756.  
  757. HMUSIC BASSDEF(BASS_MusicLoad)(BOOL mem, const void *file, QWORD offset, DWORD length, DWORD flags, DWORD freq);
  758. BOOL BASSDEF(BASS_MusicFree)(HMUSIC handle);
  759.  
  760. HSAMPLE BASSDEF(BASS_SampleLoad)(BOOL mem, const void *file, QWORD offset, DWORD length, DWORD max, DWORD flags);
  761. HSAMPLE BASSDEF(BASS_SampleCreate)(DWORD length, DWORD freq, DWORD chans, DWORD max, DWORD flags);
  762. BOOL BASSDEF(BASS_SampleFree)(HSAMPLE handle);
  763. BOOL BASSDEF(BASS_SampleSetData)(HSAMPLE handle, const void *buffer);
  764. BOOL BASSDEF(BASS_SampleGetData)(HSAMPLE handle, void *buffer);
  765. BOOL BASSDEF(BASS_SampleGetInfo)(HSAMPLE handle, BASS_SAMPLE *info);
  766. BOOL BASSDEF(BASS_SampleSetInfo)(HSAMPLE handle, const BASS_SAMPLE *info);
  767. HCHANNEL BASSDEF(BASS_SampleGetChannel)(HSAMPLE handle, BOOL onlynew);
  768. DWORD BASSDEF(BASS_SampleGetChannels)(HSAMPLE handle, HCHANNEL *channels);
  769. BOOL BASSDEF(BASS_SampleStop)(HSAMPLE handle);
  770.  
  771. HSTREAM BASSDEF(BASS_StreamCreate)(DWORD freq, DWORD chans, DWORD flags, STREAMPROC *proc, void *user);
  772. HSTREAM BASSDEF(BASS_StreamCreateFile)(BOOL mem, const void *file, QWORD offset, QWORD length, DWORD flags);
  773. HSTREAM BASSDEF(BASS_StreamCreateURL)(const char *url, DWORD offset, DWORD flags, DOWNLOADPROC *proc, void *user);
  774. HSTREAM BASSDEF(BASS_StreamCreateFileUser)(DWORD system, DWORD flags, const BASS_FILEPROCS *proc, void *user);
  775. BOOL BASSDEF(BASS_StreamFree)(HSTREAM handle);
  776. QWORD BASSDEF(BASS_StreamGetFilePosition)(HSTREAM handle, DWORD mode);
  777. DWORD BASSDEF(BASS_StreamPutData)(HSTREAM handle, const void *buffer, DWORD length);
  778. DWORD BASSDEF(BASS_StreamPutFileData)(HSTREAM handle, const void *buffer, DWORD length);
  779.  
  780. BOOL BASSDEF(BASS_RecordGetDeviceInfo)(DWORD device, BASS_DEVICEINFO *info);
  781. BOOL BASSDEF(BASS_RecordInit)(int device);
  782. BOOL BASSDEF(BASS_RecordSetDevice)(DWORD device);
  783. DWORD BASSDEF(BASS_RecordGetDevice)();
  784. BOOL BASSDEF(BASS_RecordFree)();
  785. BOOL BASSDEF(BASS_RecordGetInfo)(BASS_RECORDINFO *info);
  786. const char *BASSDEF(BASS_RecordGetInputName)(int input);
  787. BOOL BASSDEF(BASS_RecordSetInput)(int input, DWORD flags, float volume);
  788. DWORD BASSDEF(BASS_RecordGetInput)(int input, float *volume);
  789. HRECORD BASSDEF(BASS_RecordStart)(DWORD freq, DWORD chans, DWORD flags, RECORDPROC *proc, void *user);
  790.  
  791. double BASSDEF(BASS_ChannelBytes2Seconds)(DWORD handle, QWORD pos);
  792. QWORD BASSDEF(BASS_ChannelSeconds2Bytes)(DWORD handle, double pos);
  793. DWORD BASSDEF(BASS_ChannelGetDevice)(DWORD handle);
  794. BOOL BASSDEF(BASS_ChannelSetDevice)(DWORD handle, DWORD device);
  795. DWORD BASSDEF(BASS_ChannelIsActive)(DWORD handle);
  796. BOOL BASSDEF(BASS_ChannelGetInfo)(DWORD handle, BASS_CHANNELINFO *info);
  797. const char *BASSDEF(BASS_ChannelGetTags)(DWORD handle, DWORD tags);
  798. DWORD BASSDEF(BASS_ChannelFlags)(DWORD handle, DWORD flags, DWORD mask);
  799. BOOL BASSDEF(BASS_ChannelUpdate)(DWORD handle, DWORD length);
  800. BOOL BASSDEF(BASS_ChannelLock)(DWORD handle, BOOL lock);
  801. BOOL BASSDEF(BASS_ChannelPlay)(DWORD handle, BOOL restart);
  802. BOOL BASSDEF(BASS_ChannelStop)(DWORD handle);
  803. BOOL BASSDEF(BASS_ChannelPause)(DWORD handle);
  804. BOOL BASSDEF(BASS_ChannelSetAttribute)(DWORD handle, DWORD attrib, float value);
  805. BOOL BASSDEF(BASS_ChannelGetAttribute)(DWORD handle, DWORD attrib, float *value);
  806. BOOL BASSDEF(BASS_ChannelSlideAttribute)(DWORD handle, DWORD attrib, float value, DWORD time);
  807. BOOL BASSDEF(BASS_ChannelIsSliding)(DWORD handle, DWORD attrib);
  808. BOOL BASSDEF(BASS_ChannelSet3DAttributes)(DWORD handle, int mode, float min, float max, int iangle, int oangle, float outvol);
  809. BOOL BASSDEF(BASS_ChannelGet3DAttributes)(DWORD handle, DWORD *mode, float *min, float *max, DWORD *iangle, DWORD *oangle, float *outvol);
  810. BOOL BASSDEF(BASS_ChannelSet3DPosition)(DWORD handle, const BASS_3DVECTOR *pos, const BASS_3DVECTOR *orient, const BASS_3DVECTOR *vel);
  811. BOOL BASSDEF(BASS_ChannelGet3DPosition)(DWORD handle, BASS_3DVECTOR *pos, BASS_3DVECTOR *orient, BASS_3DVECTOR *vel);
  812. QWORD BASSDEF(BASS_ChannelGetLength)(DWORD handle, DWORD mode);
  813. BOOL BASSDEF(BASS_ChannelSetPosition)(DWORD handle, QWORD pos, DWORD mode);
  814. QWORD BASSDEF(BASS_ChannelGetPosition)(DWORD handle, DWORD mode);
  815. DWORD BASSDEF(BASS_ChannelGetLevel)(DWORD handle);
  816. DWORD BASSDEF(BASS_ChannelGetData)(DWORD handle, void *buffer, DWORD length);
  817. HSYNC BASSDEF(BASS_ChannelSetSync)(DWORD handle, DWORD type, QWORD param, SYNCPROC *proc, void *user);
  818. BOOL BASSDEF(BASS_ChannelRemoveSync)(DWORD handle, HSYNC sync);
  819. HDSP BASSDEF(BASS_ChannelSetDSP)(DWORD handle, DSPPROC *proc, void *user, int priority);
  820. BOOL BASSDEF(BASS_ChannelRemoveDSP)(DWORD handle, HDSP dsp);
  821. BOOL BASSDEF(BASS_ChannelSetLink)(DWORD handle, DWORD chan);
  822. BOOL BASSDEF(BASS_ChannelRemoveLink)(DWORD handle, DWORD chan);
  823. HFX BASSDEF(BASS_ChannelSetFX)(DWORD handle, DWORD type, int priority);
  824. BOOL BASSDEF(BASS_ChannelRemoveFX)(DWORD handle, HFX fx);
  825.  
  826. BOOL BASSDEF(BASS_FXSetParameters)(HFX handle, const void *params);
  827. BOOL BASSDEF(BASS_FXGetParameters)(HFX handle, void *params);
  828. BOOL BASSDEF(BASS_FXReset)(HFX handle);
  829.  
  830. #ifdef __cplusplus
  831. }
  832. #endif
  833.  
  834. #endif
  835.