annotate src/sid/xs_player.h @ 2647:5808b64d3f68

branch merge
author Paula Stanciu <paula.stanciu@gmail.com>
date Sun, 25 May 2008 21:29:48 +0300
parents f4dce14ed238
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
735
6c3c7b841382 [svn] - sync audacious-sid with latest xmms-sid, from Matti Hamalainen (ccr).
nenolod
parents:
diff changeset
1 #ifndef XS_PLAYER_H
6c3c7b841382 [svn] - sync audacious-sid with latest xmms-sid, from Matti Hamalainen (ccr).
nenolod
parents:
diff changeset
2 #define XS_PLAYER_H
6c3c7b841382 [svn] - sync audacious-sid with latest xmms-sid, from Matti Hamalainen (ccr).
nenolod
parents:
diff changeset
3
6c3c7b841382 [svn] - sync audacious-sid with latest xmms-sid, from Matti Hamalainen (ccr).
nenolod
parents:
diff changeset
4 #include "xmms-sid.h"
6c3c7b841382 [svn] - sync audacious-sid with latest xmms-sid, from Matti Hamalainen (ccr).
nenolod
parents:
diff changeset
5 #include "xs_config.h"
6c3c7b841382 [svn] - sync audacious-sid with latest xmms-sid, from Matti Hamalainen (ccr).
nenolod
parents:
diff changeset
6
6c3c7b841382 [svn] - sync audacious-sid with latest xmms-sid, from Matti Hamalainen (ccr).
nenolod
parents:
diff changeset
7 #ifdef __cplusplus
6c3c7b841382 [svn] - sync audacious-sid with latest xmms-sid, from Matti Hamalainen (ccr).
nenolod
parents:
diff changeset
8 extern "C" {
6c3c7b841382 [svn] - sync audacious-sid with latest xmms-sid, from Matti Hamalainen (ccr).
nenolod
parents:
diff changeset
9 #endif
6c3c7b841382 [svn] - sync audacious-sid with latest xmms-sid, from Matti Hamalainen (ccr).
nenolod
parents:
diff changeset
10
2507
251336bee085 Cosmetic cleanups, synchronized from XMMS-SID.
Matti Hamalainen <ccr@tnsp.org>
parents: 1578
diff changeset
11 struct xs_status_t;
735
6c3c7b841382 [svn] - sync audacious-sid with latest xmms-sid, from Matti Hamalainen (ccr).
nenolod
parents:
diff changeset
12
6c3c7b841382 [svn] - sync audacious-sid with latest xmms-sid, from Matti Hamalainen (ccr).
nenolod
parents:
diff changeset
13 typedef struct {
2509
1223e8510d8a Change tabs to 4 spaces, everywhere.
Matti Hamalainen <ccr@tnsp.org>
parents: 2507
diff changeset
14 gint plrIdent;
1223e8510d8a Change tabs to 4 spaces, everywhere.
Matti Hamalainen <ccr@tnsp.org>
parents: 2507
diff changeset
15 gboolean (*plrProbe)(xs_file_t *);
1223e8510d8a Change tabs to 4 spaces, everywhere.
Matti Hamalainen <ccr@tnsp.org>
parents: 2507
diff changeset
16 gboolean (*plrInit)(struct xs_status_t *);
1223e8510d8a Change tabs to 4 spaces, everywhere.
Matti Hamalainen <ccr@tnsp.org>
parents: 2507
diff changeset
17 void (*plrClose)(struct xs_status_t *);
1223e8510d8a Change tabs to 4 spaces, everywhere.
Matti Hamalainen <ccr@tnsp.org>
parents: 2507
diff changeset
18 gboolean (*plrInitSong)(struct xs_status_t *);
2593
f4dce14ed238 Indentation cleanups.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
19 guint (*plrFillBuffer)(struct xs_status_t *, gchar *, guint);
2509
1223e8510d8a Change tabs to 4 spaces, everywhere.
Matti Hamalainen <ccr@tnsp.org>
parents: 2507
diff changeset
20 gboolean (*plrLoadSID)(struct xs_status_t *, gchar *);
1223e8510d8a Change tabs to 4 spaces, everywhere.
Matti Hamalainen <ccr@tnsp.org>
parents: 2507
diff changeset
21 void (*plrDeleteSID)(struct xs_status_t *);
1223e8510d8a Change tabs to 4 spaces, everywhere.
Matti Hamalainen <ccr@tnsp.org>
parents: 2507
diff changeset
22 xs_tuneinfo_t* (*plrGetSIDInfo)(const gchar *);
1223e8510d8a Change tabs to 4 spaces, everywhere.
Matti Hamalainen <ccr@tnsp.org>
parents: 2507
diff changeset
23 gboolean (*plrUpdateSIDInfo)(struct xs_status_t *);
1223e8510d8a Change tabs to 4 spaces, everywhere.
Matti Hamalainen <ccr@tnsp.org>
parents: 2507
diff changeset
24 void (*plrFlush)(struct xs_status_t *);
2507
251336bee085 Cosmetic cleanups, synchronized from XMMS-SID.
Matti Hamalainen <ccr@tnsp.org>
parents: 1578
diff changeset
25 } xs_player_t;
735
6c3c7b841382 [svn] - sync audacious-sid with latest xmms-sid, from Matti Hamalainen (ccr).
nenolod
parents:
diff changeset
26
6c3c7b841382 [svn] - sync audacious-sid with latest xmms-sid, from Matti Hamalainen (ccr).
nenolod
parents:
diff changeset
27
2507
251336bee085 Cosmetic cleanups, synchronized from XMMS-SID.
Matti Hamalainen <ccr@tnsp.org>
parents: 1578
diff changeset
28 typedef struct xs_status_t {
2593
f4dce14ed238 Indentation cleanups.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
29 gint audioFrequency, /* Audio settings */
f4dce14ed238 Indentation cleanups.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
30 audioChannels,
f4dce14ed238 Indentation cleanups.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
31 audioBitsPerSample,
f4dce14ed238 Indentation cleanups.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
32 oversampleFactor; /* Factor of oversampling */
f4dce14ed238 Indentation cleanups.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
33 AFormat audioFormat;
f4dce14ed238 Indentation cleanups.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
34 gboolean oversampleEnable; /* TRUE after sidEngine initialization,
f4dce14ed238 Indentation cleanups.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
35 if xs_cfg.oversampleEnable == TRUE and
f4dce14ed238 Indentation cleanups.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
36 emulation backend supports oversampling.
f4dce14ed238 Indentation cleanups.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
37 */
f4dce14ed238 Indentation cleanups.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
38 void *sidEngine; /* SID-emulation internal engine data */
f4dce14ed238 Indentation cleanups.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
39 xs_player_t *sidPlayer; /* Selected player engine */
f4dce14ed238 Indentation cleanups.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
40 gboolean isError,
f4dce14ed238 Indentation cleanups.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
41 isPlaying,
f4dce14ed238 Indentation cleanups.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
42 isInitialized;
f4dce14ed238 Indentation cleanups.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
43 gint currSong, /* Current sub-tune */
f4dce14ed238 Indentation cleanups.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
44 lastTime;
735
6c3c7b841382 [svn] - sync audacious-sid with latest xmms-sid, from Matti Hamalainen (ccr).
nenolod
parents:
diff changeset
45
2593
f4dce14ed238 Indentation cleanups.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
46 xs_tuneinfo_t *tuneInfo;
2507
251336bee085 Cosmetic cleanups, synchronized from XMMS-SID.
Matti Hamalainen <ccr@tnsp.org>
parents: 1578
diff changeset
47 } xs_status_t;
735
6c3c7b841382 [svn] - sync audacious-sid with latest xmms-sid, from Matti Hamalainen (ccr).
nenolod
parents:
diff changeset
48
6c3c7b841382 [svn] - sync audacious-sid with latest xmms-sid, from Matti Hamalainen (ccr).
nenolod
parents:
diff changeset
49
6c3c7b841382 [svn] - sync audacious-sid with latest xmms-sid, from Matti Hamalainen (ccr).
nenolod
parents:
diff changeset
50 /* Global variables
6c3c7b841382 [svn] - sync audacious-sid with latest xmms-sid, from Matti Hamalainen (ccr).
nenolod
parents:
diff changeset
51 */
2509
1223e8510d8a Change tabs to 4 spaces, everywhere.
Matti Hamalainen <ccr@tnsp.org>
parents: 2507
diff changeset
52 extern InputPlugin xs_plugin_ip;
735
6c3c7b841382 [svn] - sync audacious-sid with latest xmms-sid, from Matti Hamalainen (ccr).
nenolod
parents:
diff changeset
53
2509
1223e8510d8a Change tabs to 4 spaces, everywhere.
Matti Hamalainen <ccr@tnsp.org>
parents: 2507
diff changeset
54 extern xs_status_t xs_status;
735
6c3c7b841382 [svn] - sync audacious-sid with latest xmms-sid, from Matti Hamalainen (ccr).
nenolod
parents:
diff changeset
55 XS_MUTEX_H(xs_status);
6c3c7b841382 [svn] - sync audacious-sid with latest xmms-sid, from Matti Hamalainen (ccr).
nenolod
parents:
diff changeset
56
6c3c7b841382 [svn] - sync audacious-sid with latest xmms-sid, from Matti Hamalainen (ccr).
nenolod
parents:
diff changeset
57
6c3c7b841382 [svn] - sync audacious-sid with latest xmms-sid, from Matti Hamalainen (ccr).
nenolod
parents:
diff changeset
58 #ifdef __cplusplus
6c3c7b841382 [svn] - sync audacious-sid with latest xmms-sid, from Matti Hamalainen (ccr).
nenolod
parents:
diff changeset
59 }
6c3c7b841382 [svn] - sync audacious-sid with latest xmms-sid, from Matti Hamalainen (ccr).
nenolod
parents:
diff changeset
60 #endif
6c3c7b841382 [svn] - sync audacious-sid with latest xmms-sid, from Matti Hamalainen (ccr).
nenolod
parents:
diff changeset
61 #endif /* XS_PLAYER_H */