1 /***************************************************************************
3 * Open \______ \ ____ ____ | | _\_ |__ _______ ___
4 * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
5 * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
6 * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
10 * Copyright (C) 2005 by Michiel van der Kolk
12 * All files in this archive are subject to the GNU General Public License.
13 * See the file COPYING in the source tree root for full license agreement.
15 * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
16 * KIND, either express or implied.
18 ****************************************************************************/
22 #ifdef ROCKBOX_LITTLE_ENDIAN
23 #define BE32(_x_) (((_x_ & 0xff000000) >> 24) | \
24 ((_x_ & 0x00ff0000) >> 8) | \
25 ((_x_ & 0x0000ff00) << 8) | \
26 ((_x_ & 0x000000ff) << 24))
27 #define BE16(_x_) ( ((_x_&0xFF00) >> 8)|((_x_&0xFF)<<8))
33 #define SONGENTRY_SIZE (tagdbheader.songlen+12+tagdbheader.genrelen+4)
34 #define FILEENTRY_SIZE (tagdbheader.filelen+12)
35 #define ALBUMENTRY_SIZE (tagdbheader.albumlen+4+tagdbheader.songarraylen*4)
36 #define ARTISTENTRY_SIZE (tagdbheader.artistlen+tagdbheader.albumarraylen*4)
38 #define FILERECORD2OFFSET(_x_) (tagdbheader.filestart + _x_ * FILEENTRY_SIZE)
40 extern int tagdb_initialized
;
69 extern struct tagdb_header tagdbheader
;
73 void tagdb_shutdown(void);
75 #define TAGDB_VERSION 2
91 extern struct rundb_header rundbheader
;
93 #define RUNDB_VERSION 1