jankovicsandras / imagetracerjs

Simple raster image tracer and vectorizer written in JavaScript.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Does this library require canvas?

velara3 opened this issue · comments

Does this library require canvas?

I'm attempting to work around lack of canvas and ImageData object here.

Hi,

No, it doesn't require canvas, but you need to load and decode the image into an ImageData-like object. It has width, height and data: a one-dimensional array with R G B A values.

var myImagedata = { width: ... , height: ... , data: [ R,G,B,A, R,G,B,A, ... ] };

I tried to answer your Stackoverflow question also.

Thanks @jankovicsandras! I think that might be it. I'll work on it when I get back to work.

OK. I'm closing this Issue now, but you can reopen it, if it won't work or you have more questions.