-
Notifications
You must be signed in to change notification settings - Fork 75
Release MIDI Note Convert v0.9 #451
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
JMWalkman
wants to merge
1
commit into
ReaTeam:master
Choose a base branch
from
JMWalkman:reapack.com_upload-1783540193875
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,14 @@ | ||
| desc: MIDI Note Convert | ||
| author: José M Muñoz (J-WalkMan) | ||
| version: 0.9 | ||
| changelog: Initial release | ||
| metapackage: true | ||
| provides: | ||
| josmmuozjwalkman_MIDI Note Convert/MIDI Note to CC.jsfx > josmmuozjwalkman_MIDI Note Convert/JWM_MIDI Note to CC | ||
| josmmuozjwalkman_MIDI Note Convert/MIDI Note to PC.jsfx > josmmuozjwalkman_MIDI Note Convert/JWM_Midi Note to PC | ||
| josmmuozjwalkman_MIDI Note Convert/MIDI Note Trigger CC > josmmuozjwalkman_MIDI Note Convert/JWM_MIDI Note Trigger CC | ||
| about: | ||
| #MIDI Note Convert | ||
|
|
||
| These JSFX Plugins turn MIDI note messages to other types of messages like CC or PC | ||
|
|
||
102 changes: 102 additions & 0 deletions
102
MIDI/josmmuozjwalkman_MIDI Note Convert/MIDI Note Trigger CC
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,102 @@ | ||
| desc:MIDI Note Trigger CC | ||
| //tags: MIDI processing routing | ||
| // Uses a MIDI Note to trigger up to 10 CC messages. | ||
| // The trigger note gets converted to CC but other messages | ||
| // pass through normally | ||
|
|
||
| slider1: 0<0, 127, 1> Trigger note | ||
|
|
||
| slider2: 0<0, 128, 1{Off, 0 Bank Sel M,1 Mod Wheel M,2 Breath M,3,4 Foot P M,5 Porta M,6 Data Entry M,7 Vol M,8 Balance M,9,10 Pan M,11 Expression M,12 Ctrl 1 M,13 Ctrl 2 M,14,15,16 GP Slider 1,17 GP Slider 2,18 GP Slider 3,19 GP Slider 4,20,21,22,23,24,25,26,27,28,29,30,31,32 Bank Sel L,33 Mod Wheel L,34 Breath L,35,36 Foot P L,37 Porta L,38 Data Entry L,39 Vol L,40 Balance L,41,42 Pan L,43 Expression L,44 Ctrl 1 L,45 Ctrl 2 L,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64 Hold P sw,65 Porta sw,66 Sustenuto sw,67 Soft P sw,68 Legato P sw,69 Hold 2 P sw,70 S.Variation,71 S.Timbre,72 S.Release,73 S.Attack,74 S.Brightness,75 S.Ctrl 6,76 S.Ctrl 7,77 S.Ctrl 8,78 S.Ctrl 9,79 S.Ctrl 10,80 GP B.1 sw,81 GP B.2 sw,82 GP B.3 sw,83 GP B.4 sw,84,85,86,87,88,89,90,91 Effects Lv,92 Trem Lv,93 Chorus Lv,94 Celeste Lv,95 Phaser Lv,96 Data B. Inc,97 Data B. Dec,98 NRP L,99 NRP M,100 RP L,101 RP M,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127}> CC 1 # | ||
| slider3: 0<0, 127, 1> CC 1 Value | ||
| slider4: 0<0, 128, 1{Off, 0 Bank Sel M,1 Mod Wheel M,2 Breath M,3,4 Foot P M,5 Porta M,6 Data Entry M,7 Vol M,8 Balance M,9,10 Pan M,11 Expression M,12 Ctrl 1 M,13 Ctrl 2 M,14,15,16 GP Slider 1,17 GP Slider 2,18 GP Slider 3,19 GP Slider 4,20,21,22,23,24,25,26,27,28,29,30,31,32 Bank Sel L,33 Mod Wheel L,34 Breath L,35,36 Foot P L,37 Porta L,38 Data Entry L,39 Vol L,40 Balance L,41,42 Pan L,43 Expression L,44 Ctrl 1 L,45 Ctrl 2 L,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64 Hold P sw,65 Porta sw,66 Sustenuto sw,67 Soft P sw,68 Legato P sw,69 Hold 2 P sw,70 S.Variation,71 S.Timbre,72 S.Release,73 S.Attack,74 S.Brightness,75 S.Ctrl 6,76 S.Ctrl 7,77 S.Ctrl 8,78 S.Ctrl 9,79 S.Ctrl 10,80 GP B.1 sw,81 GP B.2 sw,82 GP B.3 sw,83 GP B.4 sw,84,85,86,87,88,89,90,91 Effects Lv,92 Trem Lv,93 Chorus Lv,94 Celeste Lv,95 Phaser Lv,96 Data B. Inc,97 Data B. Dec,98 NRP L,99 NRP M,100 RP L,101 RP M,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127}> CC 2 # | ||
| slider5: 0<0, 127, 1> CC 2 Value | ||
| slider6: 0<0, 128, 1{Off, 0 Bank Sel M,1 Mod Wheel M,2 Breath M,3,4 Foot P M,5 Porta M,6 Data Entry M,7 Vol M,8 Balance M,9,10 Pan M,11 Expression M,12 Ctrl 1 M,13 Ctrl 2 M,14,15,16 GP Slider 1,17 GP Slider 2,18 GP Slider 3,19 GP Slider 4,20,21,22,23,24,25,26,27,28,29,30,31,32 Bank Sel L,33 Mod Wheel L,34 Breath L,35,36 Foot P L,37 Porta L,38 Data Entry L,39 Vol L,40 Balance L,41,42 Pan L,43 Expression L,44 Ctrl 1 L,45 Ctrl 2 L,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64 Hold P sw,65 Porta sw,66 Sustenuto sw,67 Soft P sw,68 Legato P sw,69 Hold 2 P sw,70 S.Variation,71 S.Timbre,72 S.Release,73 S.Attack,74 S.Brightness,75 S.Ctrl 6,76 S.Ctrl 7,77 S.Ctrl 8,78 S.Ctrl 9,79 S.Ctrl 10,80 GP B.1 sw,81 GP B.2 sw,82 GP B.3 sw,83 GP B.4 sw,84,85,86,87,88,89,90,91 Effects Lv,92 Trem Lv,93 Chorus Lv,94 Celeste Lv,95 Phaser Lv,96 Data B. Inc,97 Data B. Dec,98 NRP L,99 NRP M,100 RP L,101 RP M,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127}> CC 3 # | ||
| slider7: 0<0, 127, 1> CC 3 Value | ||
| slider8: 0<0, 128, 1{Off, 0 Bank Sel M,1 Mod Wheel M,2 Breath M,3,4 Foot P M,5 Porta M,6 Data Entry M,7 Vol M,8 Balance M,9,10 Pan M,11 Expression M,12 Ctrl 1 M,13 Ctrl 2 M,14,15,16 GP Slider 1,17 GP Slider 2,18 GP Slider 3,19 GP Slider 4,20,21,22,23,24,25,26,27,28,29,30,31,32 Bank Sel L,33 Mod Wheel L,34 Breath L,35,36 Foot P L,37 Porta L,38 Data Entry L,39 Vol L,40 Balance L,41,42 Pan L,43 Expression L,44 Ctrl 1 L,45 Ctrl 2 L,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64 Hold P sw,65 Porta sw,66 Sustenuto sw,67 Soft P sw,68 Legato P sw,69 Hold 2 P sw,70 S.Variation,71 S.Timbre,72 S.Release,73 S.Attack,74 S.Brightness,75 S.Ctrl 6,76 S.Ctrl 7,77 S.Ctrl 8,78 S.Ctrl 9,79 S.Ctrl 10,80 GP B.1 sw,81 GP B.2 sw,82 GP B.3 sw,83 GP B.4 sw,84,85,86,87,88,89,90,91 Effects Lv,92 Trem Lv,93 Chorus Lv,94 Celeste Lv,95 Phaser Lv,96 Data B. Inc,97 Data B. Dec,98 NRP L,99 NRP M,100 RP L,101 RP M,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127}> CC 4 # | ||
| slider9: 0<0, 127, 1> CC 4 Value | ||
| slider10: 0<0, 128, 1{Off, 0 Bank Sel M,1 Mod Wheel M,2 Breath M,3,4 Foot P M,5 Porta M,6 Data Entry M,7 Vol M,8 Balance M,9,10 Pan M,11 Expression M,12 Ctrl 1 M,13 Ctrl 2 M,14,15,16 GP Slider 1,17 GP Slider 2,18 GP Slider 3,19 GP Slider 4,20,21,22,23,24,25,26,27,28,29,30,31,32 Bank Sel L,33 Mod Wheel L,34 Breath L,35,36 Foot P L,37 Porta L,38 Data Entry L,39 Vol L,40 Balance L,41,42 Pan L,43 Expression L,44 Ctrl 1 L,45 Ctrl 2 L,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64 Hold P sw,65 Porta sw,66 Sustenuto sw,67 Soft P sw,68 Legato P sw,69 Hold 2 P sw,70 S.Variation,71 S.Timbre,72 S.Release,73 S.Attack,74 S.Brightness,75 S.Ctrl 6,76 S.Ctrl 7,77 S.Ctrl 8,78 S.Ctrl 9,79 S.Ctrl 10,80 GP B.1 sw,81 GP B.2 sw,82 GP B.3 sw,83 GP B.4 sw,84,85,86,87,88,89,90,91 Effects Lv,92 Trem Lv,93 Chorus Lv,94 Celeste Lv,95 Phaser Lv,96 Data B. Inc,97 Data B. Dec,98 NRP L,99 NRP M,100 RP L,101 RP M,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127}> CC 5 # | ||
| slider11: 0<0, 127, 1> CC 5 Value | ||
|
|
||
| slider12: 0<0, 128, 1{Off, 0 Bank Sel M,1 Mod Wheel M,2 Breath M,3,4 Foot P M,5 Porta M,6 Data Entry M,7 Vol M,8 Balance M,9,10 Pan M,11 Expression M,12 Ctrl 1 M,13 Ctrl 2 M,14,15,16 GP Slider 1,17 GP Slider 2,18 GP Slider 3,19 GP Slider 4,20,21,22,23,24,25,26,27,28,29,30,31,32 Bank Sel L,33 Mod Wheel L,34 Breath L,35,36 Foot P L,37 Porta L,38 Data Entry L,39 Vol L,40 Balance L,41,42 Pan L,43 Expression L,44 Ctrl 1 L,45 Ctrl 2 L,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64 Hold P sw,65 Porta sw,66 Sustenuto sw,67 Soft P sw,68 Legato P sw,69 Hold 2 P sw,70 S.Variation,71 S.Timbre,72 S.Release,73 S.Attack,74 S.Brightness,75 S.Ctrl 6,76 S.Ctrl 7,77 S.Ctrl 8,78 S.Ctrl 9,79 S.Ctrl 10,80 GP B.1 sw,81 GP B.2 sw,82 GP B.3 sw,83 GP B.4 sw,84,85,86,87,88,89,90,91 Effects Lv,92 Trem Lv,93 Chorus Lv,94 Celeste Lv,95 Phaser Lv,96 Data B. Inc,97 Data B. Dec,98 NRP L,99 NRP M,100 RP L,101 RP M,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127}> CC 6 # | ||
| slider13: 0<0, 127, 1> CC 6 Value | ||
| slider14: 0<0, 128, 1{Off, 0 Bank Sel M,1 Mod Wheel M,2 Breath M,3,4 Foot P M,5 Porta M,6 Data Entry M,7 Vol M,8 Balance M,9,10 Pan M,11 Expression M,12 Ctrl 1 M,13 Ctrl 2 M,14,15,16 GP Slider 1,17 GP Slider 2,18 GP Slider 3,19 GP Slider 4,20,21,22,23,24,25,26,27,28,29,30,31,32 Bank Sel L,33 Mod Wheel L,34 Breath L,35,36 Foot P L,37 Porta L,38 Data Entry L,39 Vol L,40 Balance L,41,42 Pan L,43 Expression L,44 Ctrl 1 L,45 Ctrl 2 L,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64 Hold P sw,65 Porta sw,66 Sustenuto sw,67 Soft P sw,68 Legato P sw,69 Hold 2 P sw,70 S.Variation,71 S.Timbre,72 S.Release,73 S.Attack,74 S.Brightness,75 S.Ctrl 6,76 S.Ctrl 7,77 S.Ctrl 8,78 S.Ctrl 9,79 S.Ctrl 10,80 GP B.1 sw,81 GP B.2 sw,82 GP B.3 sw,83 GP B.4 sw,84,85,86,87,88,89,90,91 Effects Lv,92 Trem Lv,93 Chorus Lv,94 Celeste Lv,95 Phaser Lv,96 Data B. Inc,97 Data B. Dec,98 NRP L,99 NRP M,100 RP L,101 RP M,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127}> CC 7 # | ||
| slider15: 0<0, 127, 1> CC 7 Value | ||
| slider16: 0<0, 128, 1{Off, 0 Bank Sel M,1 Mod Wheel M,2 Breath M,3,4 Foot P M,5 Porta M,6 Data Entry M,7 Vol M,8 Balance M,9,10 Pan M,11 Expression M,12 Ctrl 1 M,13 Ctrl 2 M,14,15,16 GP Slider 1,17 GP Slider 2,18 GP Slider 3,19 GP Slider 4,20,21,22,23,24,25,26,27,28,29,30,31,32 Bank Sel L,33 Mod Wheel L,34 Breath L,35,36 Foot P L,37 Porta L,38 Data Entry L,39 Vol L,40 Balance L,41,42 Pan L,43 Expression L,44 Ctrl 1 L,45 Ctrl 2 L,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64 Hold P sw,65 Porta sw,66 Sustenuto sw,67 Soft P sw,68 Legato P sw,69 Hold 2 P sw,70 S.Variation,71 S.Timbre,72 S.Release,73 S.Attack,74 S.Brightness,75 S.Ctrl 6,76 S.Ctrl 7,77 S.Ctrl 8,78 S.Ctrl 9,79 S.Ctrl 10,80 GP B.1 sw,81 GP B.2 sw,82 GP B.3 sw,83 GP B.4 sw,84,85,86,87,88,89,90,91 Effects Lv,92 Trem Lv,93 Chorus Lv,94 Celeste Lv,95 Phaser Lv,96 Data B. Inc,97 Data B. Dec,98 NRP L,99 NRP M,100 RP L,101 RP M,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127}> CC 8 # | ||
| slider17: 0<0, 127, 1> CC 8 Value | ||
| slider18: 0<0, 128, 1{Off, 0 Bank Sel M,1 Mod Wheel M,2 Breath M,3,4 Foot P M,5 Porta M,6 Data Entry M,7 Vol M,8 Balance M,9,10 Pan M,11 Expression M,12 Ctrl 1 M,13 Ctrl 2 M,14,15,16 GP Slider 1,17 GP Slider 2,18 GP Slider 3,19 GP Slider 4,20,21,22,23,24,25,26,27,28,29,30,31,32 Bank Sel L,33 Mod Wheel L,34 Breath L,35,36 Foot P L,37 Porta L,38 Data Entry L,39 Vol L,40 Balance L,41,42 Pan L,43 Expression L,44 Ctrl 1 L,45 Ctrl 2 L,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64 Hold P sw,65 Porta sw,66 Sustenuto sw,67 Soft P sw,68 Legato P sw,69 Hold 2 P sw,70 S.Variation,71 S.Timbre,72 S.Release,73 S.Attack,74 S.Brightness,75 S.Ctrl 6,76 S.Ctrl 7,77 S.Ctrl 8,78 S.Ctrl 9,79 S.Ctrl 10,80 GP B.1 sw,81 GP B.2 sw,82 GP B.3 sw,83 GP B.4 sw,84,85,86,87,88,89,90,91 Effects Lv,92 Trem Lv,93 Chorus Lv,94 Celeste Lv,95 Phaser Lv,96 Data B. Inc,97 Data B. Dec,98 NRP L,99 NRP M,100 RP L,101 RP M,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127}> CC 9 # | ||
| slider19: 0<0, 127, 1> CC 9 Value | ||
| slider20: 0<0, 128, 1{Off, 0 Bank Sel M,1 Mod Wheel M,2 Breath M,3,4 Foot P M,5 Porta M,6 Data Entry M,7 Vol M,8 Balance M,9,10 Pan M,11 Expression M,12 Ctrl 1 M,13 Ctrl 2 M,14,15,16 GP Slider 1,17 GP Slider 2,18 GP Slider 3,19 GP Slider 4,20,21,22,23,24,25,26,27,28,29,30,31,32 Bank Sel L,33 Mod Wheel L,34 Breath L,35,36 Foot P L,37 Porta L,38 Data Entry L,39 Vol L,40 Balance L,41,42 Pan L,43 Expression L,44 Ctrl 1 L,45 Ctrl 2 L,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64 Hold P sw,65 Porta sw,66 Sustenuto sw,67 Soft P sw,68 Legato P sw,69 Hold 2 P sw,70 S.Variation,71 S.Timbre,72 S.Release,73 S.Attack,74 S.Brightness,75 S.Ctrl 6,76 S.Ctrl 7,77 S.Ctrl 8,78 S.Ctrl 9,79 S.Ctrl 10,80 GP B.1 sw,81 GP B.2 sw,82 GP B.3 sw,83 GP B.4 sw,84,85,86,87,88,89,90,91 Effects Lv,92 Trem Lv,93 Chorus Lv,94 Celeste Lv,95 Phaser Lv,96 Data B. Inc,97 Data B. Dec,98 NRP L,99 NRP M,100 RP L,101 RP M,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127}> CC 10 # | ||
| slider21: 0<0, 127, 1> CC 10 Value | ||
|
|
||
| in_pin:none | ||
| out_pin:none | ||
|
|
||
| @init | ||
|
|
||
| CCnum = 256; | ||
| CCval = 512; | ||
|
|
||
| NOTE_OFF = 8; | ||
| NOTE_ON = 9; | ||
|
|
||
| @slider | ||
|
|
||
| note_trigger = slider1; | ||
|
|
||
| CCnum[1] = slider2; | ||
| CCnum[2] = slider4; | ||
| CCnum[3] = slider6; | ||
| CCnum[4] = slider8; | ||
| CCnum[5] = slider10; | ||
| CCnum[6] = slider12; | ||
| CCnum[7] = slider14; | ||
| CCnum[8] = slider16; | ||
| CCnum[9] = slider18; | ||
| CCnum[10] = slider20; | ||
|
|
||
| CCval[1] = slider3; | ||
| CCval[2] = slider5; | ||
| CCval[3] = slider7; | ||
| CCval[4] = slider9; | ||
| CCval[5] = slider11; | ||
| CCval[6] = slider13; | ||
| CCval[7] = slider15; | ||
| CCval[8] = slider17; | ||
| CCval[9] = slider19; | ||
| CCval[10] = slider21; | ||
|
|
||
| @block | ||
|
|
||
| // function(offset, status_byte, data_byte) | ||
| // samples, type_chan, MSB, LSB) | ||
| // midisend(0, $x80, 10, 20) // Note OFF | ||
| // midisend(0, $x90, 10, 20) // Note ON | ||
| // midisend(0, $xBF, 10, 20) // CC on chan 16 | ||
| // midisend(0, $xC0, 10, 20) // Program Change | ||
| // midisend(0, $xE0, 10, 20) // Pitch Bend | ||
|
|
||
| while (midirecv(offset, type_chan, d_byte1, d_byte2)) ( | ||
|
|
||
| status_type = (type_chan/16)|0; | ||
| // status_chan = (type_chan-(status_type*16))|0; | ||
|
|
||
| is_note = status_type == NOTE_ON; | ||
| is_trigger = d_byte1 == note_trigger; | ||
|
|
||
|
|
||
| (is_note && is_trigger) ? ( | ||
| cc_type_chan = type_chan + $x20; // turn note to cc | ||
|
|
||
| i = 1; | ||
| loop(10, | ||
| CCnum[i] > 0 ? ( | ||
| midisend(offset, cc_type_chan, CCnum[i]-1, CCval[i]); | ||
| // midisend(offset, cc_type_chan, CCnum[i] + (CCval[i] * 256)) | ||
| ); | ||
|
|
||
| i+=1; | ||
| ); | ||
| ) : ( | ||
| midisend(offset, type_chan, d_byte1, d_byte2); | ||
| ); | ||
| ); |
43 changes: 43 additions & 0 deletions
43
MIDI/josmmuozjwalkman_MIDI Note Convert/MIDI Note to CC.jsfx
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,43 @@ | ||
| noindex: true | ||
|
|
||
| desc:MIDI Note to CC | ||
| //tags: MIDI processing routing | ||
| // turn all note messages to CC messages | ||
| // note = cc number, velocity = cc value | ||
|
|
||
| slider1:passthrough=1<0,1,1{no, yes}> Other events (CC, etc) pass through | ||
|
|
||
| in_pin:none | ||
| out_pin:none | ||
|
|
||
| @init | ||
|
|
||
| NOTE_OFF = 8; | ||
| NOTE_ON = 9; | ||
|
|
||
| @block | ||
|
|
||
| // function(offset, status_byte, data_byte) | ||
| // samples, type_chan, MSB, LSB) | ||
| // midisend(0, $x80, 10, 20) // Note OFF | ||
| // midisend(0, $x90, 10, 20) // Note ON | ||
| // midisend(0, $xBF, 10, 20) // CC on chan 16 | ||
| // midisend(0, $xC0, 10, 20) // Program Change | ||
| // midisend(0, $xE0, 10, 20) // Pitch Bend | ||
|
|
||
| while (midirecv(offset, type_chan, d_byte1, d_byte2)) ( | ||
| status_type = (type_chan/16)|0; | ||
| status_chan = (type_chan-(status_type*16))|0; | ||
|
|
||
| status_type == NOTE_ON ? ( | ||
| type_chan = type_chan + $x20; | ||
| midisend(offset, type_chan, d_byte1, d_byte2); | ||
| ) : ( | ||
| passthrough == 1 && status_type != NOTE_OFF ? ( | ||
| midisend(offset, type_chan, d_byte1, d_byte2); | ||
| ) | ||
| ); | ||
|
|
||
|
|
||
|
|
||
| ); |
41 changes: 41 additions & 0 deletions
41
MIDI/josmmuozjwalkman_MIDI Note Convert/MIDI Note to PC.jsfx
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,41 @@ | ||
| noindex: true | ||
|
|
||
| desc:MIDI Note to PC | ||
| //tags: MIDI processing routing | ||
| // turn all note messages to Program Change messages | ||
| // note = pc number, velocity ignored | ||
|
|
||
| slider1:passthrough=1<0,1,1{no, yes}> Other events (CC, etc) pass through | ||
|
|
||
| in_pin:none | ||
| out_pin:none | ||
|
|
||
| @init | ||
|
|
||
| NOTE_OFF = 8; | ||
| NOTE_ON = 9; | ||
|
|
||
| @block | ||
|
|
||
| // function(offset, status_byte, data_byte) | ||
| // samples, type_chan, MSB, LSB) | ||
| // midisend(0, $x80, 10, 20) // Note OFF | ||
| // midisend(0, $x90, 10, 20) // Note ON | ||
| // midisend(0, $xBF, 10, 20) // CC on chan 16 | ||
| // midisend(0, $xC0, 10, 20) // Program Change | ||
| // midisend(0, $xE0, 10, 20) // Pitch Bend | ||
|
|
||
| while (midirecv(offset, type_chan, d_byte1, d_byte2)) ( | ||
| status_type = (type_chan/16)|0; | ||
| status_chan = (type_chan-(status_type*16))|0; | ||
|
|
||
| status_type == NOTE_ON ? ( | ||
| type_chan = type_chan + $x30; | ||
| midisend(offset, type_chan, d_byte1, d_byte2); | ||
| ); | ||
|
|
||
| passthrough == 1 && status_type != NOTE_OFF ? ( | ||
| midisend(offset, type_chan, d_byte1, d_byte2); | ||
| ) | ||
|
|
||
| ); |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The .jsfx extension should be used in all the files. Also, if using "JWM_" as the author prefix, the storage filenames (directory + files) should also use the same instead of the longer "josmmuozjwalkman_".