summaryrefslogtreecommitdiff
path: root/plugins/artwork/artwork.h
blob: 816ca3491bbcc6f7c4c8dee42b437ee662272dd0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#ifndef __ARTWORK_H
#define __ARTWORK_H

#include "../../deadbeef.h"

typedef void (*artwork_callback) (const char *artist, const char *album);

char*
fetch (const char *url);

int
fetch_to_file (const char *url, const char *filename);

int
fetch_to_stream (const char *url, FILE *stream);

typedef struct {
    DB_misc_t plugin;
    // returns filename of cached image, or NULL
    char* (*get_album_art) (DB_playItem_t *track, artwork_callback callback);
} DB_artwork_plugin_t;

#endif /*__ARTWORK_H*/