1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
//! # Router Trait — signal routing
//!
//! `Router` — a semantically separate type of graph node intended
//! exclusively for signal routing (mixers, matrix switches,
//! selectors). Unlike `Processor`, which performs DSP signal
//! processing, `Router` only redistributes input signals to outputs
//! with the ability to dynamically change connection topology.
//!
//! ## Differences from Processor
//!
//! | Characteristic | Processor | Router |
//! |---|---|---|
//! | I/O count | Fixed | Dynamic N→M |
//! | DSP | Yes (filter, effect) | No (only sum/commutation) |
//! | Topology | Known at build time | Can change at runtime |
//! | Visualization | Rectangle (P-scheme) | Diamond (P-scheme, condition) |
use crateTranscendental;
use crateClockTick;
use crateNode;
use crateProcessResult;
/// Signal router — N inputs, M outputs, configurable matrix.
///
/// Unlike `Processor::process()`, which performs DSP, `Router`
/// only redistributes input signals to outputs. The router
/// manages its own output ports via `Node::output_port_mut()`.
///
/// `TapeLoop` is obtained not through this trait, but through the graph resource registry
/// — see `GraphBuilder::add_resource()` and `Node::init()`.