269
|
1 #ifndef XS_LENGTH_H
|
|
2 #define XS_LENGTH_H
|
|
3
|
|
4 #include "xmms-sid.h"
|
|
5 #include "xs_md5.h"
|
|
6
|
|
7 #ifdef __cplusplus
|
|
8 extern "C" {
|
|
9 #endif
|
|
10
|
|
11 /*
|
|
12 * Defines and typedefs
|
|
13 */
|
|
14 typedef struct _t_xs_sldb_node {
|
|
15 t_xs_md5hash md5Hash; /* 128-bit MD5 hash-digest */
|
|
16 gint nLengths; /* Number of lengths */
|
|
17 gint32 sLengths[XS_STIL_MAXENTRY+1];
|
|
18 /* Lengths in seconds */
|
|
19
|
|
20 struct _t_xs_sldb_node *pPrev, *pNext;
|
|
21 } t_xs_sldb_node;
|
|
22
|
|
23 typedef struct {
|
|
24 t_xs_sldb_node *pNodes,
|
|
25 **ppIndex;
|
|
26 gint n;
|
|
27 } t_xs_sldb;
|
|
28
|
|
29
|
|
30 /*
|
|
31 * Functions
|
|
32 */
|
|
33 gint xs_sldb_read(t_xs_sldb *, gchar *);
|
|
34 gint xs_sldb_index(t_xs_sldb *);
|
|
35 void xs_sldb_free(t_xs_sldb *);
|
|
36 t_xs_sldb_node * xs_sldb_get(t_xs_sldb *, gchar *);
|
|
37
|
|
38
|
|
39 gint xs_songlen_init(void);
|
|
40 void xs_songlen_close(void);
|
|
41 t_xs_sldb_node * xs_songlen_get(gchar *);
|
|
42
|
|
43 #ifdef __cplusplus
|
|
44 }
|
|
45 #endif
|
|
46 #endif /* XS_LENGTH_H */
|