summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--examples/test.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/examples/test.c b/examples/test.c
index 24d1d7b..56632a5 100644
--- a/examples/test.c
+++ b/examples/test.c
@@ -74,7 +74,8 @@ int main(int argc, char **argv) {
};
size_t sample_rate = 44100,
- duration_s = 60,
+ buffer_size = 4096,
+ duration_s = 60,
i;
if (argc != 2) {
@@ -91,7 +92,7 @@ int main(int argc, char **argv) {
if ((synth_l = xas_synth_new(XAS_AUDIO_STREAM_PCM_16_BIT,
sample_rate,
- sample_rate,
+ buffer_size,
(xas_synth_callback_sample)sine_sample,
(xas_synth_callback_cleanup)sine_cleanup,
&sine_channels[0])) == NULL) {
@@ -100,7 +101,7 @@ int main(int argc, char **argv) {
if ((synth_r = xas_synth_new(XAS_AUDIO_STREAM_PCM_16_BIT,
sample_rate,
- sample_rate,
+ buffer_size,
(xas_synth_callback_sample)sine_sample,
(xas_synth_callback_cleanup)sine_cleanup,
&sine_channels[1])) == NULL) {
@@ -110,7 +111,7 @@ int main(int argc, char **argv) {
if ((mixer = xas_mixer_new(XAS_AUDIO_STREAM_PCM_16_BIT,
sample_rate,
XAS_AUDIO_STREAM_STEREO,
- sample_rate)) == NULL) {
+ buffer_size)) == NULL) {
goto error_mixer_new;
}