[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
On Thu, Mar 21, 2013 at 4:04 AM, Si Robertson <firstname.lastname@example.org> wrote:
I have to say I can not think of any reason for native matrix objects to be implemented by browser vendors unless those objects (a) provide a significant performance gain over custom code, and (b) are compatible with WebGL.
The main reason is to make the life of authors easier. Today, they have to parse and create string matrices which is a huge pain and very slow.
A secondary reason is to harmonize SVG, Canvas and CSS so authors don't have to learn 3 different matrices.
We know that WebGL has more stringent performance requirements. We'd like the matrix class to be useful for WebGL as well so if we're open to changing the interface.
However, easy of use is more important to us than raw performance.
Matrix operations that work on typed arrays are very fast already if the code is optimised, and it is relatively easily to avoid creating new type arrays when needed.
If you read the thread, you'll see that Dean Jackson from Apple talked to their JS engineers and they believed that this class would be faster than typed arrays.