howler.js icon indicating copy to clipboard operation
howler.js copied to clipboard

Google Chrome deprecation warnings.

Open tammesalu opened this issue 9 years ago • 9 comments

Google Chrome is giving me following warnings when I use Howler in my project:

howler.js:2213 [Deprecation] GainNode.gain.value setter smoothing is deprecated and will be removed in M64, around January 2018. Please use setTargetAtTime() instead if smoothing is needed. See https://www.chromestatus.com/features/5287995770929152 for more details.

[Deprecation] AudioParam value setter will become equivalent to AudioParam.setValueAtTime() in M65, around March 2018 See https://webaudio.github.io/web-audio-api/#dom-audioparam-value for more details.

Does anyone know what are those warnings and can they be addressed in Howlers code?

tammesalu avatar Nov 21 '17 15:11 tammesalu

It is only a couple of weeks left until January, so is it possible to have this fix released to NPM?

klaasman avatar Dec 11 '17 08:12 klaasman

This just got pushed to npm in 2.0.6.

goldfire avatar Dec 15 '17 22:12 goldfire

Great, thanks!

klaasman avatar Dec 16 '17 07:12 klaasman

I'm still getting the following deprecation warning in 2.0.7

[Deprecation] AudioParam value setter will become equivalent to AudioParam.setValueAtTime() in M65, around March 2018 See https://webaudio.github.io/web-audio-api/#dom-audioparam-value for more details.

It appears that 0b538a7 only addressed the issue with GainNode.gain.value but the issues with rate still exist.

The culprit is here: sound._node.bufferSource.playbackRate.value = sound._rate;

This should probably also be updated: sound._node.bufferSource.playbackRate.value = rate;

Stenerson avatar Dec 29 '17 16:12 Stenerson

@Stenerson Thanks! Just fixed this with dc0a2cf8d2c0ca17246573de90c7f95f6991438d and will try to get a 2.0.8 release out soon.

goldfire avatar Dec 29 '17 22:12 goldfire

Is the first warning a breaking change?

"GainNode.gain.value setter smoothing is deprecated and will be removed in M64"

I've just updated to M64 and, though I still get the warning, the audio still works.

Edit: I've looked into it and as far as I can see, it's not a breaking change, it just means that the Gain will be set immediately instead of smoothly (unless setTargetTime is used instead). If that's so, I can live with that and just update projects as other changes are made.

julesongithub avatar Jan 25 '18 09:01 julesongithub

[Deprecation] AudioParam value setter will become equivalent to AudioParam.setValueAtTime() in M65, around March 2018 See https://webaudio.github.io/web-audio-api/#dom-audioparam-value for more details.

The error is in reference to sound._node.bufferSource.playbackRate.value = sound._rate; within the _refreshBuffer function.

EDIT: Nevermind, I didn't see the update.

DFortun81 avatar Feb 08 '18 22:02 DFortun81

@DFortun81 That was fixed in v2.0.8.

goldfire avatar Feb 08 '18 22:02 goldfire

Yeah, sorry. I didn't see the update.

DFortun81 avatar Feb 08 '18 22:02 DFortun81