LabelAtlas
abelAtlasIntroduction
CCLabelAtlas was the 1st fast label added into cocos2d. But it was superseded by CCBitmapFontAtlas.It is being maintained for backwards compatibility, but you should use CCBitmapFontAtlas instead.
Creating a LabelAtlas
CCLabelAtlas *label = [CCLabelAtlas labelAtlasWithString:@"Hello World" charMapFile:@"tuffy_bold_italic-charmap.png" itemWidth:48 itemHeight:64 startCharMap:' '];
[self add:label];
-
charMapFileis an image file that contains all the characters. Each character should be ordered according to its ASCII value and the image can't contain more than 256 characters. -
itemWidthis the width of the characters in pixels -
itemHeightis the height of the characters in pixels -
startCharMapis the first character of the map.
http://www.cocos2d-iphone.org/wiki/doku.php/prog_guide:labels


3326

被折叠的 条评论
为什么被折叠?



