Drawing vector art in an iPhone app
Im developing an iPhone game, and I want to know how to draw vector art, right now Im drawing all my art in Illustrator + Photoshop, it looks ok, but what I do is to save my vector art to png and then I use it in my game.
What I want to do, is to use my vector art instead, how can I do this?
Thx.
(I've read that I should us开发者_JS百科e Quartz2d and Core Animation.. but dunno what those are or how to use them tbh)
You should start by reading the Quartz 2D Programming Guide.
Quartz 2D is the underlying drawing technology in iOS, and is vector based.
If you plan to use art drawn from illustrator & photoshop you may have to jump through some hoops to turn your assets into something you can draw directly.
You may consider exporting your assets to pdf and using the Quartz 2D's pdf support to draw them. If it's not quick enough, you may yet be able to use it to cache stuff to bitmaps. I haven't tried this myself, but it's certainly what I'd try first.
Good luck!
精彩评论