1 /***************************************************************************
3 * Open \______ \ ____ ____ | | _\_ |__ _______ ___
4 * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
5 * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
6 * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
10 * Code that has been in mpeg.c/h before, now creating an encapsulated play
11 * data module, to be used by other sources than file playback as well.
13 * Copyright (C) 2004 by Linus Nielsen Feltzing
15 * All files in this archive are subject to the GNU General Public License.
16 * See the file COPYING in the source tree root for full license agreement.
18 * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
19 * KIND, either express or implied.
21 ****************************************************************************/
22 #ifndef _MP3_PLAYBACK_H_
23 #define _MP3_PLAYBACK_H_
27 /* functions formerly in mpeg.c */
28 void mp3_init(int volume
, int bass
, int treble
, int balance
, int loudness
,
29 int avc
, int channel_config
, int stereo_width
,
30 int mdb_strength
, int mdb_harmonics
,
31 int mdb_center
, int mdb_shape
, bool mdb_enable
,
34 /* exported just for mpeg.c, to keep the recording there */
35 #if (CONFIG_CODEC == MAS3587F) || (CONFIG_CODEC == MAS3539F)
36 void demand_irq_enable(bool on
);
39 /* new functions, exported to plugin API */
40 void mp3_play_init(void);
41 void mp3_play_data(const unsigned char* start
, int size
,
42 void (*get_more
)(unsigned char** start
, size_t* size
) /* callback fn */
44 void mp3_play_pause(bool play
);
45 bool mp3_pause_done(void);
46 void mp3_play_stop(void);
47 long mp3_get_playtime(void);
48 void mp3_reset_playtime(void);
49 bool mp3_is_playing(void);
50 unsigned char* mp3_get_pos(void);
51 void mp3_shutdown(void);
53 #endif /* #ifndef _MP3_PLAYBACK_H_ */