Digital Images - Colors - Changing Colors in Photographs Change the Yellow Flowers to Red ones
Do the following:
Ans:
Now do the following:
Edit the button "Change Color" and for every pixel, set the green and the blue to 0. Ans:
Setting green and blue to 0 everywhere, all that is left is the area of red light that went into the original image, aka the "red channel" of the image. The red light is most prominent for the area of yellow flowers, which makes sense as we know that yellow = red + green. Making less drastic changes Set the Red to double the Red e.g. in the Repeat loop: put charToNum (char (pixelStart + 2) of image1) into tRed //put numToChar (0 ) into char (pixelStart + 2) of image1 // Red put numToChar (0 ) into char (pixelStart + 3) of image1 // Green put numToChar (0 ) into char (pixelStart + 4) of image1 // Blue put numToChar (tRed * 2 ) into char (pixelStart + 2) of image1 // Red Does that make the photo more red? Do the yellow flowers change? Set the Red to 50% of the Red already there (cut it in half) e.g. in the Repeat loop: put charToNum (char (pixelStart + 2) of image1) into tRed put numToChar (tRed * 0.5 ) into char (pixelStart + 2) of image1 // Red Does that make the photo less red? Do the yellow flowers change? Examples to Try Example #1
Ans: put charToNum (char (pixelStart + 3) of image1) into tGreen put numToChar (tGreen * .75 ) into char (pixelStart + 3) of image1 // Green Example #2
Ans: put charToNum (char (pixelStart + 2) of image1) into tRed put charToNum (char (pixelStart + 3) of image1) into tGreen put charToNum (char (pixelStart + 4) of image1) into tBlue put numToChar (tRed * 0.75 ) into char (pixelStart + 2) of image1 // Red put numToChar (tGreen * 0.75 ) into char (pixelStart + 3) of image1 // Green put numToChar (tBlue * 0.75 ) into char (pixelStart + 4) of image1 // Blue Example #3
Next steps: Download the file below - "Digital_Image_Color_2" See if you can:
Try loading some other photos and play around with changing the colors |
Home > Digital Magic >

