Mercurial > hg > qm-vamp-plugins
comparison libmain.cpp @ 3:991d0fe8bb27
* Add plugin entry point and make it build correctly
author | Chris Cannam <c.cannam@qmul.ac.uk> |
---|---|
date | Thu, 06 Apr 2006 12:02:34 +0000 |
parents | |
children | 507f923a93e8 |
comparison
equal
deleted
inserted
replaced
2:c10bbd8fe62a | 3:991d0fe8bb27 |
---|---|
1 /* -*- c-basic-offset: 4 indent-tabs-mode: nil -*- vi:set ts=8 sts=4 sw=4: */ | |
2 | |
3 /* | |
4 QM Vamp Plugin Set | |
5 | |
6 Centre for Digital Music, Queen Mary, University of London. | |
7 All rights reserved. | |
8 */ | |
9 | |
10 #include <vamp/vamp.h> | |
11 #include <vamp-sdk/PluginAdapter.h> | |
12 | |
13 #include "plugins/BeatDetect.h" | |
14 #include "plugins/ChromagramPlugin.h" | |
15 #include "plugins/TonalChangeDetect.h" | |
16 | |
17 static Vamp::PluginAdapter<BeatDetector> beatDetectorAdapter; | |
18 static Vamp::PluginAdapter<ChromagramPlugin> chromagramPluginAdapter; | |
19 static Vamp::PluginAdapter<TonalChangeDetect> tonalChangeDetectorAdapter; | |
20 | |
21 const VampPluginDescriptor *vampGetPluginDescriptor(unsigned int index) | |
22 { | |
23 switch (index) { | |
24 case 0: return beatDetectorAdapter.getDescriptor(); | |
25 case 1: return chromagramPluginAdapter.getDescriptor(); | |
26 case 2: return tonalChangeDetectorAdapter.getDescriptor(); | |
27 default: return 0; | |
28 } | |
29 } | |
30 |