Hello m3guitar,

I have already implemented support for this, it will be merged shortly. I
currently have a pull request in for slides (needs a rebase before merging
- I'm working on that), and it will be the pull request after that which
adds support for this feature, so you will see this functionality appearing
in Musescore soon.

I understand from your IRC message that you are using this feature as a way
of educating yourself (though which aspect you are aiming to improve I
don't know - I assume that it is C++ programming). If that's the case, then
you could use my implementation as a sort of solution to that problem I
guess (you can see my implementation in my fork of Musescore on Github).
You might already be aware that the GPX format is fundamentally different
from the previous formats in Guitar Pro. The format is an archive, with is
compressed with a proprietary compression algorithm. Inside that is a
filesystem, inside which is a file 'score.gpif' which contains everything
you need (this file is in XML format). The previous versions of Guitar Pro
all had binary files as their input format. The following rough method can
be used to add support for fingering in Guitar Pro 6:

-> Get a GPX file decompressed, and rip out the 'score.gpif' file which is
inside the resulting filesystem. This contains everything you need to know.
(I recommend you take the current implementation for that).
-> Open Guitar Pro 6, make a trivial score with just one bar.
-> Inspect the resulting score.gpif file which describes this score.
-> Go back to Guitar Pro 6 and add fingering to a note.
-> Inspect the new score.gpif file and the difference in this file and the
initially created one is the information you are looking for. You can then
create as many notes as there are unique fingerings, and then add support
for all cases in the implementation.

More specifically, fingerings are attached to the "Note" descriptions
inside score.gpif, and not beats (as you would expect, the same beat can
have multiple notes each with a specified fingering). The relevant nodes of
the XML file are called "LeftFingering" and "RightFingering" for left and
right fingerings respectively. The fingering on the left hand is
represented as one of the list [O, t, 1, 2, 3, 4] where O is open, t is
thumb, and the following numbers indicate the finger digit. On the right
hand it is different, and the list is [P, I, M, A, C] ('open' is not
represented on the right hand).

Any questions/comments etc feel free to grab me either via this mailing
list or on IRC (feel free to also e-mail me directly, but if you think that
your comments might be helpful to future developers, the mailing list is
best so that such information is accessible to others). Cheers!

John




On 27 July 2014 14:36, m3guitar <[email protected]> wrote:

> Hi, I am new here, and as a tutorial project I want to add fingerings to
> the
> score when importing Guitar Pro tablature. I have got the basic
> functionality working for gp5, adding code around lines 2680 in
> importgtp.cpp where the finger number is readily available. My question is,
> does anyone know how to get the finger number from a gpx file (Guitar Pro
> 6)? I cannot see a way to extract it as with gp5.
>
> ole
>
>
>
> --
> View this message in context:
> http://dev-list.musescore.org/Fingerings-for-Guitar-Pro-import-tp7578877.html
> Sent from the MuseScore Developer mailing list archive at Nabble.com.
>
>
> ------------------------------------------------------------------------------
> Want fast and easy access to all the code in your enterprise? Index and
> search up to 200,000 lines of code with a free copy of Black Duck
> Code Sight - the same software that powers the world's largest code
> search on Ohloh, the Black Duck Open Hub! Try it now.
> http://p.sf.net/sfu/bds
> _______________________________________________
> Mscore-developer mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/mscore-developer
>
------------------------------------------------------------------------------
Want fast and easy access to all the code in your enterprise? Index and
search up to 200,000 lines of code with a free copy of Black Duck
Code Sight - the same software that powers the world's largest code
search on Ohloh, the Black Duck Open Hub! Try it now.
http://p.sf.net/sfu/bds
_______________________________________________
Mscore-developer mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mscore-developer

Reply via email to