File: midi-mappings.h

package info (click to toggle)
lsp-plugins 1.2.5-1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 91,856 kB
  • sloc: cpp: 427,831; xml: 57,779; makefile: 9,961; php: 1,005; sh: 18
file content (40 lines) | stat: -rw-r--r-- 894 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
#pragma once

#include "../../plugin.h"

static CLAP_CONSTEXPR const char CLAP_EXT_MIDI_MAPPINGS[] = "clap.midi-mappings.draft/0";

#ifdef __cplusplus
extern "C" {
#endif

enum {
   CLAP_MIDI_MAPPING_CC7,
   CLAP_MIDI_MAPPING_CC14,
   CLAP_MIDI_MAPPING_RPN,
   CLAP_MIDI_MAPPING_NRPN,
};
typedef int32_t clap_midi_mapping_type;

typedef struct clap_midi_mapping {
   int32_t channel;
   int32_t number;
   clap_id param_id;
} clap_midi_mapping_t;

typedef struct clap_plugin_midi_mappings {
   // [main-thread]
   uint32_t(CLAP_ABI *count)(const clap_plugin_t *plugin);

   // [main-thread]
   bool(CLAP_ABI *get)(const clap_plugin_t *plugin, uint32_t index, clap_midi_mapping_t *mapping);
} clap_plugin_midi_mappings_t;

typedef struct clap_host_midi_mappings {
   // [main-thread]
   void(CLAP_ABI *changed)(const clap_host_t *host);
} clap_host_midi_mappings_t;

#ifdef __cplusplus
}
#endif