Melodeon.net Forums

Discussions => Tunes => ABC => Topic started by: Clive Williams on May 15, 2015, 02:44:05 PM

Title: ABC Player/Editor Webpage
Post by: Clive Williams on May 15, 2015, 02:44:05 PM
Those of you who use ABC may be interested in a webpage I've stuck on my webpage here

http://www.clivew.com/abc.php

It's a page that you enter ABC in the left panel, and it automatically draws it as music on the right panel. What's interesting about that, I hear you ask? Well... it does it in real time, so if you edit the left, it instantly updates the right panel. And... *if* you've got your midi player set up just right in your browser, it plays it too! (if it's not setup right, it just gives you a midi file to download instead). I have managed to get in browser midi playback to work on one of my PCs in Firefox, but it needs quicktime, and Chrome no longer supports Quicktime, and I don't think IE ever did properly, so the midi bit needs work.

As you can tell, I haven't come up with a catchy name for it yet; it's very much a work in progress. Any ideas? Things I'm working on when I get a mo'

- Make it automatically resize when the window is too small to show the score in the area available (fairly easy)
- Implement a better javascript powered midi player that works on any browser (very difficult)
- Some kind of automatic transposition mechanism (not that hard)

In case you think I'm a genius programmer, well, I may be, but the clever bits of this page aren't down to me - they're using an astoundingly clever javascript abc library, abcjs written by Paul Rosen and Gregory Dyke. I was looking at integrating that into an Android ABC app, but I've put that mini project on hold for a while, not because this library doesn't work on Android (it does), but because I can't get a sensible midi implementation going. A web based solution though? No reason at all why that shouldn't work.

Anyway, have fun...

Clive

Title: Re: ABC Player/Editor Webpage
Post by: TomB on May 15, 2015, 06:08:09 PM
Very neat, Clive, but how does this stand against all the other ABC converters on the web?  I've tried many over the years but for reliability, ease of use and 'does what I want when i want', it's Nils Liberg's EasyABC  I keep on my desktop.
Title: Re: ABC Player/Editor Webpage
Post by: Clive Williams on May 15, 2015, 08:22:04 PM
Very neat, Clive, but how does this stand against all the other ABC converters on the web?  I've tried many over the years but for reliability, ease of use and 'does what I want when i want', it's Nils Liberg's EasyABC  I keep on my desktop.

It comes down to the translation built into ABCJS, so effectively, it's either a 'it works' or 'it doesn't'. I haven't seen anything (so far) that breaks it though. Once I get the midi javascript library rolling, it will be quite impressive...
Title: Re: ABC Player/Editor Webpage
Post by: Rog on May 15, 2015, 08:37:40 PM
Great stuff! Um.. The display doesn't work very well on an iPad mini. Don't know if it works on a regular iPad. The rendered dots overlap into the ABC window.
Title: Re: ABC Player/Editor Webpage
Post by: Clive Williams on May 15, 2015, 09:36:46 PM
Great stuff! Um.. The display doesn't work very well on an iPad mini. Don't know if it works on a regular iPad. The rendered dots overlap into the ABC window.

yes, it needs to autosize the dots relative to the display of the window space available - not as easy to do as you think, but doable. You'll probably get a better result turned landscape, though I expect it will be the same on an ipad.
Title: Re: ABC Player/Editor Webpage
Post by: Mike Hirst on May 16, 2015, 12:14:15 AM
Great stuff! Um.. The display doesn't work very well on an iPad mini. Don't know if it works on a regular iPad. The rendered dots overlap into the ABC window.

yes, it needs to autosize the dots relative to the display of the window space available - not as easy to do as you think, but doable. You'll probably get a better result turned landscape, though I expect it will be the same on an ipad.

I had some good results resizing abcjs output for Kindle 3. If I can find the code I'll send it via PM.
Title: Re: ABC Player/Editor Webpage
Post by: Clive Williams on May 16, 2015, 12:17:58 AM
I had some good results resizing abcjs output for Kindle 3. If I can find the code I'll send it via PM.

