Re: [pointerevents] It is not possible to generate one set of angle values from other set (#321)

We would need to add those functions to the specification. Alternatively we can just have getAzimuth and getAltitude functions on PointerEvent which just returns its angle in these forms. So instead of saying PointerEvent.azimuth they'd have to call PointerEvent.getAzimuth and would get the same thing. But the attribute is not going to be in PointerEventInit dict anymore and no way for the developer to initialize the PE with azimuth/altitude.

There is one caveat with respect to this solution that is rare but I'd like to put it out there at least. For now pens are only on the top of the surface and can never be meaningfully parallel to the surface. So tiltX/Y seems fine in these cases. But in the future if there are some stylus devices that support like the whole sphere, the plane that is parallel to the surface tiltX/Y will have problems that one set like tiltX/tiltY=0 could represent any position on the parallel plane to the surface but Azimuth/Altitude can express exactly where the pen is. So if we only allow developers to create synthetic events with tiltx/y they will not be able to express these states correctly.

-- 
GitHub Notification of comment by NavidZ
Please view or discuss this issue at https://github.com/w3c/pointerevents/issues/321#issuecomment-628172961 using your GitHub account

Received on Wednesday, 13 May 2020 18:39:00 UTC