refactor: 3-module pd architecture + viz non-blocking fix
- midi-in.pd: netreceive -> route -> unpack -> pitch/velocity outlets - audio-out.pd: inlet~ -> dac~ abstraction - synth.pd: consumer patch wiring midi-in -> voice -> audio-out - led-matrix-viz.py: router socket non-blocking, registered with poller - pd.rego: skip outlet/abstraction false positives in validation
This commit is contained in:
@@ -100,7 +100,7 @@ violation contains msg if {
|
||||
msg := sprintf("connect[%d]/[%d]: duplicate (%d,%d)->(%d,%d)", [a.x_index, b.x_index, a.src, a.outlet, a.dst, a.inlet])
|
||||
}
|
||||
|
||||
# Signal-to-control connection
|
||||
# Signal-to-control connection (skip unknown objects — might be abstractions with inlet~)
|
||||
violation contains msg if {
|
||||
some rec in input.records
|
||||
rec.type == "connect"
|
||||
@@ -110,6 +110,7 @@ violation contains msg if {
|
||||
dst_rec.type == "obj"
|
||||
is_signal(src_rec.name)
|
||||
not is_signal(dst_rec.name)
|
||||
known_inlets[dst_rec.name]
|
||||
msg := sprintf("connect[%d]: signal (~) outlet %d (%s) to control inlet %d (%s)", [rec.x_index, rec.src, src_rec.name, rec.dst, dst_rec.name])
|
||||
}
|
||||
|
||||
@@ -137,11 +138,14 @@ violation contains msg if {
|
||||
}
|
||||
|
||||
# Inlet exceeds known count (skip -1 = variable)
|
||||
# Skip outlet objects (valid in abstractions) and unknown abstractions
|
||||
violation contains msg if {
|
||||
some rec in input.records
|
||||
rec.type == "connect"
|
||||
dst_rec := record_by_idx(rec.dst)
|
||||
dst_rec.type == "obj"
|
||||
dst_rec.name != "outlet"
|
||||
dst_rec.name != "outlet~"
|
||||
known_inlets[dst_rec.name]
|
||||
known_inlets[dst_rec.name] != -1
|
||||
rec.inlet >= known_inlets[dst_rec.name]
|
||||
|
||||
Reference in New Issue
Block a user