comparison plugin/FeatureExtractionPluginFactory.cpp @ 408:115f60df1e4d

* Speed up spectrogram painting by releasing mutex in FFTDataServer while calculating data prior to writing it, and by adding whole-column value query methods to FFT objects * Add paint cache to Thumbwheel -- repaints of this widget were slowing down the whole spectrogram repaint * More uses of MutexLocker (named and with debug) and more profile points * Make startup much quicker some of the time, with OSC server in place
author Chris Cannam
date Thu, 08 May 2008 14:46:22 +0000
parents 9203b82a8c53
children 9e1e12d1fbc3
comparison
equal deleted inserted replaced
407:88ad01799040 408:115f60df1e4d
27 #include <QFileInfo> 27 #include <QFileInfo>
28 #include <QTextStream> 28 #include <QTextStream>
29 29
30 #include <iostream> 30 #include <iostream>
31 31
32 #include "base/Profiler.h"
33
32 //#define DEBUG_PLUGIN_SCAN_AND_INSTANTIATE 1 34 //#define DEBUG_PLUGIN_SCAN_AND_INSTANTIATE 1
33 35
34 class PluginDeletionNotifyAdapter : public Vamp::HostExt::PluginWrapper { 36 class PluginDeletionNotifyAdapter : public Vamp::HostExt::PluginWrapper {
35 public: 37 public:
36 PluginDeletionNotifyAdapter(Vamp::Plugin *plugin, 38 PluginDeletionNotifyAdapter(Vamp::Plugin *plugin,
106 } 108 }
107 109
108 std::vector<QString> 110 std::vector<QString>
109 FeatureExtractionPluginFactory::getPluginIdentifiers() 111 FeatureExtractionPluginFactory::getPluginIdentifiers()
110 { 112 {
113 Profiler profiler("FeatureExtractionPluginFactory::getPluginIdentifiers");
114
111 std::vector<QString> rv; 115 std::vector<QString> rv;
112 std::vector<QString> path = getPluginPath(); 116 std::vector<QString> path = getPluginPath();
113 117
114 for (std::vector<QString>::iterator i = path.begin(); i != path.end(); ++i) { 118 for (std::vector<QString>::iterator i = path.begin(); i != path.end(); ++i) {
115 119
294 298
295 Vamp::Plugin * 299 Vamp::Plugin *
296 FeatureExtractionPluginFactory::instantiatePlugin(QString identifier, 300 FeatureExtractionPluginFactory::instantiatePlugin(QString identifier,
297 float inputSampleRate) 301 float inputSampleRate)
298 { 302 {
303 Profiler profiler("FeatureExtractionPluginFactory::instantiatePlugin");
304
299 Vamp::Plugin *rv = 0; 305 Vamp::Plugin *rv = 0;
300 Vamp::PluginHostAdapter *plugin = 0; 306 Vamp::PluginHostAdapter *plugin = 0;
301 307
302 const VampPluginDescriptor *descriptor = 0; 308 const VampPluginDescriptor *descriptor = 0;
303 int index = 0; 309 int index = 0;