Thanks Mike - that'd be great. Like many such projects, the abcjs technology is fantastic, but it does need more examples in the documentation!
Title: Re: ABC Player/Editor Webpage
Post by: The Blues Viking on May 16, 2015, 05:18:16 AM
Nicely done. Works very well, but it's unlikely to replace my stand-alone editor (currently Barfly) unless it gets a "Transpose" feature. But for most other uses, I think I like this better.

TBV
Title: Re: ABC Player/Editor Webpage
Post by: Theo on May 16, 2015, 10:02:21 AM
Thanks Clive, that is very useful.    There used to be a similar tool on concertina.net which I used for occasionally to get notation from ABC.  It is no longer available so your will be a great replacement.   The immediate editing feature is a big improvement on the c.net tool.
Title: Re: ABC Player/Editor Webpage
Post by: Lester on May 16, 2015, 10:38:48 AM
This, as Theo said, will be a great replacement for the c.net ABC Convert-a-matic. But to achieve that it would be really good if it output a PDF page/PNG image of the manuscript.
Title: Re: ABC Player/Editor Webpage
Post by: Stiamh on May 16, 2015, 12:27:40 PM
This one seems already to do everything you are trying to do Clive, clearly using the same tools.

http://music.gordfisch.net/montrealsession/editor.php

I find it pretty useful but I miss their earlier version, which didn't do instant updating but handled outputting of large tunebooks very well (this one doesn't).
Title: Re: ABC Player/Editor Webpage
Post by: Pete Dunk on May 16, 2015, 03:19:24 PM
This, as Theo said, will be a great replacement for the c.net ABC Convert-a-matic. But to achieve that it would be really good if it output a PDF page/PNG image of the manuscript.

This site does just that - Draw The Dots (http://drawthedots.com/). Not surprising really as it's Paul Rosen's own implementation of abcjs. It also allows uploading of whole tunebooks which can be private or shared.

Paul Rosen is a tunesmith in his own right and seems to be challenging Nigel Chippendale and Robin Dunn to be the new 'Most Fiendishly Difficult Tune Writer', check this out!

X: 28
T:Elgin Rag
C:Paul Rosen
S:Copyright 2004, Paul Rosen
M:4/4
L:1/8
Q:1/2=112
R:Ragtime
K:C
"C"GAcG AcGA|"Ab"_e2_e2c4|"G"d2AB2 AG2|d2d2 BAG2|"C"GAcG AcGA|"Ab"_e2_e2c4|
"G"d2ef2ed2|1"C"c8:|2"C"c6eg|:"A7"aege fe^c2|"Dm"dfedA2A2|"G7"BABc dBG2|
"C"cBAG E4|"A7"aege fe^c2|"Dm"dfed A2A2|"G7"BABc dBG2|1"C"c6eg:|2"C"c8||
T:Harmony
"C"cdec decd|"Ab"_a2_a2_e4|"G"g2de2 dB2|g2g2 dcB2|"C"cdec decd|"Ab"_a2_a2_e4|
"G"g2ab2gf2|1"C"e8:|2"C"e6ab||:"A7"c'aba age2|"Dm"fagfd2d2|"G7"dcde gdB2|
"C"edcB G4|"A7"c'aba age2|"Dm"fagfd2d2|"G7"dcde gdB2|1"C"e6ab:|2"C"e8||
Title: Re: ABC Player/Editor Webpage
Post by: Pete Dunk on May 16, 2015, 05:04:09 PM
I find it pretty useful but I miss their earlier version, which didn't do instant updating but handled outputting of large tunebooks very well (this one doesn't).

Yes, Robin Beech seems to have shot himself in the foot with this version. Draw the Dots (http://forum.melodeon.net/Draw the Dots) handles and stores tunebooks and you can set them to public or private.
Title: Re: ABC Player/Editor Webpage
Post by: Anahata on May 16, 2015, 05:11:38 PM
Is Elgin Rag supposed to be played in that key on a D/G melodeon?
(it looks theoretically possible, apart from the Aâ™­ and Dm chords)
Title: Re: ABC Player/Editor Webpage
Post by: Pete Dunk on May 16, 2015, 06:03:19 PM
I don't know Anahata as I'm not sure what instrument Paul Rosen plays and I posted it as a curiosity, not expecting anyone to actually attempt playing it!  >:E :||:
Title: Re: ABC Player/Editor Webpage
Post by: Anahata on May 16, 2015, 09:49:14 PM
mandolin, fiddle, accordion, apparently. (and the accordion turns out to be a melodeon)

I only asked because "most fiendishly difficult tune" would partly depend on what instrument you were trying to play it on.
Title: Re: ABC Player/Editor Webpage
Post by: Pete Dunk on May 16, 2015, 10:32:01 PM
I only asked because "most fiendishly difficult tune" would partly depend on what instrument you were trying to play it on.

With the greatest of respect I wouldn't normally include consummately talented professional folk musicians in my assessment of a 'fiendishly difficult tune' for we mere mortals. Now begone before I set you homework with the words 'Bach Cello Suite' in them ;) ;D
Title: Re: ABC Player/Editor Webpage
Post by: Clive Williams on May 16, 2015, 11:23:20 PM
This one seems already to do everything you are trying to do Clive, clearly using the same tools.

http://music.gordfisch.net/montrealsession/editor.php

I find it pretty useful but I miss their earlier version, which didn't do instant updating but handled outputting of large tunebooks very well (this one doesn't).

That's pretty neat, isn't it? I'm coming at it from a slightly different direction - no wish to support tunebooks (if the Android app version ever shows the light of day though, it would), it's simply a little implementation of abcjs, because most of the ones I've seen so far are badly laid out. Not that mine's much better at the moment until I implement the autoshrinking stuff, but having the abc window and music window side by side (rather than above each other) means you can ABC encode a tune from a tunebook, and see, on the fly, that you've got it right. So essentially, I'm looking for a 'can you encode that written tune for me so I can hear what it sounds like, because I can't read music' tool. But it's very early days yet - I just added this page as an after thought after giving my personal home page a (much needed) overhaul/rewrite.

Cheers,

Clive

Title: Re: ABC Player/Editor Webpage
Post by: Chris Ryall on May 17, 2015, 04:50:29 AM
Presently enjoying the St Isidro festival (flamanco night!) but deeply look forward to playing with this on return.  It was a very slow download here in Madrid, maybe much linked code(?) and didn't want to do much on this iPad, but congratulations.

name? Is DotABC copyrighted yet? It might make sense, particularly if it could also take a stave click and update the ABC panel. Is that a facility?

another "well done", Chris :|glug

Title: Re: ABC Player/Editor Webpage
Post by: Pete Dunk on May 17, 2015, 01:01:31 PM
I'm coming at it from a slightly different direction

Just to clarify, none of my posts pointing to other converters was intended as a snub to yours Clive, merely showing that other features are possible. I was in fact initially astounded by yours as it did something I'd never seen before with online ABC tools, real time updating of notation as you type. This provides me with a solution to my problem with transcribing at work during my lunch hour. I can't install any software on the school network and transcribing in text only to edit and troubleshoot later is a pain, but now I can transcribe into your converter, visually checking as I go, listen to the end result and then copy the text into notepad and pop the file into Box for collection later. Neat tool Clive, well done!
Title: Re: ABC Player/Editor Webpage
Post by: vof on May 17, 2015, 08:44:15 PM
Clive - the player side is not working for me - the QT logo appears to be greyed out - should it show a normal set of playback controls? I've just upgraded QT but no improvement. I'm using XP/FF38.0.1/QT7.7.6. The download midi link works and plays in WMP/VLC.

Any ideas what's wrong/missing?

vof
Title: Re: ABC Player/Editor Webpage
Post by: The Blues Viking on May 17, 2015, 10:12:35 PM
This one seems already to do everything you are trying to do Clive, clearly using the same tools.

http://music.gordfisch.net/montrealsession/editor.php

Had a quick look at this, and it doesn't appear to recognize that there's such a thing as a minor key. Am I missing something?

TBV
Title: Re: ABC Player/Editor Webpage
Post by: Stiamh on May 17, 2015, 10:47:12 PM
Had a quick look at this, and it doesn't appear to recognize that there's such a thing as a minor key. Am I missing something?
You must be looking at the transpose dropdown list. That's for changing the key of a tune you have already entered or pasted in.

The editing window recognizes all the usual keys if you enter them in the usual way as D, Dmaj, Dmin, Dm, Dmix, Ddor, etc. etc.

