| Summary: | Distorted MIDI playback with FluidSynth if Windows sample rate set to 192kHz | ||
|---|---|---|---|
| Product: | SDL_mixer | Reporter: | Fabian Greffrath <fabian+debian> |
| Component: | misc | Assignee: | Ryan C. Gordon <icculus> |
| Status: | RESOLVED FIXED | QA Contact: | Sam Lantinga <slouken> |
| Severity: | normal | ||
| Priority: | P2 | CC: | sezeroz |
| Version: | 2.0.2 | ||
| Hardware: | x86_64 | ||
| OS: | Windows 10 | ||
| Attachments: | patch for bug #3969 | ||
|
Description
Fabian Greffrath
2017-11-17 21:09:44 UTC
Created attachment 4766 [details] patch for bug #3969 The attached patch against current development tree does the following: - calls fluid_settings_getnum() to learn the actual samplerate, as set by the library, and passes that to SDL_NewAudioStream() as 'src_rate' instead of music_spec.freq: This _should_ fix the original issue as reported by Fabian Greffrath. - frees the audio stream in FLUIDSYNTH_Delete() which, I think has been an oversight for some time. This is compile-tested only: please review and test. The brace-matching ordeal in FLUIDSYNTH_Load() was a tough one, i.e.: I could easily have made a mistake there. ('hg diff -w' would give you a more readable diff ignoring whitespace changes.) Patch now run-tested on Linux and push to current hg as https://hg.libsdl.org/SDL_mixer/rev/8def6444de8a Closing as fixed. |