From 79d6c75a1324073488a2e34db36ce0afb203537c Mon Sep 17 00:00:00 2001 From: XANTRONIX Development Date: Sun, 27 Feb 2022 23:20:12 -0500 Subject: Implement xas_object Changes: * Implement xas_object as a base "class" for all playback state objects; allow implementation of start() and stop() methods to control playback * Move code for setting gain, bank slot to a new method, xas_bank_player_select() * Remove code from xas_bank_player_start() setting gain, bank slot * Add xas_object header to each monaural playable object --- examples/say.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'examples') diff --git a/examples/say.c b/examples/say.c index fa16242..c89a245 100644 --- a/examples/say.c +++ b/examples/say.c @@ -154,12 +154,14 @@ int main(int argc, char **argv) { goto error_bank_record; } + xas_bank_player_select(player, 0, 1.0); + for (i=0; i= 300 && !xas_bank_player_playing(player)) { - xas_bank_player_start(player, 0, 1.0); + xas_bank_player_start(player); } if ((readlen = xas_audio_stream_read(mixer->output, -- cgit v1.2.3