5 ms·
You probably would have been better off with typed arrays and fragment shaders, if you were going for performance.
by warfangle 12y ago
You probably would have been better off with typed arrays and fragment shaders, if you were going for performance.
- k__ 12y agoAren't the arrays produced by a canvas object typed?
- warfangle 12y agoYep, but they only become performant when you treat them as such instead of doing naive e.g. multiplication. See: https://hacks.mozilla.org/2011/12/faster-canvas-pixel-manipulation-with-typed-arrays/ https://hacks.mozilla.org/2011/12/faster-canvas-pixel-manipu...