Linus Nielsen Feltzing | 1c497e6 | 2005-06-05 23:05:10 +0000 | [diff] [blame] | 1 | /*************************************************************************** |
| 2 | * __________ __ ___. |
| 3 | * Open \______ \ ____ ____ | | _\_ |__ _______ ___ |
| 4 | * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ / |
| 5 | * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < < |
| 6 | * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \ |
| 7 | * \/ \/ \/ \/ \/ |
| 8 | * $Id$ |
| 9 | * |
| 10 | * Copyright (C) 2005 Miika Pekkarinen |
| 11 | * |
Daniel Stenberg | 2acc0ac | 2008-06-28 18:10:04 +0000 | [diff] [blame^] | 12 | * This program is free software; you can redistribute it and/or |
| 13 | * modify it under the terms of the GNU General Public License |
| 14 | * as published by the Free Software Foundation; either version 2 |
| 15 | * of the License, or (at your option) any later version. |
Linus Nielsen Feltzing | 1c497e6 | 2005-06-05 23:05:10 +0000 | [diff] [blame] | 16 | * |
| 17 | * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY |
| 18 | * KIND, either express or implied. |
| 19 | * |
| 20 | ****************************************************************************/ |
| 21 | |
Dave Chapman | 3ad485b | 2005-06-14 22:27:57 +0000 | [diff] [blame] | 22 | #ifndef _PLAYBACK_H |
| 23 | #define _PLAYBACK_H |
| 24 | |
Dave Chapman | 3ad485b | 2005-06-14 22:27:57 +0000 | [diff] [blame] | 25 | #include <stdbool.h> |
Bertrik Sikken | c97e503 | 2008-04-28 14:13:13 +0000 | [diff] [blame] | 26 | #include "config.h" |
Miika Pekkarinen | d43bff9 | 2006-07-29 17:25:31 +0000 | [diff] [blame] | 27 | |
Miika Pekkarinen | 7d6d122 | 2005-06-29 21:36:30 +0000 | [diff] [blame] | 28 | /* Functions */ |
Steve Bavin | 135cc75 | 2008-03-28 12:51:33 +0000 | [diff] [blame] | 29 | const char *get_codec_filename(int cod_spec); |
Nils Wallménius | 5b76936 | 2007-08-06 13:08:36 +0000 | [diff] [blame] | 30 | void voice_wait(void); |
Steve Bavin | c9df8fd | 2008-03-28 11:24:24 +0000 | [diff] [blame] | 31 | void audio_wait_for_init(void); |
| 32 | int audio_track_count(void); |
| 33 | long audio_filebufused(void); |
| 34 | void audio_pre_ff_rewind(void); |
Steve Bavin | 135cc75 | 2008-03-28 12:51:33 +0000 | [diff] [blame] | 35 | void audio_set_crossfade(int type); |
Steve Bavin | c9df8fd | 2008-03-28 11:24:24 +0000 | [diff] [blame] | 36 | |
| 37 | void audio_hard_stop(void); /* Stops audio from serving playback */ |
| 38 | |
| 39 | enum |
| 40 | { |
| 41 | AUDIO_WANT_PLAYBACK = 0, |
| 42 | AUDIO_WANT_VOICE, |
| 43 | }; |
Steve Bavin | 135cc75 | 2008-03-28 12:51:33 +0000 | [diff] [blame] | 44 | bool audio_restore_playback(int type); /* Restores the audio buffer to handle the requested playback */ |
Steve Bavin | c9df8fd | 2008-03-28 11:24:24 +0000 | [diff] [blame] | 45 | |
| 46 | #ifdef HAVE_ALBUMART |
| 47 | int audio_current_aa_hid(void); |
| 48 | #endif |
Miika Pekkarinen | 7d6d122 | 2005-06-29 21:36:30 +0000 | [diff] [blame] | 49 | |
Linus Nielsen Feltzing | 224c0a1 | 2006-08-15 12:27:07 +0000 | [diff] [blame] | 50 | #if CONFIG_CODEC == SWCODEC /* This #ifdef is better here than gui/gwps.c */ |
Anton Oleynikov | 00928af | 2005-11-10 22:31:47 +0000 | [diff] [blame] | 51 | extern void audio_next_dir(void); |
| 52 | extern void audio_prev_dir(void); |
Linus Nielsen Feltzing | 224c0a1 | 2006-08-15 12:27:07 +0000 | [diff] [blame] | 53 | #else |
Stéphane Doyon | ab0f7e1 | 2008-05-04 13:47:58 +0000 | [diff] [blame] | 54 | #define audio_next_dir() ({ }) |
| 55 | #define audio_prev_dir() ({ }) |
Linus Nielsen Feltzing | 224c0a1 | 2006-08-15 12:27:07 +0000 | [diff] [blame] | 56 | #endif |
Miika Pekkarinen | d319116 | 2006-01-27 11:39:46 +0000 | [diff] [blame] | 57 | |
Linus Nielsen Feltzing | 1c497e6 | 2005-06-05 23:05:10 +0000 | [diff] [blame] | 58 | #endif |
| 59 | |
| 60 | |