title: CGPath (AddCurveToPoint) - the difference between the first control point's x and y and the second
body: <p>I'm pretty new to Xcode so I've decided to get used to Quartz drawing, although I'm slowly getting used to it, I'm having trouble drawing bezier paths.</p>
  
  <p>In particular, from my Illustrator design, I want to draw a shape (the Spade logo from a pack of playing cards) although the x and y points are OK, I think I'm mixing up which point is the first control point and which is the second.</p>
  
  <p>I always imagined it as, if you imagine a desk and rotate the outside of the shape along the top of it (so the shape is always on the desk as oppose to below it) the first control point is on the left and the second is on the right.</p>
  
  <p>What is the case?</p>
  
  <p>Thanks in advance, Adam.</p>
  
  <p><img src="https://i.stack.imgur.com/zebZR.png" alt="Here is a picture describing what I mean"></p>
  
  <p>And here is my code:</p>
  
  <pre><code>CGMutablePathRef spadePath = CGPathCreateMutable();
  
  CGPathMoveToPoint(spadePath, NULL, 17.0f, 0.0f);
  
  CGPathAddCurveToPoint(spadePath, NULL, 17.0f, 7.3f, 17.0f, 7.318f, 34.0f, 25.475f);
  CGPathAddCurveToPoint(spadePath, NULL, 34.0f, 14.754f, 34.0f, 36.197f, 20.838f, 35.029f);
  CGPathAddCurveToPoint(spadePath, NULL, 24.679f, 38.425f, 20.838f, 41.03f, 17.0f, 39.2f);
  CGPathAddCurveToPoint(spadePath, NULL, 2.846f, 39.2f, 31.156f, 39.2f, 13.163f, 35.029f);
  CGPathAddCurveToPoint(spadePath, NULL, 13.163f, 41.03f, 9.323f, 38.425f, 0.0f, 25.475f);
  CGPathAddCurveToPoint(spadePath, NULL, 0.0f, 36.197f, 0.0f, 14.754f, 17.0f, 0.0f);
  
  CGPathCloseSubpath(spadePath);
  </code></pre>