ImageTools.getBufferFromImage(image) Method (JS)
Retrieves the underlying image data for an image as an ArrayBuffer.
Example
// Here image is expected to be an `Image` object
var ImageTools = require("FuseJS/ImageTools");
ImageTools.getBufferFromImage(image)
.then(function(buf) { console.log("Image contains " + buf.byteLength + " bytes"); });
Location
- Namespace
- Fuse.ImageTools
- Package
- Fuse.ImageTools 2.9.1
Returns
Promise
a Promise of an ArrayBuffer of image data