标签:bug 使用 can mat style rman ring class sprite
1. 关于 SKShapeNode
刚接触SpriteKit时,看到这个类,以为它会比SKSpriteNode更为轻量级,但其实不是:
Shape nodes are useful for content that cannot be easily decomposed into simple textured sprites. Shape nodes are also very useful for building and displaying debugging information on top of your game content. However, the SKSpriteNode class offers higher performance than this class, so use shape nodes sparingly.
其实是SKSpriteNode有更高的效率。
这里提到了SKShapeNode的使用场景:Shape nodes are useful for content that cannot be easily decomposed into simple textured sprites. 这句话怎么理解呢?
我们看一看官方文档用SKShapeNode实现的效果图:
上面这4附图,都是用ShapeNode绘制出来的。我是这样理解的,当你需要利用opengl函数绘制一些内容时,可以使用ShapeNode,否则应该使用SpriteNode。
标签:bug 使用 can mat style rman ring class sprite
原文地址:http://www.cnblogs.com/breezemist/p/6322299.html