summaryrefslogtreecommitdiff
path: root/deadbeef.h
diff options
context:
space:
mode:
authorGravatar waker <wakeroid@gmail.com>2012-05-17 20:50:47 +0200
committerGravatar waker <wakeroid@gmail.com>2012-05-17 20:50:47 +0200
commit816d87e1d38dc0fecbe1fa47794b2d7a18d2e321 (patch)
tree6753620029a94976bf27d474156723dd2f403813 /deadbeef.h
parentaf55e42f2422f8734bc80fb8a58eba80b29937ef (diff)
fixed many calls to pl_find_meta[_raw] being called without pl_lock;
added debug pl_ensure_lock function which asserts when pl_lock is not set when it is required; added new API functions for thread-safe metadata access
Diffstat (limited to 'deadbeef.h')
-rw-r--r--deadbeef.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/deadbeef.h b/deadbeef.h
index 73452c4e..6de9e9d0 100644
--- a/deadbeef.h
+++ b/deadbeef.h
@@ -61,6 +61,7 @@ extern "C" {
// api version history:
// 9.9 -- devel
+// 1.4 -- deadbeef-0.5.5
// 1.3 -- deadbeef-0.5.3
// 1.2 -- deadbeef-0.5.2
// 1.1 -- deadbeef-0.5.1
@@ -750,10 +751,20 @@ typedef struct {
void (*metacache_unref) (const char *str);
// this function must return original un-overriden value (ignoring the keys prefixed with '!')
+ // it's not thread-safe, and must be used under the same conditions as the
+ // pl_find_meta
const char *(*pl_find_meta_raw) (DB_playItem_t *it, const char *key);
// ******* new 1.3 APIs ********
int (*streamer_dsp_chain_save) (void);
+
+ // ******* new 1.4 APIs ********
+ int (*pl_get_meta) (DB_playItem_t *it, const char *key, char *val, int size);
+ int (*pl_get_meta_raw) (DB_playItem_t *it, const char *key, char *val, int size);
+ int (*plt_get_meta) (ddb_playlist_t *handle, const char *key, char *val, int size);
+
+ // fast way to test if a field exists in playitem
+ int (*pl_meta_exists) (DB_playItem_t *it, const char *key);
} DB_functions_t;
// NOTE: an item placement must be selected like this