myMPD
Internal API documentation
Loading...
Searching...
No Matches
albumart.c File Reference

myMPD Albumart API More...

#include "compile_time.h"
#include "src/mympd_api/albumart.h"
#include "src/lib/album.h"
#include "src/lib/api.h"
#include "src/lib/cache/cache_disk.h"
#include "src/lib/cache/cache_disk_images.h"
#include "src/lib/cache/cache_rax_album.h"
#include "src/lib/json/json_print.h"
#include "src/lib/json/json_rpc.h"
#include "src/lib/log.h"
#include "src/lib/mem.h"
#include "src/lib/mimetype.h"
#include "src/lib/sds_extras.h"
#include "src/mympd_api/trigger.h"
#include "src/mympd_client/errorhandler.h"
#include "src/mympd_client/search.h"
#include <string.h>
Include dependency graph for albumart.c:

Functions

sds mympd_api_albumart_getcover_by_album_id (struct t_partition_state *partition_state, struct t_cache *album_cache, sds buffer, unsigned request_id, sds albumid, unsigned size)
 
sds mympd_api_albumart_getcover_by_uri (struct t_mympd_state *mympd_state, struct t_partition_state *partition_state, sds buffer, unsigned request_id, unsigned long conn_id, sds uri, void **binary)
 

Detailed Description

myMPD Albumart API

Function Documentation

◆ mympd_api_albumart_getcover_by_album_id()

sds mympd_api_albumart_getcover_by_album_id ( struct t_partition_state partition_state,
struct t_cache album_cache,
sds  buffer,
unsigned  request_id,
sds  albumid,
unsigned  size 
)

Reads the albumart by album id

Parameters
partition_statepointer to partition specific states
album_cachepointer to album cache
bufferalready allocated sds string for the jsonrpc response
request_idrequest id
albumidthe album id
sizesize of the albumart
Returns
jsonrpc response

◆ mympd_api_albumart_getcover_by_uri()

sds mympd_api_albumart_getcover_by_uri ( struct t_mympd_state mympd_state,
struct t_partition_state partition_state,
sds  buffer,
unsigned  request_id,
unsigned long  conn_id,
sds  uri,
void **  binary 
)

Reads the albumart from mpd by song uri

Parameters
mympd_statepointer to mympd state
partition_statepointer to partition specific states
bufferalready allocated sds string for the jsonrpc response
request_idrequest id
conn_idmongoose connection id
uriuri to get cover for
binarypointer to an already allocated sds string for the binary response
Returns
jsonrpc response