User Tools

Site Tools


Tutorial 01: Working With Pixels

Part 1:

… an interactive application, allowing the user to click on a pixel in an image, resulting in small circle draw at the same location and filled with the same pixel color, the size of the circle being proportional to the red component of the pixel color. [Based on Reas & Frey (2007), pg 364.] Click HERE or on any of the examples below to go to the dynamic applet version.

Figure 1: Original Image.
Figure 2: Clicking & Holding A Single Pixel. When mouse is released, image reverts to the original shown in Figure 1.
Figure 3: Dragging across multiple pixels. Again, when mouse finally released, image reverts to the original shown in Figure 1.

Part 2:

Static Displays of Processed Images (see array of figures below).

(1) The image in the upper left is a small piece of a larger image of several cows hamming it up for the camera. In the subsequent processing comments below, I'll call this the “original” image.

(2) The upper right corner was obtained by drawing a circle centered at each pixel location in the original image, with the fill-color matching the original pixel, and the radius of the circle proportional to the red-color value of that same pixel. A cropping process was later used to crop out the disk “overflow” along the edges. [Based on an idea in Reas & Frey (2007), pg 364.]

(3) The image in the lower left corner was obtained using filter(GRAY) on the original image.

(4) Lower right: obtained from original image by applying filter(THRESHOLD).

cs276/wdcraft.tutorial01.txt · Last modified: 2008/09/29 10:44 by wdcraft