Bug Issue: Muffled Sounds On HTML5


Pages: 1

RosalinaGalaxer

  • Level 3 Stencyler
March 05, 2019, 01:15:47 pm
When testing on HTML5, all sounds (Music and Sound Effects) are muffled and get random pops. This is not the case on Flash. I haven't tested any other platforms as of yet.


rob1221

  • Master Stencyler
  • *
March 07, 2019, 05:43:20 am
This isn't something I've noticed before.  Does this happen on every sound file, including those created from different sources?  Also is this web HTML5 or mobile?
  • Status changed from New to Need Info


RosalinaGalaxer

  • Level 3 Stencyler
March 07, 2019, 12:01:07 pm
This happens on every sound file, with multiple different export options and from multiple sources. I have not tested mobile HTML5: this is all on web HTML5.

I think it's also worth mentioning that (on HTML5) you need to cause a second sound effect to play to get your looping music playing, even if the music is started in a scene "when created" event.


irock

  • Master Stencyler
  • *
March 07, 2019, 07:13:23 pm
I've noticed this as well on HTML5, tested in both Firefox and Safari on Mac. The sound files in the assets folder for the built game sound fine, but it sounds really low quality when played in engine.


rob1221

  • Master Stencyler
  • *
March 08, 2019, 07:11:56 am
I tested one of my games on Flash/HTML5 (Firefox on Windows) but I'm not hearing any audio problems and I'm also not getting the initial sound looping problem.


RosalinaGalaxer

  • Level 3 Stencyler
March 08, 2019, 02:15:46 pm
Very strange.

Here's how everything should sound: https://www.newgrounds.com/dump/item/cdfe604604423def9486eaab36d3d767

And here's how it sounds on HTML5: https://www.newgrounds.com/projects/games/1309603/preview

Please tell me I'm not crazy, and it breaks on your end too.


rob1221

  • Master Stencyler
  • *
March 08, 2019, 03:10:34 pm
Yeah I hear the difference there.  I have no idea what would cause it though.
  • Status changed from Need Info to New


RosalinaGalaxer

  • Level 3 Stencyler
March 12, 2019, 12:59:55 pm
So is there anything I can do to help figure out what's wrong?


rob1221

  • Master Stencyler
  • *
March 12, 2019, 01:17:45 pm
Unless the problem is specific to certain files, I'm not sure what can be done other than wait for OpenFL (or their HTML5 audio library Howler) to fix the problem.


RosalinaGalaxer

  • Level 3 Stencyler
March 29, 2019, 05:10:46 pm
A small update: none of these issues exist when testing on Windows. I'm not sure if that means we can do anything about it, though. Does the Windows end of Stencyl run on OpenFL?


rob1221

  • Master Stencyler
  • *
March 29, 2019, 06:05:50 pm
Yeah it does.


RosalinaGalaxer

  • Level 3 Stencyler
March 29, 2019, 10:06:06 pm
Are sounds set up differently on OpenFL for Windows and HTML5? If they're the same, then it might actually be a problem on our side...


rob1221

  • Master Stencyler
  • *
March 30, 2019, 04:19:46 am
They are different.  Howler is only for HTML5.  I'm guessing the problem is there, although it's possible the problem could be in OpenFL's code.
https://github.com/goldfire/howler.js


RosalinaGalaxer

  • Level 3 Stencyler
March 30, 2019, 09:19:19 am
Is it possible to edit Howler? I found this: https://github.com/goldfire/howler.js/issues/112 but I'm not sure where I'd go to implement it.


rob1221

  • Master Stencyler
  • *
March 30, 2019, 10:18:02 am
The only file I found is plaf/haxe/lib/lime/lime/dependencies/howler.min.js which seems to be a really compressed version of the source so I don't know how you'd go about editing it.


RosalinaGalaxer

  • Level 3 Stencyler
April 05, 2019, 12:58:38 pm
So I tested on Internet Explorer and Microsoft Edge. Neither had audio issues. Chrome seems to be the only browser that gets muffled audio.

I also found out that Chrome has a weird policy that won't allow an HTML5 object to play sound until the user interacts with said HTML5 object. So I just needed to set up a scene that gets the player to click on the screen before any sounds are played.

However, I want this game to run on Chrome because other than this audio problem, Chrome runs the game like a dream compared to IE or ME.
« Last Edit: April 05, 2019, 12:59:02 pm by RosalinaGalaxer »


Justin

  • Master Stencyler
  • *
June 27, 2019, 05:42:47 pm
We can't do anything about Chrome's policy about not playing audio until user input is detected, unfortunately.

The howler issue you referenced is quite old, and any fixes that may have been made there have likely been picked up by OpenFL quite some time ago.

Between 4.0.1 (assuming you're on that build) and the latest private builds, Howler was updated from 2.1.0 to 2.1.1, so maybe something in that update improved this. You can try it out once we release the next public build.
  • Status changed from New to Assigned
  • Issue Assigned from (none) to Justin


Pages: 1

Details

  • Reported
    March 05, 2019, 01:15:47 pm
  • Updated
    June 27, 2019, 05:42:47 pm

  • View Status
    Public
  • Type
    Bug
  • Status
    Assigned
  • Priority
    Normal
  • Version
    Stencyl 3.5
  • Fixed in
    (none)
  • Assigned to
    Justin
  • Category
    Sound Editor

Tags