Skip to content
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

Support of vorbis-compressed sf3 sound fonts #140

Closed
derselbst opened this issue Jun 23, 2015 · 4 comments · Fixed by #183
Closed

Support of vorbis-compressed sf3 sound fonts #140

derselbst opened this issue Jun 23, 2015 · 4 comments · Fixed by #183

Comments

@derselbst
Copy link
Member

Musescore 2.0 introduced a new soundfont format sf3
See: https://musescore.org/en/node/20818

I took the liberty to post this request from Fabian Greffrath [email protected] from
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=740710 into the ticket system of fluidsynth.

Musescore is widely used and created this new format as part of their version 2.0 delivery.
Would be great if this feature would be officially distributed by fluidsynth.

Reinhold

Reported by: z34rgfj35

Original Ticket: fluidsynth/tickets/142

@derselbst
Copy link
Member Author

I have created the attached patch to add support for sound fonts in SF3 format with Ogg Vorbis compressed samples to FluidSynth. It is mostly a proof of concept but works well already. I'd be glad if this would lead to the inclusion of this feature in FluidSynth.

Original comment by: fabian_deb

@derselbst
Copy link
Member Author

In the previous patch, I had an off-by-one error in the calculation of the sample sizes. In FluidSynth, sample->end points to the last valid point in a sample, not to the first point after. This means that all samples were calculated one byte too short.

Now, all samples are correctly decoded, i.e. there are no samples with sfinfo.frames == 0 anymore. This also means that the loopstart and loopend variables are now correctly set. Also, most of the quality loss that I originally blamed on the compression seems to be gone now.

Original comment by: fabian_deb

@fabiangreffrath
Copy link
Contributor

@derselbst
Copy link
Member Author

@fabiangreffrath Looks good. Feel free to create a pull request so this can be discussed. However, I currently dont think that this will make it into the upcoming 1.1.7 maintenance release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants