开发者

iphone: draw line with custom brush in Quartz2d

I am writing a drawing application on iPhone. I did the drawing with color and width, with CGContextMoveToPoint and CGContextAddLineToPoint function in Core Graphics. I wonder that can I make a custom style of brush, texture, to change the display style of the line? Because I would like to make the line like开发者_高级运维 pen drawing style. I have checked GLPaint sample code of Apple before but I would like to do that with Core Graphics.

Can you have any idea of my problem? I am very appreciated.


You need to learn about CGPattern drawing and use CGContextSetStrokePattern

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