BuGUI
BUtton Grid User Interface
Loading...
Searching...
No Matches
midi_component.hpp
1#pragma once
2#include "component.hpp"
3
4namespace bugui
5{
6// in message type
9template <typename Device, typename Component>
10struct in_message_t final
11{
12 using type = void;
13};
14
16template <typename Device, has_explicit_in_type Component>
17struct in_message_t<Device, Component> final
18{
19 using type = Component;
20};
21
25template <has_in_type Device, typename Component>
28{
29 using type = Device;
30};
31
32// out message type
35template <typename Device, typename Component>
36struct out_message_t final
37{
38 using type = void;
39};
40
42template <typename Device, has_explicit_out_type Component>
43struct out_message_t<Device, Component> final
44{
45 using type = Component;
46};
47
51template <has_out_type Device, typename Component>
54{
55 using type = Device;
56};
57
60template <typename Device, typename Component>
61 requires
62 speaks_midi<typename protocol_t<Device, Component>::type>
63 struct component<Device, Component> final
64{
65 using color_t = color_t<Device, Component>::type;
66 using protocol_t = protocol_t<Device, Component>::type;
67 using in_message_t = in_message_t<Device, Component>::type;
68 using out_message_t = out_message_t<Device, Component>::type;
69 using init_t = init_t<Device, Component>::type;
70 using clear_t = clear_t<Device, Component>::type;
71};
72
73}
Definition midi_message.hpp:87
Definition midi_message.hpp:137
Primary template. To be specialized.
Definition component.hpp:99
Primary template for a Device and a Component that do not feature an in declaration.
Definition midi_component.hpp:11
Primary template for a Device and a Component that do not feature an out declaration.
Definition midi_component.hpp:37