Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Please help fix my code. I am wishing to create a method that transforms the image, or any image, into grayscale using 30%, 59%, and
Please help fix my code. I am wishing to create a method that transforms the image, or any image, into grayscale using 30%, 59%, and 11% to convert the pixel values. Right now, I am getting a green tint, instead of gray. Please provide a repaired java code that correctly converts to grayscale.
public void filter(PixeLImage theImage) l // get the data from the image Pixelll data - theImage.getData); //for each pixel multiply the color value for each red green and blue by //to make the image gray for (int row = 0; rowStep by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started