title: Draw a line on an image using angle and center point using Python
body: <p>I'm facing a little issue in my code. I have a dataframe of coords and angels.
  I want to draw a line from a certain xy coords to the edge of the image on a certain angle (say 45 degree).</p>
  <p>How can I do that using PIL? Looping over x2 = x + length*cos(angle) doesn't look like a good solution (but I might be wrong here).</p>
  <p>Thanks in advance.</p>
  <p><a href="https://i.stack.imgur.com/4p6kE.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/4p6kE.png" alt="enter image description here" /></a></p>