comparison src/sexypsf/xmms.c @ 1090:3bcb772fa1b5 trunk

[svn] - sexypsf: convert to plugin API v2
author nenolod
date Thu, 24 May 2007 23:16:36 -0700
parents 914c96de3244
children 2ae8155baef1
comparison
equal deleted inserted replaced
1089:f61ed3f66f2a 1090:3bcb772fa1b5
43 static gchar *get_title_psf(gchar *fn); 43 static gchar *get_title_psf(gchar *fn);
44 static int paused; 44 static int paused;
45 static GThread *dethread; 45 static GThread *dethread;
46 static PSFINFO *PSFInfo=NULL; 46 static PSFINFO *PSFInfo=NULL;
47 47
48
49 InputPlugin *get_iplugin_info(void)
50 {
51 sexypsf_ip.description = "PSF Module Decoder";
52 return &sexypsf_ip;
53 }
54
55 static int is_our_fd(gchar *filename, VFSFile *file) { 48 static int is_our_fd(gchar *filename, VFSFile *file) {
56 gchar magic[4], *tmps; 49 gchar magic[4], *tmps;
57 // Filter out psflib [we use them, but we can't play them] 50 // Filter out psflib [we use them, but we can't play them]
58 static const gchar *teststr = "psflib"; 51 static const gchar *teststr = "psflib";
59 if (strlen(teststr) < strlen(filename)) { 52 if (strlen(teststr) < strlen(filename)) {
262 255
263 InputPlugin sexypsf_ip = 256 InputPlugin sexypsf_ip =
264 { 257 {
265 NULL, 258 NULL,
266 NULL, 259 NULL,
267 "Plays PSF1 files.", 260 "PSF Audio Plugin",
268 NULL, 261 NULL,
269 NULL, 262 NULL,
270 NULL, 263 NULL,
271 NULL, 264 NULL,
272 NULL, 265 NULL,
290 NULL, 283 NULL,
291 NULL, 284 NULL,
292 is_our_fd, 285 is_our_fd,
293 sexypsf_fmts, 286 sexypsf_fmts,
294 }; 287 };
288
289 InputPlugin *sexypsf_iplist[] = { &sexypsf_ip, NULL };
290
291 DECLARE_PLUGIN(sexypsf, NULL, NULL, sexypsf_iplist, NULL, NULL, NULL, NULL);