I have a problem find the angle of the line going through the circles, the image is as follows as left
Here we can see a line going through the partial circles my problem is to find the angle of the line from both left and right. Mostly I need to get some thing like right side of above image
Where point “A” is static and point “B” and point “C” are dynamic. And “D” is the line going through the circles. And I need to find the angles “X” and “Y”.
This is my idea of approach, But I don’t know how to? So, anyone please help me with this!!
I am using OpenCV python.