Re: Intent to implement: DOMMatrix

2014-06-03 Thread K. Gadd
Inverses get used *a lot*. I would argue that they are only 'advanced' in that there are many lines of code in an implementation - they are a common operation when setting up transforms or working with transforms. For example, reverse-projecting from an onscreen point into a point on the surface of

Re: Intent to implement: DOMMatrix

2014-06-02 Thread K. Gadd
Minor spec suggestion: This looks like a great primitive, but having to create GC pressure to multiply values by the matrix seems like a real mistake. transformPoint should have an overload that accepts a Float64Array and mutates it in-place, or maybe a 'in, out' pair of arrays. Probably also accep

Re: Oculus VR support & somehwat-non-free code in the tree

2014-04-15 Thread K. Gadd
The following is all my opinion, of course: Arguably many of the wins currently being seen in web games were only possible because your biggest competitor (Google, w/NaCL) basically ceded the market by failing to ship promptly and failing to support their developers. I don't think the asm.js game

Re: Oculus VR support & somehwat-non-free code in the tree

2014-04-15 Thread K. Gadd
Arguably if you wait for other vendors to expose VR before you do it, you'll end up having to implement a sub-standard proprietary API like you did with Web Audio. If you're first to the market (even with a prototype that's preffed off), you can exert a lot more pressure on how things turn out, IMO

Re: Memory management in features implemented in JS

2014-03-23 Thread K. Gadd
e clear: My reason for responding to this thread initially was to argue with the reasoning 'weak references shouldn't be added to the web platform, so we shouldn't use them'. Since I was involved in extensive discussions re: WRs on es-discuss, I wanted to chime in on that.) -kg On

Re: Memory management in features implemented in JS

2014-03-22 Thread K. Gadd
the end user to implement their own GC (with weak references) to bypass the fact that the JS garbage collector is intentionally crippled. On Fri, Mar 21, 2014 at 9:20 PM, Jason Orendorff wrote: > On 3/21/14, 10:23 PM, K. Gadd wrote: >> A hypothetical scenario (please ignore any minor

Re: Memory management in features implemented in JS

2014-03-21 Thread K. Gadd
In many cases the point at which an object becomes uninteresting is the point at which it is unreachable, and no deterministically identifiable point before that. It is true that in many cases you don't need anything resembling weak references, and can simply manually mark objects as dead. There ar

Re: Memory management in features implemented in JS

2014-03-20 Thread K. Gadd
Keep in mind that es-discuss has hosted frequent, detailed discussions on the topic of weak references and it is quite possible that they could be introduced in ES7 or ES8 (at least based on what has been said on the list), due to their requirement for solving certain problems in large-scale applic

Re: Exposing the CSS/SVG Filters as Canvas API's

2013-08-19 Thread K. Gadd
Consider this my +1 in favor of a dedicated .colorMatrix attribute, preferably in the form of a Uint8Array or Float32Array instead of another *!@$ string. SVG color matrices provide a superset of some very important rendering operations that show up a lot in game rendering. Right now to emulate th

Re: Exposing the CSS/SVG Filters as Canvas API's

2013-08-19 Thread K. Gadd
tmap fonts, etc). The latter use case is the most common one, and can be represented by a color matrix. On Thu, Aug 8, 2013 at 2:55 PM, Robert O'Callahan wrote: > On Fri, Aug 9, 2013 at 9:29 AM, K. Gadd wrote: > >> Consider this my +1 in favor of a dedicated .colorMatrix attrib

Re: vsync proposal

2013-08-13 Thread K. Gadd
I'm not sure you can ever achieve 'ideal' results when it comes to the interaction between requestAnimationFrame and vsync. requestAnimationFrame is fundamentally flawed for combining low latency with tearing-free presentation because it conceptually ties updating, rendering and presentation all in

Re: Exposing the CSS/SVG Filters as Canvas API's

2013-08-08 Thread K. Gadd
For use cases like mine, any other alternative requires origin-clean image data anyway, since the workarounds usually involve getImageData or WebGL or something (and SVG itself seems to hate non-origin-clean image data, based on my tests). So having this stuff only work for origin-clean image data