Impact

This forum is read only and just serves as an archive. If you have any questions, please post them on github.com/phoboslab/impact

1 decade ago by MikeL

I just started working with sound for my games. I have been using a sound for the ship shooting. I notice there appears to be a delay in the firing sound. Not for all of the shots, just periodically.

I did a quick test with Biolab and thought I perceived the same delay - but only occasionally. I'm guessing this has something to do with the browser/canvas/HTML 5 combo and the timing of the sound actually playing? I just tested with Chrome 10.0.648.205.

1 decade ago by BFresh

Yeah noticed wild variations in the ability of browsers to play back audio. The only thing I really know to do is make sure audio files are pre-loaded. Besides that, I noticed that IE9 had no audio lag for me, Chrome had a bit and was spotty, Safari had a ton of lag. Firefox also had some lag. I ended up using full songs for background music because at first I tried just short loops that I hoped would be continuous but you could here the lag between it finishing and playing again. I tried to accommodate for that in the sound file to make it still sound good and the result was that it sounded good in one browser but not another with more or less lag so I dropped it. I just dont think browsers are that great with sound yet.

I also played with the number of multi-channels allowed and it didn't seem to change things much.

1 decade ago by MikeL

Thanks for the quick feedback BFresh. I know that you've been doing a lot of work with that, so it's very helpful. The next thing I was going to mess with was the multi-channels, so you've saved me some time. :)

We'll just have to wait for the browsers to catch up!

1 decade ago by fugufish

HTML5 audio was excellent for me in:
Safari 5 (Mac)
FF 4

it's very choppy in Chrome 10+11, the choppiness increasing with canvas size!

1 decade ago by Ken

Yep same thing here with my game. I removed the sound of the ball hitting objects and simply just use a background track to give it a sense of mood. Right now I think the html5 audio is good for ambient sounds. For example in YOSS you could do things like ships exploding in the distance or other battle type sounds in your game I would think this would put up an auditory illusion of the battle without needing sounds linked directly to quick events. That's going to be my approach right now at least.
Page 1 of 1
« first « previous next › last »