Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.javascript > #35727

Re: Build messages for websynth via small interface.

Newsgroups comp.lang.javascript
Date 2018-09-29 22:29 -0700
References (1 earlier) <b2e51f4f-8ea9-4f32-a9a2-987c86ca6e89@googlegroups.com> <c660e1fb-958e-47f4-b457-1c6b4f397453@googlegroups.com> <odfvqdhpcspvs22fb7d6eralrhj4c76a7u@4ax.com> <83ae72f5-03ee-4eed-9e0f-c6e590aef0ba@googlegroups.com> <91309641-2564-4c32-a036-498e4ff97ab7@googlegroups.com>
Message-ID <d371042c-e68e-482c-9c07-3caa746cd99f@googlegroups.com> (permalink)
Subject Re: Build messages for websynth via small interface.
From Jonas Thörnvall <jonas.thornvall@gmail.com>

Show all headers | View raw


Den lördag 29 september 2018 kl. 20:52:54 UTC+2 skrev Jonas Thörnvall:
> Den lördag 29 september 2018 kl. 20:47:24 UTC+2 skrev Jonas Thörnvall:
> > Den lördag 29 september 2018 kl. 20:01:17 UTC+2 skrev John G Harris:
> > > On Sat, 29 Sep 2018 08:14:41 -0700 (PDT), Jonas Thörnvall
> > > <jonas.thornvall@gmail.com> wrote:
> > > 
> > > >Den lördag 29 september 2018 kl. 15:06:42 UTC+2 skrev Jonas Thörnvall:
> > > 
> > > >> >         this.SendMessage = function(sy, s) {
> > > 
> > > > synth.SendMessage(testMess);
> > > 
> > > Compare those two lines
> > > 
> > >   John
> > 
> > Should i just put a zero, and think the other argument is the string?
> 
> Well i tried it does not change the patch/program/sound.
>  testMess="midi,@,"+programC;
>  synth.SendMessage(0,testMess);
> 
> What is sy?
>         this.sy = null; 
>         this.Load = function(url) { 
>             this.sy = window.open(url, "right", "width=900,height=670,scrollbars=yes,resizable=yes"); 
>         } 
>         this.NoteOn = function(note, velo) { 
>             this.SendMessage(this.sy, "midi,90," + note.toString(16) + "," + velo.toString(16)); 
>         } 
>         this.NoteOff = function(note) { 
>             this.SendMessage(this.sy, "midi,80," + note.toString(16) + ",0"); 
>         } 
>         this.AllSoundOff = function() { 
>             this.SendMessage(this.sy, "midi,b0,78,0"); 
>         }

Well i just can't get the messages to change program or midi channel, but it must work because they use it in this midiplayer.

https://logue.github.io/smfplayer.js/#zip=midifiles%2FYAMAHA%20mididata%20library.zip&file=CLASSIC%2Fcl42xg.mid

Back to comp.lang.javascript | Previous | Next — Previous in thread | Find similar | Unroll thread


Thread

Build messages for websynth via small interface. Jonas Thörnvall <jonas.thornvall@gmail.com> - 2018-09-29 06:00 -0700
  Re: Build messages for websynth via small interface. Jonas Thörnvall <jonas.thornvall@gmail.com> - 2018-09-29 06:06 -0700
    Re: Build messages for websynth via small interface. Jonas Thörnvall <jonas.thornvall@gmail.com> - 2018-09-29 08:14 -0700
      Re: Build messages for websynth via small interface. John G Harris <niam@jghnorth.org.uk.invalid> - 2018-09-29 19:01 +0100
        Re: Build messages for websynth via small interface. Jonas Thörnvall <jonas.thornvall@gmail.com> - 2018-09-29 11:33 -0700
        Re: Build messages for websynth via small interface. Jonas Thörnvall <jonas.thornvall@gmail.com> - 2018-09-29 11:47 -0700
          Re: Build messages for websynth via small interface. Jonas Thörnvall <jonas.thornvall@gmail.com> - 2018-09-29 11:52 -0700
            Re: Build messages for websynth via small interface. Jonas Thörnvall <jonas.thornvall@gmail.com> - 2018-09-29 22:29 -0700

csiph-web