HyperTalk ABC Music Notation via MIDI
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller
-
- Posts: 627
- Joined: Wed Apr 24, 2013 4:53 pm
- Contact:
HyperTalk ABC Music Notation via MIDI
I've been playing around with MIDI via JavaScript in a Browser instances that utilize either WebMIDI API (in Chrome/CEF 43 and up) or a browser plug-in called Jazz-Plugin available for all platforms at http://Jazz-Soft.net for more than a year. While I was recently looking for a certain usage example I came across a .js library call jsPlayCommand that uses the same thing for musical output. It was designed to emulate HyperCard's ABC music notation for use with the authors own X-Talk language, OpenXION http://www.kreativekorp.com/docs/openxion/1.4/manual/. Since it's written in JS it works just as well to extend LiveCode's abilities. So I just connected the dots (or rather the .js) for an LC stack that plays HyperTalk music using whatever the default synth is that lives in your OS (probably Apple's DLS Synh or MS Wave Table Synth), YEAH!
Here, try it for yourself, but if you are using the LC9 builds on macOS you may need to run it in 32bit mode.
http://livecodeshare.runrev.com/stack/847/HyperTalkMIDI
I also took the time to figure out how to upload to LiveCodeShare.runrev.com so I'll probably be posting more examples of mixing JZZ.js with LiveCode, writing AND READING MIDI files in pure LCS, and other stuff soon!
Here, try it for yourself, but if you are using the LC9 builds on macOS you may need to run it in 32bit mode.
http://livecodeshare.runrev.com/stack/847/HyperTalkMIDI
I also took the time to figure out how to upload to LiveCodeShare.runrev.com so I'll probably be posting more examples of mixing JZZ.js with LiveCode, writing AND READING MIDI files in pure LCS, and other stuff soon!
Last edited by PaulDaMacMan on Wed May 09, 2018 1:17 am, edited 5 times in total.
Re: HyperTalk ABC Music Notation via MIDI
Hi all,
For a private project, I had to evaluate and validate if it was
possible to build an external in 64 bits, using Flex and Bison !
As I was using these tools in 2009 for my Maestro Junior( ABC player) MacOSX external,
I spent a couple of hours to update everything and here is a new version
which shows that it is possible:
Just to be clear: MacOS only, external and it needs to run LC in 64 bits.
Oh and it uses the Apple CoreMidi framework.
If anyone is interested to have a look at it,
just let me know and I'll send it to you.
Now back to my project...
Thierry
For a private project, I had to evaluate and validate if it was
possible to build an external in 64 bits, using Flex and Bison !
As I was using these tools in 2009 for my Maestro Junior( ABC player) MacOSX external,
I spent a couple of hours to update everything and here is a new version
which shows that it is possible:
Just to be clear: MacOS only, external and it needs to run LC in 64 bits.
Oh and it uses the Apple CoreMidi framework.
If anyone is interested to have a look at it,
just let me know and I'll send it to you.
Now back to my project...
Thierry
!
SUNNY-TDZ.COM doesn't belong to me since 2021.
To contact me, use the Private messages. Merci.
!
SUNNY-TDZ.COM doesn't belong to me since 2021.
To contact me, use the Private messages. Merci.
!
-
- Posts: 627
- Joined: Wed Apr 24, 2013 4:53 pm
- Contact:
Re: HyperTalk ABC Music Notation via MIDI
Since I started this thread 7 months ago LiveCode 9 has come out with FFI (Foreign Function Interface) pretty much ready for prime time, and I've created a mostly complete LiveCode Builder LCB wrapper for AVMIDIPlayer that is available in macOS 10.9 (actually I think it was included earlier, 10.7?) and iOS 8+ (though I have not tested at all on iOS). It's still a work in progress but it works pretty well now and it's available free and is open-source, here: https://github.com/PaulMcClernan/LCB_macAVMidiPlayer
Next up wrapping Core MIDI for some live real-time fun!
Sorry other platforms (though I do know I can get MIDI to play with built-in sounds on Android without any sort of LiveCode add-ons)
Next up wrapping Core MIDI for some live real-time fun!
Sorry other platforms (though I do know I can get MIDI to play with built-in sounds on Android without any sort of LiveCode add-ons)
-
- Posts: 627
- Joined: Wed Apr 24, 2013 4:53 pm
- Contact:
Re: HyperTalk ABC Music Notation via MIDI
I need to dig out the UDI's PlayPMD ABC/MIDI Library (which I updated a little bit), and a few other music demos I created or collected over the decades (ancient HyperCard stacks).
-
- Posts: 627
- Joined: Wed Apr 24, 2013 4:53 pm
- Contact:
Re: HyperTalk ABC Music Notation via MIDI
Actually, I might stick with wrapping the Objective C AVFoundation / AVKit stuff like AVAudioUnitMIDIInstrument and AVAudioUnitSampler because I don't think there are any examples of wrapping CoreFoundation's C API's (which is what CoreMIDI is) and so I don't know how to make binding strings for that stuff, and I also have a feeling it might involve aggregate types (which is still marked experimental in the LCB guide).Next up wrapping Core MIDI for some live real-time fun!
Oh that reminds me, I remember someone had a little bit of success early on in LCB development with wrapping FluidSynth on Windows so someone might be interested in looking that up in the LiveCode Builder section of the forum.Sorry other platforms (though I do know I can get MIDI to play with built-in sounds on Android without any sort of LiveCode add-ons)
-
- Posts: 627
- Joined: Wed Apr 24, 2013 4:53 pm
- Contact:
Re: HyperTalk ABC Music Notation via MIDI
Since my last reply to this thread I have created working (at least partially) LiveCode Builder libraries for binding to CoreMIDI (MIDI out only, a work in progress), AVMIDIPlayer (pretty much complete), and AVAudioUnitSampler (working, but very much a work in progress).
https://github.com/PaulMcClernan/
https://github.com/PaulMcClernan/
Re: HyperTalk ABC Music Notation via MIDI
Nice work Paul!