1 /*
2 * Copyright (c) 2015-2016 Hanspeter Portner (dev@open-music-kontrollers.ch)
3 *
4 * This is free software: you can redistribute it and/or modify
5 * it under the terms of the Artistic License 2.0 as published by
6 * The Perl Foundation.
7 *
8 * This source is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * Artistic License 2.0 for more details.
12 *
13 * You should have received a copy of the Artistic License 2.0
14 * along the source as a COPYING file. If not, obtain it from
15 * http://www.perlfoundation.org/artistic_license_2_0.
16 */
17
18 #include <synthpod_lv2.h>
19 #include <sandbox_ui.h>
20
21 const LV2UI_Descriptor synthpod_common_1_ui = {
22 .URI = SYNTHPOD_COMMON_UI_URI,
23 .instantiate = sandbox_ui_instantiate,
24 .cleanup = sandbox_ui_cleanup,
25 .port_event = sandbox_ui_port_event,
26 .extension_data = sandbox_ui_extension_data
27 };
28
29 const LV2UI_Descriptor synthpod_common_2_kx = {
30 .URI = SYNTHPOD_COMMON_KX_URI,
31 .instantiate = sandbox_ui_instantiate,
32 .cleanup = sandbox_ui_cleanup,
33 .port_event = sandbox_ui_port_event,
34 .extension_data = NULL
35 };
36
37 #ifdef _WIN32
38 __declspec(dllexport)
39 #else
40 __attribute__((visibility("default")))
41 #endif
42 const LV2UI_Descriptor*
lv2ui_descriptor(uint32_t index)43 lv2ui_descriptor(uint32_t index)
44 {
45 switch(index)
46 {
47 case 0:
48 return &synthpod_common_1_ui;
49 case 1:
50 return &synthpod_common_2_kx;
51
52 default:
53 return NULL;
54 }
55 }
56