- From: <bugzilla@jessica.w3.org>
- Date: Tue, 14 Aug 2012 12:36:48 +0000
- To: public-html@w3.org
https://www.w3.org/Bugs/Public/show_bug.cgi?id=18556
Summary: 2d.imageData.object.round.html has wrong expectations
Product: HTML WG
Version: unspecified
Platform: All
OS/Version: All
Status: NEW
Severity: normal
Priority: P2
Component: HTML Canvas 2D Context
AssignedTo: dave.null@w3.org
ReportedBy: dominik.rottsches@intel.com
QAContact: public-html-bugzilla@w3.org
CC: mike@w3.org, public-html-wg-issue-tracking@w3.org,
public-html@w3.org
2d.imageData.object.round.html expects flooring for decimal values. AFAICS,
this is not up to date any more. I conclude that there's the following chain:
ctx.getImageData() returns an ImageData object whose data property is of type
Uint8ClampedArray. According to:
http://www.khronos.org/registry/typedarray/specs/latest/#7.1
Uint8ClampedArray uses WebIDL's _Clamping_ semantics, not EnforceRange
semantics.
Looking at
http://www.w3.org/TR/WebIDL/#Clamp , we read:
"See the rules for converting ECMAScript values to the various IDL integer
types in section 4.2 for the specific requirements that the use of [Clamp]
entails."
which then redirects to 4.2.5.3 (the Clamp case, not the EnforceRange) case:
http://www.w3.org/TR/WebIDL/#es-octet
which mandates rounding, not flooring.
Hence, the expectations in the patch should be changed to nearest values, not
floored values.
--
Configure bugmail: https://www.w3.org/Bugs/Public/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
Received on Tuesday, 14 August 2012 12:36:52 UTC