Re: [w3c/gamepad] Added GamepadPose (#25)

> The Geometry spec seems fine to me. I'm not sure why Chrome has not implemented it

Because, as I mentioned before, there was significant doubts about performance which have yet to be addressed. And it's not just Chrome. The thread that I found for WebKit raised the same issues, and I don't think Edge has shown any interest in the API at all. Firefox seems to be the only platform that has committed to the API.

There were also concerns about whether or not the objects presented in the spec would actually provide enough functionality to be useful. For example: The spec describes no functions for the create of a projection matrix, which is extremely frequently used by 3D graphics applications. The DOM just happens to handle that for you, so it was left out. What this means is that whether you use the Geometry spec or not users are still being forced to pull in a third party library to handle the average 3D application's needs.

> I'd encourage you to implement them in Chrome as part of Web VR and the Gamepad API!

Forgive me, but I have plenty of work to do and deadlines in which to do them. It's not practical for me to try and sufficiently address the issues in and fully ship an unrelated API in Chrome just to avoid using a structure that developers have already proven happy to work with. If I saw active forward momentum in the Geometry interfaces I may feel differently, but it seems that they have stalled out due to lack of interest.

> It's true that there are libraries to work around the awkwardness you are imposing on developers.

I expect that these values will frequently be fed into WebGL for visualization, which accepts TypedArrays as it's representation of vectors and matrices. Is working with the native type accepted by the target API really more awkward than dealing with conversions in and out of a type meant for DOM manipulation?

> It's not possible to avoid the mutability while using typed arrays.

This is a fair point, but I'm not convinced it outweighs the above concerns about the Geometry interfaces. 

At their core `DOMPoint` and `DOMMatrix` appear to be designed with the needs of CSS transforms in mind. That's great! But it doesn't appear to be well suited for the average WebGL application, which I expect to be a far more common use of this API. (And for the times when users do want to use the Geometry interfaces instead it's very easy to create one from a TypedArray with the `fromFloat32Array` constructors.)

---
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/w3c/gamepad/pull/25#issuecomment-236638838

Received on Monday, 1 August 2016 16:55:21 UTC