Heim > Fragen und Antworten > Hauptteil
如果简单的绘制一个图形,是不是2者都可以,没有区别?
如果需要动画,选择CA。 是这样的吗
PHP中文网2017-04-18 09:47:11
CoreGraphics 多用于2D图像和图片的绘制。
CoreAnimation 多用于动画,View 级别的。
Core Graphics (also known as Quartz) is the native drawing engine for iOS apps and provides support for custom 2D vector- and image-based rendering. Although not as fast as OpenGL ES rendering, this framework is well suited for situations where you want to render custom 2D shapes and images dynamically.
Core Animation (part of the Quartz Core framework) is a foundational technology that optimizes the animation experience of your apps. UIKit views use Core Animation to provide view-level animation support. You can use Core Animation directly when you want more control over the behavior of your animations.