[Webkit-unassigned] [Bug 106001] Floating point precision error in AudioPannerNode

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Thu Jan 24 00:27:38 PST 2013


https://bugs.webkit.org/show_bug.cgi?id=106001





--- Comment #1 from Soo-Hyun Choi <s.choi at hackerslab.eu>  2013-01-24 00:29:32 PST ---
(In reply to comment #0)
> Please refer the sample code here below:
> 
> 
>       test(function () {
>             var context = window.AudioContext;
>             var pannerNode = context.createPanner();
>             pannerNode.maxDistance = 100.55;
>             assert_true(pannerNode.maxDistance === 100.55, "AudioPannerNode.maxDistance is float value" + pannerNode.maxDistance);
>         } );
> 
> Expected Result: Assert should return true.
> Current Result: Assert is returning false. Because pannerNode.maxDistance is getting value as 100.55000305175781.
> Analysis: While setMaxDistance() called, value is set as 100.55000305175781. The conversion is like double->float->double causing precision error.
> Verified version: Webkitr-137862.

This sounds like there is a bug in "Source/WebCore/platform/audio/Distance.h" whereby "setMaxDistance()" is trying to type-cast maxDistance variable into double (from what it is defined as float).

Any update?

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.


More information about the webkit-unassigned mailing list