Chris@23: Chris@23: // This is a skeleton file for use in creating your own plugin Chris@23: // libraries. Replace MyPlugin and myPlugin throughout with the name Chris@23: // of your first plugin class, and fill in the gaps as appropriate. Chris@23: Chris@23: Chris@23: #include Chris@23: #include Chris@23: Chris@23: #include "MyPlugin.h" Chris@23: Chris@23: Chris@23: // Declare one static adapter here for each plugin class in this library. Chris@23: Chris@23: static Vamp::PluginAdapter myPluginAdapter; Chris@23: Chris@23: Chris@23: // This is the entry-point for the library, and the only function that Chris@23: // needs to be publicly exported. Chris@23: Chris@23: const VampPluginDescriptor * Chris@23: vampGetPluginDescriptor(unsigned int version, unsigned int index) Chris@23: { Chris@23: if (version < 1) return 0; Chris@23: Chris@23: // Return a different plugin adaptor's descriptor for each index, Chris@23: // and return 0 for the first index after you run out of plugins. Chris@23: // (That's how the host finds out how many plugins are in this Chris@23: // library.) Chris@23: Chris@23: switch (index) { Chris@23: case 0: return myPluginAdapter.getDescriptor(); Chris@23: default: return 0; Chris@23: } Chris@23: } Chris@23: Chris@23: