ubuntustudio-bugs team mailing list archive
-
ubuntustudio-bugs team
-
Mailing list archive
-
Message #11650
[Bug 2047656] Re: [SRU] Players terminate after stopping and restarting
Here is the test in python (you can chooses any midifile and adapt the variable midifile accordingly).
You can also adapt the lib variable.
--
from ctypes import c_int, c_double, c_char_p, byref, CDLL
import logging
import time
lib="./libfluidsynth.so.3.2.2"
fluidsynth = CDLL(lib)
def b(s):
return s.encode("latin-1")
midifile="airwolf.mid"
settings = fluidsynth.new_fluid_settings()
fluidsynth.fluid_settings_setnum(settings, c_char_p(b('synth.gain')), c_double(0.2))
synth = fluidsynth.new_fluid_synth(settings)
filename="/usr/share/sounds/sf2/FluidR3_GM.sf2"
soundfont = fluidsynth.fluid_synth_sfload(synth, c_char_p(b(filename)), 0)
player = fluidsynth.new_fluid_player(synth)
fluidsynth.fluid_settings_setstr(settings, c_char_p(b('audio.driver')),
c_char_p(b('pulseaudio')))
audio_driver = fluidsynth.new_fluid_audio_driver(settings, synth)
errcode = fluidsynth.fluid_player_add(player, c_char_p(b(midifile)))
if (errcode!=0): logging.warning("add midi failed")
errcode = fluidsynth.fluid_player_seek(player, 0)
if (errcode!=0): logging.warning("seek failed")
total_ticks = fluidsynth.fluid_player_get_total_ticks(player)
errcode = fluidsynth.fluid_player_play(player)
if (errcode!=0): logging.warning("play failed")
total_ticks = fluidsynth.fluid_player_get_total_ticks(player)
time.sleep(1)
errcode = fluidsynth.fluid_player_stop(player)
if (errcode!=0): logging.warning("stop failed")
current_tick = fluidsynth.fluid_player_get_current_tick(player)
total_ticks = fluidsynth.fluid_player_get_total_ticks(player)
errcode = fluidsynth.fluid_player_play(player)
if (errcode!=0): logging.warning("continue failed")
--
You received this bug notification because you are a member of Ubuntu
Studio Bugs, which is subscribed to fluidsynth in Ubuntu.
Matching subscriptions: Ubuntu Studio Bugs
https://bugs.launchpad.net/bugs/2047656
Title:
[SRU] Players terminate after stopping and restarting
Status in fluidsynth package in Ubuntu:
Fix Released
Status in fluidsynth source package in Mantic:
Incomplete
Status in fluidsynth source package in Noble:
Fix Released
Bug description:
[ Impact ]
Fluidsynth 2.3.3 has an issue where it will terminate upon start/stop
of playback of a midi song, causing issues for a multitude of players
including EasyABC. This will cause said player to be unable to
playback again and perhaps even crash. See
https://github.com/FluidSynth/fluidsynth/issues/1272, fix in
https://github.com/FluidSynth/fluidsynth/commit/377ab9db2f87bc407eeb940e0361edc77da77055.
This is the included patch with the upload of
2.3.3-2.1ubuntu-0.23.10.1
[ Test Case ]
* Begin midi playback in any midi player using fluidsynth from the
terminal
* Stop midi playback
* Attempt start again
* Error in terminal: fluidsynth: error: The maximum playback duration
has been reached. Terminating player!
[ What could go wrong ]
This is actually a fix for a regression that was found in version
2.3.3 of fluidsynth and fixed for 2.3.4, which can be found in noble.
I think the only thing that can go wrong here is that this patch is
not the actual fix and we need to find more solutions within.
I have tested this in my PPA and it *seems* to fix it, but it would be
nice if the original reporter could verify once this lands in
proposed.
[ Other information ]
Included below is the original report, in which case the reporter
deduces that the problem is the binary being spat-out is the 2.3.2
version from the 2.3.3 sources. This is not the case, as it appears to
be confusion due to the -2.1 Debian revision number. I assure, this is
definitely the 2.3.3, and the bug, per the github link in the Impact
section, is pertinent to this version.
---
The latest package of fluidsynth should include the sources from
version 2.3.3 but the binary includes only version 2.3.2
This version has a bug (see
https://github.com/FluidSynth/fluidsynth/issues/1272), which leads to
problems in EasyABC.
Please include the latest version 2.3.3 from upstream in the ubuntu
package.
--
Description: Ubuntu 23.10
Release: 23.10
Codename: mantic
$ apt-cache policy libfluidsynth3
libfluidsynth3:
Installiert: 2.3.3-2.1
Installationskandidat: 2.3.3-2.1
Versionstabelle:
*** 2.3.3-2.1 500
500 http://de.archive.ubuntu.com/ubuntu mantic/universe amd64 Packages
100 /var/lib/dpkg/status
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/fluidsynth/+bug/2047656/+subscriptions
References