Sie sind auf Seite 1von 3

Task #1: Write a Python file that processes an image to have a horizontal green strip down the middle.

Tip #1: Make sure to have Jellyfish.gif, cImage.py, and your own Python file in the same folder. If you don t, you will get module/file not found error . Tip #2: Command-Option-Esc allows you to force quit a image window that won t close.

Task #2: Switch the red and blue intensity values for every pixel in the image. Before Processing After Processing

Tip #1: Make sure to have Jellyfish.gif, cImage.py, and your own Python file in the same folder. If you don t, you will get module/file not found error . Tip #2: Command-Option-Esc allows you to force quit a image window that won t close.

Task #3: Create a black and white image of the tuplis. It should only have two colors in it (0,0,0) and (255,255,255) Before Processing After Processing

Tip #1: First convert to grayscale (using the book example as a guide) Tip #2: If the grayscale value of a pixel is greater than (128, 128, 128), set the pixel to white. Otherwise, set the pixel to black.