Note: I did not verify the Quickstart example because the same example works properly on another platform.
Code to reproduce the issue:
room.getStats().then(function(value) {
if (value && value.length) {
value[0].remoteAudioTrackStats.forEach(function(track) {
log(`track.trackSid: ${track.trackSid} level ${track.audioLevel}`);
});
}
});
Expected behavior:
Audio levels in the documented range 0...32767, working good on Safari 14 on Mac OS:
[Log] "track.trackSid: MT3af13d717aff1d269e56d2fd64c3856b level null"
[Log] "track.trackSid: MT3af13d717aff1d269e56d2fd64c3856b level 43"
[Log] "track.trackSid: MT3af13d717aff1d269e56d2fd64c3856b level 28"
[Log] "track.trackSid: MT3af13d717aff1d269e56d2fd64c3856b level 23"
[Log] "track.trackSid: MT3af13d717aff1d269e56d2fd64c3856b level 25"
Actual behavior:
Out of range values on Brave Browser 1.15.72:
// not speaking, room is silent:
track.trackSid: MTfbcf486eef... level 753641
track.trackSid: MTfbcf486eef... level 753641
track.trackSid: MTfbcf486eef... level 819175
track.trackSid: MTfbcf486eef... level 622573
// when speaking:
track.trackSid: MTfbcf486eef... level 243688179
track.trackSid: MTfbcf486eef... level 12746363
Software versions:
Official Chrome 86 seems to be having similar issues, (v85 working fine).
(EDIT: Previously included some tests showing different numbers - then realised we've divided and log-scaled them. That would put them on similar scales to what julien saw above - I'll take a look and post updated numbers if they differ).
Out-of-range numbers on Windows 10 - 10.0.19042, Chrome 86.0.4240.75
Working fine on Windows 10 - 10.0.19042, Chrome 85.0.4183.121
Hi @julien-l ,
Thanks for writing in with your issue. @makarandp0 Can you take a look and file a Chromium bug if necessary?
Thanks,
Manjesh
Hello @julien-l and @tr00st - Thank you for reporting this issue. This looks like bug in recent version of chrome which is returning wrong values for audioLevel. I will file a bug against chrome soon, I have also filed a bug to workaround this issue in the SDK (JSDK-3053).
This is https://bugs.chromium.org/p/chromium/issues/detail?id=1142626 and looks like it will get fixed in M88. I will keep watch on the chrome build when it's available
Most helpful comment
Hello @julien-l and @tr00st - Thank you for reporting this issue. This looks like bug in recent version of chrome which is returning wrong values for audioLevel. I will file a bug against chrome soon, I have also filed a bug to workaround this issue in the SDK (JSDK-3053).