Then if you choose a note in the dropdown list it will transpose the tune to the same mode/scale of the tonic you select, e.g. from Gm to Abm...
Title: Re: ABC Player/Editor Webpage
Post by: The Blues Viking on May 17, 2015, 11:22:35 PM
The editing window recognizes all the usual keys if you enter them in the usual way as D, Dmaj, Dmin, Dm, Dmix, Ddor, etc. etc.

Then if you choose a note in the dropdown list it will transpose the tune to the same mode/scale of the tonic you select, e.g. from Gm to Abm...

Thanks, Stiamh. Got it.

I apologize to all for a bit of thread-drift, for asking a question unrelated to Clive's excellent editor. I really was interested in an on-line editor that had a "transpose" feature.

TBV
Title: Re: ABC Player/Editor Webpage
Post by: Clive Williams on May 18, 2015, 12:06:08 AM
The editing window recognizes all the usual keys if you enter them in the usual way as D, Dmaj, Dmin, Dm, Dmix, Ddor, etc. etc.

Then if you choose a note in the dropdown list it will transpose the tune to the same mode/scale of the tonic you select, e.g. from Gm to Abm...

Thanks, Stiamh. Got it.

I apologize to all for a bit of thread-drift, for asking a question unrelated to Clive's excellent editor. I really was interested in an on-line editor that had a "transpose" feature.

TBV

Took me a while to figure that out too, but it is neat! I'm going to try and implement something similar myself (eventually).
Title: Re: ABC Player/Editor Webpage
Post by: Clive Williams on May 18, 2015, 12:07:49 AM
I had some good results resizing abcjs output for Kindle 3. If I can find the code I'll send it via PM.

... I think I've got resizing working now - but thanks for the offer Mike!
Title: Re: ABC Player/Editor Webpage
Post by: Clive Williams on May 18, 2015, 12:11:08 AM
I'm coming at it from a slightly different direction

Just to clarify, none of my posts pointing to other converters was intended as a snub to yours Clive, merely showing that other features are possible.

Not at all Pete - thanks for bringing these pages to my attention; I hadn't seen that one! Always on the lookout for other interesting implementations too; my favourite is ABCMus, an old Windows program with an automatic 'suggest a chord sequence' feature, complete with a 'strangeness' figure that you can change to alter the chord sequence from standard 3 chord trick to 'wacky jazz chords and beyond'. Would love to implement that!
Title: Re: ABC Player/Editor Webpage
Post by: Clive Williams on May 18, 2015, 12:12:58 AM
It was a very slow download here in Madrid, maybe much linked code(?) and didn't want to do much on this iPad, but congratulations.

name? Is DotABC copyrighted yet? It might make sense, particularly if it could also take a stave click and update the ABC panel. Is that a facility?

another "well done", Chris :|glug

I haven't really tested it on tablet yet if I'm honest; it "may" work, but I wouldn't bet the farm on it. Once I've got midi working properly I might spend a bit of effort to try and get it ipad/android compatible... but it very much depends on the midi implementation and how generic that is.
Title: Re: ABC Player/Editor Webpage
Post by: Clive Williams on May 18, 2015, 12:15:53 AM
Clive - the player side is not working for me - the QT logo appears to be greyed out - should it show a normal set of playback controls? I've just upgraded QT but no improvement. I'm using XP/FF38.0.1/QT7.7.6. The download midi link works and plays in WMP/VLC.

Any ideas what's wrong/missing?

vof

Yes, midi's a bit horrible at the moment - all the application does is output embedded midi and let the browser figure out what to do with it. Unfortunately, you need to have a very unusual combination of software running for embedded midi to actually work these days; most browser implementations fail miserably. I have had it working on one of my PCs running Firefox (with Quicktime installed), but it doesn't on another one. One of my priorities is to see if I can use a generic javascript midi player instead of relying on the browser - if so, this will be a lot more reliable. In the meantime though, the download link should work as you say.
Title: Re: ABC Player/Editor Webpage
Post by: Clive Williams on May 18, 2015, 12:17:34 AM
PS: Hopefully I fixed that horrible issue with autosizing the music score panel now. Transposing and a decent midi implementation to go!
Title: Re: ABC Player/Editor Webpage
Post by: brianread on May 18, 2015, 09:48:47 AM
Yes, midi's a bit horrible at the moment - all the application does is output embedded midi and let the browser figure out what to do with it. Unfortunately, you need to have a very unusual combination of software running for embedded midi to actually work these days; most browser implementations fail miserably. I have had it working on one of my PCs running Firefox (with Quicktime installed), but it doesn't on another one. One of my priorities is to see if I can use a generic javascript midi player instead of relying on the browser - if so, this will be a lot more reliable. In the meantime though, the download link should work as you say.

