I'd like to be able to make an empty PixelArray to compare with output from node-canvas from within JavaScript.
For example:
var cleanData = new PixelArray ( 20 );
Is this possible? Am I on the wrong version of Node.js? (0.8.3)
I'd like to be able to make an empty PixelArray to compare with output from node-canvas from within JavaScript. For example:
Is this possible? Am I on the wrong version of Node.js? (0.8.3) |
|||
Uint8ClampedArray works.
Some background: http://www.khronos.org/registry/typedarray/specs/latest/#7.1 Uint8ClampedArray is defined in order to replace CanvasPixelArray. It behaves identically to the other typed array views, except that the setters and constructor use clamping [WEBIDL] rather than modulo arithmetic when converting incoming number values. |
|||
|
PixelArray
) – Chris Bosco Nov 23 '12 at 4:35