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

mikmod broken volume and loop support #119

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

mikmod broken volume and loop support #119

SDLBugzilla opened this issue Feb 11, 2021 · 0 comments

Comments

@SDLBugzilla
Copy link
Collaborator

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: All, All

Comments on the original bug report:

On 2012-07-26 14:41:56 +0000, wrote:

Created attachment 914
patch to fix volume and looping issues in SDL_mixer mikmod suppport

When playing .mod or .it files using SDL_mixer's mikmod support looping and initial volume are ignored, making music play improperly and making volume reset to max every time the song loops. This makes Mix_VolumeMusic work differently for mikmod than any other music support as it doesn't persist volume through the loop.

Attached is a quick patch I made that fixes both issues for me by enabling loop support and setting the initial volume when starting play.

On 2012-07-26 23:13:33 +0000, Sam Lantinga wrote:

Does it enable loop support, or does it actually make all mod music loop by default?

On 2012-07-26 23:26:11 +0000, wrote:

Created attachment 915
fixed version of patch without wrap turned on

the "loop" setting for mikmod enabled in-module looping, not looping the entire mod, with it set to 0 mikmod will ignore any segement loops which causes most songs to play improperly.

I just uploaded a new patch though, i noticed i accidently left "wrap" turned on after you mentioned that, "wrap" is the setting that tells the mod file to play forever in mikmod so you probably don't want that patched in on your version.

On 2012-10-06 03:06:52 +0000, Mika Attila wrote:

I tested the patch, and it works well for me.

As raptor85 mentioned, wrap is the flag that tells mikmod to loop forever.

The loop flag is for in-module loops, which should play how they are meant to, even if they play endlessly regardless of the loop parameter in SDL_PlayMusic.

In that case, the user should manually stop the song when he wants to.

On 2017-10-21 22:21:48 +0000, Sam Lantinga wrote:

Fixed, thanks!
https://hg.libsdl.org/SDL_mixer/rev/4359e193d93f

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