title: How to get the segments of a path geometry in Direct2D?
body: <p>The following picture show a path geometry in Direct2D, it contains 5 segments, each segment is a straight line, my request is that, given such a hill, i want to get all the 5 lines.</p>
  
  <p><img src="https://i.stack.imgur.com/Ns9If.png" alt="enter image description here"></p>
  
  <p>but it seems there is no related API can get the segments of a path geometry in Direct2D, I see the ID2D1PathGeometry interface provide a method GetSegmentCount, if we can not get the segments, why Microsoft provide this method? </p>