BEAST - Free Software Audio Synthesizer and Tracker  0.9.2
bsemidivoice.hh
Go to the documentation of this file.
1  // Licensed GNU LGPL v2.1 or later: http://www.gnu.org/licenses/lgpl.html
2 #ifndef __BSE_MIDI_VOICE_H__
3 #define __BSE_MIDI_VOICE_H__
4 
5 #include <bse/bsesource.hh>
6 #include <bse/bsesnet.hh>
7 
8 G_BEGIN_DECLS
9 
10 /* --- object type macros --- */
11 #define BSE_TYPE_MIDI_VOICE_INPUT (BSE_TYPE_ID (BseMidiVoiceInput))
12 #define BSE_MIDI_VOICE_INPUT(object) (G_TYPE_CHECK_INSTANCE_CAST ((object), BSE_TYPE_MIDI_VOICE_INPUT, BseMidiVoiceInput))
13 #define BSE_MIDI_VOICE_INPUT_CLASS(class) (G_TYPE_CHECK_CLASS_CAST ((class), BSE_TYPE_MIDI_VOICE_INPUT, BseMidiVoiceInputClass))
14 #define BSE_IS_MIDI_VOICE_INPUT(object) (G_TYPE_CHECK_INSTANCE_TYPE ((object), BSE_TYPE_MIDI_VOICE_INPUT))
15 #define BSE_IS_MIDI_VOICE_INPUT_CLASS(class) (G_TYPE_CHECK_CLASS_TYPE ((class), BSE_TYPE_MIDI_VOICE_INPUT))
16 #define BSE_MIDI_VOICE_INPUT_GET_CLASS(object) (G_TYPE_INSTANCE_GET_CLASS ((object), BSE_TYPE_MIDI_VOICE_INPUT, BseMidiVoiceInputClass))
17 #define BSE_TYPE_MIDI_VOICE_SWITCH (BSE_TYPE_ID (BseMidiVoiceSwitch))
18 #define BSE_MIDI_VOICE_SWITCH(object) (G_TYPE_CHECK_INSTANCE_CAST ((object), BSE_TYPE_MIDI_VOICE_SWITCH, BseMidiVoiceSwitch))
19 #define BSE_MIDI_VOICE_SWITCH_CLASS(class) (G_TYPE_CHECK_CLASS_CAST ((class), BSE_TYPE_MIDI_VOICE_SWITCH, BseMidiVoiceSwitchClass))
20 #define BSE_IS_MIDI_VOICE_SWITCH(object) (G_TYPE_CHECK_INSTANCE_TYPE ((object), BSE_TYPE_MIDI_VOICE_SWITCH))
21 #define BSE_IS_MIDI_VOICE_SWITCH_CLASS(class) (G_TYPE_CHECK_CLASS_TYPE ((class), BSE_TYPE_MIDI_VOICE_SWITCH))
22 #define BSE_MIDI_VOICE_SWITCH_GET_CLASS(object) (G_TYPE_INSTANCE_GET_CLASS ((object), BSE_TYPE_MIDI_VOICE_SWITCH, BseMidiVoiceSwitchClass))
23 
25  guint midi_channel;
26  GSList *midi_voices;
27 };
29 {};
31  BseMidiVoiceSwitch *voice_switch;
32 };
34 {};
35 
36 void bse_midi_voice_switch_set_midi_channel (BseMidiVoiceSwitch *self,
37  guint midi_channel);
38 BseMidiContext bse_midi_voice_switch_ref_poly_voice (BseMidiVoiceSwitch *self,
39  guint context_handle,
40  BseTrans *trans);
41 BseMidiContext bse_midi_voice_switch_peek_poly_voice (BseMidiVoiceSwitch *self,
42  guint context_handle);
43 void bse_midi_voice_switch_unref_poly_voice (BseMidiVoiceSwitch *self,
44  guint context_handle,
45  BseTrans *trans);
46 void bse_midi_voice_input_set_voice_switch (BseMidiVoiceInput *self,
47  BseMidiVoiceSwitch *voice_switch);
48 
49 
50 /* --- channels --- */
51 enum
52 {
53  BSE_MIDI_VOICE_INPUT_OCHANNEL_FREQUENCY,
54  BSE_MIDI_VOICE_INPUT_OCHANNEL_GATE,
55  BSE_MIDI_VOICE_INPUT_OCHANNEL_VELOCITY,
56  BSE_MIDI_VOICE_INPUT_OCHANNEL_AFTERTOUCH
57 };
58 enum
59 {
60  BSE_MIDI_VOICE_SWITCH_ICHANNEL_LEFT,
61  BSE_MIDI_VOICE_SWITCH_ICHANNEL_RIGHT,
62  BSE_MIDI_VOICE_SWITCH_ICHANNEL_DISCONNECT
63 };
64 enum
65 {
66  BSE_MIDI_VOICE_SWITCH_OCHANNEL_LEFT,
67  BSE_MIDI_VOICE_SWITCH_OCHANNEL_RIGHT,
68  BSE_MIDI_VOICE_SWITCH_OCHANNEL_DISCONNECT
69 };
70 
71 G_END_DECLS
72 
73 #endif /* __BSE_MIDI_VOICE_H__ */
Definition: bsesnet.hh:48
Definition: bsemidivoice.hh:28
Definition: bsemidivoice.hh:24
Definition: bsemidivoice.hh:33
Definition: bsemidivoice.hh:30
Definition: bsesource.hh:84
Definition: bsesource.hh:92