Closed aboveyunhai closed 1 year ago
You can get the RGBA contents of a Canvas via getImageData(). That can then be passed directly to thumbhash.
https://github.com/evanw/thumbhash/blob/5c56a42dacf1f5a1792d71087eeabc53937ce10b/index.html#L472
You can get the RGBA contents of a Canvas via getImageData(). That can then be passed directly to thumbhash.
https://github.com/evanw/thumbhash/blob/5c56a42dacf1f5a1792d71087eeabc53937ce10b/index.html#L472
oh thx for the file link, it looks like <canvas />
is more a native element for the hash. I was originally think it's canvas -> img, but it's actually the opposite.
I think it's possible to do it on canvas via
but is it possible