diff examples/SpectralCentroid.cpp @ 49:aa64a46320d4

* Rename "name" and "description" to "identifier" and "name"; add new "description" that actually contains a description
author cannam
date Mon, 26 Feb 2007 18:08:48 +0000
parents f46bf5e0fa42
children 1982246a3902
line wrap: on
line diff
--- a/examples/SpectralCentroid.cpp	Thu Jan 25 13:39:31 2007 +0000
+++ b/examples/SpectralCentroid.cpp	Mon Feb 26 18:08:48 2007 +0000
@@ -56,15 +56,21 @@
 }
 
 string
-SpectralCentroid::getName() const
+SpectralCentroid::getIdentifier() const
 {
     return "spectralcentroid";
 }
 
 string
+SpectralCentroid::getName() const
+{
+    return "Spectral Centroid";
+}
+
+string
 SpectralCentroid::getDescription() const
 {
-    return "Spectral Centroid";
+    return "Calculate the centroid frequency of the spectrum of the input signal";
 }
 
 string
@@ -108,9 +114,10 @@
     OutputList list;
 
     OutputDescriptor d;
-    d.name = "logcentroid";
+    d.identifier = "logcentroid";
+    d.name = "Log Frequency Centroid";
+    d.description = "Centroid of the log weighted frequency spectrum";
     d.unit = "Hz";
-    d.description = "Log Frequency Centroid";
     d.hasFixedBinCount = true;
     d.binCount = 1;
     d.hasKnownExtents = false;
@@ -118,8 +125,9 @@
     d.sampleType = OutputDescriptor::OneSamplePerStep;
     list.push_back(d);
 
-    d.name = "linearcentroid";
-    d.description = "Linear Frequency Centroid";
+    d.identifier = "linearcentroid";
+    d.name = "Linear Frequency Centroid";
+    d.description = "Centroid of the linear frequency spectrum";
     list.push_back(d);
 
     return list;