Describe in English what this image or pixel function does def fun1): p -Pixel(0
ID: 3744340 • Letter: D
Question
Describe in English what this image or pixel function does def fun1): p -Pixel(0,0,0) return(p) Describe in English what this image or pixel function does def fun20) p = Pixel (255,255,255) return(p) Describe in English what these image or pixel functions do and what are their difference. def fun3(p): def fun4 (p): r- p.getRedO 8 - p.getGreen () b p.getBlue() x(rtg+b)//3 q Pixel (X , X , X) return(q) r - p.getRed) q-Pixel(r,r,r) return(q) Describe in English what this image or pixel function does def fun5(p) r 2*p.getRed ( )%256 g - p.getGreen () b- 2*p . getBlue ( )%256 q-Pixel(r,g,b) return(q)Explanation / Answer
1) fun1 returns a black pixel 2) fun2 returns a white pixel 3) fun3 takes average of input pixel and then returns a pixel with equal r, g, b values and with the intensity of calculated average fun4 returns a pixel with equal r, g, b values and with the intensity of red in the input pixel. 4) fun5 returns a new pixel with same green value as input pixel, but twice as red and blue that of the input pixel.