I'm writing a quick front end to display guitar tablature. The front end is in Flash but I want to store the tab in some human-readable format. Anyone know of something that already exists? Any suggestions on how to go about it? One idea I got from reading some stackoverflow posts was to use a strict ASCII tab format like so:
e||-1------3--------------0--|----2-------0---
B||--1-----3------------1----|----3-------0---
G||---2----0----------0------|----2-------1---
D||----3---0--------2--------|----0-------2---
A||----3---2------3----------|------------2---
E||----1---3----3------------|------------0---
It has advantages. I can gain a lot of info from the structure (how many strings, their tunings, the relative placement of notes) but it is a bit verbose. I'm guessing the '-'s will compress away pretty well when sent over the wire.
If anyone knows of an existing data-format for describing guitar tab I'll take a look as well.
edit:
I should note that this format is 90% for me and may not ever been seen by anyone other than myself. I want an easy way to write tab files that will be displayed eventually as graphics in a Flash front-end and I don't want to have to write an editor front end.
Write numbers on the lines that correspond to where the string is fretted. To start transcribing the notes of the song, play the song. Start slow and play 1 or 2 notes, then pause and write them down. To transcribe a chord, write the fret numbers for each string stacked on top of each other in a vertical.
A tab is usually written using six horizontal lines, each corresponding with a string on the guitar. The bottom line represents the lowest, thickest string, while the top string represents the highest, thinnest string.
The numbers you will see on a piece of tablature represent the frets you are supposed to put your fingers on. You read these numbers from left to right just like you would read a book. Notes: Single numbers from left to right represent a melody line or solo that you might play.
p = pull-off. b = bend. / = slide up. \ = slide down. PM – – – – = palm muting (above or below TAB)
Check out the ASCII tab format. Also great description of the format is here:
http://www.howtoreadguitartabs.net/
ASCII export would be a great feature, but using ASCII as internal data format is not a good idea. For example, note durations would be extremely hard to express (hou would you store 32nds or even 16ths?, not to mention triplets...), so parsing those files would be extremely difficult. Moreover, users would be tempted to load ASCII files created outside your app, which will be likely to fail.
To sum up, i'd recommend to either try to reuse existing format or invent your own if that's not feasible. You may try to use XML for that.
EDIT: Beside DGuitar, i know of TuxGuitar and KGuitar, which support Guitar Pro files. You can look into their sources or ask their authors about file formats. I think there is also open source PowerTab-to-ASCII converter.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With