New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't parse some files #31

Closed
emanchado opened this Issue Oct 8, 2012 · 2 comments

Comments

Projects
None yet
2 participants
@emanchado

emanchado commented Oct 8, 2012

Hi there,

I was delighted to find alphaTab, it's a very cool piece of software. My use-case for it is simply loading .gpx files so I can print them.

Long story short, it doesn't seem to parse some/many of the files produced by the (Android) mobile app. After debugging it a bit, it seems the problem is that alphaTab is a bit too strict in parsing. Wild guess: the mobile app doesn't clean up the file contents after deleting notes, so the file ends up with "empty" notes that make alphaTab barf; maybe the desktop version does clean up and that's why you haven't seen the issue.

Anyway, as I didn't really want to learn Haxe or install any of the tools and figure them out, I simply debugged and patched the generated Javascript. The patch is very small and simple, so it shouldn't be any problem for you to figure out how to adapt it to the original sources. See https://gist.github.com/3854210 for the raw JS patch.

I haven't written any tests (I haven't even checked if you have tests for this), but I can send you a couple of files that failed but work now, if you want.

Thanks a lot for alphaTab, you rock!

@Danielku15

This comment has been minimized.

Member

Danielku15 commented Oct 9, 2012

Thanks for the patch. I will consider it in the new alphaTab version. The GPX parser is quite basic in the current alphaTab state. The main problem is that the structure of the GPX file is quite different from my current class model which makes it hard to parse.

@emanchado

This comment has been minimized.

emanchado commented Oct 27, 2012

Hmmm... actually the second hunk of that patch was kind of silly. The problem in that case seemed to be silences, not "broken notes".

I've created a second version of the patch that seems to support the same files, but actually shows the silences in them :-) See https://gist.github.com/3963781

@Danielku15 Danielku15 closed this Jan 2, 2014

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