title: IOS: Scaling Images while Maintaining a Fixed Point
body: <p>I am trying to draw an image such that point (X0, Y0) in the image is at a fixed point (usually center of the screen). I am using UIImage drawImageAtPoint (I have to use rotated and multiple images that cannot be scaled to  rectangle) on a UIView.</p>
  
  <p>This means that the upper left corner (X1, X2) usually is not (0,0).</p>
  
  <p>Now I want to scale the image (CGContextScaleCTM by S) but keep the image point (X0, Y0) in the same location on the screen.</p>
  
  <p>If I scale the image by S, how much do I need to change (X1, X1) to keep (X0, Y0) in the same location on the screen>?</p>
  
  <p>I have tried a number of transforms based upon other systems I have used but am not getting anything to work. </p>
  
  <p>Does anyone know what this transform should be? </p>