Skip to content
This repository was archived by the owner on Dec 17, 2024. It is now read-only.
This repository was archived by the owner on Dec 17, 2024. It is now read-only.

Audio clips can get stuck at 100% volume #110

@tomdixon

Description

@tomdixon

When many instances of a single short clip are triggered in quick succession, Howler can get into a state where subsequent changes to the volume of the clip are ignored. This has the effect of the clips always being played at full volume even if the volume on the play action is set to less than 100%.

After some investigation it appears that Howler's internal loadQueue is getting stuck with a stop event from the clip which is never removed from the queue, preventing the volume change events from ever firing after the clips start playing:

image

This appears to be an unintended side effect of this fix which was necessary to fix an issue with looping clips sometimes never stopping: clockwork-dog/howler.js@63acd80

Reverting this change seems to prevent the issue from happening, I believe due to the fact that the stop event is not always being emitted with the above change that passes through the internal flag to the queued stop event:
https://github.com/goldfire/howler.js/blob/a2a47933f1ffcee659e4939a65e075fa7f25706c/src/howler.core.js#L1138

The reasons for this are tied up in the core of Howler's logic and will need some thorough investigation to unpick.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions