1

円の描き方を知っている // コードの描画

CGContextClearRect(UIGraphicsGetCurrentContext(), rect);
CGContextRef context = UIGraphicsGetCurrentContext();
CGContextSetLineWidth(context, 1.0f);

CGContextSetFillColorWithColor(context, [UIColor colorWithRed:0 green:0.5 blue:0 alpha:0.5].CGColor);
CGRect circlePoint = CGRectMake(startX, startY, circleDiameter, circleDiameter);
CGContextFillEllipseInRect(context, circlePoint);//
CGContextSetStrokeColorWithColor(context, [UIColor blackColor].CGColor);
CGContextStrokeEllipseInRect(context, circlePoint);

しかし、どうすればグラデーションで線/円を描くことができますか?

4

0 に答える 0