CoderLine / alphaTab

alphaTab is a cross platform music notation and guitar tablature rendering library.
http://www.alphatab.net
Mozilla Public License 2.0
1.24k stars 202 forks source link

Multiple Time Signatures across multiple tracks #287

Open dgriessler opened 5 years ago

dgriessler commented 5 years ago

Your environment

Expected Results

I have multiple tracks and one set of tracks has a time signature 4 4 and the other set of tracks has a time signature 12 8. The tracks with a time signature 4 4 should have that displayed on their line and those with 12 8 should have that displayed on their line.

Observed Results

The 12 8 time signature is displayed on all tracks.

Steps to Reproduce (for bugs)

  1. See the linked source code. The index.html contains the alphaTex currently being rendered. In a nutshell:
    \track "Soprano"
    \staff {score} \tuning piano \instrument acousticgrandpiano \ks G
    \ts 4 4 :2 g3{-} r |
    \track "Piano Accompaniment"
    \staff {score} \tuning piano \instrument acousticgrandpiano \ks G \clef F4
    \ts 12 8 :1 g2{d} |

    will show only the 12 8 time signature. The alphaTex that is currently being rendered is longer.

Possible Solution

I'm guessing that it assumes there is only one time signature across tracks. You'd have to expand it to accept multiple and draw multiple.

Danielku15 commented 5 years ago

I think this is not how music sheets work. Time signatures are just like the tempo an element that must be the same for all instruments placed within a song. It would break almost any logic when you display 2 instruments of the same song side-by-side.

dgriessler commented 5 years ago

It's called Polytempo https://en.wikipedia.org/wiki/Polytempo Although rare for it to occur in one track, some composers do include it. In my case, the piano accompaniment is in 12 8 while the choral group is singing in 4 4. I can submit a feature request if that should be my next step since it doesn't sound like its currently supported.