fluid-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[fluid-dev] soundfont recognition


From: Orcan Ogetbil
Subject: [fluid-dev] soundfont recognition
Date: Sat, 6 Jan 2018 15:13:04 -0500

Hi all,

A while ago, we received the following bug report on Fedora for qsynth:
https://bugzilla.redhat.com/show_bug.cgi?id=1399896

Basically, qsynth calls fluid_is_soundfont() with a filename, and if
the call returns 1, qsynth believes the file is a soundfont and it
saves the filename in its config. If the file starts with the RIFF
header but is not a soundfont file (e.g. wav, avi, ... file), qsynth
fails to load the file. But since the config is already written,
qsynth fails on subsequent starts. The workaround is to remove the
qsynth config file.

I began with working on the qsynth side to fix this problem. But it
occured to me, this should best be handled on the fluidsynth side by
making the fluid_is_soundfont() function a little smarter.

In the attached patch, the function not only checks for the RIFF
header, but also checks for the sfbk header between bytes 8-11. "sfbk"
is in the soundfont specification. e.g.
http://www.vgmpf.com/Wiki/index.php/SF2

Please feel free to take the patch or the idea.

Best regards,
Orcan Ogetbil

Attachment: fluidsynth-sfbk-header.patch
Description: Text Data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]