ref: ea6241ec1a2edebbaec309a59cc7acfeaf6553a0
parent: 5727f04d70a5dde5a8c8a54961eff192429000b7
author: Nicola Pisanti <pisanti.nicola@gmail.com>
date: Sat Jun 19 15:05:54 EDT 2021
tweaks to H and osc/udp/midi operators visualization Highlights all the output message operators when banged. The H operator shouldn't have an output port but a right-side-locked port type, and has been modified.
--- a/sim.c
+++ b/sim.c
@@ -242,6 +242,7 @@
Usz channel = index_of(channel_g);
if (channel > 15)
return;
+ PORT(0, 0, OUT);
Oevent_midi_cc *oe =
(Oevent_midi_cc *)oevent_list_alloc_item(extra_params->oevent_list);
oe->oevent_type = Oevent_type_midi_cc;
@@ -305,6 +306,7 @@
if (vel_num > 127)
vel_num = 127;
}
+ PORT(0, 0, OUT);
Oevent_midi_note *oe =
(Oevent_midi_note *)oevent_list_alloc_item(extra_params->oevent_list);
oe->oevent_type = (U8)Oevent_type_midi_note;
@@ -335,6 +337,7 @@
}
n = i;
STOP_IF_NOT_BANGED;
+ PORT(0, 0, OUT);
Oevent_udp_string *oe =
(Oevent_udp_string *)oevent_list_alloc_item(extra_params->oevent_list);
oe->oevent_type = (U8)Oevent_type_udp_string;
@@ -356,6 +359,7 @@
STOP_IF_NOT_BANGED;
Glyph g = PEEK(0, 1);
if (g != '.') {
+ PORT(0, 0, OUT);
U8 buff[Oevent_osc_int_count];
for (Usz i = 0; i < len; ++i) {
buff[i] = (U8)index_of(PEEK(0, (Isz)i + 3));
@@ -384,6 +388,7 @@
Usz channel = index_of(channel_g);
if (channel > 15)
return;
+ PORT(0, 0, OUT);
Oevent_midi_pb *oe =
(Oevent_midi_pb *)oevent_list_alloc_item(extra_params->oevent_list);
oe->oevent_type = Oevent_type_midi_pb;
@@ -474,7 +479,7 @@
BEGIN_OPERATOR(halt)
LOWERCASE_REQUIRES_BANG;
- PORT(1, 0, OUT);
+ PORT(1, 0, IN | PARAM);
END_OPERATOR
BEGIN_OPERATOR(increment)
--
⑨