demux 6

Demultiplexer. Connects inlet i to outlet number s. Other outlets copy their corresponding default inlets.
Author: Johannes Taelman
License: BSD
Github: demux/demux 6.axo

IO Variants: 4


Variant: 1

Inlets

frac32buffer input

frac32buffer default 0

frac32buffer default 1

frac32buffer default 2

frac32buffer default 3

frac32buffer default 4

frac32buffer default 5

int32.positive select

Outlets

frac32buffer output 0

frac32buffer output 1

frac32buffer output 2

frac32buffer output 3

frac32buffer output 4

frac32buffer output 5

Audio Rate
switch (inlet_s > 0 ? inlet_s : 0) {
case 0:
  outlet_o0 = inlet_i;
  outlet_o1 = inlet_d1;
  outlet_o2 = inlet_d2;
  outlet_o3 = inlet_d3;
  outlet_o4 = inlet_d4;
  outlet_o5 = inlet_d5;
  break;
case 1:
  outlet_o0 = inlet_d0;
  outlet_o1 = inlet_i;
  outlet_o2 = inlet_d2;
  outlet_o3 = inlet_d3;
  outlet_o4 = inlet_d4;
  outlet_o5 = inlet_d5;
  break;
case 2:
  outlet_o0 = inlet_d0;
  outlet_o1 = inlet_d1;
  outlet_o2 = inlet_i;
  outlet_o3 = inlet_d3;
  outlet_o4 = inlet_d4;
  outlet_o5 = inlet_d5;
  break;
case 3:
  outlet_o0 = inlet_d0;
  outlet_o1 = inlet_d1;
  outlet_o2 = inlet_d2;
  outlet_o3 = inlet_i;
  outlet_o4 = inlet_d4;
  outlet_o5 = inlet_d5;
  break;
case 4:
  outlet_o0 = inlet_d0;
  outlet_o1 = inlet_d1;
  outlet_o2 = inlet_d2;
  outlet_o3 = inlet_d3;
  outlet_o4 = inlet_i;
  outlet_o5 = inlet_d5;
  break;
case 5:
  outlet_o0 = inlet_d0;
  outlet_o1 = inlet_d1;
  outlet_o2 = inlet_d2;
  outlet_o3 = inlet_d3;
  outlet_o4 = inlet_d4;
  outlet_o5 = inlet_i;
  break;
default:
  outlet_o0 = inlet_d0;
  outlet_o1 = inlet_d1;
  outlet_o2 = inlet_d2;
  outlet_o3 = inlet_d3;
  outlet_o4 = inlet_d4;
  outlet_o5 = inlet_d5;
}

Variant: 2

Inlets

int32.positive select

frac32 input

frac32 default 0

frac32 default 1

frac32 default 2

frac32 default 3

frac32 default 4

frac32 default 5

Outlets

frac32 output 0

frac32 output 1

frac32 output 2

frac32 output 3

frac32 output 4

frac32 output 5

Control Rate
switch (inlet_s > 0 ? inlet_s : 0) {
case 0:
  outlet_o0 = inlet_i;
  outlet_o1 = inlet_d1;
  outlet_o2 = inlet_d2;
  outlet_o3 = inlet_d3;
  outlet_o4 = inlet_d4;
  outlet_o5 = inlet_d5;
  break;
case 1:
  outlet_o0 = inlet_d0;
  outlet_o1 = inlet_i;
  outlet_o2 = inlet_d2;
  outlet_o3 = inlet_d3;
  outlet_o4 = inlet_d4;
  outlet_o5 = inlet_d5;
  break;
case 2:
  outlet_o0 = inlet_d0;
  outlet_o1 = inlet_d1;
  outlet_o2 = inlet_i;
  outlet_o3 = inlet_d3;
  outlet_o4 = inlet_d4;
  outlet_o5 = inlet_d5;
  break;
case 3:
  outlet_o0 = inlet_d0;
  outlet_o1 = inlet_d1;
  outlet_o2 = inlet_d2;
  outlet_o3 = inlet_i;
  outlet_o4 = inlet_d4;
  outlet_o5 = inlet_d5;
  break;
case 4:
  outlet_o0 = inlet_d0;
  outlet_o1 = inlet_d1;
  outlet_o2 = inlet_d2;
  outlet_o3 = inlet_d3;
  outlet_o4 = inlet_i;
  outlet_o5 = inlet_d5;
  break;
case 5:
  outlet_o0 = inlet_d0;
  outlet_o1 = inlet_d1;
  outlet_o2 = inlet_d2;
  outlet_o3 = inlet_d3;
  outlet_o4 = inlet_d4;
  outlet_o5 = inlet_i;
  break;
default:
  outlet_o0 = inlet_d0;
  outlet_o1 = inlet_d1;
  outlet_o2 = inlet_d2;
  outlet_o3 = inlet_d3;
  outlet_o4 = inlet_d4;
  outlet_o5 = inlet_d5;
}

