DynamicAtlasManager Class

Module: cc Parent Module: cc

Manage Dynamic Atlas Manager. Dynamic Atlas Manager is used for merging textures at runtime, see Dynamic Atlas for details.

Index

Properties
  • enabled Boolean Enable or disable the dynamic atlas, see Dynamic Atlas for details.
  • maxAtlasCount Number The maximum number of atlas that can be created.
  • atlasCount Number Get the current created atlas count.
  • textureBleeding Boolean Is enable textureBleeding.
  • textureSize Number The size of the atlas that was created
  • maxFrameSize Number The maximum size of the picture that can be added to the atlas.
  • minFrameSize Number The minimum size of the picture that can be added to the atlas.
Methods
  • insertSpriteFrame Append a sprite frame into the dynamic atlas.
  • reset Resets all dynamic atlas, and the existing ones will be destroyed.
  • showDebug Displays all the dynamic atlas in the current scene, which you can use to view the current atlas state.

Details

Properties

enabled

Enable or disable the dynamic atlas, see Dynamic Atlas for details.

meta description
Type Boolean
Defined in cocos2d/core/renderer/utils/dynamic-atlas/manager.js:39
maxAtlasCount

The maximum number of atlas that can be created.

meta description
Type Number
Defined in cocos2d/core/renderer/utils/dynamic-atlas/manager.js:62
atlasCount

Get the current created atlas count.

meta description
Type Number
Defined in cocos2d/core/renderer/utils/dynamic-atlas/manager.js:75
textureBleeding

Is enable textureBleeding.

meta description
Type Boolean
Defined in cocos2d/core/renderer/utils/dynamic-atlas/manager.js:85
textureSize

The size of the atlas that was created

meta description
Type Number
Defined in cocos2d/core/renderer/utils/dynamic-atlas/manager.js:99
maxFrameSize

The maximum size of the picture that can be added to the atlas.

meta description
Type Number
Defined in cocos2d/core/renderer/utils/dynamic-atlas/manager.js:112
minFrameSize

The minimum size of the picture that can be added to the atlas.

meta description
Type Number
Defined in cocos2d/core/renderer/utils/dynamic-atlas/manager.js:125

Methods

insertSpriteFrame

Append a sprite frame into the dynamic atlas.

meta description
Returns Object
Defined in cocos2d/core/renderer/utils/dynamic-atlas/manager.js:133
Parameters
reset

Resets all dynamic atlas, and the existing ones will be destroyed.

meta description
Defined in cocos2d/core/renderer/utils/dynamic-atlas/manager.js:160
showDebug

Displays all the dynamic atlas in the current scene, which you can use to view the current atlas state.

meta description
Returns Node
Defined in cocos2d/core/renderer/utils/dynamic-atlas/manager.js:194
Parameters

results matching ""

    No results matching ""