Works fine under firefox on Fedora 21, under chrome you have to open the downloaded file.
Title: Re: ABC Player/Editor Webpage
Post by: lildogturpy on May 18, 2015, 02:40:49 PM
I find it pretty useful but I miss their earlier version, which didn't do instant updating but handled outputting of large tunebooks very well (this one doesn't).

Yes, Robin Beech seems to have shot himself in the foot with this version. Draw the Dots (http://forum.melodeon.net/Draw the Dots) handles and stores tunebooks and you can set them to public or private.

If you can describe the problem to me, I'll take a look and see what can be fixed. Haven't had any feedback via the editor page itself so I wasn't aware there was a problem.

I just pasted the jigs.abc file from the montrealsession site into the editor and although the asynchronous update of the files was a little slow, it generated all the tunes in a single PDF file without any problem.

Following up on other comments, I found the abcjs library very difficult to adjust since there is almost no documentation and the code might be easy to follow for someone is more than just a javascript hack, but for me it took forever even to find out how to scale the abcjs output rendering.

Midi is always a nightmare. I don't think apple plan to continue supporting it even.

Robin Beech (limp, limp)
Title: Re: ABC Player/Editor Webpage
Post by: Stiamh on May 18, 2015, 06:32:17 PM
I just pasted the jigs.abc file from the montrealsession site into the editor and although the asynchronous update of the files was a little slow, it generated all the tunes in a single PDF file without any problem.

Robin, as you know, I relied on your old editor to produce PDF output from my band tunebook - approx. 250 tunes and 130 pages - which it would do in a matter of seconds.

The new editor cannot do this for me. It ignores formatting commands and decides what text fields it will reproduce and where it will position them, displays text on top of staves - and it bugs. I just tried again, and Firefox kept warning me that a script was not responding. (After clicking "Continue" 45 times I gave up and clicked "Debug" and the line shown is 1001 (2nd line of the SetTimeout function.))

I think I sent you my tunebook abc file when we were discussing this behaviour many months ago. Have you been able to get the new editor to work with it?

So, while I find your new editor very useful with its instant updating for creating, editing or transposing single tunes, I have abandoned the idea of using it produce a PDF tunebook. A blessing in disguise since it prompted me to install gs and abcm2ps and work out how to use them.

BTW I think Clive's idea of displaying the output side-by-side with the editing window, when screen size permits, would be a very useful improvement.
Title: Re: ABC Player/Editor Webpage
Post by: GuyWyatt on May 19, 2015, 11:23:34 AM
Clive, this is great fun. I am working from home today, which tends to be in my local coffee shop, to avoid the temptation of sitting around playing tunes.  Unfortunately, whilst taking a break, I found this and am now going to have to spend the rest of the morning playing with it.
G
Title: Re: ABC Player/Editor Webpage
Post by: lildogturpy on May 24, 2015, 09:29:44 PM
I just pasted the jigs.abc file from the montrealsession site into the editor and although the asynchronous update of the files was a little slow, it generated all the tunes in a single PDF file without any problem.

Robin, as you know, I relied on your old editor to produce PDF output from my band tunebook - approx. 250 tunes and 130 pages - which it would do in a matter of seconds.

BTW I think Clive's idea of displaying the output side-by-side with the editing window, when screen size permits, would be a very useful improvement.

thanks for the clarification. It maybe using abcjs that is causing the slowdown since the software to actually produce the pdf file is the same. I'll investigate. I like the idea of having the abc side by side with the music, worth taking a look at that too.
SimplePortal 2.3.5 © 2008-2012, SimplePortal