image-js / tiff

TIFF image decoder written entirely in JavaScript
MIT License
195 stars 17 forks source link

Force alpha decoding? #22

Open benwiley4000 opened 4 years ago

benwiley4000 commented 4 years ago

It would be interesting to have an option to always return 4-component alpha representation, even if the image is only 3-channel. The idea being that you can then directly use the Uint8Array's buffer to create a Uint8ClampedArray to be fed into a canvas's ImageData.