Cocos2d_x + Lua [2] -- use the texturepacker texture packer

Source: Internet
Author: User

Odustggg Personal Original, welcome to reprint, reprint please indicate the source,
Advantages of texturepacke:
1. Memory problems. The width and height of OpenGL textures and the memory used will automatically expand to the Npower of 2. For example, 257*257 will be used for 512*512, and mobile phone memory is a rare resource,
2. In terms of rendering speed, we should try to reduce the texture switching during rendering. If we do not pack the image, the texture rendering efficiency will be reduced once every image is switched. In order to increase the loading speed, splice multiple small images into a large image, load them at a time, and reduce I/O

: Http://

Data format: Format of the engine supported for export data file: export file path (such as image. plist) Texture format: texture Format Image Format: image pixel format dithering: Jitter, default nearestneighbour


Cache = ccspriteframecache: sharedspriteframecache () cache: addspriteframeswithfile ("resource/tilemap/test/image. plist "," resource/tilemap/test/image.png "); sprite = ccsprite: spritewithspriteframename (" 2.jpg ")

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.