This method returns an ImageData object, which has three main properties:
ImageData.width: How many elements are there in each line?
ImageData.height: How many elements are there in each column?
ImageData.data: stores a one-dimensional array of RGBA values of each pixel obtained from the canvas. The array holds four values for each pixel-red, green, blue and alpha transparency. Each value is between 0 and 255. Therefore, each pixel on the canvas becomes four integer values in the array. Arrays are filled from left to right and from top to bottom.
Judge that the pixel values are all 255, that is, all pixels are blank. How many values do non-white pixels need to be valid?