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

[PATCH] native_midi_macosx: volume should be set before starting playing #289

Closed
SDLBugzilla opened this issue Feb 11, 2021 · 0 comments
Closed

Comments

@SDLBugzilla
Copy link
Collaborator

SDLBugzilla commented Feb 11, 2021

This bug report was migrated from our old Bugzilla tracker.

These attachments are available in the static archive:

Reported in version: unspecified
Reported for operating system, platform: Mac OS X (All), All

Comments on the original bug report:

On 2020-11-18 20:42:29 +0000, wrote:

Created attachment 4525
native_midi_macosx: set volume before starting playing

On macOS, the native MIDI backend applies volume after the MIDI file starts playing, which can lead to a split second of music at an incorrect volume (e.g. say you want to fade it in, or just have it start muted).

I tracked this to native_midi_start in native_midi_macosx.c, which calls MusicPlayerStart before calling GetSequenceAudioUnit and native_midi_setvolume — this needs to be the other way round. We can safely move these around since we have a valid AudioUnit in the graph after calling MusicPlayerPreroll.

Patch attached.

On 2020-11-22 08:37:59 +0000, Ozkan Sezer wrote:

This patch is in: https://hg.libsdl.org/SDL_mixer/rev/900ad643ac68
Thanks.

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

No branches or pull requests

1 participant