If you are still trying to fit all the piece together, look again at the transform method from PhotoMagic.java:
The transform() method
Takes a Picture and an LFSR as arguments and returns a new Picture object that is the result of transforming the argument picture using the LFSR as follows:
- For each pixel (col, row), in column-major order—(0, 0), (0, 1), (0, 2), … —extract the red, green, and blue components of the color (each component is an integer between 0 and 255).
- Then, xor the red component with a newly-generated 8-bit integer.
- Do the same for the green (using another new 8-bit integer) and, finally, the blue.
- Create a new Color object using the result of the xor operations, and set the pixel in the new picture to that color.