seal 0.1.1 → 0.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/README.md +19 -0
- data/include/seal/buf.h +17 -9
- data/include/seal/core.h +14 -8
- data/include/seal/efs.h +8 -8
- data/include/seal/err.h +3 -1
- data/include/seal/fmt.h +4 -2
- data/include/seal/listener.h +32 -9
- data/include/seal/rvb.h +71 -31
- data/include/seal/src.h +65 -37
- data/include/seal/stream.h +12 -5
- data/mpg123/build/config.guess +0 -0
- data/mpg123/build/config.sub +0 -0
- data/mpg123/build/depcomp +0 -0
- data/mpg123/build/install-sh +0 -0
- data/mpg123/build/missing +0 -0
- data/mpg123/configure +0 -0
- data/mpg123/ports/MSVC++/2010/libmpg123/libmpg123.vcxproj +2 -2
- data/mpg123/ports/MSVC++/2010/libmpg123/yasm.exe +0 -0
- data/mpg123/scripts/benchmark-cpu.pl +0 -0
- data/mpg123/src/win32_net.c +0 -0
- data/mpg123/src/win32_support.c +0 -0
- data/mpg123/src/win32_support.h +0 -0
- data/mpg123/windows-builds.sh +0 -0
- data/spec/spec_helper.rb +16 -3
- data/spec/support/movable_object.rb +25 -11
- data/src/rubyext.c +30 -1
- data/src/seal/buf.c +16 -3
- data/src/seal/core.c +16 -7
- data/src/seal/efs.c +37 -11
- data/src/seal/err.c +1 -0
- data/src/seal/listener.c +30 -0
- data/src/seal/mpg.c +6 -2
- data/src/seal/ov.c +9 -2
- data/src/seal/rvb.c +52 -21
- data/src/seal/src.c +75 -6
- data/src/seal/stream.c +4 -0
- data/src/seal/threading.c +8 -2
- data/src/seal/wav.c +6 -2
- metadata +7 -7
data/README.md
CHANGED
@@ -29,10 +29,20 @@ Change the position of the source:
|
|
29
29
|
source.position = 3, 2, -4
|
30
30
|
```
|
31
31
|
|
32
|
+
Or change the position of the source based on velocity:
|
33
|
+
|
34
|
+
```ruby
|
35
|
+
source.velocity = 1, 2, -1
|
36
|
+
source.move # automatically add the velocity vector to the position vector
|
37
|
+
```
|
38
|
+
|
32
39
|
Change the position of the listener (a singleton of Seal::Listener):
|
33
40
|
|
34
41
|
```ruby
|
35
42
|
Seal.listener.position = -1, -1, 0
|
43
|
+
# ...
|
44
|
+
Seal.listener.velocity = 3, 1, -1
|
45
|
+
seal.listener.move
|
36
46
|
```
|
37
47
|
|
38
48
|
Play the source:
|
@@ -69,6 +79,7 @@ Apply a reverberation effect to the sound source:
|
|
69
79
|
|
70
80
|
```ruby
|
71
81
|
# Allocate an effect slot and associate a specific reverb object.
|
82
|
+
# Here we are using a predefined reverb effect. See doc for `Reverb::Preset`.
|
72
83
|
slot = EffectSlot.new(Reverb.new(Reverb::Preset::FOREST))
|
73
84
|
# Start feeding the slot.
|
74
85
|
source.feed(slot, 0)
|
@@ -115,6 +126,10 @@ seal_destroy_rvb(&rvb);
|
|
115
126
|
seal_cleanup();
|
116
127
|
```
|
117
128
|
|
129
|
+
For detailed documentation, refer to:
|
130
|
+
[http://rubydoc.info/gems/seal](http://rubydoc.info/gems/seal)
|
131
|
+
[zhang.su/seal](http://zhang.su/seal)
|
132
|
+
|
118
133
|
## Platforms
|
119
134
|
|
120
135
|
Linux, Windows and Mac OS X are officially tested and supported. Seal should
|
@@ -208,6 +223,10 @@ Use `rake demo:<demo_name>` to run the demos under the `demo/` directory.
|
|
208
223
|
|
209
224
|
3D audio positioning (attenuation).
|
210
225
|
|
226
|
+
- doppler
|
227
|
+
|
228
|
+
Doppler Effect demonstration.
|
229
|
+
|
211
230
|
- reverb
|
212
231
|
|
213
232
|
Audio reverberation. There are lots of built-in reverb presets, but this
|
data/include/seal/buf.h
CHANGED
@@ -35,14 +35,14 @@ extern "C" {
|
|
35
35
|
*
|
36
36
|
* @param buf the buffer to initialize
|
37
37
|
*/
|
38
|
-
seal_err_t seal_init_buf(seal_buf_t*);
|
38
|
+
seal_err_t SEAL_API seal_init_buf(seal_buf_t*);
|
39
39
|
|
40
40
|
/*
|
41
41
|
* Destroys a buffer that is not currently used by any source.
|
42
42
|
*
|
43
43
|
* @param buf the buffer to destroy
|
44
44
|
*/
|
45
|
-
seal_err_t seal_destroy_buf(seal_buf_t*);
|
45
|
+
seal_err_t SEAL_API seal_destroy_buf(seal_buf_t*);
|
46
46
|
|
47
47
|
/*
|
48
48
|
* Loads audio from a file to a buffer that is not currently used by any
|
@@ -54,7 +54,11 @@ seal_err_t seal_destroy_buf(seal_buf_t*);
|
|
54
54
|
* audio format will be attempted if `fmt' is
|
55
55
|
* `SEAL_UNKNOWN_FMT'
|
56
56
|
*/
|
57
|
-
seal_err_t seal_load2buf(
|
57
|
+
seal_err_t SEAL_API seal_load2buf(
|
58
|
+
seal_buf_t*,
|
59
|
+
const char* /*filename*/,
|
60
|
+
seal_fmt_t
|
61
|
+
);
|
58
62
|
|
59
63
|
/*
|
60
64
|
* Copies raw PCM data to a buffer that is not currently used by any source.
|
@@ -63,7 +67,7 @@ seal_err_t seal_load2buf(seal_buf_t*, const char* /*filename*/, seal_fmt_t);
|
|
63
67
|
* @param buf the destination buffer to receive the copied data
|
64
68
|
* @param raw the source raw data to copy
|
65
69
|
*/
|
66
|
-
seal_err_t seal_raw2buf(seal_buf_t*, seal_raw_t*);
|
70
|
+
seal_err_t SEAL_API seal_raw2buf(seal_buf_t*, seal_raw_t*);
|
67
71
|
|
68
72
|
/*
|
69
73
|
* Gets the size, in bytes, of a buffer. The default is 0.
|
@@ -71,7 +75,7 @@ seal_err_t seal_raw2buf(seal_buf_t*, seal_raw_t*);
|
|
71
75
|
* @param buf the buffer to retrive the size of
|
72
76
|
* @param psize the receiver of the size
|
73
77
|
*/
|
74
|
-
seal_err_t seal_get_buf_size(seal_buf_t*, int* /*psize*/);
|
78
|
+
seal_err_t SEAL_API seal_get_buf_size(seal_buf_t*, int* /*psize*/);
|
75
79
|
|
76
80
|
/*
|
77
81
|
* Gets the frequency (sample rate) of the audio contained in a buffer. The
|
@@ -80,7 +84,7 @@ seal_err_t seal_get_buf_size(seal_buf_t*, int* /*psize*/);
|
|
80
84
|
* @param buf the buffer to retrive the frequency of
|
81
85
|
* @param pfreq the receiver of the frequency
|
82
86
|
*/
|
83
|
-
seal_err_t seal_get_buf_freq(seal_buf_t*, int* /*pfreq*/);
|
87
|
+
seal_err_t SEAL_API seal_get_buf_freq(seal_buf_t*, int* /*pfreq*/);
|
84
88
|
|
85
89
|
/*
|
86
90
|
* Gets the bit depth (bits per sample) of the audio contained in a buffer.
|
@@ -89,7 +93,7 @@ seal_err_t seal_get_buf_freq(seal_buf_t*, int* /*pfreq*/);
|
|
89
93
|
* @param buf the buffer to retrive the bit depth of
|
90
94
|
* @param pbps the receiver of the bit depth
|
91
95
|
*/
|
92
|
-
seal_err_t seal_get_buf_bps(seal_buf_t*, int* /*pbps*/);
|
96
|
+
seal_err_t SEAL_API seal_get_buf_bps(seal_buf_t*, int* /*pbps*/);
|
93
97
|
|
94
98
|
/*
|
95
99
|
* Gets the number of channels of the audio contained in a buffer. The default
|
@@ -98,7 +102,7 @@ seal_err_t seal_get_buf_bps(seal_buf_t*, int* /*pbps*/);
|
|
98
102
|
* @param buf the buffer to retrive the number of channels of
|
99
103
|
* @param pnchannels the receiver of the number of channels
|
100
104
|
*/
|
101
|
-
seal_err_t seal_get_buf_nchannels(seal_buf_t*, int* /*pnchannels*/);
|
105
|
+
seal_err_t SEAL_API seal_get_buf_nchannels(seal_buf_t*, int* /*pnchannels*/);
|
102
106
|
|
103
107
|
/*
|
104
108
|
* Loads an audio file and extracts the whole PCM data to memory. This is the
|
@@ -112,7 +116,11 @@ seal_err_t seal_get_buf_nchannels(seal_buf_t*, int* /*pnchannels*/);
|
|
112
116
|
* audio format will be attempted if the passed-in `fmt' is
|
113
117
|
* `SEAL_UNKNOWN_FMT'
|
114
118
|
*/
|
115
|
-
seal_err_t seal_load(
|
119
|
+
seal_err_t SEAL_API seal_load(
|
120
|
+
seal_raw_t*,
|
121
|
+
const char* /*filename*/,
|
122
|
+
seal_fmt_t
|
123
|
+
);
|
116
124
|
|
117
125
|
#ifdef __cplusplus
|
118
126
|
}
|
data/include/seal/core.h
CHANGED
@@ -20,22 +20,22 @@ extern "C" {
|
|
20
20
|
*
|
21
21
|
* @param device_name the name of a device; 0 to use the default one
|
22
22
|
*/
|
23
|
-
seal_err_t seal_startup(const char* /*device_name*/);
|
23
|
+
seal_err_t SEAL_API seal_startup(const char* /*device_name*/);
|
24
24
|
|
25
25
|
/* Uninitializes Seal and invalidate all Seal objects. Thread-unsafe. */
|
26
|
-
void seal_cleanup(void);
|
26
|
+
void SEAL_API seal_cleanup(void);
|
27
27
|
|
28
28
|
/*
|
29
29
|
* @return the maximum number of effect slots a source can feed concurrently.
|
30
30
|
*/
|
31
|
-
int seal_get_per_src_effect_limit(void);
|
31
|
+
int SEAL_API seal_get_per_src_effect_limit(void);
|
32
32
|
|
33
33
|
/*
|
34
34
|
* Gets the Seal version string.
|
35
35
|
*
|
36
36
|
* @return the version string
|
37
37
|
*/
|
38
|
-
const char* seal_get_version(void);
|
38
|
+
const char* SEAL_API seal_get_version(void);
|
39
39
|
|
40
40
|
#ifdef __cplusplus
|
41
41
|
}
|
@@ -61,11 +61,17 @@ typedef void _seal_openal_getteri(unsigned int, int, int*);
|
|
61
61
|
/* Common helpers. */
|
62
62
|
unsigned int _seal_openal_id(void*);
|
63
63
|
seal_err_t _seal_gen_objs(int, unsigned int*, _seal_openal_initializer_t*);
|
64
|
-
seal_err_t _seal_delete_objs(
|
65
|
-
|
64
|
+
seal_err_t _seal_delete_objs(
|
65
|
+
int,
|
66
|
+
const unsigned int*,
|
67
|
+
_seal_openal_destroyer_t*
|
68
|
+
);
|
66
69
|
seal_err_t _seal_init_obj(void*, _seal_openal_initializer_t*);
|
67
|
-
seal_err_t _seal_destroy_obj(
|
68
|
-
|
70
|
+
seal_err_t _seal_destroy_obj(
|
71
|
+
void*,
|
72
|
+
_seal_openal_destroyer_t*,
|
73
|
+
_seal_openal_validator_t*
|
74
|
+
);
|
69
75
|
seal_err_t _seal_setf(void*, int, float, _seal_openal_setterf*);
|
70
76
|
seal_err_t _seal_getf(void*, int, float*, _seal_openal_getterf*);
|
71
77
|
seal_err_t _seal_seti(void*, int, int, _seal_openal_setteri*);
|
data/include/seal/efs.h
CHANGED
@@ -31,14 +31,14 @@ typedef struct seal_efs_t seal_efs_t;
|
|
31
31
|
*
|
32
32
|
* @param efs the effect slot to initialize
|
33
33
|
*/
|
34
|
-
seal_err_t seal_init_efs(seal_efs_t*);
|
34
|
+
seal_err_t SEAL_API seal_init_efs(seal_efs_t*);
|
35
35
|
|
36
36
|
/*
|
37
37
|
* Destroys an effect slot.
|
38
38
|
*
|
39
39
|
* @param efs the effect slot to destroy
|
40
40
|
*/
|
41
|
-
seal_err_t seal_destroy_efs(seal_efs_t*);
|
41
|
+
seal_err_t SEAL_API seal_destroy_efs(seal_efs_t*);
|
42
42
|
|
43
43
|
/*
|
44
44
|
* Fills an effect slot with an effect object, then the effect Slot will
|
@@ -51,7 +51,7 @@ seal_err_t seal_destroy_efs(seal_efs_t*);
|
|
51
51
|
* @param efs the effect slot to fill
|
52
52
|
* @param effect the effect to fill the effect slot with
|
53
53
|
*/
|
54
|
-
seal_err_t seal_set_efs_effect(seal_efs_t*, void* /*effect*/);
|
54
|
+
seal_err_t SEAL_API seal_set_efs_effect(seal_efs_t*, void* /*effect*/);
|
55
55
|
|
56
56
|
/*
|
57
57
|
* Sets the output level of an effect Slot in the interval [0.0f, 1.0f]. A
|
@@ -60,7 +60,7 @@ seal_err_t seal_set_efs_effect(seal_efs_t*, void* /*effect*/);
|
|
60
60
|
* @param efs the effect slot to set the gain of
|
61
61
|
* @param gain the gain
|
62
62
|
*/
|
63
|
-
seal_err_t seal_set_efs_gain(seal_efs_t*, float /*gain*/);
|
63
|
+
seal_err_t SEAL_API seal_set_efs_gain(seal_efs_t*, float /*gain*/);
|
64
64
|
|
65
65
|
/*
|
66
66
|
* Sets whether the effect should have automatic adjustments based on the
|
@@ -69,7 +69,7 @@ seal_err_t seal_set_efs_gain(seal_efs_t*, float /*gain*/);
|
|
69
69
|
* @param efs the effect slot to set the auto adjust flag of
|
70
70
|
* @param automatic 1 to set it auto adjust or otherwise 0
|
71
71
|
*/
|
72
|
-
seal_err_t seal_set_efs_auto(seal_efs_t*, char /*automatic*/);
|
72
|
+
seal_err_t SEAL_API seal_set_efs_auto(seal_efs_t*, char /*automatic*/);
|
73
73
|
|
74
74
|
/*
|
75
75
|
* Gets the effect object in an effect slot. The default is 0 (null pointer).
|
@@ -77,7 +77,7 @@ seal_err_t seal_set_efs_auto(seal_efs_t*, char /*automatic*/);
|
|
77
77
|
* @param efs the effect slot to get the effect object of
|
78
78
|
* @return the effect object
|
79
79
|
*/
|
80
|
-
void* seal_get_efs_effect(seal_efs_t*);
|
80
|
+
void* SEAL_API seal_get_efs_effect(seal_efs_t*);
|
81
81
|
|
82
82
|
/*
|
83
83
|
* Gets the output level of an effect Slot in the interval. The default is
|
@@ -86,7 +86,7 @@ void* seal_get_efs_effect(seal_efs_t*);
|
|
86
86
|
* @param efs the effect slot to get the gain of
|
87
87
|
* @param pgain the receiver of the gain
|
88
88
|
*/
|
89
|
-
seal_err_t seal_get_efs_gain(seal_efs_t*, float* /*pgain*/);
|
89
|
+
seal_err_t SEAL_API seal_get_efs_gain(seal_efs_t*, float* /*pgain*/);
|
90
90
|
|
91
91
|
/*
|
92
92
|
* Determines if the effect is automatically adjusted. The default is true
|
@@ -95,7 +95,7 @@ seal_err_t seal_get_efs_gain(seal_efs_t*, float* /*pgain*/);
|
|
95
95
|
* @param efs the effect slot to determine
|
96
96
|
* @param pauto the receiver of the auto adjust flag
|
97
97
|
*/
|
98
|
-
seal_err_t seal_is_efs_auto(seal_efs_t*, char* /*pauto*/);
|
98
|
+
seal_err_t SEAL_API seal_is_efs_auto(seal_efs_t*, char* /*pauto*/);
|
99
99
|
|
100
100
|
/*
|
101
101
|
*****************************************************************************
|
data/include/seal/err.h
CHANGED
@@ -7,6 +7,8 @@
|
|
7
7
|
#ifndef _SEAL_ERR_H_
|
8
8
|
#define _SEAL_ERR_H_
|
9
9
|
|
10
|
+
#define SEAL_API
|
11
|
+
|
10
12
|
enum seal_err_t
|
11
13
|
{
|
12
14
|
SEAL_OK,
|
@@ -68,7 +70,7 @@ extern "C" {
|
|
68
70
|
* @param err the error to get the message associated with
|
69
71
|
* @return the error message if there is any or otherwise 0
|
70
72
|
*/
|
71
|
-
const char* seal_get_err_msg(seal_err_t);
|
73
|
+
const char* SEAL_API seal_get_err_msg(seal_err_t);
|
72
74
|
|
73
75
|
#ifdef __cplusplus
|
74
76
|
}
|
data/include/seal/fmt.h
CHANGED
@@ -43,8 +43,10 @@ seal_err_t seal_recognize_fmt(const char* /*filename*/, seal_fmt_t* /*pfmt*/);
|
|
43
43
|
* otherwise the file format is checked and `pfmt' receives
|
44
44
|
* the known format
|
45
45
|
*/
|
46
|
-
seal_err_t seal_ensure_fmt_known(
|
47
|
-
|
46
|
+
seal_err_t seal_ensure_fmt_known(
|
47
|
+
const char* /*filename*/,
|
48
|
+
seal_fmt_t* /*pfmt*/
|
49
|
+
);
|
48
50
|
|
49
51
|
#ifdef __cplusplus
|
50
52
|
}
|
data/include/seal/listener.h
CHANGED
@@ -17,6 +17,13 @@
|
|
17
17
|
extern "C" {
|
18
18
|
#endif
|
19
19
|
|
20
|
+
/*
|
21
|
+
* Moves the listener (changes the position) based on the listener velocity.
|
22
|
+
* This is a syntactic sugar for adding the velocity vector and position
|
23
|
+
* vector.
|
24
|
+
*/
|
25
|
+
seal_err_t SEAL_API seal_move_listener(void);
|
26
|
+
|
20
27
|
/*
|
21
28
|
* Sets the master scalar amplitude multiplier of the listener which applies
|
22
29
|
* to all the sources. 1.0f means that the sound is unattenuated; 0.5f means
|
@@ -24,7 +31,7 @@ extern "C" {
|
|
24
31
|
*
|
25
32
|
* @param gain the scalar amplitude multiplier in the interval [0.0f, +inf.)
|
26
33
|
*/
|
27
|
-
seal_err_t seal_set_listener_gain(float /*gain*/);
|
34
|
+
seal_err_t SEAL_API seal_set_listener_gain(float /*gain*/);
|
28
35
|
|
29
36
|
/*
|
30
37
|
* Sets the position of the listener in a right-handed Cartesian coordinate
|
@@ -34,7 +41,11 @@ seal_err_t seal_set_listener_gain(float /*gain*/);
|
|
34
41
|
* @param y the y position to set
|
35
42
|
* @param z the z position to set
|
36
43
|
*/
|
37
|
-
seal_err_t seal_set_listener_pos(
|
44
|
+
seal_err_t SEAL_API seal_set_listener_pos(
|
45
|
+
float /*x*/,
|
46
|
+
float /*y*/,
|
47
|
+
float /*z*/
|
48
|
+
);
|
38
49
|
|
39
50
|
/*
|
40
51
|
* Sets the velocity of the listener in a right-handed Cartesian coordinate
|
@@ -45,7 +56,11 @@ seal_err_t seal_set_listener_pos(float /*x*/, float /*y*/, float /*z*/);
|
|
45
56
|
* @param y the y velocity to set
|
46
57
|
* @param z the z velocity to set
|
47
58
|
*/
|
48
|
-
seal_err_t seal_set_listener_vel(
|
59
|
+
seal_err_t SEAL_API seal_set_listener_vel(
|
60
|
+
float /*x*/,
|
61
|
+
float /*y*/,
|
62
|
+
float /*z*/
|
63
|
+
);
|
49
64
|
|
50
65
|
/*
|
51
66
|
* Sets the orientation of the listener.
|
@@ -57,7 +72,7 @@ seal_err_t seal_set_listener_vel(float /*x*/, float /*y*/, float /*z*/);
|
|
57
72
|
* linearly independent, must not be NaN and must not be
|
58
73
|
* normalized. Otherwise, the operation is undefined
|
59
74
|
*/
|
60
|
-
seal_err_t seal_set_listener_orien(float* /*orien*/);
|
75
|
+
seal_err_t SEAL_API seal_set_listener_orien(float* /*orien*/);
|
61
76
|
|
62
77
|
/*
|
63
78
|
* Gets the gain of the listener. The default is 1.0f.
|
@@ -65,7 +80,7 @@ seal_err_t seal_set_listener_orien(float* /*orien*/);
|
|
65
80
|
* @see seal_set_listener_gain
|
66
81
|
* @param pgain the receiver of the gain
|
67
82
|
*/
|
68
|
-
seal_err_t seal_get_listener_gain(float* /*pgain*/);
|
83
|
+
seal_err_t SEAL_API seal_get_listener_gain(float* /*pgain*/);
|
69
84
|
|
70
85
|
/*
|
71
86
|
* Gets the position of the listener. The default is ( 0.0f, 0.0f, 0.0f ).
|
@@ -75,7 +90,11 @@ seal_err_t seal_get_listener_gain(float* /*pgain*/);
|
|
75
90
|
* @param py the receiver of the y position
|
76
91
|
* @param pz the receiver of the z position
|
77
92
|
*/
|
78
|
-
seal_err_t seal_get_listener_pos(
|
93
|
+
seal_err_t SEAL_API seal_get_listener_pos(
|
94
|
+
float* /*px*/,
|
95
|
+
float* /*py*/,
|
96
|
+
float* /*pz*/
|
97
|
+
);
|
79
98
|
|
80
99
|
/*
|
81
100
|
* Gets the velocity of the listener. The default is ( 0.0f, 0.0f, 0.0f ).
|
@@ -85,7 +104,11 @@ seal_err_t seal_get_listener_pos(float* /*px*/, float* /*py*/, float* /*pz*/);
|
|
85
104
|
* @param py the receiver of the y velocity
|
86
105
|
* @param pz the receiver of the z velocity
|
87
106
|
*/
|
88
|
-
seal_err_t seal_get_listener_vel(
|
107
|
+
seal_err_t SEAL_API seal_get_listener_vel(
|
108
|
+
float* /*px*/,
|
109
|
+
float* /*py*/,
|
110
|
+
float* /*pz*/
|
111
|
+
);
|
89
112
|
|
90
113
|
/*
|
91
114
|
* Gets the orientation of the listener. The default is
|
@@ -95,10 +118,10 @@ seal_err_t seal_get_listener_vel(float* /*px*/, float* /*py*/, float* /*pz*/);
|
|
95
118
|
* @param orien the array of a pair of 3-tuple that receives the 'at' vector
|
96
119
|
* and the 'up' vector
|
97
120
|
*/
|
98
|
-
seal_err_t seal_get_listener_orien(float* /*orien*/);
|
121
|
+
seal_err_t SEAL_API seal_get_listener_orien(float* /*orien*/);
|
99
122
|
|
100
123
|
#ifdef __cplusplus
|
101
124
|
}
|
102
125
|
#endif
|
103
126
|
|
104
|
-
#endif /* _SEAL_LISTENER_H_ */
|
127
|
+
#endif /* _SEAL_LISTENER_H_ */
|
data/include/seal/rvb.h
CHANGED
@@ -177,14 +177,14 @@ extern "C" {
|
|
177
177
|
*
|
178
178
|
* @param reverb the reverb object to initialize
|
179
179
|
*/
|
180
|
-
seal_err_t seal_init_rvb(seal_rvb_t*);
|
180
|
+
seal_err_t SEAL_API seal_init_rvb(seal_rvb_t*);
|
181
181
|
|
182
182
|
/*
|
183
183
|
* Destroys a reverb effect.
|
184
184
|
*
|
185
185
|
* @param reverb the reverb to destroy
|
186
186
|
*/
|
187
|
-
seal_err_t seal_destroy_rvb(seal_rvb_t*);
|
187
|
+
seal_err_t SEAL_API seal_destroy_rvb(seal_rvb_t*);
|
188
188
|
|
189
189
|
/*
|
190
190
|
* Loads the specified reverb paramter preset into a reverb object.
|
@@ -192,7 +192,7 @@ seal_err_t seal_destroy_rvb(seal_rvb_t*);
|
|
192
192
|
* @param reverb the reverb to load the preset into
|
193
193
|
* @param preset the preset to load
|
194
194
|
*/
|
195
|
-
seal_err_t seal_load_rvb(seal_rvb_t*, seal_rvb_preset_t);
|
195
|
+
seal_err_t SEAL_API seal_load_rvb(seal_rvb_t*, seal_rvb_preset_t);
|
196
196
|
|
197
197
|
/*
|
198
198
|
* Sets the modal density of a reverb in the interval [0.0f, 1.0f]. The
|
@@ -202,7 +202,7 @@ seal_err_t seal_load_rvb(seal_rvb_t*, seal_rvb_preset_t);
|
|
202
202
|
* @param reverb the reverb to set the density of
|
203
203
|
* @param density the density
|
204
204
|
*/
|
205
|
-
seal_err_t seal_set_rvb_density(seal_rvb_t*, float /*density*/);
|
205
|
+
seal_err_t SEAL_API seal_set_rvb_density(seal_rvb_t*, float /*density*/);
|
206
206
|
|
207
207
|
/*
|
208
208
|
* Sets the diffusion of a reverb in the interval [0.0f, 1.0f]. The diffusion
|
@@ -214,7 +214,7 @@ seal_err_t seal_set_rvb_density(seal_rvb_t*, float /*density*/);
|
|
214
214
|
* @param reverb the reverb to set the diffusion of
|
215
215
|
* @param diffusion the diffusion
|
216
216
|
*/
|
217
|
-
seal_err_t seal_set_rvb_diffusion(seal_rvb_t*, float /*diffusion*/);
|
217
|
+
seal_err_t SEAL_API seal_set_rvb_diffusion(seal_rvb_t*, float /*diffusion*/);
|
218
218
|
|
219
219
|
/*
|
220
220
|
* Sets the gain of a reverb in the interval [0.0f, 1.0f], or from -100 dB (no
|
@@ -227,7 +227,7 @@ seal_err_t seal_set_rvb_diffusion(seal_rvb_t*, float /*diffusion*/);
|
|
227
227
|
* @param reverb the reverb to set the gain of
|
228
228
|
* @param gain the gain
|
229
229
|
*/
|
230
|
-
seal_err_t seal_set_rvb_gain(seal_rvb_t*, float /*gain*/);
|
230
|
+
seal_err_t SEAL_API seal_set_rvb_gain(seal_rvb_t*, float /*gain*/);
|
231
231
|
|
232
232
|
/*
|
233
233
|
* Sets the high-frequency gain of a reverb in the interval [0.0f, 1.0f], or
|
@@ -240,7 +240,7 @@ seal_err_t seal_set_rvb_gain(seal_rvb_t*, float /*gain*/);
|
|
240
240
|
* @param reverb the reverb to set the high-frequency gain of
|
241
241
|
* @param hfgain the high-frequency gain
|
242
242
|
*/
|
243
|
-
seal_err_t seal_set_rvb_hfgain(seal_rvb_t*, float /*hfgain*/);
|
243
|
+
seal_err_t SEAL_API seal_set_rvb_hfgain(seal_rvb_t*, float /*hfgain*/);
|
244
244
|
|
245
245
|
/*
|
246
246
|
* Sets the decay time of a reverb in the interval [0.1f, 20.0f], typically
|
@@ -250,7 +250,7 @@ seal_err_t seal_set_rvb_hfgain(seal_rvb_t*, float /*hfgain*/);
|
|
250
250
|
* @param reverb the reverb to set the decay time of
|
251
251
|
* @param time the decay time
|
252
252
|
*/
|
253
|
-
seal_err_t seal_set_rvb_decay_time(seal_rvb_t*, float /*time*/);
|
253
|
+
seal_err_t SEAL_API seal_set_rvb_decay_time(seal_rvb_t*, float /*time*/);
|
254
254
|
|
255
255
|
/*
|
256
256
|
* Sets the high-frequency decay ratio, or the spectral quality of the decay
|
@@ -267,7 +267,7 @@ seal_err_t seal_set_rvb_decay_time(seal_rvb_t*, float /*time*/);
|
|
267
267
|
* @param reverb the reverb to set the decay high-frequency ratio of
|
268
268
|
* @param ratio the decay high-frequency ratio
|
269
269
|
*/
|
270
|
-
seal_err_t seal_set_rvb_hfdecay_ratio(seal_rvb_t*, float /*ratio*/);
|
270
|
+
seal_err_t SEAL_API seal_set_rvb_hfdecay_ratio(seal_rvb_t*, float /*ratio*/);
|
271
271
|
|
272
272
|
/*
|
273
273
|
* Sets the reflections gain, or the overall amount of initial reflections
|
@@ -287,7 +287,10 @@ seal_err_t seal_set_rvb_hfdecay_ratio(seal_rvb_t*, float /*ratio*/);
|
|
287
287
|
* @param reverb the reverb to set the reflections gain of
|
288
288
|
* @param gain the reflections gain
|
289
289
|
*/
|
290
|
-
seal_err_t seal_set_rvb_reflections_gain(
|
290
|
+
seal_err_t SEAL_API seal_set_rvb_reflections_gain(
|
291
|
+
seal_rvb_t*,
|
292
|
+
float /*gain*/
|
293
|
+
);
|
291
294
|
|
292
295
|
/*
|
293
296
|
* Sets the reflections delay of a reverb in the interval [0.0f, 0.3f] (in
|
@@ -299,7 +302,10 @@ seal_err_t seal_set_rvb_reflections_gain(seal_rvb_t*, float /*gain*/);
|
|
299
302
|
* @param reverb the reverb to set the reflections delay of
|
300
303
|
* @param delay the reflections delay
|
301
304
|
*/
|
302
|
-
seal_err_t seal_set_rvb_reflections_delay(
|
305
|
+
seal_err_t SEAL_API seal_set_rvb_reflections_delay(
|
306
|
+
seal_rvb_t*,
|
307
|
+
float /*delay*/
|
308
|
+
);
|
303
309
|
|
304
310
|
/*
|
305
311
|
* Sets the late gain, or the overall amount of later reverberation relative
|
@@ -314,7 +320,10 @@ seal_err_t seal_set_rvb_reflections_delay(seal_rvb_t*, float /*delay*/);
|
|
314
320
|
* @param reverb the reverb to set the late gain of
|
315
321
|
* @param gain the late gain
|
316
322
|
*/
|
317
|
-
seal_err_t seal_set_rvb_late_gain(
|
323
|
+
seal_err_t SEAL_API seal_set_rvb_late_gain(
|
324
|
+
seal_rvb_t*,
|
325
|
+
float /*gain*/
|
326
|
+
);
|
318
327
|
|
319
328
|
/*
|
320
329
|
* Sets the late delay of a reverb in the interval [0.0f, 0.1f] (in second)
|
@@ -325,7 +334,10 @@ seal_err_t seal_set_rvb_late_gain(seal_rvb_t*, float /*gain*/);
|
|
325
334
|
* @param reverb the reverb to set the late delay of
|
326
335
|
* @param delay the late delay
|
327
336
|
*/
|
328
|
-
seal_err_t seal_set_rvb_late_delay(
|
337
|
+
seal_err_t SEAL_API seal_set_rvb_late_delay(
|
338
|
+
seal_rvb_t*,
|
339
|
+
float /*delay*/
|
340
|
+
);
|
329
341
|
|
330
342
|
/*
|
331
343
|
* Sets the air absorption high-frequency gain of a reverb in the interval
|
@@ -341,7 +353,10 @@ seal_err_t seal_set_rvb_late_delay(seal_rvb_t*, float /*delay*/);
|
|
341
353
|
* @param reverb the reverb to set the air absorption gain of
|
342
354
|
* @param gain the air absorption high-frequency gain
|
343
355
|
*/
|
344
|
-
seal_err_t seal_set_rvb_air_absorbtion_hfgain(
|
356
|
+
seal_err_t SEAL_API seal_set_rvb_air_absorbtion_hfgain(
|
357
|
+
seal_rvb_t*,
|
358
|
+
float /*hfgain*/
|
359
|
+
);
|
345
360
|
|
346
361
|
/*
|
347
362
|
* Sets the room rolloff factor of a reverb in the interval [0.0f, 10.0f]. It
|
@@ -369,7 +384,10 @@ seal_err_t seal_set_rvb_air_absorbtion_hfgain(seal_rvb_t*, float /*hfgain*/);
|
|
369
384
|
* @param reverb the reverb to set the room rolloff factor of
|
370
385
|
* @param factor the room rolloff factor
|
371
386
|
*/
|
372
|
-
seal_err_t seal_set_rvb_room_rolloff_factor(
|
387
|
+
seal_err_t SEAL_API seal_set_rvb_room_rolloff_factor(
|
388
|
+
seal_rvb_t*,
|
389
|
+
float /*factor*/
|
390
|
+
);
|
373
391
|
|
374
392
|
/*
|
375
393
|
* Sets whether the high-frequency decay time automatically stays below a
|
@@ -385,7 +403,10 @@ seal_err_t seal_set_rvb_room_rolloff_factor(seal_rvb_t*, float /*factor*/);
|
|
385
403
|
* @param reverb the reverb to set the high-frequency decay limit flag of
|
386
404
|
* @param limited 1 to set it limited or otherwise 0
|
387
405
|
*/
|
388
|
-
seal_err_t seal_set_rvb_hfdecay_limited(
|
406
|
+
seal_err_t SEAL_API seal_set_rvb_hfdecay_limited(
|
407
|
+
seal_rvb_t*,
|
408
|
+
char /*limited*/
|
409
|
+
);
|
389
410
|
|
390
411
|
/*
|
391
412
|
* Gets the density of a reverb. The default is 1.0f.
|
@@ -394,7 +415,7 @@ seal_err_t seal_set_rvb_hfdecay_limited(seal_rvb_t*, char /*limited*/);
|
|
394
415
|
* @param reverb the source to get the density of
|
395
416
|
* @param pdensity the receiver of the density
|
396
417
|
*/
|
397
|
-
seal_err_t seal_get_rvb_density(seal_rvb_t*, float* /*pdensity*/);
|
418
|
+
seal_err_t SEAL_API seal_get_rvb_density(seal_rvb_t*, float* /*pdensity*/);
|
398
419
|
|
399
420
|
/*
|
400
421
|
* Gets the diffusion of a reverb. The default is 1.0f.
|
@@ -403,7 +424,10 @@ seal_err_t seal_get_rvb_density(seal_rvb_t*, float* /*pdensity*/);
|
|
403
424
|
* @param reverb the source to get the diffusion of
|
404
425
|
* @param pdiffusion the receiver of diffusion
|
405
426
|
*/
|
406
|
-
seal_err_t seal_get_rvb_diffusion(
|
427
|
+
seal_err_t SEAL_API seal_get_rvb_diffusion(
|
428
|
+
seal_rvb_t*,
|
429
|
+
float* /*pdiffusion*/
|
430
|
+
);
|
407
431
|
|
408
432
|
/*
|
409
433
|
* Gets the gain of a reverb. The default is 0.32f.
|
@@ -412,7 +436,7 @@ seal_err_t seal_get_rvb_diffusion(seal_rvb_t*, float* /*pdiffusion*/);
|
|
412
436
|
* @param reverb the source to get the gain of
|
413
437
|
* @param pgain the receiver of the gain
|
414
438
|
*/
|
415
|
-
seal_err_t seal_get_rvb_gain(seal_rvb_t*, float* /*pgain*/);
|
439
|
+
seal_err_t SEAL_API seal_get_rvb_gain(seal_rvb_t*, float* /*pgain*/);
|
416
440
|
|
417
441
|
/*
|
418
442
|
* Gets the high-frequency gain of a reverb. The default is 0.89f.
|
@@ -421,7 +445,7 @@ seal_err_t seal_get_rvb_gain(seal_rvb_t*, float* /*pgain*/);
|
|
421
445
|
* @param reverb the source to get the high-frequency gain of
|
422
446
|
* @param phfgain the receiver of the high-frequency gain
|
423
447
|
*/
|
424
|
-
seal_err_t seal_get_rvb_hfgain(seal_rvb_t*, float* /*phfgain*/);
|
448
|
+
seal_err_t SEAL_API seal_get_rvb_hfgain(seal_rvb_t*, float* /*phfgain*/);
|
425
449
|
|
426
450
|
/*
|
427
451
|
* Gets the decay time of a reverb. The default is 1.49f.
|
@@ -430,7 +454,7 @@ seal_err_t seal_get_rvb_hfgain(seal_rvb_t*, float* /*phfgain*/);
|
|
430
454
|
* @param reverb the source to get the decay time of
|
431
455
|
* @param ptime the receiver of the decay time
|
432
456
|
*/
|
433
|
-
seal_err_t seal_get_rvb_decay_time(seal_rvb_t*, float* /*ptime*/);
|
457
|
+
seal_err_t SEAL_API seal_get_rvb_decay_time(seal_rvb_t*, float* /*ptime*/);
|
434
458
|
|
435
459
|
/*
|
436
460
|
* Gets the high-frequency decay ratio of a reverb. The default is 0.83f.
|
@@ -439,7 +463,10 @@ seal_err_t seal_get_rvb_decay_time(seal_rvb_t*, float* /*ptime*/);
|
|
439
463
|
* @param reverb the source to get the high-frequency decay time of
|
440
464
|
* @param pratio the receiver of the high-frequency decay ratio
|
441
465
|
*/
|
442
|
-
seal_err_t seal_get_rvb_hfdecay_ratio(
|
466
|
+
seal_err_t SEAL_API seal_get_rvb_hfdecay_ratio(
|
467
|
+
seal_rvb_t*,
|
468
|
+
float* /*pratio*/
|
469
|
+
);
|
443
470
|
|
444
471
|
/*
|
445
472
|
* Gets the reflections gain of a reverb. The default is 0.05f.
|
@@ -448,7 +475,10 @@ seal_err_t seal_get_rvb_hfdecay_ratio(seal_rvb_t*, float* /*pratio*/);
|
|
448
475
|
* @param reverb the source to get the reflections gain of
|
449
476
|
* @param pgain the receiver of the reflections gain
|
450
477
|
*/
|
451
|
-
seal_err_t seal_get_rvb_reflections_gain(
|
478
|
+
seal_err_t SEAL_API seal_get_rvb_reflections_gain(
|
479
|
+
seal_rvb_t*,
|
480
|
+
float* /*pgain*/
|
481
|
+
);
|
452
482
|
|
453
483
|
/*
|
454
484
|
* Gets the reflections delay of a reverb. The default is 0.007f.
|
@@ -457,7 +487,10 @@ seal_err_t seal_get_rvb_reflections_gain(seal_rvb_t*, float* /*pgain*/);
|
|
457
487
|
* @param reverb the source to get the reflections delay of
|
458
488
|
* @param pdelay the receiver of the reflections delay
|
459
489
|
*/
|
460
|
-
seal_err_t seal_get_rvb_reflections_delay(
|
490
|
+
seal_err_t SEAL_API seal_get_rvb_reflections_delay(
|
491
|
+
seal_rvb_t*,
|
492
|
+
float* /*pdelay*/
|
493
|
+
);
|
461
494
|
|
462
495
|
/*
|
463
496
|
* Gets the late gain of a reverb. The default is 1.26f.
|
@@ -466,7 +499,7 @@ seal_err_t seal_get_rvb_reflections_delay(seal_rvb_t*, float* /*pdelay*/);
|
|
466
499
|
* @param reverb the source to get the late gain of
|
467
500
|
* @param pgain the receiver of the late gain
|
468
501
|
*/
|
469
|
-
seal_err_t seal_get_rvb_late_gain(seal_rvb_t*, float* /*pgain*/);
|
502
|
+
seal_err_t SEAL_API seal_get_rvb_late_gain(seal_rvb_t*, float* /*pgain*/);
|
470
503
|
|
471
504
|
/*
|
472
505
|
* Gets the late delay of a reverb. The default is 0.011f.
|
@@ -475,7 +508,7 @@ seal_err_t seal_get_rvb_late_gain(seal_rvb_t*, float* /*pgain*/);
|
|
475
508
|
* @param reverb the source to get the late delay of
|
476
509
|
* @param pdelay the receiver of the late delay
|
477
510
|
*/
|
478
|
-
seal_err_t seal_get_rvb_late_delay(seal_rvb_t*, float* /*pdelay*/);
|
511
|
+
seal_err_t SEAL_API seal_get_rvb_late_delay(seal_rvb_t*, float* /*pdelay*/);
|
479
512
|
|
480
513
|
/*
|
481
514
|
* Gets the air absorbtion high-frequency gain of a reverb. The default is
|
@@ -485,8 +518,10 @@ seal_err_t seal_get_rvb_late_delay(seal_rvb_t*, float* /*pdelay*/);
|
|
485
518
|
* @param reverb the source to get the gain of
|
486
519
|
* @param phfgain the receiver of the air absorbtion high-frequency gain
|
487
520
|
*/
|
488
|
-
seal_err_t seal_get_rvb_air_absorbtion_hfgain(
|
489
|
-
|
521
|
+
seal_err_t SEAL_API seal_get_rvb_air_absorbtion_hfgain(
|
522
|
+
seal_rvb_t*,
|
523
|
+
float* /*phfgain*/
|
524
|
+
);
|
490
525
|
|
491
526
|
/*
|
492
527
|
* Gets the room rolloff factor of a reverb. The default is 0.0f.
|
@@ -495,8 +530,10 @@ seal_err_t seal_get_rvb_air_absorbtion_hfgain(seal_rvb_t*,
|
|
495
530
|
* @param reverb the source to get the factor of
|
496
531
|
* @param pfactor the receiver of the room rolloff factor
|
497
532
|
*/
|
498
|
-
seal_err_t seal_get_rvb_room_rolloff_factor(
|
499
|
-
|
533
|
+
seal_err_t SEAL_API seal_get_rvb_room_rolloff_factor(
|
534
|
+
seal_rvb_t*,
|
535
|
+
float* /*pfactor*/
|
536
|
+
);
|
500
537
|
|
501
538
|
/*
|
502
539
|
* Determines if the high-frequency decay of a reverb is limited. The default
|
@@ -506,7 +543,10 @@ seal_err_t seal_get_rvb_room_rolloff_factor(seal_rvb_t*,
|
|
506
543
|
* @param reverb the source to get the limited flag of
|
507
544
|
* @param plimited the receiver of the limited flag
|
508
545
|
*/
|
509
|
-
seal_err_t seal_is_rvb_hfdecay_limited(
|
546
|
+
seal_err_t SEAL_API seal_is_rvb_hfdecay_limited(
|
547
|
+
seal_rvb_t*,
|
548
|
+
char* /*plimited*/
|
549
|
+
);
|
510
550
|
|
511
551
|
#ifdef __cplusplus
|
512
552
|
}
|