I don't know why this is giving me so much trouble but I want to draw an image on the current context and have it rotate around it's center. No matter what I do it rotates around one of it's corners or some other point, how can i get it to rotate around IT'S center?
PHP Code:
CGContextSaveGState(context);
CGContextRotateCTM (context, rotate);
CGContextTranslateCTM( context, x, y);
CGContextDrawImage(context, CGRectMake(0, 0, 100, 100), test.CGImage);
CGContextRestoreGState(context);