Access raw YUV values from JPEG with JavaScript
问题 I have dynamically loaded a JPEG image into a 2D html canvas and I would like to access the raw YCbCr pixel values. From what I understand, JPEG encodes the pixel data in YCbCr, but chrome appears convert it to RGB when accessing it with getImageData(). I have tried using the RGB to YCbCr conversion calculations but it appears to be a lossy conversion as they don't map perfectly 1-to-1. Is it possible to access the raw YCbCr pixel values in JavaScript? 回答1: Yes and no. When the browser loads