create a loop to determine the pixel distance from the center using the distance formula
1 view (last 30 days)
Yogesh Bhambhwani on 12 Nov 2020
using the distance formula I need to find the the pixel distance from the center of my image 'sunflower.jpg'. I have found the center of my image im just cofused on how to write the loop and what values my x and y would be.
d^2 = (x-x_c)^2 + (y-y_c)^2 (distance formula)