summaryrefslogtreecommitdiff
path: root/apps/playback.h
diff options
context:
space:
mode:
Diffstat (limited to 'apps/playback.h')
-rw-r--r--apps/playback.h51
1 files changed, 43 insertions, 8 deletions
diff --git a/apps/playback.h b/apps/playback.h
index add11e296b..a53d2bb2e7 100644
--- a/apps/playback.h
+++ b/apps/playback.h
@@ -23,6 +23,7 @@
23#define _PLAYBACK_H 23#define _PLAYBACK_H
24 24
25#include <stdbool.h> 25#include <stdbool.h>
26#include <stdlib.h>
26#include "config.h" 27#include "config.h"
27 28
28#ifdef HAVE_ALBUMART 29#ifdef HAVE_ALBUMART
@@ -52,7 +53,6 @@ void playback_release_aa_slot(int slot);
52#endif 53#endif
53 54
54/* Functions */ 55/* Functions */
55const char *get_codec_filename(int cod_spec);
56void voice_wait(void); 56void voice_wait(void);
57bool audio_is_thread_ready(void); 57bool audio_is_thread_ready(void);
58int audio_track_count(void); 58int audio_track_count(void);
@@ -68,18 +68,53 @@ enum
68 AUDIO_WANT_VOICE, 68 AUDIO_WANT_VOICE,
69}; 69};
70bool audio_restore_playback(int type); /* Restores the audio buffer to handle the requested playback */ 70bool audio_restore_playback(int type); /* Restores the audio buffer to handle the requested playback */
71void codec_thread_do_callback(void (*fn)(void), 71size_t audio_get_filebuflen(void);
72 unsigned int *codec_thread_id); 72int get_audio_hid(void);
73int *get_codec_hid(void);
74void audio_set_prev_elapsed(unsigned long setting);
75bool audio_is_playing(void);
76bool audio_is_paused(void);
73 77
78/* Define one constant that includes recording related functionality */
79#if defined(HAVE_RECORDING) && !defined(SIMULATOR)
80#define AUDIO_HAVE_RECORDING
81#endif
82
83enum {
84 Q_NULL = 0,
85 Q_AUDIO_PLAY = 1,
86 Q_AUDIO_STOP,
87 Q_AUDIO_PAUSE,
88 Q_AUDIO_SKIP,
89 Q_AUDIO_PRE_FF_REWIND,
90 Q_AUDIO_FF_REWIND,
91 Q_AUDIO_CHECK_NEW_TRACK,
92 Q_AUDIO_FLUSH,
93 Q_AUDIO_TRACK_CHANGED,
94 Q_AUDIO_DIR_SKIP,
95 Q_AUDIO_POSTINIT,
96 Q_AUDIO_FILL_BUFFER,
97 Q_AUDIO_FINISH_LOAD,
98 Q_CODEC_REQUEST_COMPLETE,
99 Q_CODEC_REQUEST_FAILED,
100
101 Q_CODEC_LOAD,
102 Q_CODEC_LOAD_DISK,
103
104#ifdef AUDIO_HAVE_RECORDING
105 Q_ENCODER_LOAD_DISK,
106 Q_ENCODER_RECORD,
107#endif
74 108
75#if CONFIG_CODEC == SWCODEC /* This #ifdef is better here than gui/wps.c */ 109 Q_CODEC_DO_CALLBACK,
76extern void audio_next_dir(void); 110};
77extern void audio_prev_dir(void); 111
112#if CONFIG_CODEC == SWCODEC
113void audio_next_dir(void);
114void audio_prev_dir(void);
78#else 115#else
79#define audio_next_dir() ({ }) 116#define audio_next_dir() ({ })
80#define audio_prev_dir() ({ }) 117#define audio_prev_dir() ({ })
81#endif 118#endif
82 119
83#endif 120#endif
84
85