If a 16-bit single channel (Gray-scale) raw pixel data losslessly encoded into Image format(e.g.PNG, Webp , Jpeg-2000 or JPEG-XR) and Image rendered to HTML5 canvas, then is there any way to retrieve original 16-bit Raw pixel data from the canvas?
When drawn to a canvas the image is uncompressed, and all the pixels data are pre-multiplied and converted to 24-bit data + an 8-bit alpha channel (RGBA).
In this process the image loses everything from the original, even for same color depth original image because of various rounding errors (See Canvas fingerprinting.)
So even lossless formats are lossy on a canvas.
If you need the raw data, you'll need to write a parser yourself and treat directly your images files as arrayBuffer.