Skip to content

feat(drums/tabs): allow showTablature for percussion (drums) notation#2591

Open
leocaseiro wants to merge 3 commits intoCoderLine:developfrom
leocaseiro:allow-tabs-for-drums
Open

feat(drums/tabs): allow showTablature for percussion (drums) notation#2591
leocaseiro wants to merge 3 commits intoCoderLine:developfrom
leocaseiro:allow-tabs-for-drums

Conversation

@leocaseiro
Copy link
Copy Markdown

Issues

Related to #474

Proposed changes

In this PR, I am allowing the display of tablature for drums as well.
This is useful to identify different patterns in drum guitar pro files. As some drummers use on kick (35) or another (36), or alternative toms that can be considered T1 (high), T2 (medium), or Floor Tom (low), but is quite different from gp file to file.

This feature is already available in Guitar Pro, Tux Guitar, and Soundslice.

Luckily for us, *.gp files already provide the string, and fret as an alternative tuning:

<Property name="Tuning">
    <Pitches>0 0 0 0 0 0</Pitches>
    <Flat></Flat>
    <Instrument>Undefined</Instrument>
    <Label>
        <![CDATA[]]>
    </Label>
    <LabelVisible>true</LabelVisible>
</Property>

eg.

<Note id="0">
    <InstrumentArticulation>8</InstrumentArticulation>
    <Properties>
        <Property name="ConcertPitch">
            <Pitch>
                <Step>C</Step>
                <Accidental></Accidental>
                <Octave>-1</Octave>
            </Pitch>
        </Property>
        <Property name="Fret">
            <Fret>36</Fret>
        </Property>
        <Property name="Midi">
            <Number>36</Number>
        </Property>
        <Property name="String">
            <String>4</String>
        </Property>
        <Property name="TransposedPitch">
            <Pitch>
                <Step>C</Step>
                <Accidental></Accidental>
                <Octave>-1</Octave>
            </Pitch>
        </Property>
    </Properties>
</Note>

Checklist

  • I consent that this change becomes part of alphaTab under it's current or any future open source license
  • Changes are implemented
  • New tests were added

Further details

  • This is a breaking change (I don't think it is)
  • This change will require update of the documentation/website (not sure tbh)

I have included, as part of test-data, an example with default values from GuitarPro. (drum-tabs.gp).
drum-tabs

GuitarPro allows customising the line for each note individually, so I also added a file with custom settings for the same note (e.g., bass drum - 36).

drum-custom-lines

@leocaseiro
Copy link
Copy Markdown
Author

I found out an issue when loading some weird .gp that don't have the correct string.
E.g. <String>6</String>, so I am forcing to load on line 5 instead.

These ones are ignored in TuxGuitar, and are loaded only in the staff on GuitarPro, but not in tabs.
(pushed a way to force to be always 5, if string is 5+.

@Danielku15
Copy link
Copy Markdown
Member

I think this PR needs some more polishing to handle the real-world file scenarios correctly and I am wondering if these "tabs" are really something drummers want to see. The drummers I talked to in the past, would not know how to read/play such numeric tabs.

Arobas is changing back-and-forth with the feature to allow tabs for percussion. It is not guaranteed that a score.gpif defines strings for percussion notes as some versions didn't support this.

If we want to support such display, alphaTab would need to be extended overall to support this. e.g. in all exporters and importers we would need to handle it correctly.

Your change currently breaks various assumptions and checks within alphaTab as it does not support mixing "fret/string" and "percussion articulations" within one staff.


I think it would be better to first collect the full scope of supporting "numeric drum tabs" and then implement things across all areas.

@leocaseiro
Copy link
Copy Markdown
Author

Hi @Danielku15, thank you so much for the feedback, and context.

I apologise that my approach might break something that I'm unaware. I really wanted to able to see both notation and what midi input we have in each drum
Note.

I agree that some drummers might not use the numbers in isolation to read, but I have 2 edge cases for those to use combined with the standard notation.

  1. used in editing mode. Feature Request: add/edit percussion tracks gallegretti/escala#5

  2. to be able to identify what is the correct note when hitting with midi input (https://leocaseiro.github.io/alphaTabWebsite/docs/rhythm-game)

The second case is a experiment in doing that uses alphatab as a rhythm game. It's more useful for drums, but could use for keyboard, and my goal in the future is to try identify the frequency via microfone to listen to guitar too.

The drum midi notes, is useful to identify why my notes are not the correct one. Unfortunately, there are too may variations of drum notations. Some drummers use the 35 for the bass drum kick, when others use 36, instead.

Eg with 36 https://www.songsterr.com/a/wsa/metallica-one-drum-tab-s444

Eg with 35 https://www.songsterr.com/a/wsa/metallica-all-metallica-songs-drum-tab-s558950

For toms, the variation is even more discrepant. Where some drummers would use high time with 48, and others with 47 or 50.

Eg
Multiple toms:
https://www.songsterr.com/a/wsa/metallica-all-metallica-songs-drum-tab-s558950

So having the number in the UI, helps to the player to map the drum note properly.

As my approach wasn't the best one, I am willing to discuss a better option. Do you use discord or something else? Or here in GH is your best contact?

Thanks in advance.

@Danielku15
Copy link
Copy Markdown
Member

As my approach wasn't the best one, I am willing to discuss a better option. Do you use discord or something else? Or here in GH is your best contact?

Analyzing things bottom up within alphaTab:

I think the general approach is not fully wrong, it is just not complete. I'd say from a data model perspective we could open up that "percussion notes" can be composed from a "instrument articulation" + "string". And percussion staves need to have a "tuning" defining the number of "strings" shown for tabs. This has to be checked across the data model that we do not clear out any string values (e.g. on the finish chain).

Then across the importers we have to ensure that we fill the string value correctly. For some importers it might mean to find a "empty" string we can place things on.

For alphaTex we'd need to add some syntax to specify the string for the note. Best would be the same syntax as for guitar tabs.

Then also all exporters have to be adapted accordingly.

For MIDI/Audio nothing changes.

On rendering we would need to ensure we create the tab clef and show the respective number (from instrument articulation) and string.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants