Control Surface  1.1.0
MIDI Control Surface library for Arduino
BankConfig.hpp
Go to the documentation of this file.
1 /* ✔ */
2 
3 #pragma once
4 
5 #include <Def/Def.hpp>
6 
8 
9 /**
10  * @brief An enumeration of the different bank types.
11  */
12 enum BankType {
13  /**
14  * @brief Change the offset of the address (i.e. Controller number or
15  * Note number) of the element.
16  */
18  /**
19  * @brief Change the offset of the channel number of the element.
20  */
22  /**
23  * @brief Change the offset of the cable number of the element
24  * (experimental).
25  * @todo Implement
26  */
28 };
29 
30 template <setting_t N>
31 class Bank;
32 class OutputBank;
33 
34 /**
35  * @brief A struct for selecting the bank of BankableMIDIInput%s and the
36  * bank type.
37  */
38 template <setting_t N>
39 struct BankConfig {
41  : bank(bank), type(type) {}
43  const BankType type;
44 };
45 
46 /**
47  * @brief A struct for selecting the bank of BankableMIDIOutput%s and the
48  * bank type.
49  */
52  : bank(bank), type(type) {}
54  const BankType type;
55 };
56 
OutputBank
A class for changing the address of BankableMIDIOutputs.
Definition: Bank.hpp:20
Bank
A class that groups Bankable BankableMIDIOutputs and BankableMIDIInputs, and allows the user to chang...
Definition: Bank.hpp:77
Def.hpp
BEGIN_CS_NAMESPACE
#define BEGIN_CS_NAMESPACE
Definition: Settings/NamespaceSettings.hpp:9
OutputBankConfig::bank
OutputBank & bank
Definition: BankConfig.hpp:53
BankConfig::bank
Bank< N > & bank
Definition: BankConfig.hpp:42
END_CS_NAMESPACE
#define END_CS_NAMESPACE
Definition: Settings/NamespaceSettings.hpp:10
OutputBankConfig::OutputBankConfig
OutputBankConfig(OutputBank &bank, BankType type=CHANGE_ADDRESS)
Definition: BankConfig.hpp:51
OutputBankConfig::type
const BankType type
Definition: BankConfig.hpp:54
CHANGE_CHANNEL
Change the offset of the channel number of the element.
Definition: BankConfig.hpp:21
BankConfig::BankConfig
BankConfig(Bank< N > &bank, BankType type=CHANGE_ADDRESS)
Definition: BankConfig.hpp:40
CHANGE_CABLENB
Change the offset of the cable number of the element (experimental).
Definition: BankConfig.hpp:27
BankType
BankType
An enumeration of the different bank types.
Definition: BankConfig.hpp:12
BankConfig
A struct for selecting the bank of BankableMIDIInputs and the bank type.
Definition: BankConfig.hpp:39
CHANGE_ADDRESS
Change the offset of the address (i.e.
Definition: BankConfig.hpp:17
OutputBankConfig
A struct for selecting the bank of BankableMIDIOutputs and the bank type.
Definition: BankConfig.hpp:50
BankConfig::type
const BankType type
Definition: BankConfig.hpp:43