W3C home > Mailing lists > Public > public-device-apis-log@w3.org > March 2017

Re: [sensors] Provide the DeviceOrientation sensor

From: Tobie Langel via GitHub <sysbot+gh@w3.org>
Date: Wed, 01 Mar 2017 15:27:35 +0000
To: public-device-apis-log@w3.org
Message-ID: <issue_comment.created-283371516-1488382047-sysbot+gh@w3.org>
> With screen orientation API this would be impossible. Using rotation
 matrices is overkill for such simple use-case, thus, I think, some 
helper methods / constants might be useful.

Whether or not that use case is actually a valid one—I'd probably 
argue higher-level events (e.g. `oncallpaused`) would make more sense,
 here—this is the very distinction I'm trying to make between 
high-level and low-level sensors. We should have separate constructors
 for these, not a huge kitchen-sink API.

There's also little sense for an API with such a coarse output to be 
able to specify input parameters like polling frequency with such 
precision. So maybe my initial plan to have `MotionSensor` extend 
`Sensor` is not the right one. Maybe we instead need to have 
`HighFrequencySensor` extend `Sensor` (or something like that).

GitHub Notification of comment by tobie
Please view or discuss this issue at 
https://github.com/w3c/sensors/issues/170#issuecomment-283371516 using
 your GitHub account
Received on Wednesday, 1 March 2017 15:27:42 UTC

This archive was generated by hypermail 2.3.1 : Monday, 23 October 2017 12:18:52 UTC