Computers and Technology

I am trying to figure out how to ask the user to input a choice between blue, green, or red and then output their choice for this next assignment by changing the filter. I have two separate ideas that I can't seem to combine correctly. any ideas? This is all in python code. # Constants for the image
IMAGE_URL = "https://codehs. com/uploads/c709d869e62686611c1ac84 9367b3245"
IMAGE_WIDTH = 420
IMAGE_HEIGHT = 300
IMAGE_LOAD_TIME = 1000

image = Image(IMAGE_URL)
image. set_size(IMAGE_WIDTH, IMAGE_HEIGHT)
add(image)

"""
Filter that takes an image as a parameter
and applies a color filter, then returns the filtered image
"""
# asks the user to input a color of choice

user_color = input("Pick a color, blue, red or green:")
def custom_filter(image):
for x in range(image. get_width()):
for y in range(image. get_height()):
image. set_blue(x, y,-50)
image. set_red(x, y,100)

return image

def change_image():
global image
image = custom_filter(image)

timer. set_timeout(change_image, IMAGE_LOAD_TIME)

answer
Answers: 3

Other questions on the subject: Computers and Technology

image
Computers and Technology, 21.06.2019 18:00, mterzic1
Assume that you have an array of integers named a. which of these code segments print the same results? int i = 1; while(i < a. length) { system. out. println(a[i]); i++; } int i; for (i = 0; i < a. length; i++) { system. out. println(a[i]); } for (int i : a) { system. out. println(i); } i and ii only ii and iii only i and iii only all three print the same results. all three print different results.
Answers: 3
image
Computers and Technology, 22.06.2019 04:30, fatherbamboo
Dr. wisteria is a prominent chiropractor in the chicago area. she wants to provide a forum for her patients to discuss their health concerns and to seek and offer advice to other patients. which telecommunications tool is most appropriate for dr. wisteria's needs?
Answers: 3
image
Computers and Technology, 22.06.2019 22:00, bbysl15
What is the name of the option in most presentation applications with which you can modify slide elements? 1. the option enables you to modify a slide element in most presentation applications.
Answers: 3
image
Computers and Technology, 23.06.2019 01:50, rhonda45801
Free points just awnser this. what should i watch on netflix
Answers: 2
Do you know the correct answer?
I am trying to figure out how to ask the user to input a choice between blue, green, or red and then...

Questions in other subjects:

Konu
Mathematics, 23.11.2020 20:10
Konu
Mathematics, 23.11.2020 20:10
Konu
History, 23.11.2020 20:10
Konu
Chemistry, 23.11.2020 20:10
Konu
Computers and Technology, 23.11.2020 20:10