Variant: 3

Inlets

int32 input

int32 default 0

int32 default 1

int32 default 2

int32 default 3

int32 default 4

int32 default 5

int32.positive select

Outlets

int32 output 0

int32 output 1

int32 output 2

int32 output 3

int32 output 4

int32 output 5

Control Rate
switch (inlet_s > 0 ? inlet_s : 0) {
case 0:
  outlet_o0 = inlet_i;
  outlet_o1 = inlet_d1;
  outlet_o2 = inlet_d2;
  outlet_o3 = inlet_d3;
  outlet_o4 = inlet_d4;
  outlet_o5 = inlet_d5;
  break;
case 1:
  outlet_o0 = inlet_d0;
  outlet_o1 = inlet_i;
  outlet_o2 = inlet_d2;
  outlet_o3 = inlet_d3;
  outlet_o4 = inlet_d4;
  outlet_o5 = inlet_d5;
  break;
case 2:
  outlet_o0 = inlet_d0;
  outlet_o1 = inlet_d1;
  outlet_o2 = inlet_i;
  outlet_o3 = inlet_d3;
  outlet_o4 = inlet_d4;
  outlet_o5 = inlet_d5;
  break;
case 3:
  outlet_o0 = inlet_d0;
  outlet_o1 = inlet_d1;
  outlet_o2 = inlet_d2;
  outlet_o3 = inlet_i;
  outlet_o4 = inlet_d4;
  outlet_o5 = inlet_d5;
  break;
case 4:
  outlet_o0 = inlet_d0;
  outlet_o1 = inlet_d1;
  outlet_o2 = inlet_d2;
  outlet_o3 = inlet_d3;
  outlet_o4 = inlet_i;
  outlet_o5 = inlet_d5;
  break;
case 5:
  outlet_o0 = inlet_d0;
  outlet_o1 = inlet_d1;
  outlet_o2 = inlet_d2;
  outlet_o3 = inlet_d3;
  outlet_o4 = inlet_d4;
  outlet_o5 = inlet_i;
  break;
default:
  outlet_o0 = inlet_d0;
  outlet_o1 = inlet_d1;
  outlet_o2 = inlet_d2;
  outlet_o3 = inlet_d3;
  outlet_o4 = inlet_d4;
  outlet_o5 = inlet_d5;
}

Variant: 4

Inlets

int32.positive select

bool32 input

bool32 default 0

bool32 default 1

bool32 default 2

bool32 default 3

bool32 default 4

bool32 default 5

Outlets

bool32 output 0

bool32 output 1

bool32 output 2

bool32 output 3

bool32 output 4

bool32 output 5

Control Rate
switch (inlet_s > 0 ? inlet_s : 0) {
case 0:
  outlet_o0 = inlet_i;
  outlet_o1 = inlet_d1;
  outlet_o2 = inlet_d2;
  outlet_o3 = inlet_d3;
  outlet_o4 = inlet_d4;
  outlet_o5 = inlet_d5;
  break;
case 1:
  outlet_o0 = inlet_d0;
  outlet_o1 = inlet_i;
  outlet_o2 = inlet_d2;
  outlet_o3 = inlet_d3;
  outlet_o4 = inlet_d4;
  outlet_o5 = inlet_d5;
  break;
case 2:
  outlet_o0 = inlet_d0;
  outlet_o1 = inlet_d1;
  outlet_o2 = inlet_i;
  outlet_o3 = inlet_d3;
  outlet_o4 = inlet_d4;
  outlet_o5 = inlet_d5;
  break;
case 3:
  outlet_o0 = inlet_d0;
  outlet_o1 = inlet_d1;
  outlet_o2 = inlet_d2;
  outlet_o3 = inlet_i;
  outlet_o4 = inlet_d4;
  outlet_o5 = inlet_d5;
  break;
case 4:
  outlet_o0 = inlet_d0;
  outlet_o1 = inlet_d1;
  outlet_o2 = inlet_d2;
  outlet_o3 = inlet_d3;
  outlet_o4 = inlet_i;
  outlet_o5 = inlet_d5;
  break;
case 5:
  outlet_o0 = inlet_d0;
  outlet_o1 = inlet_d1;
  outlet_o2 = inlet_d2;
  outlet_o3 = inlet_d3;
  outlet_o4 = inlet_d4;
  outlet_o5 = inlet_i;
  break;
default:
  outlet_o0 = inlet_d0;
  outlet_o1 = inlet_d1;
  outlet_o2 = inlet_d2;
  outlet_o3 = inlet_d3;
  outlet_o4 = inlet_d4;
  outlet_o5 = inlet_d5;
}

Privacy

© 2024 Zrna Research