diff vamp/vamp.h @ 167:31eda4b11f2b

* First bit of Vamp v2 work -- add an optional duration to features in a backward compatible way. Warning: this code is unstable and experimental and may change significantly in the coming weeks.
author cannam
date Thu, 17 Jul 2008 08:52:26 +0000
parents 7fc1041daa9d
children 006a775133b1
line wrap: on
line diff
--- a/vamp/vamp.h	Wed Jul 09 11:00:16 2008 +0000
+++ b/vamp/vamp.h	Thu Jul 17 08:52:26 2008 +0000
@@ -50,7 +50,7 @@
  * See also the vampApiVersion field in the plugin descriptor, and the
  * hostApiVersion argument to the vampGetPluginDescriptor function.
  */
-#define VAMP_API_VERSION 1
+#define VAMP_API_VERSION 2
 
 /**
  * C language API for Vamp plugins.
@@ -184,6 +184,19 @@
 
 } VampFeature;
 
+typedef struct _VampFeatureV2
+{
+    /** 1 if the feature has a duration. */
+    int hasDuration;
+
+    /** Seconds component of duratiion. */
+    int durationSec;
+
+    /** Nanoseconds component of duration. */
+    int durationNsec;
+
+} VampFeatureV2;
+
 typedef struct _VampFeatureList
 {
     /** Number of features in this feature list. */
@@ -192,6 +205,9 @@
     /** Features in this feature list.  May be NULL if featureCount is zero. */
     VampFeature *features;
 
+    /** Vamp 2.0 extended information for features in this feature list. */
+    VampFeatureV2 *featuresV2;
+
 } VampFeatureList;
 
 typedef enum