Adjusting brightness and contrast One often needs to tweak the brightness and contrast level of an image. For example, you…