From 802e48080eec6e1ff8ea7a705973a517d05373d4 Mon Sep 17 00:00:00 2001 From: minggo Date: Thu, 8 Feb 2018 10:40:29 +0800 Subject: [PATCH] New renderer (#1097) * build work on mac * build ok on iOS * fix compiling error on android * fix android link error --- .../cocos2d_libs.xcodeproj/project.pbxproj | 4567 +++-------------- native/cocos/2d/CCAction.cpp | 356 -- native/cocos/2d/CCAction.h | 458 -- native/cocos/2d/CCActionCamera.cpp | 248 - native/cocos/2d/CCActionCamera.h | 184 - native/cocos/2d/CCActionCatmullRom.cpp | 558 -- native/cocos/2d/CCActionCatmullRom.h | 349 -- native/cocos/2d/CCActionEase.cpp | 1394 ----- native/cocos/2d/CCActionEase.h | 1281 ----- native/cocos/2d/CCActionGrid.cpp | 445 -- native/cocos/2d/CCActionGrid.h | 423 -- native/cocos/2d/CCActionGrid3D.cpp | 734 --- native/cocos/2d/CCActionGrid3D.h | 621 --- native/cocos/2d/CCActionInstant.cpp | 419 -- native/cocos/2d/CCActionInstant.h | 443 -- native/cocos/2d/CCActionInterval.cpp | 2640 ---------- native/cocos/2d/CCActionInterval.h | 1593 ------ native/cocos/2d/CCActionManager.cpp | 505 -- native/cocos/2d/CCActionManager.h | 193 - native/cocos/2d/CCActionPageTurn3D.cpp | 134 - native/cocos/2d/CCActionPageTurn3D.h | 75 - native/cocos/2d/CCActionProgressTimer.cpp | 135 - native/cocos/2d/CCActionProgressTimer.h | 135 - native/cocos/2d/CCActionTiledGrid.cpp | 876 ---- native/cocos/2d/CCActionTiledGrid.h | 611 --- native/cocos/2d/CCActionTween.cpp | 81 - native/cocos/2d/CCActionTween.h | 127 - native/cocos/2d/CCAnimation.cpp | 204 - native/cocos/2d/CCAnimation.h | 326 -- native/cocos/2d/CCAnimationCache.cpp | 250 - native/cocos/2d/CCAnimationCache.h | 134 - native/cocos/2d/CCAtlasNode.cpp | 259 - native/cocos/2d/CCAtlasNode.h | 159 - native/cocos/2d/CCAutoPolygon.cpp | 704 --- native/cocos/2d/CCAutoPolygon.h | 268 - native/cocos/2d/CCClippingNode.cpp | 369 -- native/cocos/2d/CCClippingNode.h | 174 - native/cocos/2d/CCClippingRectangleNode.cpp | 110 - native/cocos/2d/CCClippingRectangleNode.h | 119 - native/cocos/2d/CCComponent.cpp | 154 - native/cocos/2d/CCComponent.h | 96 - native/cocos/2d/CCComponentContainer.cpp | 153 - native/cocos/2d/CCComponentContainer.h | 80 - native/cocos/2d/CCDrawNode.cpp | 953 ---- native/cocos/2d/CCDrawNode.h | 361 -- native/cocos/2d/CCDrawingPrimitives.cpp | 507 -- native/cocos/2d/CCDrawingPrimitives.h | 274 - native/cocos/2d/CCFastTMXLayer.cpp | 883 ---- native/cocos/2d/CCFastTMXLayer.h | 363 -- native/cocos/2d/CCFastTMXTiledMap.cpp | 278 - native/cocos/2d/CCFastTMXTiledMap.h | 242 - native/cocos/2d/CCFont.cpp | 27 - native/cocos/2d/CCFontAtlas.cpp | 490 -- native/cocos/2d/CCFontAtlas.h | 156 - native/cocos/2d/CCFontAtlasCache.cpp | 281 - native/cocos/2d/CCFontAtlasCache.h | 82 - native/cocos/2d/CCFontCharMap.cpp | 155 - native/cocos/2d/CCFontFNT.cpp | 922 ---- native/cocos/2d/CCFontFNT.h | 78 - native/cocos/2d/CCFontFreeType.cpp | 660 --- native/cocos/2d/CCFontFreeType.h | 122 - native/cocos/2d/CCGLBufferedNode.cpp | 98 - native/cocos/2d/CCGLBufferedNode.h | 65 - native/cocos/2d/CCGrabber.cpp | 103 - native/cocos/2d/CCGrabber.h | 76 - native/cocos/2d/CCGrid.cpp | 797 --- native/cocos/2d/CCGrid.h | 284 - native/cocos/2d/CCLabel.cpp | 2287 --------- native/cocos/2d/CCLabel.h | 809 --- native/cocos/2d/CCLabelAtlas.cpp | 278 - native/cocos/2d/CCLabelAtlas.h | 134 - native/cocos/2d/CCLabelTTF.cpp | 45 - native/cocos/2d/CCLabelTTF.h | 50 - native/cocos/2d/CCLabelTextFormatter.cpp | 400 -- native/cocos/2d/CCLabelTextFormatter.h | 27 - native/cocos/2d/CCLayer.cpp | 677 --- native/cocos/2d/CCLayer.h | 452 -- native/cocos/2d/CCMenu.cpp | 581 --- native/cocos/2d/CCMenu.h | 213 - native/cocos/2d/CCMenuItem.cpp | 869 ---- native/cocos/2d/CCMenuItem.h | 537 -- native/cocos/2d/CCMotionStreak.cpp | 423 -- native/cocos/2d/CCMotionStreak.h | 222 - native/cocos/2d/CCNode.cpp | 2159 -------- native/cocos/2d/CCNode.h | 1946 ------- native/cocos/2d/CCNodeGrid.cpp | 194 - native/cocos/2d/CCNodeGrid.h | 116 - native/cocos/2d/CCParallaxNode.cpp | 177 - native/cocos/2d/CCParallaxNode.h | 120 - native/cocos/2d/CCParticleBatchNode.cpp | 507 -- native/cocos/2d/CCParticleBatchNode.h | 189 - native/cocos/2d/CCParticleExamples.cpp | 1238 ----- native/cocos/2d/CCParticleExamples.h | 457 -- native/cocos/2d/CCParticleSystem.cpp | 1377 ----- native/cocos/2d/CCParticleSystem.h | 984 ---- native/cocos/2d/CCParticleSystemQuad.cpp | 711 --- native/cocos/2d/CCParticleSystemQuad.h | 197 - native/cocos/2d/CCProgressTimer.cpp | 563 -- native/cocos/2d/CCProgressTimer.h | 211 - native/cocos/2d/CCProtectedNode.cpp | 458 -- native/cocos/2d/CCProtectedNode.h | 207 - native/cocos/2d/CCRenderTexture.cpp | 811 --- native/cocos/2d/CCRenderTexture.h | 379 -- native/cocos/2d/CCScene.cpp | 119 - native/cocos/2d/CCScene.h | 108 - native/cocos/2d/CCSprite.cpp | 1204 ----- native/cocos/2d/CCSprite.h | 629 --- native/cocos/2d/CCSpriteBatchNode.cpp | 726 --- native/cocos/2d/CCSpriteBatchNode.h | 277 - native/cocos/2d/CCSpriteFrame.cpp | 233 - native/cocos/2d/CCSpriteFrame.h | 282 - native/cocos/2d/CCSpriteFrameCache.cpp | 768 --- native/cocos/2d/CCSpriteFrameCache.h | 271 - native/cocos/2d/CCTMXLayer.cpp | 808 --- native/cocos/2d/CCTMXLayer.h | 369 -- native/cocos/2d/CCTMXObjectGroup.cpp | 525 -- native/cocos/2d/CCTMXObjectGroup.h | 246 - native/cocos/2d/CCTMXTiledMap.cpp | 344 -- native/cocos/2d/CCTMXTiledMap.h | 325 -- native/cocos/2d/CCTMXXMLParser.cpp | 872 ---- native/cocos/2d/CCTMXXMLParser.h | 409 -- native/cocos/2d/CCTextFieldTTF.cpp | 708 --- native/cocos/2d/CCTextFieldTTF.h | 318 -- native/cocos/2d/CCTileMapAtlas.cpp | 259 - native/cocos/2d/CCTileMapAtlas.h | 122 - native/cocos/2d/CCTransition.cpp | 1765 ------- native/cocos/2d/CCTransition.h | 1093 ---- native/cocos/2d/CCTransitionPageTurn.cpp | 175 - native/cocos/2d/CCTransitionPageTurn.h | 126 - native/cocos/2d/CCTransitionProgress.cpp | 345 -- native/cocos/2d/CCTransitionProgress.h | 264 - native/cocos/2d/CCTweenFunction.cpp | 554 -- native/cocos/2d/CCTweenFunction.h | 301 -- native/cocos/2d/cocos2d.def | 3 - native/cocos/2d/cocos2d_headers.props | 23 - native/cocos/2d/cocos2dx.props | 20 - native/cocos/2d/libcocos2d.vcxproj | 646 --- native/cocos/2d/libcocos2d.vcxproj.filters | 1478 ------ native/cocos/Android.mk | 304 +- native/cocos/base/CCAsyncTaskPool.cpp | 56 - native/cocos/base/CCAsyncTaskPool.h | 221 - native/cocos/base/CCConfiguration.cpp | 17 +- native/cocos/base/CCConfiguration.h | 1 - native/cocos/base/CCDataVisitor.cpp | 8 - native/cocos/base/CCDirector.cpp | 1464 ------ native/cocos/base/CCDirector.h | 685 --- native/cocos/base/CCEventDispatcher.cpp | 1580 ------ native/cocos/base/CCEventDispatcher.h | 355 -- native/cocos/base/CCNinePatchImageParser.cpp | 218 - native/cocos/base/CCNinePatchImageParser.h | 122 - native/cocos/base/CCProtocols.h | 286 -- native/cocos/base/CCRef.cpp | 1 - native/cocos/base/CCScheduler.cpp | 1137 ---- native/cocos/base/CCScheduler.h | 496 -- native/cocos/base/CCScriptSupport.cpp | 227 - native/cocos/base/CCScriptSupport.h | 923 ---- native/cocos/base/CCStencilStateManager.cpp | 278 - native/cocos/base/CCStencilStateManager.hpp | 80 - native/cocos/base/CCThreadPool.cpp | 442 -- native/cocos/base/CCThreadPool.h | 237 - native/cocos/base/CCUserDefault-android.cpp | 1 - native/cocos/base/CCUserDefault.cpp | 1 - native/cocos/base/ccMacros.h | 26 +- native/cocos/base/ccTypes.cpp | 16 + native/cocos/base/ccTypes.h | 27 + native/cocos/base/ccUTF8.cpp | 1 - native/cocos/base/ccUtils.cpp | 329 +- native/cocos/base/ccUtils.h | 90 +- native/cocos/cocos2d.h | 113 +- native/cocos/platform/CCApplication.h | 44 - native/cocos/platform/CCApplicationProtocol.h | 162 - native/cocos/platform/CCCommon.h | 83 - native/cocos/platform/CCFileUtils.cpp | 1 - native/cocos/platform/CCGLView.cpp | 526 -- native/cocos/platform/CCGLView.h | 436 -- native/cocos/platform/CCImage.cpp | 199 +- native/cocos/platform/CCImage.h | 90 +- native/cocos/platform/CCSAXParser.h | 2 +- native/cocos/platform/CCThread.cpp | 48 - native/cocos/platform/CCThread.h | 68 - native/cocos/platform/android/Android.mk | 3 - .../android/CCApplication-android.cpp | 215 - .../platform/android/CCApplication-android.h | 114 - .../platform/android/CCCommon-android.cpp | 53 - .../platform/android/CCFileUtils-android.cpp | 1 - native/cocos/platform/android/CCGL-android.h | 8 + .../platform/android/CCGLViewImpl-android.cpp | 132 - .../platform/android/CCGLViewImpl-android.h | 66 - .../platform/android/javaactivity-android.cpp | 68 +- ...org_cocos2dx_lib_Cocos2dxAccelerometer.cpp | 18 +- .../Java_org_cocos2dx_lib_Cocos2dxBitmap.cpp | 2 - ...Java_org_cocos2dx_lib_Cocos2dxRenderer.cpp | 59 +- .../cocos/platform/android/jni/TouchesJni.cpp | 30 +- .../cocos/platform/apple/CCFileUtils-apple.mm | 1 - native/cocos/platform/apple/CCThread-apple.mm | 44 - .../platform/desktop/CCGLViewImpl-desktop.cpp | 976 ---- .../platform/desktop/CCGLViewImpl-desktop.h | 164 - native/cocos/platform/ios/CCApplication-ios.h | 116 - .../cocos/platform/ios/CCApplication-ios.mm | 169 - native/cocos/platform/ios/CCCommon-ios.mm | 66 - native/cocos/platform/ios/CCDevice-ios.mm | 10 +- .../platform/ios/CCDirectorCaller-ios.mm | 17 +- native/cocos/platform/ios/CCEAGLView-ios.mm | 66 +- native/cocos/platform/ios/CCGL-ios.h | 31 +- native/cocos/platform/ios/CCGLViewImpl-ios.h | 97 - native/cocos/platform/ios/CCGLViewImpl-ios.mm | 280 - native/cocos/platform/ios/CCImage-ios.mm | 1 - native/cocos/platform/mac/CCApplication-mac.h | 122 - .../cocos/platform/mac/CCApplication-mac.mm | 218 - native/cocos/platform/mac/CCCommon-mac.mm | 67 - native/cocos/renderer/Android.mk | 50 + native/cocos/renderer/CCBatchCommand.cpp | 75 - native/cocos/renderer/CCBatchCommand.h | 84 - native/cocos/renderer/CCCustomCommand.h | 81 - native/cocos/renderer/CCGLProgram.cpp | 945 ---- native/cocos/renderer/CCGLProgram.h | 491 -- native/cocos/renderer/CCGLProgramCache.cpp | 434 -- native/cocos/renderer/CCGLProgramCache.h | 110 - native/cocos/renderer/CCGLProgramState.cpp | 920 ---- native/cocos/renderer/CCGLProgramState.h | 479 -- .../cocos/renderer/CCGLProgramStateCache.cpp | 98 - native/cocos/renderer/CCGLProgramStateCache.h | 80 - native/cocos/renderer/CCGroupCommand.cpp | 94 - native/cocos/renderer/CCGroupCommand.h | 89 - native/cocos/renderer/CCPrimitive.cpp | 124 - native/cocos/renderer/CCPrimitive.h | 94 - native/cocos/renderer/CCPrimitiveCommand.cpp | 88 - native/cocos/renderer/CCPrimitiveCommand.h | 95 - native/cocos/renderer/CCQuadCommand.cpp | 112 - native/cocos/renderer/CCQuadCommand.h | 87 - native/cocos/renderer/CCRenderCommand.h | 135 - native/cocos/renderer/CCRenderCommandPool.h | 100 - native/cocos/renderer/CCRenderer.cpp | 829 --- native/cocos/renderer/CCRenderer.h | 283 - native/cocos/renderer/CCTexture2D.cpp | 1479 ------ native/cocos/renderer/CCTexture2D.h | 551 -- native/cocos/renderer/CCTextureAtlas.cpp | 696 --- native/cocos/renderer/CCTextureAtlas.h | 274 - native/cocos/renderer/CCTextureCache.cpp | 900 ---- native/cocos/renderer/CCTextureCache.h | 317 -- native/cocos/renderer/CCTrianglesCommand.cpp | 113 - native/cocos/renderer/CCTrianglesCommand.h | 125 - native/cocos/renderer/CCVertexIndexBuffer.cpp | 310 -- native/cocos/renderer/CCVertexIndexBuffer.h | 267 - native/cocos/renderer/CCVertexIndexData.cpp | 150 - native/cocos/renderer/CCVertexIndexData.h | 189 - native/cocos/renderer/Macro.h | 192 + native/cocos/renderer/Types.cpp | 68 + native/cocos/renderer/Types.h | 203 + native/cocos/renderer/ccGLStateCache.cpp | 274 - native/cocos/renderer/ccGLStateCache.h | 186 - .../cocos/renderer/ccShader_CameraClear.frag | 15 - .../cocos/renderer/ccShader_CameraClear.vert | 24 - native/cocos/renderer/ccShader_Label.vert | 46 - native/cocos/renderer/ccShader_Label_df.frag | 26 - .../renderer/ccShader_Label_df_glow.frag | 26 - .../cocos/renderer/ccShader_Label_normal.frag | 42 - .../renderer/ccShader_Label_outline.frag | 43 - .../renderer/ccShader_PositionColor.frag | 38 - .../renderer/ccShader_PositionColor.vert | 42 - .../ccShader_PositionColorLengthTexture.frag | 42 - .../ccShader_PositionColorLengthTexture.vert | 52 - ...hader_PositionColorTextureAsPointsize.vert | 46 - ..._PositionColorTextureAsPointsize_wp81.vert | 43 - .../renderer/ccShader_PositionTexture.frag | 38 - .../renderer/ccShader_PositionTexture.vert | 42 - .../ccShader_PositionTextureA8Color.frag | 41 - .../ccShader_PositionTextureA8Color.vert | 46 - .../ccShader_PositionTextureColor.frag | 38 - .../ccShader_PositionTextureColor.vert | 46 - ...cShader_PositionTextureColorAlphaTest.frag | 47 - .../ccShader_PositionTextureColor_noMVP.frag | 39 - .../ccShader_PositionTextureColor_noMVP.vert | 45 - .../ccShader_PositionTexture_uColor.frag | 40 - .../ccShader_PositionTexture_uColor.vert | 42 - .../renderer/ccShader_Position_uColor.frag | 38 - .../renderer/ccShader_Position_uColor.vert | 44 - .../ccShader_Position_uColor_wp81.vert | 43 - .../renderer/ccShader_SpriteDistortion.frag | 28 - native/cocos/renderer/ccShader_UI_Gray.frag | 17 - native/cocos/renderer/ccShaders.cpp | 85 - native/cocos/renderer/ccShaders.h | 105 - native/cocos/renderer/gfx/DeviceGraphics.cpp | 1158 +++++ native/cocos/renderer/gfx/DeviceGraphics.h | 191 + native/cocos/renderer/gfx/FrameBuffer.cpp | 132 + .../gfx/FrameBuffer.h} | 77 +- native/cocos/renderer/gfx/GFX.cpp | 25 + native/cocos/renderer/gfx/GFX.h | 35 + .../gfx/GFXUtils.cpp} | 50 +- .../UIWebView.mm => renderer/gfx/GFXUtils.h} | 11 +- .../gfx/GraphicsHandle.cpp} | 27 +- .../gfx/GraphicsHandle.h} | 27 +- native/cocos/renderer/gfx/IndexBuffer.cpp | 119 + native/cocos/renderer/gfx/IndexBuffer.h | 85 + native/cocos/renderer/gfx/Program.cpp | 393 ++ native/cocos/renderer/gfx/Program.h | 83 + .../RenderBuffer.cpp} | 55 +- .../CCFont.h => renderer/gfx/RenderBuffer.h} | 48 +- native/cocos/renderer/gfx/RenderTarget.cpp | 25 + .../gfx/RenderTarget.h} | 35 +- native/cocos/renderer/gfx/State.cpp | 423 ++ native/cocos/renderer/gfx/State.h | 118 + native/cocos/renderer/gfx/Texture.cpp | 259 + native/cocos/renderer/gfx/Texture.h | 253 + native/cocos/renderer/gfx/Texture2D.cpp | 745 +++ .../{CCCustomCommand.cpp => gfx/Texture2D.h} | 52 +- native/cocos/renderer/gfx/VertexBuffer.cpp | 123 + native/cocos/renderer/gfx/VertexBuffer.h | 84 + native/cocos/renderer/gfx/VertexFormat.cpp | 143 + native/cocos/renderer/gfx/VertexFormat.h | 102 + .../cocos/renderer/renderer/BaseRenderer.cpp | 356 ++ native/cocos/renderer/renderer/BaseRenderer.h | 96 + native/cocos/renderer/renderer/Camera.cpp | 189 + native/cocos/renderer/renderer/Camera.h | 119 + native/cocos/renderer/renderer/Config.cpp | 68 + native/cocos/renderer/renderer/Config.h | 46 + native/cocos/renderer/renderer/Effect.cpp | 112 + .../renderer/Effect.h} | 79 +- .../renderer/renderer/ForwardRenderer.cpp | 102 + .../renderer/ForwardRenderer.h} | 29 +- native/cocos/renderer/renderer/INode.h | 42 + .../renderer/InputAssembler.cpp} | 89 +- .../cocos/renderer/renderer/InputAssembler.h | 70 + native/cocos/renderer/renderer/Light.cpp | 255 + native/cocos/renderer/renderer/Light.h | 159 + native/cocos/renderer/renderer/Model.cpp | 108 + native/cocos/renderer/renderer/Model.h | 87 + native/cocos/renderer/renderer/Pass.cpp | 106 + native/cocos/renderer/renderer/Pass.h | 110 + native/cocos/renderer/renderer/ProgramLib.cpp | 246 + native/cocos/renderer/renderer/ProgramLib.h | 67 + native/cocos/renderer/renderer/Renderer.h | 40 + .../cocos/renderer/renderer/RendererUtils.cpp | 90 + .../renderer/RendererUtils.h} | 39 +- native/cocos/renderer/renderer/Scene.cpp | 110 + native/cocos/renderer/renderer/Scene.h | 79 + native/cocos/renderer/renderer/Technique.cpp | 383 ++ native/cocos/renderer/renderer/Technique.h | 136 + .../renderer/View.cpp} | 33 +- native/cocos/renderer/renderer/View.h | 72 + .../js-bindings/auto/jsb_gfx_auto.cpp | 1679 ++++++ .../js-bindings/auto/jsb_gfx_auto.hpp | 130 + .../js-bindings/auto/jsb_renderer_auto.cpp | 3160 ++++++++++++ .../js-bindings/auto/jsb_renderer_auto.hpp | 198 + .../js-bindings/manual/BaseJSAction.cpp | 115 - .../js-bindings/manual/BaseJSAction.h | 53 - .../js-bindings/manual/jsb_classtype.cpp | 25 - .../js-bindings/manual/jsb_classtype.hpp | 27 +- .../js-bindings/manual/jsb_conversions.cpp | 2428 ++++++--- .../js-bindings/manual/jsb_conversions.hpp | 238 +- .../js-bindings/manual/jsb_gfx_manual.cpp | 950 ++++ .../js-bindings/manual/jsb_gfx_manual.hpp | 7 + .../js-bindings/manual/jsb_global.cpp | 73 +- .../scripting/js-bindings/manual/jsb_global.h | 28 +- .../manual/jsb_module_register.cpp | 60 +- .../manual/jsb_renderer_manual.cpp | 398 ++ .../manual/jsb_renderer_manual.hpp | 7 + .../js-bindings/manual/jsb_socketio.cpp | 3 +- .../js-bindings/proj.android/Android.mk | 157 +- .../project.pbxproj | 372 +- .../script/ccui/jsb_ccui_create_apis.js | 187 - .../script/ccui/jsb_ccui_deprecated.js | 109 - .../script/ccui/jsb_ccui_property_apis.js | 74 - .../script/ccui/jsb_ccui_property_impls.js | 143 - .../js-bindings/script/ccui/jsb_cocos2d_ui.js | 278 - native/cocos/ui/Android.mk | 28 - native/cocos/ui/CocosGUI.cpp | 39 - native/cocos/ui/CocosGUI.h | 64 - native/cocos/ui/GUIDefine.h | 78 - native/cocos/ui/GUIExport.h | 59 - .../cocos/ui/UIEditBox/Mac/CCUIEditBoxMac.h | 73 - .../cocos/ui/UIEditBox/Mac/CCUIEditBoxMac.mm | 353 -- .../ui/UIEditBox/Mac/CCUIMultilineTextField.m | 121 - .../ui/UIEditBox/Mac/CCUIPasswordTextField.m | 222 - .../UIEditBox/Mac/CCUISingleLineTextField.m | 212 - native/cocos/ui/UIEditBox/Mac/CCUITextInput.h | 49 - native/cocos/ui/UIEditBox/UIEditBox.cpp | 538 -- native/cocos/ui/UIEditBox/UIEditBox.h | 509 -- .../ui/UIEditBox/UIEditBoxImpl-android.cpp | 264 - .../ui/UIEditBox/UIEditBoxImpl-android.h | 89 - .../ui/UIEditBox/UIEditBoxImpl-common.cpp | 411 -- .../cocos/ui/UIEditBox/UIEditBoxImpl-common.h | 148 - native/cocos/ui/UIEditBox/UIEditBoxImpl-ios.h | 95 - .../cocos/ui/UIEditBox/UIEditBoxImpl-ios.mm | 246 - native/cocos/ui/UIEditBox/UIEditBoxImpl-mac.h | 92 - .../cocos/ui/UIEditBox/UIEditBoxImpl-mac.mm | 232 - .../cocos/ui/UIEditBox/UIEditBoxImpl-stub.cpp | 44 - .../ui/UIEditBox/UIEditBoxImpl-win32.cpp | 450 -- .../cocos/ui/UIEditBox/UIEditBoxImpl-win32.h | 99 - native/cocos/ui/UIEditBox/UIEditBoxImpl.h | 106 - .../cocos/ui/UIEditBox/iOS/CCUIEditBoxIOS.h | 64 - .../cocos/ui/UIEditBox/iOS/CCUIEditBoxIOS.mm | 469 -- .../ui/UIEditBox/iOS/CCUIMultilineTextField.h | 40 - .../UIEditBox/iOS/CCUIMultilineTextField.mm | 156 - .../UIEditBox/iOS/CCUISingleLineTextField.h | 36 - native/cocos/ui/UIEditBox/iOS/CCUITextInput.h | 49 - .../UIEditBox/iOS/UITextField+CCUITextInput.h | 39 - .../UIEditBox/iOS/UITextView+CCUITextInput.mm | 100 - native/cocos/ui/UIHelper.cpp | 190 - native/cocos/ui/UIHelper.h | 124 - native/cocos/ui/UIScale9Sprite.cpp | 1422 ----- native/cocos/ui/UIScale9Sprite.h | 696 --- native/cocos/ui/UIVideoPlayer-android.cpp | 326 -- native/cocos/ui/UIVideoPlayer-ios.mm | 609 --- native/cocos/ui/UIVideoPlayer.h | 233 - native/cocos/ui/UIWebView-inl.h | 234 - native/cocos/ui/UIWebView.h | 252 - native/cocos/ui/UIWebViewImpl-android.cpp | 293 -- native/cocos/ui/UIWebViewImpl-android.h | 106 - native/cocos/ui/UIWebViewImpl-ios.h | 96 - native/cocos/ui/UIWebViewImpl-ios.mm | 395 -- native/cocos/ui/UIWidget.cpp | 1204 ----- native/cocos/ui/UIWidget.h | 851 --- native/cocos/ui/proj.win32/libui.vcxproj | 167 - .../cocos/ui/proj.win32/libui.vcxproj.filters | 210 - .../assets-manager/AssetsManagerEx.cpp | 22 +- .../assets-manager/AssetsManagerEx.h | 3 +- native/tools/tojs/cocos2dx_ui.ini | 70 - native/tools/tojs/gfx.ini | 71 + native/tools/tojs/renderer.ini | 72 + 420 files changed, 18575 insertions(+), 111255 deletions(-) delete mode 100644 native/cocos/2d/CCAction.cpp delete mode 100644 native/cocos/2d/CCAction.h delete mode 100644 native/cocos/2d/CCActionCamera.cpp delete mode 100644 native/cocos/2d/CCActionCamera.h delete mode 100644 native/cocos/2d/CCActionCatmullRom.cpp delete mode 100644 native/cocos/2d/CCActionCatmullRom.h delete mode 100644 native/cocos/2d/CCActionEase.cpp delete mode 100644 native/cocos/2d/CCActionEase.h delete mode 100644 native/cocos/2d/CCActionGrid.cpp delete mode 100644 native/cocos/2d/CCActionGrid.h delete mode 100644 native/cocos/2d/CCActionGrid3D.cpp delete mode 100644 native/cocos/2d/CCActionGrid3D.h delete mode 100644 native/cocos/2d/CCActionInstant.cpp delete mode 100644 native/cocos/2d/CCActionInstant.h delete mode 100644 native/cocos/2d/CCActionInterval.cpp delete mode 100644 native/cocos/2d/CCActionInterval.h delete mode 100644 native/cocos/2d/CCActionManager.cpp delete mode 100644 native/cocos/2d/CCActionManager.h delete mode 100644 native/cocos/2d/CCActionPageTurn3D.cpp delete mode 100644 native/cocos/2d/CCActionPageTurn3D.h delete mode 100644 native/cocos/2d/CCActionProgressTimer.cpp delete mode 100644 native/cocos/2d/CCActionProgressTimer.h delete mode 100644 native/cocos/2d/CCActionTiledGrid.cpp delete mode 100644 native/cocos/2d/CCActionTiledGrid.h delete mode 100644 native/cocos/2d/CCActionTween.cpp delete mode 100644 native/cocos/2d/CCActionTween.h delete mode 100644 native/cocos/2d/CCAnimation.cpp delete mode 100644 native/cocos/2d/CCAnimation.h delete mode 100644 native/cocos/2d/CCAnimationCache.cpp delete mode 100644 native/cocos/2d/CCAnimationCache.h delete mode 100644 native/cocos/2d/CCAtlasNode.cpp delete mode 100644 native/cocos/2d/CCAtlasNode.h delete mode 100644 native/cocos/2d/CCAutoPolygon.cpp delete mode 100644 native/cocos/2d/CCAutoPolygon.h delete mode 100644 native/cocos/2d/CCClippingNode.cpp delete mode 100644 native/cocos/2d/CCClippingNode.h delete mode 100644 native/cocos/2d/CCClippingRectangleNode.cpp delete mode 100644 native/cocos/2d/CCClippingRectangleNode.h delete mode 100644 native/cocos/2d/CCComponent.cpp delete mode 100644 native/cocos/2d/CCComponent.h delete mode 100644 native/cocos/2d/CCComponentContainer.cpp delete mode 100644 native/cocos/2d/CCComponentContainer.h delete mode 100644 native/cocos/2d/CCDrawNode.cpp delete mode 100644 native/cocos/2d/CCDrawNode.h delete mode 100644 native/cocos/2d/CCDrawingPrimitives.cpp delete mode 100644 native/cocos/2d/CCDrawingPrimitives.h delete mode 100644 native/cocos/2d/CCFastTMXLayer.cpp delete mode 100644 native/cocos/2d/CCFastTMXLayer.h delete mode 100644 native/cocos/2d/CCFastTMXTiledMap.cpp delete mode 100644 native/cocos/2d/CCFastTMXTiledMap.h delete mode 100644 native/cocos/2d/CCFont.cpp delete mode 100644 native/cocos/2d/CCFontAtlas.cpp delete mode 100644 native/cocos/2d/CCFontAtlas.h delete mode 100644 native/cocos/2d/CCFontAtlasCache.cpp delete mode 100644 native/cocos/2d/CCFontAtlasCache.h delete mode 100644 native/cocos/2d/CCFontCharMap.cpp delete mode 100644 native/cocos/2d/CCFontFNT.cpp delete mode 100644 native/cocos/2d/CCFontFNT.h delete mode 100644 native/cocos/2d/CCFontFreeType.cpp delete mode 100644 native/cocos/2d/CCFontFreeType.h delete mode 100644 native/cocos/2d/CCGLBufferedNode.cpp delete mode 100644 native/cocos/2d/CCGLBufferedNode.h delete mode 100644 native/cocos/2d/CCGrabber.cpp delete mode 100644 native/cocos/2d/CCGrabber.h delete mode 100644 native/cocos/2d/CCGrid.cpp delete mode 100644 native/cocos/2d/CCGrid.h delete mode 100644 native/cocos/2d/CCLabel.cpp delete mode 100644 native/cocos/2d/CCLabel.h delete mode 100644 native/cocos/2d/CCLabelAtlas.cpp delete mode 100644 native/cocos/2d/CCLabelAtlas.h delete mode 100644 native/cocos/2d/CCLabelTTF.cpp delete mode 100644 native/cocos/2d/CCLabelTTF.h delete mode 100644 native/cocos/2d/CCLabelTextFormatter.cpp delete mode 100644 native/cocos/2d/CCLabelTextFormatter.h delete mode 100644 native/cocos/2d/CCLayer.cpp delete mode 100644 native/cocos/2d/CCLayer.h delete mode 100644 native/cocos/2d/CCMenu.cpp delete mode 100644 native/cocos/2d/CCMenu.h delete mode 100644 native/cocos/2d/CCMenuItem.cpp delete mode 100644 native/cocos/2d/CCMenuItem.h delete mode 100644 native/cocos/2d/CCMotionStreak.cpp delete mode 100644 native/cocos/2d/CCMotionStreak.h delete mode 100644 native/cocos/2d/CCNode.cpp delete mode 100644 native/cocos/2d/CCNode.h delete mode 100644 native/cocos/2d/CCNodeGrid.cpp delete mode 100644 native/cocos/2d/CCNodeGrid.h delete mode 100644 native/cocos/2d/CCParallaxNode.cpp delete mode 100644 native/cocos/2d/CCParallaxNode.h delete mode 100644 native/cocos/2d/CCParticleBatchNode.cpp delete mode 100644 native/cocos/2d/CCParticleBatchNode.h delete mode 100644 native/cocos/2d/CCParticleExamples.cpp delete mode 100644 native/cocos/2d/CCParticleExamples.h delete mode 100644 native/cocos/2d/CCParticleSystem.cpp delete mode 100644 native/cocos/2d/CCParticleSystem.h delete mode 100644 native/cocos/2d/CCParticleSystemQuad.cpp delete mode 100644 native/cocos/2d/CCParticleSystemQuad.h delete mode 100644 native/cocos/2d/CCProgressTimer.cpp delete mode 100644 native/cocos/2d/CCProgressTimer.h delete mode 100644 native/cocos/2d/CCProtectedNode.cpp delete mode 100644 native/cocos/2d/CCProtectedNode.h delete mode 100644 native/cocos/2d/CCRenderTexture.cpp delete mode 100644 native/cocos/2d/CCRenderTexture.h delete mode 100644 native/cocos/2d/CCScene.cpp delete mode 100644 native/cocos/2d/CCScene.h delete mode 100644 native/cocos/2d/CCSprite.cpp delete mode 100644 native/cocos/2d/CCSprite.h delete mode 100644 native/cocos/2d/CCSpriteBatchNode.cpp delete mode 100644 native/cocos/2d/CCSpriteBatchNode.h delete mode 100644 native/cocos/2d/CCSpriteFrame.cpp delete mode 100644 native/cocos/2d/CCSpriteFrame.h delete mode 100644 native/cocos/2d/CCSpriteFrameCache.cpp delete mode 100644 native/cocos/2d/CCSpriteFrameCache.h delete mode 100644 native/cocos/2d/CCTMXLayer.cpp delete mode 100644 native/cocos/2d/CCTMXLayer.h delete mode 100644 native/cocos/2d/CCTMXObjectGroup.cpp delete mode 100644 native/cocos/2d/CCTMXObjectGroup.h delete mode 100644 native/cocos/2d/CCTMXTiledMap.cpp delete mode 100644 native/cocos/2d/CCTMXTiledMap.h delete mode 100644 native/cocos/2d/CCTMXXMLParser.cpp delete mode 100644 native/cocos/2d/CCTMXXMLParser.h delete mode 100644 native/cocos/2d/CCTextFieldTTF.cpp delete mode 100644 native/cocos/2d/CCTextFieldTTF.h delete mode 100644 native/cocos/2d/CCTileMapAtlas.cpp delete mode 100644 native/cocos/2d/CCTileMapAtlas.h delete mode 100644 native/cocos/2d/CCTransition.cpp delete mode 100644 native/cocos/2d/CCTransition.h delete mode 100644 native/cocos/2d/CCTransitionPageTurn.cpp delete mode 100644 native/cocos/2d/CCTransitionPageTurn.h delete mode 100644 native/cocos/2d/CCTransitionProgress.cpp delete mode 100644 native/cocos/2d/CCTransitionProgress.h delete mode 100644 native/cocos/2d/CCTweenFunction.cpp delete mode 100644 native/cocos/2d/CCTweenFunction.h delete mode 100644 native/cocos/2d/cocos2d.def delete mode 100644 native/cocos/2d/cocos2d_headers.props delete mode 100644 native/cocos/2d/cocos2dx.props delete mode 100644 native/cocos/2d/libcocos2d.vcxproj delete mode 100644 native/cocos/2d/libcocos2d.vcxproj.filters delete mode 100644 native/cocos/base/CCAsyncTaskPool.cpp delete mode 100644 native/cocos/base/CCAsyncTaskPool.h delete mode 100644 native/cocos/base/CCDirector.cpp delete mode 100644 native/cocos/base/CCDirector.h delete mode 100644 native/cocos/base/CCEventDispatcher.cpp delete mode 100644 native/cocos/base/CCEventDispatcher.h delete mode 100644 native/cocos/base/CCNinePatchImageParser.cpp delete mode 100644 native/cocos/base/CCNinePatchImageParser.h delete mode 100644 native/cocos/base/CCProtocols.h delete mode 100644 native/cocos/base/CCScheduler.cpp delete mode 100644 native/cocos/base/CCScheduler.h delete mode 100644 native/cocos/base/CCScriptSupport.cpp delete mode 100644 native/cocos/base/CCScriptSupport.h delete mode 100644 native/cocos/base/CCStencilStateManager.cpp delete mode 100644 native/cocos/base/CCStencilStateManager.hpp delete mode 100644 native/cocos/base/CCThreadPool.cpp delete mode 100644 native/cocos/base/CCThreadPool.h delete mode 100644 native/cocos/platform/CCApplication.h delete mode 100644 native/cocos/platform/CCApplicationProtocol.h delete mode 100644 native/cocos/platform/CCCommon.h delete mode 100644 native/cocos/platform/CCGLView.cpp delete mode 100644 native/cocos/platform/CCGLView.h delete mode 100644 native/cocos/platform/CCThread.cpp delete mode 100644 native/cocos/platform/CCThread.h delete mode 100644 native/cocos/platform/android/CCApplication-android.cpp delete mode 100644 native/cocos/platform/android/CCApplication-android.h delete mode 100644 native/cocos/platform/android/CCCommon-android.cpp delete mode 100644 native/cocos/platform/android/CCGLViewImpl-android.cpp delete mode 100644 native/cocos/platform/android/CCGLViewImpl-android.h delete mode 100644 native/cocos/platform/apple/CCThread-apple.mm delete mode 100644 native/cocos/platform/desktop/CCGLViewImpl-desktop.cpp delete mode 100644 native/cocos/platform/desktop/CCGLViewImpl-desktop.h delete mode 100644 native/cocos/platform/ios/CCApplication-ios.h delete mode 100644 native/cocos/platform/ios/CCApplication-ios.mm delete mode 100644 native/cocos/platform/ios/CCCommon-ios.mm delete mode 100644 native/cocos/platform/ios/CCGLViewImpl-ios.h delete mode 100644 native/cocos/platform/ios/CCGLViewImpl-ios.mm delete mode 100644 native/cocos/platform/mac/CCApplication-mac.h delete mode 100644 native/cocos/platform/mac/CCApplication-mac.mm delete mode 100644 native/cocos/platform/mac/CCCommon-mac.mm create mode 100644 native/cocos/renderer/Android.mk delete mode 100644 native/cocos/renderer/CCBatchCommand.cpp delete mode 100644 native/cocos/renderer/CCBatchCommand.h delete mode 100644 native/cocos/renderer/CCCustomCommand.h delete mode 100644 native/cocos/renderer/CCGLProgram.cpp delete mode 100644 native/cocos/renderer/CCGLProgram.h delete mode 100644 native/cocos/renderer/CCGLProgramCache.cpp delete mode 100644 native/cocos/renderer/CCGLProgramCache.h delete mode 100644 native/cocos/renderer/CCGLProgramState.cpp delete mode 100644 native/cocos/renderer/CCGLProgramState.h delete mode 100644 native/cocos/renderer/CCGLProgramStateCache.cpp delete mode 100644 native/cocos/renderer/CCGLProgramStateCache.h delete mode 100644 native/cocos/renderer/CCGroupCommand.cpp delete mode 100644 native/cocos/renderer/CCGroupCommand.h delete mode 100644 native/cocos/renderer/CCPrimitive.cpp delete mode 100644 native/cocos/renderer/CCPrimitive.h delete mode 100644 native/cocos/renderer/CCPrimitiveCommand.cpp delete mode 100644 native/cocos/renderer/CCPrimitiveCommand.h delete mode 100644 native/cocos/renderer/CCQuadCommand.cpp delete mode 100644 native/cocos/renderer/CCQuadCommand.h delete mode 100644 native/cocos/renderer/CCRenderCommand.h delete mode 100644 native/cocos/renderer/CCRenderCommandPool.h delete mode 100644 native/cocos/renderer/CCRenderer.cpp delete mode 100644 native/cocos/renderer/CCRenderer.h delete mode 100644 native/cocos/renderer/CCTexture2D.cpp delete mode 100644 native/cocos/renderer/CCTexture2D.h delete mode 100644 native/cocos/renderer/CCTextureAtlas.cpp delete mode 100644 native/cocos/renderer/CCTextureAtlas.h delete mode 100644 native/cocos/renderer/CCTextureCache.cpp delete mode 100644 native/cocos/renderer/CCTextureCache.h delete mode 100644 native/cocos/renderer/CCTrianglesCommand.cpp delete mode 100644 native/cocos/renderer/CCTrianglesCommand.h delete mode 100644 native/cocos/renderer/CCVertexIndexBuffer.cpp delete mode 100644 native/cocos/renderer/CCVertexIndexBuffer.h delete mode 100644 native/cocos/renderer/CCVertexIndexData.cpp delete mode 100644 native/cocos/renderer/CCVertexIndexData.h create mode 100644 native/cocos/renderer/Macro.h create mode 100644 native/cocos/renderer/Types.cpp create mode 100644 native/cocos/renderer/Types.h delete mode 100644 native/cocos/renderer/ccGLStateCache.cpp delete mode 100644 native/cocos/renderer/ccGLStateCache.h delete mode 100644 native/cocos/renderer/ccShader_CameraClear.frag delete mode 100644 native/cocos/renderer/ccShader_CameraClear.vert delete mode 100644 native/cocos/renderer/ccShader_Label.vert delete mode 100644 native/cocos/renderer/ccShader_Label_df.frag delete mode 100644 native/cocos/renderer/ccShader_Label_df_glow.frag delete mode 100644 native/cocos/renderer/ccShader_Label_normal.frag delete mode 100644 native/cocos/renderer/ccShader_Label_outline.frag delete mode 100644 native/cocos/renderer/ccShader_PositionColor.frag delete mode 100644 native/cocos/renderer/ccShader_PositionColor.vert delete mode 100644 native/cocos/renderer/ccShader_PositionColorLengthTexture.frag delete mode 100644 native/cocos/renderer/ccShader_PositionColorLengthTexture.vert delete mode 100644 native/cocos/renderer/ccShader_PositionColorTextureAsPointsize.vert delete mode 100644 native/cocos/renderer/ccShader_PositionColorTextureAsPointsize_wp81.vert delete mode 100644 native/cocos/renderer/ccShader_PositionTexture.frag delete mode 100644 native/cocos/renderer/ccShader_PositionTexture.vert delete mode 100644 native/cocos/renderer/ccShader_PositionTextureA8Color.frag delete mode 100644 native/cocos/renderer/ccShader_PositionTextureA8Color.vert delete mode 100644 native/cocos/renderer/ccShader_PositionTextureColor.frag delete mode 100644 native/cocos/renderer/ccShader_PositionTextureColor.vert delete mode 100644 native/cocos/renderer/ccShader_PositionTextureColorAlphaTest.frag delete mode 100644 native/cocos/renderer/ccShader_PositionTextureColor_noMVP.frag delete mode 100644 native/cocos/renderer/ccShader_PositionTextureColor_noMVP.vert delete mode 100644 native/cocos/renderer/ccShader_PositionTexture_uColor.frag delete mode 100644 native/cocos/renderer/ccShader_PositionTexture_uColor.vert delete mode 100644 native/cocos/renderer/ccShader_Position_uColor.frag delete mode 100644 native/cocos/renderer/ccShader_Position_uColor.vert delete mode 100644 native/cocos/renderer/ccShader_Position_uColor_wp81.vert delete mode 100644 native/cocos/renderer/ccShader_SpriteDistortion.frag delete mode 100644 native/cocos/renderer/ccShader_UI_Gray.frag delete mode 100644 native/cocos/renderer/ccShaders.cpp delete mode 100644 native/cocos/renderer/ccShaders.h create mode 100644 native/cocos/renderer/gfx/DeviceGraphics.cpp create mode 100644 native/cocos/renderer/gfx/DeviceGraphics.h create mode 100644 native/cocos/renderer/gfx/FrameBuffer.cpp rename native/cocos/{2d/CCFontCharMap.h => renderer/gfx/FrameBuffer.h} (51%) create mode 100644 native/cocos/renderer/gfx/GFX.cpp create mode 100644 native/cocos/renderer/gfx/GFX.h rename native/cocos/{ui/UIEditBox/iOS/CCUISingleLineTextField.mm => renderer/gfx/GFXUtils.cpp} (57%) rename native/cocos/{ui/UIWebView.mm => renderer/gfx/GFXUtils.h} (78%) rename native/cocos/{ui/UIEditBox/Mac/CCUISingleLineTextField.h => renderer/gfx/GraphicsHandle.cpp} (78%) rename native/cocos/{ui/UIWebView.cpp => renderer/gfx/GraphicsHandle.h} (77%) create mode 100644 native/cocos/renderer/gfx/IndexBuffer.cpp create mode 100644 native/cocos/renderer/gfx/IndexBuffer.h create mode 100644 native/cocos/renderer/gfx/Program.cpp create mode 100644 native/cocos/renderer/gfx/Program.h rename native/cocos/renderer/{CCRenderCommand.cpp => gfx/RenderBuffer.cpp} (56%) rename native/cocos/{2d/CCFont.h => renderer/gfx/RenderBuffer.h} (60%) create mode 100644 native/cocos/renderer/gfx/RenderTarget.cpp rename native/cocos/{ui/UIEditBox/Mac/CCUITextFieldFormatter.h => renderer/gfx/RenderTarget.h} (77%) create mode 100644 native/cocos/renderer/gfx/State.cpp create mode 100644 native/cocos/renderer/gfx/State.h create mode 100644 native/cocos/renderer/gfx/Texture.cpp create mode 100644 native/cocos/renderer/gfx/Texture.h create mode 100644 native/cocos/renderer/gfx/Texture2D.cpp rename native/cocos/renderer/{CCCustomCommand.cpp => gfx/Texture2D.h} (59%) create mode 100644 native/cocos/renderer/gfx/VertexBuffer.cpp create mode 100644 native/cocos/renderer/gfx/VertexBuffer.h create mode 100644 native/cocos/renderer/gfx/VertexFormat.cpp create mode 100644 native/cocos/renderer/gfx/VertexFormat.h create mode 100644 native/cocos/renderer/renderer/BaseRenderer.cpp create mode 100644 native/cocos/renderer/renderer/BaseRenderer.h create mode 100644 native/cocos/renderer/renderer/Camera.cpp create mode 100644 native/cocos/renderer/renderer/Camera.h create mode 100644 native/cocos/renderer/renderer/Config.cpp create mode 100644 native/cocos/renderer/renderer/Config.h create mode 100644 native/cocos/renderer/renderer/Effect.cpp rename native/cocos/{ui/UIEditBox/Mac/CCUITextFieldFormatter.m => renderer/renderer/Effect.h} (53%) create mode 100644 native/cocos/renderer/renderer/ForwardRenderer.cpp rename native/cocos/{ui/UIEditBox/iOS/UITextView+CCUITextInput.h => renderer/renderer/ForwardRenderer.h} (71%) create mode 100644 native/cocos/renderer/renderer/INode.h rename native/cocos/{ui/UIEditBox/iOS/UITextField+CCUITextInput.mm => renderer/renderer/InputAssembler.cpp} (52%) create mode 100644 native/cocos/renderer/renderer/InputAssembler.h create mode 100644 native/cocos/renderer/renderer/Light.cpp create mode 100644 native/cocos/renderer/renderer/Light.h create mode 100644 native/cocos/renderer/renderer/Model.cpp create mode 100644 native/cocos/renderer/renderer/Model.h create mode 100644 native/cocos/renderer/renderer/Pass.cpp create mode 100644 native/cocos/renderer/renderer/Pass.h create mode 100644 native/cocos/renderer/renderer/ProgramLib.cpp create mode 100644 native/cocos/renderer/renderer/ProgramLib.h create mode 100644 native/cocos/renderer/renderer/Renderer.h create mode 100644 native/cocos/renderer/renderer/RendererUtils.cpp rename native/cocos/{ui/UIEditBox/Mac/CCUIPasswordTextField.h => renderer/renderer/RendererUtils.h} (74%) create mode 100644 native/cocos/renderer/renderer/Scene.cpp create mode 100644 native/cocos/renderer/renderer/Scene.h create mode 100644 native/cocos/renderer/renderer/Technique.cpp create mode 100644 native/cocos/renderer/renderer/Technique.h rename native/cocos/{ui/UIEditBox/Mac/CCUIMultilineTextField.h => renderer/renderer/View.cpp} (77%) create mode 100644 native/cocos/renderer/renderer/View.h create mode 100644 native/cocos/scripting/js-bindings/auto/jsb_gfx_auto.cpp create mode 100644 native/cocos/scripting/js-bindings/auto/jsb_gfx_auto.hpp create mode 100644 native/cocos/scripting/js-bindings/auto/jsb_renderer_auto.cpp create mode 100644 native/cocos/scripting/js-bindings/auto/jsb_renderer_auto.hpp delete mode 100644 native/cocos/scripting/js-bindings/manual/BaseJSAction.cpp delete mode 100644 native/cocos/scripting/js-bindings/manual/BaseJSAction.h create mode 100644 native/cocos/scripting/js-bindings/manual/jsb_gfx_manual.cpp create mode 100644 native/cocos/scripting/js-bindings/manual/jsb_gfx_manual.hpp create mode 100644 native/cocos/scripting/js-bindings/manual/jsb_renderer_manual.cpp create mode 100644 native/cocos/scripting/js-bindings/manual/jsb_renderer_manual.hpp delete mode 100644 native/cocos/scripting/js-bindings/script/ccui/jsb_ccui_create_apis.js delete mode 100644 native/cocos/scripting/js-bindings/script/ccui/jsb_ccui_deprecated.js delete mode 100644 native/cocos/scripting/js-bindings/script/ccui/jsb_ccui_property_apis.js delete mode 100644 native/cocos/scripting/js-bindings/script/ccui/jsb_ccui_property_impls.js delete mode 100644 native/cocos/scripting/js-bindings/script/ccui/jsb_cocos2d_ui.js delete mode 100644 native/cocos/ui/Android.mk delete mode 100644 native/cocos/ui/CocosGUI.cpp delete mode 100644 native/cocos/ui/CocosGUI.h delete mode 100644 native/cocos/ui/GUIDefine.h delete mode 100644 native/cocos/ui/GUIExport.h delete mode 100644 native/cocos/ui/UIEditBox/Mac/CCUIEditBoxMac.h delete mode 100644 native/cocos/ui/UIEditBox/Mac/CCUIEditBoxMac.mm delete mode 100644 native/cocos/ui/UIEditBox/Mac/CCUIMultilineTextField.m delete mode 100644 native/cocos/ui/UIEditBox/Mac/CCUIPasswordTextField.m delete mode 100644 native/cocos/ui/UIEditBox/Mac/CCUISingleLineTextField.m delete mode 100644 native/cocos/ui/UIEditBox/Mac/CCUITextInput.h delete mode 100644 native/cocos/ui/UIEditBox/UIEditBox.cpp delete mode 100644 native/cocos/ui/UIEditBox/UIEditBox.h delete mode 100644 native/cocos/ui/UIEditBox/UIEditBoxImpl-android.cpp delete mode 100644 native/cocos/ui/UIEditBox/UIEditBoxImpl-android.h delete mode 100644 native/cocos/ui/UIEditBox/UIEditBoxImpl-common.cpp delete mode 100644 native/cocos/ui/UIEditBox/UIEditBoxImpl-common.h delete mode 100644 native/cocos/ui/UIEditBox/UIEditBoxImpl-ios.h delete mode 100644 native/cocos/ui/UIEditBox/UIEditBoxImpl-ios.mm delete mode 100644 native/cocos/ui/UIEditBox/UIEditBoxImpl-mac.h delete mode 100644 native/cocos/ui/UIEditBox/UIEditBoxImpl-mac.mm delete mode 100644 native/cocos/ui/UIEditBox/UIEditBoxImpl-stub.cpp delete mode 100644 native/cocos/ui/UIEditBox/UIEditBoxImpl-win32.cpp delete mode 100644 native/cocos/ui/UIEditBox/UIEditBoxImpl-win32.h delete mode 100644 native/cocos/ui/UIEditBox/UIEditBoxImpl.h delete mode 100644 native/cocos/ui/UIEditBox/iOS/CCUIEditBoxIOS.h delete mode 100644 native/cocos/ui/UIEditBox/iOS/CCUIEditBoxIOS.mm delete mode 100644 native/cocos/ui/UIEditBox/iOS/CCUIMultilineTextField.h delete mode 100644 native/cocos/ui/UIEditBox/iOS/CCUIMultilineTextField.mm delete mode 100644 native/cocos/ui/UIEditBox/iOS/CCUISingleLineTextField.h delete mode 100644 native/cocos/ui/UIEditBox/iOS/CCUITextInput.h delete mode 100644 native/cocos/ui/UIEditBox/iOS/UITextField+CCUITextInput.h delete mode 100644 native/cocos/ui/UIEditBox/iOS/UITextView+CCUITextInput.mm delete mode 100644 native/cocos/ui/UIHelper.cpp delete mode 100644 native/cocos/ui/UIHelper.h delete mode 100644 native/cocos/ui/UIScale9Sprite.cpp delete mode 100644 native/cocos/ui/UIScale9Sprite.h delete mode 100644 native/cocos/ui/UIVideoPlayer-android.cpp delete mode 100644 native/cocos/ui/UIVideoPlayer-ios.mm delete mode 100644 native/cocos/ui/UIVideoPlayer.h delete mode 100644 native/cocos/ui/UIWebView-inl.h delete mode 100644 native/cocos/ui/UIWebView.h delete mode 100644 native/cocos/ui/UIWebViewImpl-android.cpp delete mode 100644 native/cocos/ui/UIWebViewImpl-android.h delete mode 100644 native/cocos/ui/UIWebViewImpl-ios.h delete mode 100644 native/cocos/ui/UIWebViewImpl-ios.mm delete mode 100644 native/cocos/ui/UIWidget.cpp delete mode 100644 native/cocos/ui/UIWidget.h delete mode 100644 native/cocos/ui/proj.win32/libui.vcxproj delete mode 100644 native/cocos/ui/proj.win32/libui.vcxproj.filters delete mode 100644 native/tools/tojs/cocos2dx_ui.ini create mode 100644 native/tools/tojs/gfx.ini create mode 100644 native/tools/tojs/renderer.ini diff --git a/native/build/cocos2d_libs.xcodeproj/project.pbxproj b/native/build/cocos2d_libs.xcodeproj/project.pbxproj index deb411aeb8..39a6c7e0fc 100644 --- a/native/build/cocos2d_libs.xcodeproj/project.pbxproj +++ b/native/build/cocos2d_libs.xcodeproj/project.pbxproj @@ -7,55 +7,6 @@ objects = { /* Begin PBXBuildFile section */ - 15AE184A19AAD30500C27E9E /* Export.h in Headers */ = {isa = PBXBuildFile; fileRef = 46A15FE11807A56F005B8026 /* Export.h */; }; - 15AE184B19AAD30500C27E9E /* Export.h in Headers */ = {isa = PBXBuildFile; fileRef = 46A15FE11807A56F005B8026 /* Export.h */; }; - 15AE1B6719AADA9900C27E9E /* UIScale9Sprite.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 2958244919873D8E00F9746D /* UIScale9Sprite.cpp */; }; - 15AE1B6819AADA9900C27E9E /* UIScale9Sprite.h in Headers */ = {isa = PBXBuildFile; fileRef = 2958244A19873D8E00F9746D /* UIScale9Sprite.h */; }; - 15AE1B6B19AADA9900C27E9E /* UIWidget.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 2905FA1318CF08D100240AA3 /* UIWidget.cpp */; }; - 15AE1B6C19AADA9900C27E9E /* UIWidget.h in Headers */ = {isa = PBXBuildFile; fileRef = 2905FA1418CF08D100240AA3 /* UIWidget.h */; }; - 15AE1B6D19AADA9900C27E9E /* UIHelper.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 2905F9F418CF08D000240AA3 /* UIHelper.cpp */; }; - 15AE1B6E19AADA9900C27E9E /* UIHelper.h in Headers */ = {isa = PBXBuildFile; fileRef = 2905F9F518CF08D000240AA3 /* UIHelper.h */; }; - 15AE1B6F19AADA9900C27E9E /* GUIDefine.h in Headers */ = {isa = PBXBuildFile; fileRef = 2905F9EB18CF08D000240AA3 /* GUIDefine.h */; }; - 15AE1B7019AADA9900C27E9E /* CocosGUI.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 2905F9E918CF08D000240AA3 /* CocosGUI.cpp */; }; - 15AE1B7119AADA9900C27E9E /* CocosGUI.h in Headers */ = {isa = PBXBuildFile; fileRef = 2905F9EA18CF08D000240AA3 /* CocosGUI.h */; }; - 15AE1B8C19AADA9A00C27E9E /* UIScale9Sprite.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 2958244919873D8E00F9746D /* UIScale9Sprite.cpp */; }; - 15AE1B8D19AADA9A00C27E9E /* UIScale9Sprite.h in Headers */ = {isa = PBXBuildFile; fileRef = 2958244A19873D8E00F9746D /* UIScale9Sprite.h */; }; - 15AE1B9019AADA9A00C27E9E /* UIWidget.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 2905FA1318CF08D100240AA3 /* UIWidget.cpp */; }; - 15AE1B9119AADA9A00C27E9E /* UIWidget.h in Headers */ = {isa = PBXBuildFile; fileRef = 2905FA1418CF08D100240AA3 /* UIWidget.h */; }; - 15AE1B9219AADA9A00C27E9E /* UIHelper.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 2905F9F418CF08D000240AA3 /* UIHelper.cpp */; }; - 15AE1B9319AADA9A00C27E9E /* UIHelper.h in Headers */ = {isa = PBXBuildFile; fileRef = 2905F9F518CF08D000240AA3 /* UIHelper.h */; }; - 15AE1B9419AADA9A00C27E9E /* GUIDefine.h in Headers */ = {isa = PBXBuildFile; fileRef = 2905F9EB18CF08D000240AA3 /* GUIDefine.h */; }; - 15AE1B9519AADA9A00C27E9E /* CocosGUI.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 2905F9E918CF08D000240AA3 /* CocosGUI.cpp */; }; - 15AE1B9619AADA9A00C27E9E /* CocosGUI.h in Headers */ = {isa = PBXBuildFile; fileRef = 2905F9EA18CF08D000240AA3 /* CocosGUI.h */; }; - 15AE1B9719AADAA100C27E9E /* UIVideoPlayer.h in Headers */ = {isa = PBXBuildFile; fileRef = 3EA0FB69191C841D00B170C8 /* UIVideoPlayer.h */; }; - 15AE1B9819AADAA100C27E9E /* UIVideoPlayer-ios.mm in Sources */ = {isa = PBXBuildFile; fileRef = 3EA0FB6A191C841D00B170C8 /* UIVideoPlayer-ios.mm */; }; - 15AE1BB219AADFEF00C27E9E /* HttpClient.h in Headers */ = {isa = PBXBuildFile; fileRef = 1AAF5363180E3374000584C8 /* HttpClient.h */; }; - 15AE1BB319AADFEF00C27E9E /* HttpRequest.h in Headers */ = {isa = PBXBuildFile; fileRef = 1AAF5364180E3374000584C8 /* HttpRequest.h */; }; - 15AE1BB419AADFEF00C27E9E /* HttpResponse.h in Headers */ = {isa = PBXBuildFile; fileRef = 1AAF5365180E3374000584C8 /* HttpResponse.h */; }; - 15AE1BB519AADFEF00C27E9E /* SocketIO.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AAF5366180E3374000584C8 /* SocketIO.cpp */; }; - 15AE1BB619AADFEF00C27E9E /* SocketIO.h in Headers */ = {isa = PBXBuildFile; fileRef = 1AAF5367180E3374000584C8 /* SocketIO.h */; }; - 15AE1BB819AADFEF00C27E9E /* WebSocket.h in Headers */ = {isa = PBXBuildFile; fileRef = 1AAF5369180E3374000584C8 /* WebSocket.h */; }; - 15AE1BBA19AADFF000C27E9E /* HttpClient.h in Headers */ = {isa = PBXBuildFile; fileRef = 1AAF5363180E3374000584C8 /* HttpClient.h */; }; - 15AE1BBB19AADFF000C27E9E /* HttpRequest.h in Headers */ = {isa = PBXBuildFile; fileRef = 1AAF5364180E3374000584C8 /* HttpRequest.h */; }; - 15AE1BBC19AADFF000C27E9E /* HttpResponse.h in Headers */ = {isa = PBXBuildFile; fileRef = 1AAF5365180E3374000584C8 /* HttpResponse.h */; }; - 15AE1BBD19AADFF000C27E9E /* SocketIO.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AAF5366180E3374000584C8 /* SocketIO.cpp */; }; - 15AE1BBE19AADFF000C27E9E /* SocketIO.h in Headers */ = {isa = PBXBuildFile; fileRef = 1AAF5367180E3374000584C8 /* SocketIO.h */; }; - 15AE1BC019AADFF000C27E9E /* WebSocket.h in Headers */ = {isa = PBXBuildFile; fileRef = 1AAF5369180E3374000584C8 /* WebSocket.h */; }; - 15AE1BC119AADFFB00C27E9E /* cocos-ext.h in Headers */ = {isa = PBXBuildFile; fileRef = 46A167D21807AF4D005B8026 /* cocos-ext.h */; }; - 15AE1BC219AADFFB00C27E9E /* ExtensionMacros.h in Headers */ = {isa = PBXBuildFile; fileRef = 46A168321807AF4E005B8026 /* ExtensionMacros.h */; }; - 15AE1BC319AADFFB00C27E9E /* cocos-ext.h in Headers */ = {isa = PBXBuildFile; fileRef = 46A167D21807AF4D005B8026 /* cocos-ext.h */; }; - 15AE1BC419AADFFB00C27E9E /* ExtensionMacros.h in Headers */ = {isa = PBXBuildFile; fileRef = 46A168321807AF4E005B8026 /* ExtensionMacros.h */; }; - 15EFA211198A2BB5000C57D3 /* CCProtectedNode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15EFA20F198A2BB5000C57D3 /* CCProtectedNode.cpp */; }; - 15EFA212198A2BB5000C57D3 /* CCProtectedNode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15EFA20F198A2BB5000C57D3 /* CCProtectedNode.cpp */; }; - 15EFA213198A2BB5000C57D3 /* CCProtectedNode.h in Headers */ = {isa = PBXBuildFile; fileRef = 15EFA210198A2BB5000C57D3 /* CCProtectedNode.h */; }; - 15EFA214198A2BB5000C57D3 /* CCProtectedNode.h in Headers */ = {isa = PBXBuildFile; fileRef = 15EFA210198A2BB5000C57D3 /* CCProtectedNode.h */; }; - 15FB20741AE7BF8600C31518 /* CCAutoPolygon.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15FB20721AE7BF8600C31518 /* CCAutoPolygon.cpp */; }; - 15FB20751AE7BF8600C31518 /* CCAutoPolygon.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15FB20721AE7BF8600C31518 /* CCAutoPolygon.cpp */; }; - 15FB20761AE7BF8600C31518 /* CCAutoPolygon.h in Headers */ = {isa = PBXBuildFile; fileRef = 15FB20731AE7BF8600C31518 /* CCAutoPolygon.h */; }; - 15FB20771AE7BF8600C31518 /* CCAutoPolygon.h in Headers */ = {isa = PBXBuildFile; fileRef = 15FB20731AE7BF8600C31518 /* CCAutoPolygon.h */; }; - 1A12775A18DFCC4F0005F345 /* CCTweenFunction.h in Headers */ = {isa = PBXBuildFile; fileRef = 2986667918B1B079000E39CA /* CCTweenFunction.h */; }; - 1A12775B18DFCC540005F345 /* CCTweenFunction.h in Headers */ = {isa = PBXBuildFile; fileRef = 2986667918B1B079000E39CA /* CCTweenFunction.h */; }; - 1A12775C18DFCC590005F345 /* CCTweenFunction.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 2986667818B1B079000E39CA /* CCTweenFunction.cpp */; }; 1A28FF4D1F20AFAB007A1D9D /* SRDelegateController.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A28FF1F1F20AFAB007A1D9D /* SRDelegateController.h */; }; 1A28FF4E1F20AFAB007A1D9D /* SRDelegateController.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A28FF1F1F20AFAB007A1D9D /* SRDelegateController.h */; }; 1A28FF4F1F20AFAB007A1D9D /* SRDelegateController.m in Sources */ = {isa = PBXBuildFile; fileRef = 1A28FF201F20AFAB007A1D9D /* SRDelegateController.m */; settings = {COMPILER_FLAGS = "-fobjc-arc"; }; }; @@ -142,357 +93,279 @@ 1A37E9C6200DD0680078AF72 /* CCReachability.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A37E9C4200DD0680078AF72 /* CCReachability.cpp */; }; 1A37E9C7200DDFC70078AF72 /* CCReachability.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A37E9C3200DD0680078AF72 /* CCReachability.h */; }; 1A37E9C8200DDFC90078AF72 /* CCReachability.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A37E9C4200DD0680078AF72 /* CCReachability.cpp */; }; - 1A570061180BC5A10088DEC7 /* CCAction.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570047180BC5A10088DEC7 /* CCAction.cpp */; }; - 1A570062180BC5A10088DEC7 /* CCAction.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570047180BC5A10088DEC7 /* CCAction.cpp */; }; - 1A570063180BC5A10088DEC7 /* CCAction.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570048180BC5A10088DEC7 /* CCAction.h */; }; - 1A570064180BC5A10088DEC7 /* CCAction.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570048180BC5A10088DEC7 /* CCAction.h */; }; - 1A570065180BC5A10088DEC7 /* CCActionCamera.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570049180BC5A10088DEC7 /* CCActionCamera.cpp */; }; - 1A570066180BC5A10088DEC7 /* CCActionCamera.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570049180BC5A10088DEC7 /* CCActionCamera.cpp */; }; - 1A570067180BC5A10088DEC7 /* CCActionCamera.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57004A180BC5A10088DEC7 /* CCActionCamera.h */; }; - 1A570068180BC5A10088DEC7 /* CCActionCamera.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57004A180BC5A10088DEC7 /* CCActionCamera.h */; }; - 1A570069180BC5A10088DEC7 /* CCActionCatmullRom.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A57004B180BC5A10088DEC7 /* CCActionCatmullRom.cpp */; }; - 1A57006A180BC5A10088DEC7 /* CCActionCatmullRom.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A57004B180BC5A10088DEC7 /* CCActionCatmullRom.cpp */; }; - 1A57006B180BC5A10088DEC7 /* CCActionCatmullRom.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57004C180BC5A10088DEC7 /* CCActionCatmullRom.h */; }; - 1A57006C180BC5A10088DEC7 /* CCActionCatmullRom.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57004C180BC5A10088DEC7 /* CCActionCatmullRom.h */; }; - 1A57006D180BC5A10088DEC7 /* CCActionEase.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A57004D180BC5A10088DEC7 /* CCActionEase.cpp */; }; - 1A57006E180BC5A10088DEC7 /* CCActionEase.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A57004D180BC5A10088DEC7 /* CCActionEase.cpp */; }; - 1A57006F180BC5A10088DEC7 /* CCActionEase.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57004E180BC5A10088DEC7 /* CCActionEase.h */; }; - 1A570070180BC5A10088DEC7 /* CCActionEase.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57004E180BC5A10088DEC7 /* CCActionEase.h */; }; - 1A570071180BC5A10088DEC7 /* CCActionGrid.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A57004F180BC5A10088DEC7 /* CCActionGrid.cpp */; }; - 1A570072180BC5A10088DEC7 /* CCActionGrid.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A57004F180BC5A10088DEC7 /* CCActionGrid.cpp */; }; - 1A570073180BC5A10088DEC7 /* CCActionGrid.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570050180BC5A10088DEC7 /* CCActionGrid.h */; }; - 1A570074180BC5A10088DEC7 /* CCActionGrid.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570050180BC5A10088DEC7 /* CCActionGrid.h */; }; - 1A570075180BC5A10088DEC7 /* CCActionGrid3D.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570051180BC5A10088DEC7 /* CCActionGrid3D.cpp */; }; - 1A570076180BC5A10088DEC7 /* CCActionGrid3D.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570051180BC5A10088DEC7 /* CCActionGrid3D.cpp */; }; - 1A570077180BC5A10088DEC7 /* CCActionGrid3D.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570052180BC5A10088DEC7 /* CCActionGrid3D.h */; }; - 1A570078180BC5A10088DEC7 /* CCActionGrid3D.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570052180BC5A10088DEC7 /* CCActionGrid3D.h */; }; - 1A570079180BC5A10088DEC7 /* CCActionInstant.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570053180BC5A10088DEC7 /* CCActionInstant.cpp */; }; - 1A57007A180BC5A10088DEC7 /* CCActionInstant.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570053180BC5A10088DEC7 /* CCActionInstant.cpp */; }; - 1A57007B180BC5A10088DEC7 /* CCActionInstant.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570054180BC5A10088DEC7 /* CCActionInstant.h */; }; - 1A57007C180BC5A10088DEC7 /* CCActionInstant.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570054180BC5A10088DEC7 /* CCActionInstant.h */; }; - 1A57007D180BC5A10088DEC7 /* CCActionInterval.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570055180BC5A10088DEC7 /* CCActionInterval.cpp */; }; - 1A57007E180BC5A10088DEC7 /* CCActionInterval.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570055180BC5A10088DEC7 /* CCActionInterval.cpp */; }; - 1A57007F180BC5A10088DEC7 /* CCActionInterval.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570056180BC5A10088DEC7 /* CCActionInterval.h */; }; - 1A570080180BC5A10088DEC7 /* CCActionInterval.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570056180BC5A10088DEC7 /* CCActionInterval.h */; }; - 1A570081180BC5A10088DEC7 /* CCActionManager.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570057180BC5A10088DEC7 /* CCActionManager.cpp */; }; - 1A570082180BC5A10088DEC7 /* CCActionManager.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570057180BC5A10088DEC7 /* CCActionManager.cpp */; }; - 1A570083180BC5A10088DEC7 /* CCActionManager.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570058180BC5A10088DEC7 /* CCActionManager.h */; }; - 1A570084180BC5A10088DEC7 /* CCActionManager.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570058180BC5A10088DEC7 /* CCActionManager.h */; }; - 1A570085180BC5A10088DEC7 /* CCActionPageTurn3D.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570059180BC5A10088DEC7 /* CCActionPageTurn3D.cpp */; }; - 1A570086180BC5A10088DEC7 /* CCActionPageTurn3D.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570059180BC5A10088DEC7 /* CCActionPageTurn3D.cpp */; }; - 1A570087180BC5A10088DEC7 /* CCActionPageTurn3D.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57005A180BC5A10088DEC7 /* CCActionPageTurn3D.h */; }; - 1A570088180BC5A10088DEC7 /* CCActionPageTurn3D.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57005A180BC5A10088DEC7 /* CCActionPageTurn3D.h */; }; - 1A570089180BC5A10088DEC7 /* CCActionProgressTimer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A57005B180BC5A10088DEC7 /* CCActionProgressTimer.cpp */; }; - 1A57008A180BC5A10088DEC7 /* CCActionProgressTimer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A57005B180BC5A10088DEC7 /* CCActionProgressTimer.cpp */; }; - 1A57008B180BC5A10088DEC7 /* CCActionProgressTimer.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57005C180BC5A10088DEC7 /* CCActionProgressTimer.h */; }; - 1A57008C180BC5A10088DEC7 /* CCActionProgressTimer.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57005C180BC5A10088DEC7 /* CCActionProgressTimer.h */; }; - 1A57008D180BC5A10088DEC7 /* CCActionTiledGrid.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A57005D180BC5A10088DEC7 /* CCActionTiledGrid.cpp */; }; - 1A57008E180BC5A10088DEC7 /* CCActionTiledGrid.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A57005D180BC5A10088DEC7 /* CCActionTiledGrid.cpp */; }; - 1A57008F180BC5A10088DEC7 /* CCActionTiledGrid.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57005E180BC5A10088DEC7 /* CCActionTiledGrid.h */; }; - 1A570090180BC5A10088DEC7 /* CCActionTiledGrid.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57005E180BC5A10088DEC7 /* CCActionTiledGrid.h */; }; - 1A570091180BC5A10088DEC7 /* CCActionTween.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A57005F180BC5A10088DEC7 /* CCActionTween.cpp */; }; - 1A570092180BC5A10088DEC7 /* CCActionTween.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A57005F180BC5A10088DEC7 /* CCActionTween.cpp */; }; - 1A570093180BC5A10088DEC7 /* CCActionTween.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570060180BC5A10088DEC7 /* CCActionTween.h */; }; - 1A570094180BC5A10088DEC7 /* CCActionTween.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570060180BC5A10088DEC7 /* CCActionTween.h */; }; - 1A570098180BC5C10088DEC7 /* CCAtlasNode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570096180BC5C10088DEC7 /* CCAtlasNode.cpp */; }; - 1A570099180BC5C10088DEC7 /* CCAtlasNode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570096180BC5C10088DEC7 /* CCAtlasNode.cpp */; }; - 1A57009A180BC5C10088DEC7 /* CCAtlasNode.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570097180BC5C10088DEC7 /* CCAtlasNode.h */; }; - 1A57009B180BC5C10088DEC7 /* CCAtlasNode.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570097180BC5C10088DEC7 /* CCAtlasNode.h */; }; - 1A57009E180BC5D20088DEC7 /* CCNode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A57009C180BC5D20088DEC7 /* CCNode.cpp */; }; - 1A57009F180BC5D20088DEC7 /* CCNode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A57009C180BC5D20088DEC7 /* CCNode.cpp */; }; - 1A5700A0180BC5D20088DEC7 /* CCNode.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57009D180BC5D20088DEC7 /* CCNode.h */; }; - 1A5700A1180BC5D20088DEC7 /* CCNode.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57009D180BC5D20088DEC7 /* CCNode.h */; }; - 1A57010E180BC8EE0088DEC7 /* CCDrawingPrimitives.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A57010A180BC8ED0088DEC7 /* CCDrawingPrimitives.cpp */; }; - 1A57010F180BC8EE0088DEC7 /* CCDrawingPrimitives.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A57010A180BC8ED0088DEC7 /* CCDrawingPrimitives.cpp */; }; - 1A570110180BC8EE0088DEC7 /* CCDrawingPrimitives.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57010B180BC8EE0088DEC7 /* CCDrawingPrimitives.h */; }; - 1A570111180BC8EE0088DEC7 /* CCDrawingPrimitives.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57010B180BC8EE0088DEC7 /* CCDrawingPrimitives.h */; }; - 1A570112180BC8EE0088DEC7 /* CCDrawNode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A57010C180BC8EE0088DEC7 /* CCDrawNode.cpp */; }; - 1A570113180BC8EE0088DEC7 /* CCDrawNode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A57010C180BC8EE0088DEC7 /* CCDrawNode.cpp */; }; - 1A570114180BC8EE0088DEC7 /* CCDrawNode.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57010D180BC8EE0088DEC7 /* CCDrawNode.h */; }; - 1A570115180BC8EE0088DEC7 /* CCDrawNode.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57010D180BC8EE0088DEC7 /* CCDrawNode.h */; }; - 1A57011B180BC90D0088DEC7 /* CCGrabber.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570117180BC90D0088DEC7 /* CCGrabber.cpp */; }; - 1A57011C180BC90D0088DEC7 /* CCGrabber.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570117180BC90D0088DEC7 /* CCGrabber.cpp */; }; - 1A57011D180BC90D0088DEC7 /* CCGrabber.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570118180BC90D0088DEC7 /* CCGrabber.h */; }; - 1A57011E180BC90D0088DEC7 /* CCGrabber.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570118180BC90D0088DEC7 /* CCGrabber.h */; }; - 1A57011F180BC90D0088DEC7 /* CCGrid.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570119180BC90D0088DEC7 /* CCGrid.cpp */; }; - 1A570120180BC90D0088DEC7 /* CCGrid.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570119180BC90D0088DEC7 /* CCGrid.cpp */; }; - 1A570121180BC90D0088DEC7 /* CCGrid.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57011A180BC90D0088DEC7 /* CCGrid.h */; }; - 1A570122180BC90D0088DEC7 /* CCGrid.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57011A180BC90D0088DEC7 /* CCGrid.h */; }; - 1A57019D180BCB590088DEC7 /* CCFont.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570182180BCB590088DEC7 /* CCFont.cpp */; }; - 1A57019E180BCB590088DEC7 /* CCFont.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570182180BCB590088DEC7 /* CCFont.cpp */; }; - 1A57019F180BCB590088DEC7 /* CCFont.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570183180BCB590088DEC7 /* CCFont.h */; }; - 1A5701A0180BCB590088DEC7 /* CCFont.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570183180BCB590088DEC7 /* CCFont.h */; }; - 1A5701A1180BCB590088DEC7 /* CCFontAtlas.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570184180BCB590088DEC7 /* CCFontAtlas.cpp */; }; - 1A5701A2180BCB590088DEC7 /* CCFontAtlas.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570184180BCB590088DEC7 /* CCFontAtlas.cpp */; }; - 1A5701A3180BCB590088DEC7 /* CCFontAtlas.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570185180BCB590088DEC7 /* CCFontAtlas.h */; }; - 1A5701A4180BCB590088DEC7 /* CCFontAtlas.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570185180BCB590088DEC7 /* CCFontAtlas.h */; }; - 1A5701A5180BCB590088DEC7 /* CCFontAtlasCache.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570186180BCB590088DEC7 /* CCFontAtlasCache.cpp */; }; - 1A5701A6180BCB590088DEC7 /* CCFontAtlasCache.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570186180BCB590088DEC7 /* CCFontAtlasCache.cpp */; }; - 1A5701A7180BCB590088DEC7 /* CCFontAtlasCache.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570187180BCB590088DEC7 /* CCFontAtlasCache.h */; }; - 1A5701A8180BCB590088DEC7 /* CCFontAtlasCache.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570187180BCB590088DEC7 /* CCFontAtlasCache.h */; }; - 1A5701B1180BCB590088DEC7 /* CCFontFNT.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A57018C180BCB590088DEC7 /* CCFontFNT.cpp */; }; - 1A5701B2180BCB590088DEC7 /* CCFontFNT.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A57018C180BCB590088DEC7 /* CCFontFNT.cpp */; }; - 1A5701B3180BCB590088DEC7 /* CCFontFNT.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57018D180BCB590088DEC7 /* CCFontFNT.h */; }; - 1A5701B4180BCB590088DEC7 /* CCFontFNT.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57018D180BCB590088DEC7 /* CCFontFNT.h */; }; - 1A5701B5180BCB590088DEC7 /* CCFontFreeType.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A57018E180BCB590088DEC7 /* CCFontFreeType.cpp */; }; - 1A5701B6180BCB590088DEC7 /* CCFontFreeType.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A57018E180BCB590088DEC7 /* CCFontFreeType.cpp */; }; - 1A5701B7180BCB5A0088DEC7 /* CCFontFreeType.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57018F180BCB590088DEC7 /* CCFontFreeType.h */; }; - 1A5701B8180BCB5A0088DEC7 /* CCFontFreeType.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57018F180BCB590088DEC7 /* CCFontFreeType.h */; }; - 1A5701B9180BCB5A0088DEC7 /* CCLabel.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570190180BCB590088DEC7 /* CCLabel.cpp */; }; - 1A5701BA180BCB5A0088DEC7 /* CCLabel.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570190180BCB590088DEC7 /* CCLabel.cpp */; }; - 1A5701BB180BCB5A0088DEC7 /* CCLabel.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570191180BCB590088DEC7 /* CCLabel.h */; }; - 1A5701BC180BCB5A0088DEC7 /* CCLabel.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570191180BCB590088DEC7 /* CCLabel.h */; }; - 1A5701BD180BCB5A0088DEC7 /* CCLabelAtlas.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570192180BCB590088DEC7 /* CCLabelAtlas.cpp */; }; - 1A5701BE180BCB5A0088DEC7 /* CCLabelAtlas.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570192180BCB590088DEC7 /* CCLabelAtlas.cpp */; }; - 1A5701BF180BCB5A0088DEC7 /* CCLabelAtlas.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570193180BCB590088DEC7 /* CCLabelAtlas.h */; }; - 1A5701C0180BCB5A0088DEC7 /* CCLabelAtlas.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570193180BCB590088DEC7 /* CCLabelAtlas.h */; }; - 1A5701C7180BCB5A0088DEC7 /* CCLabelTextFormatter.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570197180BCB590088DEC7 /* CCLabelTextFormatter.cpp */; }; - 1A5701C8180BCB5A0088DEC7 /* CCLabelTextFormatter.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570197180BCB590088DEC7 /* CCLabelTextFormatter.cpp */; }; - 1A5701C9180BCB5A0088DEC7 /* CCLabelTextFormatter.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570198180BCB590088DEC7 /* CCLabelTextFormatter.h */; }; - 1A5701CA180BCB5A0088DEC7 /* CCLabelTextFormatter.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570198180BCB590088DEC7 /* CCLabelTextFormatter.h */; }; - 1A5701DE180BCB8C0088DEC7 /* CCLayer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A5701D4180BCB8C0088DEC7 /* CCLayer.cpp */; }; - 1A5701DF180BCB8C0088DEC7 /* CCLayer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A5701D4180BCB8C0088DEC7 /* CCLayer.cpp */; }; - 1A5701E0180BCB8C0088DEC7 /* CCLayer.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A5701D5180BCB8C0088DEC7 /* CCLayer.h */; }; - 1A5701E1180BCB8C0088DEC7 /* CCLayer.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A5701D5180BCB8C0088DEC7 /* CCLayer.h */; }; - 1A5701E2180BCB8C0088DEC7 /* CCScene.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A5701D6180BCB8C0088DEC7 /* CCScene.cpp */; }; - 1A5701E3180BCB8C0088DEC7 /* CCScene.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A5701D6180BCB8C0088DEC7 /* CCScene.cpp */; }; - 1A5701E4180BCB8C0088DEC7 /* CCScene.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A5701D7180BCB8C0088DEC7 /* CCScene.h */; }; - 1A5701E5180BCB8C0088DEC7 /* CCScene.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A5701D7180BCB8C0088DEC7 /* CCScene.h */; }; - 1A5701E6180BCB8C0088DEC7 /* CCTransition.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A5701D8180BCB8C0088DEC7 /* CCTransition.cpp */; }; - 1A5701E7180BCB8C0088DEC7 /* CCTransition.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A5701D8180BCB8C0088DEC7 /* CCTransition.cpp */; }; - 1A5701E8180BCB8C0088DEC7 /* CCTransition.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A5701D9180BCB8C0088DEC7 /* CCTransition.h */; }; - 1A5701E9180BCB8C0088DEC7 /* CCTransition.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A5701D9180BCB8C0088DEC7 /* CCTransition.h */; }; - 1A5701EA180BCB8C0088DEC7 /* CCTransitionPageTurn.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A5701DA180BCB8C0088DEC7 /* CCTransitionPageTurn.cpp */; }; - 1A5701EB180BCB8C0088DEC7 /* CCTransitionPageTurn.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A5701DA180BCB8C0088DEC7 /* CCTransitionPageTurn.cpp */; }; - 1A5701EC180BCB8C0088DEC7 /* CCTransitionPageTurn.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A5701DB180BCB8C0088DEC7 /* CCTransitionPageTurn.h */; }; - 1A5701ED180BCB8C0088DEC7 /* CCTransitionPageTurn.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A5701DB180BCB8C0088DEC7 /* CCTransitionPageTurn.h */; }; - 1A5701EE180BCB8C0088DEC7 /* CCTransitionProgress.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A5701DC180BCB8C0088DEC7 /* CCTransitionProgress.cpp */; }; - 1A5701EF180BCB8C0088DEC7 /* CCTransitionProgress.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A5701DC180BCB8C0088DEC7 /* CCTransitionProgress.cpp */; }; - 1A5701F0180BCB8C0088DEC7 /* CCTransitionProgress.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A5701DD180BCB8C0088DEC7 /* CCTransitionProgress.h */; }; - 1A5701F1180BCB8C0088DEC7 /* CCTransitionProgress.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A5701DD180BCB8C0088DEC7 /* CCTransitionProgress.h */; }; - 1A5701F7180BCBAD0088DEC7 /* CCMenu.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A5701F3180BCBAD0088DEC7 /* CCMenu.cpp */; }; - 1A5701F8180BCBAD0088DEC7 /* CCMenu.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A5701F3180BCBAD0088DEC7 /* CCMenu.cpp */; }; - 1A5701F9180BCBAD0088DEC7 /* CCMenu.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A5701F4180BCBAD0088DEC7 /* CCMenu.h */; }; - 1A5701FA180BCBAD0088DEC7 /* CCMenu.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A5701F4180BCBAD0088DEC7 /* CCMenu.h */; }; - 1A5701FB180BCBAD0088DEC7 /* CCMenuItem.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A5701F5180BCBAD0088DEC7 /* CCMenuItem.cpp */; }; - 1A5701FC180BCBAD0088DEC7 /* CCMenuItem.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A5701F5180BCBAD0088DEC7 /* CCMenuItem.cpp */; }; - 1A5701FD180BCBAD0088DEC7 /* CCMenuItem.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A5701F6180BCBAD0088DEC7 /* CCMenuItem.h */; }; - 1A5701FE180BCBAD0088DEC7 /* CCMenuItem.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A5701F6180BCBAD0088DEC7 /* CCMenuItem.h */; }; - 1A570202180BCBD40088DEC7 /* CCClippingNode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570200180BCBD40088DEC7 /* CCClippingNode.cpp */; }; - 1A570203180BCBD40088DEC7 /* CCClippingNode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570200180BCBD40088DEC7 /* CCClippingNode.cpp */; }; - 1A570204180BCBD40088DEC7 /* CCClippingNode.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570201180BCBD40088DEC7 /* CCClippingNode.h */; }; - 1A570205180BCBD40088DEC7 /* CCClippingNode.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570201180BCBD40088DEC7 /* CCClippingNode.h */; }; - 1A570208180BCBDF0088DEC7 /* CCMotionStreak.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570206180BCBDF0088DEC7 /* CCMotionStreak.cpp */; }; - 1A570209180BCBDF0088DEC7 /* CCMotionStreak.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570206180BCBDF0088DEC7 /* CCMotionStreak.cpp */; }; - 1A57020A180BCBDF0088DEC7 /* CCMotionStreak.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570207180BCBDF0088DEC7 /* CCMotionStreak.h */; }; - 1A57020B180BCBDF0088DEC7 /* CCMotionStreak.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570207180BCBDF0088DEC7 /* CCMotionStreak.h */; }; - 1A570210180BCBF40088DEC7 /* CCProgressTimer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A57020C180BCBF40088DEC7 /* CCProgressTimer.cpp */; }; - 1A570211180BCBF40088DEC7 /* CCProgressTimer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A57020C180BCBF40088DEC7 /* CCProgressTimer.cpp */; }; - 1A570212180BCBF40088DEC7 /* CCProgressTimer.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57020D180BCBF40088DEC7 /* CCProgressTimer.h */; }; - 1A570213180BCBF40088DEC7 /* CCProgressTimer.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57020D180BCBF40088DEC7 /* CCProgressTimer.h */; }; - 1A570214180BCBF40088DEC7 /* CCRenderTexture.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A57020E180BCBF40088DEC7 /* CCRenderTexture.cpp */; }; - 1A570215180BCBF40088DEC7 /* CCRenderTexture.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A57020E180BCBF40088DEC7 /* CCRenderTexture.cpp */; }; - 1A570216180BCBF40088DEC7 /* CCRenderTexture.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57020F180BCBF40088DEC7 /* CCRenderTexture.h */; }; - 1A570217180BCBF40088DEC7 /* CCRenderTexture.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57020F180BCBF40088DEC7 /* CCRenderTexture.h */; }; - 1A570221180BCC1A0088DEC7 /* CCParticleBatchNode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570219180BCC1A0088DEC7 /* CCParticleBatchNode.cpp */; }; - 1A570222180BCC1A0088DEC7 /* CCParticleBatchNode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570219180BCC1A0088DEC7 /* CCParticleBatchNode.cpp */; }; - 1A570223180BCC1A0088DEC7 /* CCParticleBatchNode.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57021A180BCC1A0088DEC7 /* CCParticleBatchNode.h */; }; - 1A570224180BCC1A0088DEC7 /* CCParticleBatchNode.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57021A180BCC1A0088DEC7 /* CCParticleBatchNode.h */; }; - 1A570225180BCC1A0088DEC7 /* CCParticleExamples.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A57021B180BCC1A0088DEC7 /* CCParticleExamples.cpp */; }; - 1A570226180BCC1A0088DEC7 /* CCParticleExamples.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A57021B180BCC1A0088DEC7 /* CCParticleExamples.cpp */; }; - 1A570227180BCC1A0088DEC7 /* CCParticleExamples.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57021C180BCC1A0088DEC7 /* CCParticleExamples.h */; }; - 1A570228180BCC1A0088DEC7 /* CCParticleExamples.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57021C180BCC1A0088DEC7 /* CCParticleExamples.h */; }; - 1A570229180BCC1A0088DEC7 /* CCParticleSystem.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A57021D180BCC1A0088DEC7 /* CCParticleSystem.cpp */; }; - 1A57022A180BCC1A0088DEC7 /* CCParticleSystem.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A57021D180BCC1A0088DEC7 /* CCParticleSystem.cpp */; }; - 1A57022B180BCC1A0088DEC7 /* CCParticleSystem.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57021E180BCC1A0088DEC7 /* CCParticleSystem.h */; }; - 1A57022C180BCC1A0088DEC7 /* CCParticleSystem.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57021E180BCC1A0088DEC7 /* CCParticleSystem.h */; }; - 1A57022D180BCC1A0088DEC7 /* CCParticleSystemQuad.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A57021F180BCC1A0088DEC7 /* CCParticleSystemQuad.cpp */; }; - 1A57022E180BCC1A0088DEC7 /* CCParticleSystemQuad.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A57021F180BCC1A0088DEC7 /* CCParticleSystemQuad.cpp */; }; - 1A57022F180BCC1A0088DEC7 /* CCParticleSystemQuad.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570220180BCC1A0088DEC7 /* CCParticleSystemQuad.h */; }; - 1A570230180BCC1A0088DEC7 /* CCParticleSystemQuad.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570220180BCC1A0088DEC7 /* CCParticleSystemQuad.h */; }; - 1A57027E180BCC900088DEC7 /* CCSprite.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570276180BCC900088DEC7 /* CCSprite.cpp */; }; - 1A57027F180BCC900088DEC7 /* CCSprite.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570276180BCC900088DEC7 /* CCSprite.cpp */; }; - 1A570280180BCC900088DEC7 /* CCSprite.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570277180BCC900088DEC7 /* CCSprite.h */; }; - 1A570281180BCC900088DEC7 /* CCSprite.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570277180BCC900088DEC7 /* CCSprite.h */; }; - 1A570282180BCC900088DEC7 /* CCSpriteBatchNode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570278180BCC900088DEC7 /* CCSpriteBatchNode.cpp */; }; - 1A570283180BCC900088DEC7 /* CCSpriteBatchNode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570278180BCC900088DEC7 /* CCSpriteBatchNode.cpp */; }; - 1A570284180BCC900088DEC7 /* CCSpriteBatchNode.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570279180BCC900088DEC7 /* CCSpriteBatchNode.h */; }; - 1A570285180BCC900088DEC7 /* CCSpriteBatchNode.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570279180BCC900088DEC7 /* CCSpriteBatchNode.h */; }; - 1A570286180BCC900088DEC7 /* CCSpriteFrame.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A57027A180BCC900088DEC7 /* CCSpriteFrame.cpp */; }; - 1A570287180BCC900088DEC7 /* CCSpriteFrame.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A57027A180BCC900088DEC7 /* CCSpriteFrame.cpp */; }; - 1A570288180BCC900088DEC7 /* CCSpriteFrame.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57027B180BCC900088DEC7 /* CCSpriteFrame.h */; }; - 1A570289180BCC900088DEC7 /* CCSpriteFrame.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57027B180BCC900088DEC7 /* CCSpriteFrame.h */; }; - 1A57028A180BCC900088DEC7 /* CCSpriteFrameCache.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A57027C180BCC900088DEC7 /* CCSpriteFrameCache.cpp */; }; - 1A57028B180BCC900088DEC7 /* CCSpriteFrameCache.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A57027C180BCC900088DEC7 /* CCSpriteFrameCache.cpp */; }; - 1A57028C180BCC900088DEC7 /* CCSpriteFrameCache.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57027D180BCC900088DEC7 /* CCSpriteFrameCache.h */; }; - 1A57028D180BCC900088DEC7 /* CCSpriteFrameCache.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57027D180BCC900088DEC7 /* CCSpriteFrameCache.h */; }; - 1A570292180BCCAB0088DEC7 /* CCAnimation.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A57028E180BCCAB0088DEC7 /* CCAnimation.cpp */; }; - 1A570293180BCCAB0088DEC7 /* CCAnimation.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A57028E180BCCAB0088DEC7 /* CCAnimation.cpp */; }; - 1A570294180BCCAB0088DEC7 /* CCAnimation.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57028F180BCCAB0088DEC7 /* CCAnimation.h */; }; - 1A570295180BCCAB0088DEC7 /* CCAnimation.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57028F180BCCAB0088DEC7 /* CCAnimation.h */; }; - 1A570296180BCCAB0088DEC7 /* CCAnimationCache.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570290180BCCAB0088DEC7 /* CCAnimationCache.cpp */; }; - 1A570297180BCCAB0088DEC7 /* CCAnimationCache.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570290180BCCAB0088DEC7 /* CCAnimationCache.cpp */; }; - 1A570298180BCCAB0088DEC7 /* CCAnimationCache.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570291180BCCAB0088DEC7 /* CCAnimationCache.h */; }; - 1A570299180BCCAB0088DEC7 /* CCAnimationCache.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570291180BCCAB0088DEC7 /* CCAnimationCache.h */; }; - 1A5702C8180BCE370088DEC7 /* CCTextFieldTTF.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A5702C6180BCE370088DEC7 /* CCTextFieldTTF.cpp */; }; - 1A5702C9180BCE370088DEC7 /* CCTextFieldTTF.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A5702C6180BCE370088DEC7 /* CCTextFieldTTF.cpp */; }; - 1A5702CA180BCE370088DEC7 /* CCTextFieldTTF.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A5702C7180BCE370088DEC7 /* CCTextFieldTTF.h */; }; - 1A5702CB180BCE370088DEC7 /* CCTextFieldTTF.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A5702C7180BCE370088DEC7 /* CCTextFieldTTF.h */; }; - 1A5702EA180BCE750088DEC7 /* CCTileMapAtlas.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A5702E0180BCE750088DEC7 /* CCTileMapAtlas.cpp */; }; - 1A5702EB180BCE750088DEC7 /* CCTileMapAtlas.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A5702E0180BCE750088DEC7 /* CCTileMapAtlas.cpp */; }; - 1A5702EC180BCE750088DEC7 /* CCTileMapAtlas.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A5702E1180BCE750088DEC7 /* CCTileMapAtlas.h */; }; - 1A5702ED180BCE750088DEC7 /* CCTileMapAtlas.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A5702E1180BCE750088DEC7 /* CCTileMapAtlas.h */; }; - 1A5702F2180BCE750088DEC7 /* CCTMXObjectGroup.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A5702E4180BCE750088DEC7 /* CCTMXObjectGroup.cpp */; }; - 1A5702F3180BCE750088DEC7 /* CCTMXObjectGroup.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A5702E4180BCE750088DEC7 /* CCTMXObjectGroup.cpp */; }; - 1A5702F4180BCE750088DEC7 /* CCTMXObjectGroup.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A5702E5180BCE750088DEC7 /* CCTMXObjectGroup.h */; }; - 1A5702F5180BCE750088DEC7 /* CCTMXObjectGroup.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A5702E5180BCE750088DEC7 /* CCTMXObjectGroup.h */; }; - 1A5702FA180BCE750088DEC7 /* CCTMXXMLParser.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A5702E8180BCE750088DEC7 /* CCTMXXMLParser.cpp */; }; - 1A5702FB180BCE750088DEC7 /* CCTMXXMLParser.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A5702E8180BCE750088DEC7 /* CCTMXXMLParser.cpp */; }; - 1A5702FC180BCE750088DEC7 /* CCTMXXMLParser.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A5702E9180BCE750088DEC7 /* CCTMXXMLParser.h */; }; - 1A5702FD180BCE750088DEC7 /* CCTMXXMLParser.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A5702E9180BCE750088DEC7 /* CCTMXXMLParser.h */; }; - 1A570300180BCE890088DEC7 /* CCParallaxNode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A5702FE180BCE890088DEC7 /* CCParallaxNode.cpp */; }; - 1A570301180BCE890088DEC7 /* CCParallaxNode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A5702FE180BCE890088DEC7 /* CCParallaxNode.cpp */; }; - 1A570302180BCE890088DEC7 /* CCParallaxNode.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A5702FF180BCE890088DEC7 /* CCParallaxNode.h */; }; - 1A570303180BCE890088DEC7 /* CCParallaxNode.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A5702FF180BCE890088DEC7 /* CCParallaxNode.h */; }; - 1A57030C180BCF190088DEC7 /* CCComponent.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570308180BCF190088DEC7 /* CCComponent.cpp */; }; - 1A57030D180BCF190088DEC7 /* CCComponent.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A570308180BCF190088DEC7 /* CCComponent.cpp */; }; - 1A57030E180BCF190088DEC7 /* CCComponent.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570309180BCF190088DEC7 /* CCComponent.h */; }; - 1A57030F180BCF190088DEC7 /* CCComponent.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A570309180BCF190088DEC7 /* CCComponent.h */; }; - 1A570310180BCF190088DEC7 /* CCComponentContainer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A57030A180BCF190088DEC7 /* CCComponentContainer.cpp */; }; - 1A570311180BCF190088DEC7 /* CCComponentContainer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A57030A180BCF190088DEC7 /* CCComponentContainer.cpp */; }; - 1A570312180BCF190088DEC7 /* CCComponentContainer.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57030B180BCF190088DEC7 /* CCComponentContainer.h */; }; - 1A570313180BCF190088DEC7 /* CCComponentContainer.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A57030B180BCF190088DEC7 /* CCComponentContainer.h */; }; - 1A5FB7CA1DF10E3500C918C1 /* AudioDecoder.mm in Sources */ = {isa = PBXBuildFile; fileRef = 1A5FB7C71DF10E3500C918C1 /* AudioDecoder.mm */; }; - 1A5FB7CB1DF10E3500C918C1 /* AudioDecoder.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A5FB7C81DF10E3500C918C1 /* AudioDecoder.h */; }; - 1A5FB7CC1DF10E3500C918C1 /* AudioMacros.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A5FB7C91DF10E3500C918C1 /* AudioMacros.h */; }; - 1A75DC171DFE3C7700A271DF /* AudioDecoder.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A5FB7C81DF10E3500C918C1 /* AudioDecoder.h */; }; - 1A75DC181DFE3C7700A271DF /* AudioDecoder.mm in Sources */ = {isa = PBXBuildFile; fileRef = 1A5FB7C71DF10E3500C918C1 /* AudioDecoder.mm */; }; - 1A75DC191DFE3C7700A271DF /* AudioMacros.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A5FB7C91DF10E3500C918C1 /* AudioMacros.h */; }; - 1A8D25511F39C4E3002CC0A8 /* WebSocket-apple.mm in Sources */ = {isa = PBXBuildFile; fileRef = 1A28FF191F20AF94007A1D9D /* WebSocket-apple.mm */; settings = {COMPILER_FLAGS = "-fobjc-arc"; }; }; - 1A8D25521F39C4E4002CC0A8 /* WebSocket-apple.mm in Sources */ = {isa = PBXBuildFile; fileRef = 1A28FF191F20AF94007A1D9D /* WebSocket-apple.mm */; settings = {COMPILER_FLAGS = "-fobjc-arc"; }; }; 1A9A4C6E1F98B1C000C14552 /* libcocosanalytics.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 1A9A4C6D1F98B1C000C14552 /* libcocosanalytics.a */; }; - 1A9DCA27180E6955007A3AD4 /* CCGLBufferedNode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A9DCA02180E6955007A3AD4 /* CCGLBufferedNode.cpp */; }; - 1A9DCA28180E6955007A3AD4 /* CCGLBufferedNode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A9DCA02180E6955007A3AD4 /* CCGLBufferedNode.cpp */; }; - 1A9DCA29180E6955007A3AD4 /* CCGLBufferedNode.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A9DCA03180E6955007A3AD4 /* CCGLBufferedNode.h */; }; - 1A9DCA2A180E6955007A3AD4 /* CCGLBufferedNode.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A9DCA03180E6955007A3AD4 /* CCGLBufferedNode.h */; }; 1A9F0F971F301DE200A499E1 /* b2ObjectDestroyNotifier.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A9F0F951F301DE200A499E1 /* b2ObjectDestroyNotifier.cpp */; }; 1A9F0F981F301DE200A499E1 /* b2ObjectDestroyNotifier.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A9F0F951F301DE200A499E1 /* b2ObjectDestroyNotifier.cpp */; }; 1A9F0F991F301DE200A499E1 /* b2ObjectDestroyNotifier.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A9F0F961F301DE200A499E1 /* b2ObjectDestroyNotifier.h */; }; 1A9F0F9A1F301DE200A499E1 /* b2ObjectDestroyNotifier.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A9F0F961F301DE200A499E1 /* b2ObjectDestroyNotifier.h */; }; - 1AAF584F180E40B9000584C8 /* LocalStorage.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AAF584C180E40B9000584C8 /* LocalStorage.cpp */; }; - 1AAF5850180E40B9000584C8 /* LocalStorage.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AAF584C180E40B9000584C8 /* LocalStorage.cpp */; }; - 1AAF5851180E40B9000584C8 /* LocalStorage.h in Headers */ = {isa = PBXBuildFile; fileRef = 1AAF584D180E40B9000584C8 /* LocalStorage.h */; }; - 1AAF5852180E40B9000584C8 /* LocalStorage.h in Headers */ = {isa = PBXBuildFile; fileRef = 1AAF584D180E40B9000584C8 /* LocalStorage.h */; }; - 1ABA68AE1888D700007D1BB4 /* CCFontCharMap.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1ABA68AC1888D700007D1BB4 /* CCFontCharMap.cpp */; }; - 1ABA68AF1888D700007D1BB4 /* CCFontCharMap.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1ABA68AC1888D700007D1BB4 /* CCFontCharMap.cpp */; }; - 1ABA68B01888D700007D1BB4 /* CCFontCharMap.h in Headers */ = {isa = PBXBuildFile; fileRef = 1ABA68AD1888D700007D1BB4 /* CCFontCharMap.h */; }; - 1ABA68B11888D700007D1BB4 /* CCFontCharMap.h in Headers */ = {isa = PBXBuildFile; fileRef = 1ABA68AD1888D700007D1BB4 /* CCFontCharMap.h */; }; 1ACF6A3C1E4AFDC80033C137 /* libcrypto.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 1ACF6A3A1E4AFDC80033C137 /* libcrypto.a */; }; 1ACF6A3D1E4AFDC80033C137 /* libssl.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 1ACF6A3B1E4AFDC80033C137 /* libssl.a */; }; - 1AD473AC1EAD9A5200202582 /* Uri.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AD473AA1EAD9A5200202582 /* Uri.cpp */; }; - 1AD473AD1EAD9A5300202582 /* Uri.h in Headers */ = {isa = PBXBuildFile; fileRef = 1AD473AB1EAD9A5200202582 /* Uri.h */; }; - 1AD473AE1EAD9A5600202582 /* Uri.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AD473AA1EAD9A5200202582 /* Uri.cpp */; }; - 1AD473AF1EAD9A5900202582 /* Uri.h in Headers */ = {isa = PBXBuildFile; fileRef = 1AD473AB1EAD9A5200202582 /* Uri.h */; }; - 1AFFCD771F7A59B200628F2C /* CCThreadPool.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 844EB11D1F78D4CA00EFE4CD /* CCThreadPool.cpp */; }; - 1AFFCD781F7A59B200628F2C /* CCThreadPool.h in Headers */ = {isa = PBXBuildFile; fileRef = 844EB11E1F78D4CA00EFE4CD /* CCThreadPool.h */; }; - 291901431B05895600F8B4BA /* CCNinePatchImageParser.h in Headers */ = {isa = PBXBuildFile; fileRef = 291901411B05895600F8B4BA /* CCNinePatchImageParser.h */; }; - 291901441B05895600F8B4BA /* CCNinePatchImageParser.h in Headers */ = {isa = PBXBuildFile; fileRef = 291901411B05895600F8B4BA /* CCNinePatchImageParser.h */; }; - 291901451B05895600F8B4BA /* CCNinePatchImageParser.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 291901421B05895600F8B4BA /* CCNinePatchImageParser.cpp */; }; - 291901461B05895600F8B4BA /* CCNinePatchImageParser.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 291901421B05895600F8B4BA /* CCNinePatchImageParser.cpp */; }; - 292DB13D19B4574100A80320 /* UIEditBox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 292DB12F19B4574100A80320 /* UIEditBox.cpp */; }; - 292DB13E19B4574100A80320 /* UIEditBox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 292DB12F19B4574100A80320 /* UIEditBox.cpp */; }; - 292DB13F19B4574100A80320 /* UIEditBox.h in Headers */ = {isa = PBXBuildFile; fileRef = 292DB13019B4574100A80320 /* UIEditBox.h */; }; - 292DB14019B4574100A80320 /* UIEditBox.h in Headers */ = {isa = PBXBuildFile; fileRef = 292DB13019B4574100A80320 /* UIEditBox.h */; }; - 292DB14119B4574100A80320 /* UIEditBoxImpl.h in Headers */ = {isa = PBXBuildFile; fileRef = 292DB13119B4574100A80320 /* UIEditBoxImpl.h */; }; - 292DB14219B4574100A80320 /* UIEditBoxImpl.h in Headers */ = {isa = PBXBuildFile; fileRef = 292DB13119B4574100A80320 /* UIEditBoxImpl.h */; }; - 292DB14819B4574100A80320 /* UIEditBoxImpl-ios.h in Headers */ = {isa = PBXBuildFile; fileRef = 292DB13419B4574100A80320 /* UIEditBoxImpl-ios.h */; }; - 292DB14A19B4574100A80320 /* UIEditBoxImpl-ios.mm in Sources */ = {isa = PBXBuildFile; fileRef = 292DB13519B4574100A80320 /* UIEditBoxImpl-ios.mm */; }; - 292DB14B19B4574100A80320 /* UIEditBoxImpl-mac.h in Headers */ = {isa = PBXBuildFile; fileRef = 292DB13619B4574100A80320 /* UIEditBoxImpl-mac.h */; }; - 292DB14D19B4574100A80320 /* UIEditBoxImpl-mac.mm in Sources */ = {isa = PBXBuildFile; fileRef = 292DB13719B4574100A80320 /* UIEditBoxImpl-mac.mm */; }; - 29394CF019B01DBA00D2DE1A /* UIWebView.h in Headers */ = {isa = PBXBuildFile; fileRef = 29394CEC19B01DBA00D2DE1A /* UIWebView.h */; }; - 29394CF119B01DBA00D2DE1A /* UIWebView.h in Headers */ = {isa = PBXBuildFile; fileRef = 29394CEC19B01DBA00D2DE1A /* UIWebView.h */; }; - 29394CF219B01DBA00D2DE1A /* UIWebView.mm in Sources */ = {isa = PBXBuildFile; fileRef = 29394CED19B01DBA00D2DE1A /* UIWebView.mm */; }; - 29394CF319B01DBA00D2DE1A /* UIWebView.mm in Sources */ = {isa = PBXBuildFile; fileRef = 29394CED19B01DBA00D2DE1A /* UIWebView.mm */; }; - 29394CF419B01DBA00D2DE1A /* UIWebViewImpl-ios.h in Headers */ = {isa = PBXBuildFile; fileRef = 29394CEE19B01DBA00D2DE1A /* UIWebViewImpl-ios.h */; }; - 29394CF519B01DBA00D2DE1A /* UIWebViewImpl-ios.h in Headers */ = {isa = PBXBuildFile; fileRef = 29394CEE19B01DBA00D2DE1A /* UIWebViewImpl-ios.h */; }; - 29394CF619B01DBA00D2DE1A /* UIWebViewImpl-ios.mm in Sources */ = {isa = PBXBuildFile; fileRef = 29394CEF19B01DBA00D2DE1A /* UIWebViewImpl-ios.mm */; }; - 29394CF719B01DBA00D2DE1A /* UIWebViewImpl-ios.mm in Sources */ = {isa = PBXBuildFile; fileRef = 29394CEF19B01DBA00D2DE1A /* UIWebViewImpl-ios.mm */; }; 294D7D9A1D0E93A2002CE7B7 /* CCDevice-apple.h in Headers */ = {isa = PBXBuildFile; fileRef = 294D7D981D0E93A2002CE7B7 /* CCDevice-apple.h */; }; 294D7D9B1D0E93A2002CE7B7 /* CCDevice-apple.h in Headers */ = {isa = PBXBuildFile; fileRef = 294D7D981D0E93A2002CE7B7 /* CCDevice-apple.h */; }; 294D7D9C1D0E93A2002CE7B7 /* CCDevice-apple.mm in Sources */ = {isa = PBXBuildFile; fileRef = 294D7D991D0E93A2002CE7B7 /* CCDevice-apple.mm */; }; 294D7D9D1D0E93A2002CE7B7 /* CCDevice-apple.mm in Sources */ = {isa = PBXBuildFile; fileRef = 294D7D991D0E93A2002CE7B7 /* CCDevice-apple.mm */; }; - 2980F0221BA9A5550059E678 /* CCUIEditBoxIOS.h in Headers */ = {isa = PBXBuildFile; fileRef = 2980F0171BA9A5550059E678 /* CCUIEditBoxIOS.h */; }; - 2980F0231BA9A5550059E678 /* CCUIEditBoxIOS.mm in Sources */ = {isa = PBXBuildFile; fileRef = 2980F0181BA9A5550059E678 /* CCUIEditBoxIOS.mm */; }; - 2980F0241BA9A5550059E678 /* CCUIMultilineTextField.h in Headers */ = {isa = PBXBuildFile; fileRef = 2980F0191BA9A5550059E678 /* CCUIMultilineTextField.h */; }; - 2980F0251BA9A5550059E678 /* CCUIMultilineTextField.mm in Sources */ = {isa = PBXBuildFile; fileRef = 2980F01A1BA9A5550059E678 /* CCUIMultilineTextField.mm */; }; - 2980F0261BA9A5550059E678 /* CCUISingleLineTextField.h in Headers */ = {isa = PBXBuildFile; fileRef = 2980F01B1BA9A5550059E678 /* CCUISingleLineTextField.h */; }; - 2980F0271BA9A5550059E678 /* CCUISingleLineTextField.mm in Sources */ = {isa = PBXBuildFile; fileRef = 2980F01C1BA9A5550059E678 /* CCUISingleLineTextField.mm */; }; - 2980F0281BA9A5550059E678 /* CCUITextInput.h in Headers */ = {isa = PBXBuildFile; fileRef = 2980F01D1BA9A5550059E678 /* CCUITextInput.h */; }; - 2980F0291BA9A5550059E678 /* UITextField+CCUITextInput.h in Headers */ = {isa = PBXBuildFile; fileRef = 2980F01E1BA9A5550059E678 /* UITextField+CCUITextInput.h */; }; - 2980F02A1BA9A5550059E678 /* UITextField+CCUITextInput.mm in Sources */ = {isa = PBXBuildFile; fileRef = 2980F01F1BA9A5550059E678 /* UITextField+CCUITextInput.mm */; }; - 2980F02B1BA9A5550059E678 /* UITextView+CCUITextInput.h in Headers */ = {isa = PBXBuildFile; fileRef = 2980F0201BA9A5550059E678 /* UITextView+CCUITextInput.h */; }; - 2980F02C1BA9A5550059E678 /* UITextView+CCUITextInput.mm in Sources */ = {isa = PBXBuildFile; fileRef = 2980F0211BA9A5550059E678 /* UITextView+CCUITextInput.mm */; }; - 2986667F18B1B246000E39CA /* CCTweenFunction.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 2986667818B1B079000E39CA /* CCTweenFunction.cpp */; }; - 299754F4193EC95400A54AC3 /* ObjectFactory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 299754F2193EC95400A54AC3 /* ObjectFactory.cpp */; }; - 299754F5193EC95400A54AC3 /* ObjectFactory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 299754F2193EC95400A54AC3 /* ObjectFactory.cpp */; }; - 299754F6193EC95400A54AC3 /* ObjectFactory.h in Headers */ = {isa = PBXBuildFile; fileRef = 299754F3193EC95400A54AC3 /* ObjectFactory.h */; }; - 299754F7193EC95400A54AC3 /* ObjectFactory.h in Headers */ = {isa = PBXBuildFile; fileRef = 299754F3193EC95400A54AC3 /* ObjectFactory.h */; }; - 299CF1FB19A434BC00C378C1 /* ccRandom.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 299CF1F919A434BC00C378C1 /* ccRandom.cpp */; }; - 299CF1FC19A434BC00C378C1 /* ccRandom.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 299CF1F919A434BC00C378C1 /* ccRandom.cpp */; }; - 299CF1FD19A434BC00C378C1 /* ccRandom.h in Headers */ = {isa = PBXBuildFile; fileRef = 299CF1FA19A434BC00C378C1 /* ccRandom.h */; }; - 299CF1FE19A434BC00C378C1 /* ccRandom.h in Headers */ = {isa = PBXBuildFile; fileRef = 299CF1FA19A434BC00C378C1 /* ccRandom.h */; }; - 3E2BDADE19C030ED0055CDCD /* AudioEngine.h in Headers */ = {isa = PBXBuildFile; fileRef = 3E2BDADD19C030ED0055CDCD /* AudioEngine.h */; }; - 3E2BDAEC19C0436F0055CDCD /* AudioEngine.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 3E2BDAEB19C0436F0055CDCD /* AudioEngine.cpp */; }; - 3E2F27A619CFBFE100E7C490 /* AudioEngine.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 3E2BDAEB19C0436F0055CDCD /* AudioEngine.cpp */; }; - 3E2F27A719CFBFE400E7C490 /* AudioEngine.h in Headers */ = {isa = PBXBuildFile; fileRef = 3E2BDADD19C030ED0055CDCD /* AudioEngine.h */; }; - 464AD6E5197EBB1400E502D8 /* pvr.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 464AD6E3197EBB1400E502D8 /* pvr.cpp */; }; - 464AD6E6197EBB1400E502D8 /* pvr.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 464AD6E3197EBB1400E502D8 /* pvr.cpp */; }; - 464AD6E7197EBB1400E502D8 /* pvr.h in Headers */ = {isa = PBXBuildFile; fileRef = 464AD6E4197EBB1400E502D8 /* pvr.h */; }; - 464AD6E8197EBB1400E502D8 /* pvr.h in Headers */ = {isa = PBXBuildFile; fileRef = 464AD6E4197EBB1400E502D8 /* pvr.h */; }; - 4D2816661E8CBB7200F26B06 /* CCPhysicsContactImpulse.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4D2816641E8CBB7200F26B06 /* CCPhysicsContactImpulse.cpp */; }; - 4D2816671E8CBB7200F26B06 /* CCPhysicsContactImpulse.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4D2816641E8CBB7200F26B06 /* CCPhysicsContactImpulse.cpp */; }; - 4D2816681E8CBB7200F26B06 /* CCPhysicsContactImpulse.h in Headers */ = {isa = PBXBuildFile; fileRef = 4D2816651E8CBB7200F26B06 /* CCPhysicsContactImpulse.h */; }; - 4D2816691E8CBB7200F26B06 /* CCPhysicsContactImpulse.h in Headers */ = {isa = PBXBuildFile; fileRef = 4D2816651E8CBB7200F26B06 /* CCPhysicsContactImpulse.h */; }; - 4D2E69071CC543B40032DD5C /* CCGraphicsNode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4D2E69031CC543B40032DD5C /* CCGraphicsNode.cpp */; }; - 4D2E69081CC543B40032DD5C /* CCGraphicsNode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4D2E69031CC543B40032DD5C /* CCGraphicsNode.cpp */; }; - 4D2E69091CC543B40032DD5C /* CCGraphicsNode.h in Headers */ = {isa = PBXBuildFile; fileRef = 4D2E69041CC543B40032DD5C /* CCGraphicsNode.h */; }; - 4D2E690A1CC543B40032DD5C /* CCGraphicsNode.h in Headers */ = {isa = PBXBuildFile; fileRef = 4D2E69041CC543B40032DD5C /* CCGraphicsNode.h */; }; - 4D2E690B1CC543B40032DD5C /* Triangulate.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4D2E69051CC543B40032DD5C /* Triangulate.cpp */; }; - 4D2E690C1CC543B40032DD5C /* Triangulate.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4D2E69051CC543B40032DD5C /* Triangulate.cpp */; }; - 4D2E690D1CC543B40032DD5C /* Triangulate.h in Headers */ = {isa = PBXBuildFile; fileRef = 4D2E69061CC543B40032DD5C /* Triangulate.h */; }; - 4D2E690E1CC543B40032DD5C /* Triangulate.h in Headers */ = {isa = PBXBuildFile; fileRef = 4D2E69061CC543B40032DD5C /* Triangulate.h */; }; - 4D6CF4371E83AAD5003327D4 /* CCCameraNode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4D6CF4351E83AAD5003327D4 /* CCCameraNode.cpp */; }; - 4D6CF4381E83AAD5003327D4 /* CCCameraNode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4D6CF4351E83AAD5003327D4 /* CCCameraNode.cpp */; }; - 4D6CF4391E83AAD5003327D4 /* CCCameraNode.h in Headers */ = {isa = PBXBuildFile; fileRef = 4D6CF4361E83AAD5003327D4 /* CCCameraNode.h */; }; - 4D6CF43A1E83AAD5003327D4 /* CCCameraNode.h in Headers */ = {isa = PBXBuildFile; fileRef = 4D6CF4361E83AAD5003327D4 /* CCCameraNode.h */; }; - 4DC06BCF1E8A68D400CA08B1 /* CCPhysicsAABBQueryCallback.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4DC06BC11E8A68D400CA08B1 /* CCPhysicsAABBQueryCallback.cpp */; }; - 4DC06BD01E8A68D400CA08B1 /* CCPhysicsAABBQueryCallback.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4DC06BC11E8A68D400CA08B1 /* CCPhysicsAABBQueryCallback.cpp */; }; - 4DC06BD11E8A68D400CA08B1 /* CCPhysicsAABBQueryCallback.h in Headers */ = {isa = PBXBuildFile; fileRef = 4DC06BC21E8A68D400CA08B1 /* CCPhysicsAABBQueryCallback.h */; }; - 4DC06BD21E8A68D400CA08B1 /* CCPhysicsAABBQueryCallback.h in Headers */ = {isa = PBXBuildFile; fileRef = 4DC06BC21E8A68D400CA08B1 /* CCPhysicsAABBQueryCallback.h */; }; - 4DC06BD31E8A68D400CA08B1 /* CCPhysicsContactListener.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4DC06BC31E8A68D400CA08B1 /* CCPhysicsContactListener.cpp */; }; - 4DC06BD41E8A68D400CA08B1 /* CCPhysicsContactListener.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4DC06BC31E8A68D400CA08B1 /* CCPhysicsContactListener.cpp */; }; - 4DC06BD51E8A68D400CA08B1 /* CCPhysicsContactListener.h in Headers */ = {isa = PBXBuildFile; fileRef = 4DC06BC41E8A68D400CA08B1 /* CCPhysicsContactListener.h */; }; - 4DC06BD61E8A68D400CA08B1 /* CCPhysicsContactListener.h in Headers */ = {isa = PBXBuildFile; fileRef = 4DC06BC41E8A68D400CA08B1 /* CCPhysicsContactListener.h */; }; - 4DC06BDB1E8A68D400CA08B1 /* CCPhysicsDebugDraw.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4DC06BC71E8A68D400CA08B1 /* CCPhysicsDebugDraw.cpp */; }; - 4DC06BDC1E8A68D400CA08B1 /* CCPhysicsDebugDraw.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4DC06BC71E8A68D400CA08B1 /* CCPhysicsDebugDraw.cpp */; }; - 4DC06BDD1E8A68D400CA08B1 /* CCPhysicsDebugDraw.h in Headers */ = {isa = PBXBuildFile; fileRef = 4DC06BC81E8A68D400CA08B1 /* CCPhysicsDebugDraw.h */; }; - 4DC06BDE1E8A68D400CA08B1 /* CCPhysicsDebugDraw.h in Headers */ = {isa = PBXBuildFile; fileRef = 4DC06BC81E8A68D400CA08B1 /* CCPhysicsDebugDraw.h */; }; - 4DC06BDF1E8A68D400CA08B1 /* CCPhysicsRayCastCallback.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4DC06BC91E8A68D400CA08B1 /* CCPhysicsRayCastCallback.cpp */; }; - 4DC06BE01E8A68D400CA08B1 /* CCPhysicsRayCastCallback.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4DC06BC91E8A68D400CA08B1 /* CCPhysicsRayCastCallback.cpp */; }; - 4DC06BE11E8A68D400CA08B1 /* CCPhysicsRayCastCallback.h in Headers */ = {isa = PBXBuildFile; fileRef = 4DC06BCA1E8A68D400CA08B1 /* CCPhysicsRayCastCallback.h */; }; - 4DC06BE21E8A68D400CA08B1 /* CCPhysicsRayCastCallback.h in Headers */ = {isa = PBXBuildFile; fileRef = 4DC06BCA1E8A68D400CA08B1 /* CCPhysicsRayCastCallback.h */; }; - 4DC06BE31E8A68D400CA08B1 /* CCPhysicsUtils.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4DC06BCB1E8A68D400CA08B1 /* CCPhysicsUtils.cpp */; }; - 4DC06BE41E8A68D400CA08B1 /* CCPhysicsUtils.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4DC06BCB1E8A68D400CA08B1 /* CCPhysicsUtils.cpp */; }; - 4DC06BE51E8A68D400CA08B1 /* CCPhysicsUtils.h in Headers */ = {isa = PBXBuildFile; fileRef = 4DC06BCC1E8A68D400CA08B1 /* CCPhysicsUtils.h */; }; - 4DC06BE61E8A68D400CA08B1 /* CCPhysicsUtils.h in Headers */ = {isa = PBXBuildFile; fileRef = 4DC06BCC1E8A68D400CA08B1 /* CCPhysicsUtils.h */; }; - 4DC06BE71E8A68D400CA08B1 /* CCPhysicsWorldManifoldWrapper.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4DC06BCD1E8A68D400CA08B1 /* CCPhysicsWorldManifoldWrapper.cpp */; }; - 4DC06BE81E8A68D400CA08B1 /* CCPhysicsWorldManifoldWrapper.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4DC06BCD1E8A68D400CA08B1 /* CCPhysicsWorldManifoldWrapper.cpp */; }; - 4DC06BE91E8A68D400CA08B1 /* CCPhysicsWorldManifoldWrapper.h in Headers */ = {isa = PBXBuildFile; fileRef = 4DC06BCE1E8A68D400CA08B1 /* CCPhysicsWorldManifoldWrapper.h */; }; - 4DC06BEA1E8A68D400CA08B1 /* CCPhysicsWorldManifoldWrapper.h in Headers */ = {isa = PBXBuildFile; fileRef = 4DC06BCE1E8A68D400CA08B1 /* CCPhysicsWorldManifoldWrapper.h */; }; - 4DC06BED1E8B604B00CA08B1 /* CCPhysicsManifoldWrapper.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4DC06BEB1E8B604B00CA08B1 /* CCPhysicsManifoldWrapper.cpp */; }; - 4DC06BEE1E8B604B00CA08B1 /* CCPhysicsManifoldWrapper.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4DC06BEB1E8B604B00CA08B1 /* CCPhysicsManifoldWrapper.cpp */; }; - 4DC06BEF1E8B604B00CA08B1 /* CCPhysicsManifoldWrapper.h in Headers */ = {isa = PBXBuildFile; fileRef = 4DC06BEC1E8B604B00CA08B1 /* CCPhysicsManifoldWrapper.h */; }; - 4DC06BF01E8B604B00CA08B1 /* CCPhysicsManifoldWrapper.h in Headers */ = {isa = PBXBuildFile; fileRef = 4DC06BEC1E8B604B00CA08B1 /* CCPhysicsManifoldWrapper.h */; }; + 46FDDA6D202ACC6A00931238 /* INode.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA2E202ACC6A00931238 /* INode.h */; }; + 46FDDA6E202ACC6A00931238 /* INode.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA2E202ACC6A00931238 /* INode.h */; }; + 46FDDA6F202ACC6A00931238 /* Pass.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA2F202ACC6A00931238 /* Pass.cpp */; }; + 46FDDA70202ACC6A00931238 /* Pass.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA2F202ACC6A00931238 /* Pass.cpp */; }; + 46FDDA71202ACC6A00931238 /* Scene.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA30202ACC6A00931238 /* Scene.cpp */; }; + 46FDDA72202ACC6A00931238 /* Scene.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA30202ACC6A00931238 /* Scene.cpp */; }; + 46FDDA73202ACC6A00931238 /* ProgramLib.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA31202ACC6A00931238 /* ProgramLib.h */; }; + 46FDDA74202ACC6A00931238 /* ProgramLib.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA31202ACC6A00931238 /* ProgramLib.h */; }; + 46FDDA75202ACC6A00931238 /* Config.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA32202ACC6A00931238 /* Config.h */; }; + 46FDDA76202ACC6A00931238 /* Config.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA32202ACC6A00931238 /* Config.h */; }; + 46FDDA77202ACC6A00931238 /* Light.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA33202ACC6A00931238 /* Light.h */; }; + 46FDDA78202ACC6A00931238 /* Light.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA33202ACC6A00931238 /* Light.h */; }; + 46FDDA79202ACC6A00931238 /* Camera.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA34202ACC6A00931238 /* Camera.cpp */; }; + 46FDDA7A202ACC6A00931238 /* Camera.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA34202ACC6A00931238 /* Camera.cpp */; }; + 46FDDA7B202ACC6A00931238 /* Camera.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA35202ACC6A00931238 /* Camera.h */; }; + 46FDDA7C202ACC6A00931238 /* Camera.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA35202ACC6A00931238 /* Camera.h */; }; + 46FDDA7D202ACC6A00931238 /* Light.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA36202ACC6A00931238 /* Light.cpp */; }; + 46FDDA7E202ACC6A00931238 /* Light.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA36202ACC6A00931238 /* Light.cpp */; }; + 46FDDA7F202ACC6A00931238 /* Renderer.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA37202ACC6A00931238 /* Renderer.h */; }; + 46FDDA80202ACC6A00931238 /* Renderer.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA37202ACC6A00931238 /* Renderer.h */; }; + 46FDDA81202ACC6A00931238 /* RendererUtils.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA38202ACC6A00931238 /* RendererUtils.h */; }; + 46FDDA82202ACC6A00931238 /* RendererUtils.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA38202ACC6A00931238 /* RendererUtils.h */; }; + 46FDDA83202ACC6A00931238 /* Technique.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA39202ACC6A00931238 /* Technique.h */; }; + 46FDDA84202ACC6A00931238 /* Technique.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA39202ACC6A00931238 /* Technique.h */; }; + 46FDDA85202ACC6A00931238 /* View.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA3A202ACC6A00931238 /* View.h */; }; + 46FDDA86202ACC6A00931238 /* View.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA3A202ACC6A00931238 /* View.h */; }; + 46FDDA87202ACC6A00931238 /* View.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA3B202ACC6A00931238 /* View.cpp */; }; + 46FDDA88202ACC6A00931238 /* View.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA3B202ACC6A00931238 /* View.cpp */; }; + 46FDDA89202ACC6A00931238 /* Effect.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA3C202ACC6A00931238 /* Effect.cpp */; }; + 46FDDA8A202ACC6A00931238 /* Effect.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA3C202ACC6A00931238 /* Effect.cpp */; }; + 46FDDA8B202ACC6A00931238 /* ForwardRenderer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA3D202ACC6A00931238 /* ForwardRenderer.cpp */; }; + 46FDDA8C202ACC6A00931238 /* ForwardRenderer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA3D202ACC6A00931238 /* ForwardRenderer.cpp */; }; + 46FDDA8D202ACC6A00931238 /* Config.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA3E202ACC6A00931238 /* Config.cpp */; }; + 46FDDA8E202ACC6A00931238 /* Config.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA3E202ACC6A00931238 /* Config.cpp */; }; + 46FDDA8F202ACC6A00931238 /* BaseRenderer.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA3F202ACC6A00931238 /* BaseRenderer.h */; }; + 46FDDA90202ACC6A00931238 /* BaseRenderer.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA3F202ACC6A00931238 /* BaseRenderer.h */; }; + 46FDDA91202ACC6A00931238 /* Pass.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA40202ACC6A00931238 /* Pass.h */; }; + 46FDDA92202ACC6A00931238 /* Pass.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA40202ACC6A00931238 /* Pass.h */; }; + 46FDDA93202ACC6A00931238 /* Technique.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA41202ACC6A00931238 /* Technique.cpp */; }; + 46FDDA94202ACC6A00931238 /* Technique.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA41202ACC6A00931238 /* Technique.cpp */; }; + 46FDDA95202ACC6A00931238 /* RendererUtils.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA42202ACC6A00931238 /* RendererUtils.cpp */; }; + 46FDDA96202ACC6A00931238 /* RendererUtils.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA42202ACC6A00931238 /* RendererUtils.cpp */; }; + 46FDDA97202ACC6A00931238 /* Model.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA43202ACC6A00931238 /* Model.h */; }; + 46FDDA98202ACC6A00931238 /* Model.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA43202ACC6A00931238 /* Model.h */; }; + 46FDDA99202ACC6A00931238 /* Model.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA44202ACC6A00931238 /* Model.cpp */; }; + 46FDDA9A202ACC6A00931238 /* Model.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA44202ACC6A00931238 /* Model.cpp */; }; + 46FDDA9B202ACC6A00931238 /* Effect.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA45202ACC6A00931238 /* Effect.h */; }; + 46FDDA9C202ACC6A00931238 /* Effect.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA45202ACC6A00931238 /* Effect.h */; }; + 46FDDA9D202ACC6A00931238 /* BaseRenderer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA46202ACC6A00931238 /* BaseRenderer.cpp */; }; + 46FDDA9E202ACC6A00931238 /* BaseRenderer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA46202ACC6A00931238 /* BaseRenderer.cpp */; }; + 46FDDA9F202ACC6A00931238 /* ProgramLib.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA47202ACC6A00931238 /* ProgramLib.cpp */; }; + 46FDDAA0202ACC6A00931238 /* ProgramLib.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA47202ACC6A00931238 /* ProgramLib.cpp */; }; + 46FDDAA1202ACC6A00931238 /* InputAssembler.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA48202ACC6A00931238 /* InputAssembler.h */; }; + 46FDDAA2202ACC6A00931238 /* InputAssembler.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA48202ACC6A00931238 /* InputAssembler.h */; }; + 46FDDAA3202ACC6A00931238 /* InputAssembler.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA49202ACC6A00931238 /* InputAssembler.cpp */; }; + 46FDDAA4202ACC6A00931238 /* InputAssembler.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA49202ACC6A00931238 /* InputAssembler.cpp */; }; + 46FDDAA5202ACC6A00931238 /* Scene.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA4A202ACC6A00931238 /* Scene.h */; }; + 46FDDAA6202ACC6A00931238 /* Scene.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA4A202ACC6A00931238 /* Scene.h */; }; + 46FDDAA7202ACC6A00931238 /* ForwardRenderer.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA4B202ACC6A00931238 /* ForwardRenderer.h */; }; + 46FDDAA8202ACC6A00931238 /* ForwardRenderer.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA4B202ACC6A00931238 /* ForwardRenderer.h */; }; + 46FDDAA9202ACC6A00931238 /* Types.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA4C202ACC6A00931238 /* Types.cpp */; }; + 46FDDAAA202ACC6A00931238 /* Types.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA4C202ACC6A00931238 /* Types.cpp */; }; + 46FDDAAB202ACC6A00931238 /* Types.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA4E202ACC6A00931238 /* Types.h */; }; + 46FDDAAC202ACC6A00931238 /* Types.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA4E202ACC6A00931238 /* Types.h */; }; + 46FDDAAD202ACC6A00931238 /* Macro.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA4F202ACC6A00931238 /* Macro.h */; }; + 46FDDAAE202ACC6A00931238 /* Macro.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA4F202ACC6A00931238 /* Macro.h */; }; + 46FDDAAF202ACC6A00931238 /* Texture2D.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA51202ACC6A00931238 /* Texture2D.h */; }; + 46FDDAB0202ACC6A00931238 /* Texture2D.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA51202ACC6A00931238 /* Texture2D.h */; }; + 46FDDAB1202ACC6A00931238 /* DeviceGraphics.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA52202ACC6A00931238 /* DeviceGraphics.cpp */; }; + 46FDDAB2202ACC6A00931238 /* DeviceGraphics.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA52202ACC6A00931238 /* DeviceGraphics.cpp */; }; + 46FDDAB3202ACC6A00931238 /* VertexBuffer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA53202ACC6A00931238 /* VertexBuffer.cpp */; }; + 46FDDAB4202ACC6A00931238 /* VertexBuffer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA53202ACC6A00931238 /* VertexBuffer.cpp */; }; + 46FDDAB5202ACC6A00931238 /* Program.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA54202ACC6A00931238 /* Program.cpp */; }; + 46FDDAB6202ACC6A00931238 /* Program.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA54202ACC6A00931238 /* Program.cpp */; }; + 46FDDAB7202ACC6A00931238 /* IndexBuffer.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA55202ACC6A00931238 /* IndexBuffer.h */; }; + 46FDDAB8202ACC6A00931238 /* IndexBuffer.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA55202ACC6A00931238 /* IndexBuffer.h */; }; + 46FDDAB9202ACC6A00931238 /* FrameBuffer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA56202ACC6A00931238 /* FrameBuffer.cpp */; }; + 46FDDABA202ACC6A00931238 /* FrameBuffer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA56202ACC6A00931238 /* FrameBuffer.cpp */; }; + 46FDDABB202ACC6A00931238 /* VertexFormat.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA57202ACC6A00931238 /* VertexFormat.cpp */; }; + 46FDDABC202ACC6A00931238 /* VertexFormat.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA57202ACC6A00931238 /* VertexFormat.cpp */; }; + 46FDDABD202ACC6A00931238 /* DeviceGraphics.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA58202ACC6A00931238 /* DeviceGraphics.h */; }; + 46FDDABE202ACC6A00931238 /* DeviceGraphics.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA58202ACC6A00931238 /* DeviceGraphics.h */; }; + 46FDDABF202ACC6A00931238 /* State.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA59202ACC6A00931238 /* State.cpp */; }; + 46FDDAC0202ACC6A00931238 /* State.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA59202ACC6A00931238 /* State.cpp */; }; + 46FDDAC1202ACC6A00931238 /* Texture.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA5A202ACC6A00931238 /* Texture.cpp */; }; + 46FDDAC2202ACC6A00931238 /* Texture.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA5A202ACC6A00931238 /* Texture.cpp */; }; + 46FDDAC3202ACC6A00931238 /* FrameBuffer.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA5B202ACC6A00931238 /* FrameBuffer.h */; }; + 46FDDAC4202ACC6A00931238 /* FrameBuffer.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA5B202ACC6A00931238 /* FrameBuffer.h */; }; + 46FDDAC5202ACC6A00931238 /* RenderTarget.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA5C202ACC6A00931238 /* RenderTarget.cpp */; }; + 46FDDAC6202ACC6A00931238 /* RenderTarget.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA5C202ACC6A00931238 /* RenderTarget.cpp */; }; + 46FDDAC7202ACC6A00931238 /* GFX.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA5D202ACC6A00931238 /* GFX.h */; }; + 46FDDAC8202ACC6A00931238 /* GFX.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA5D202ACC6A00931238 /* GFX.h */; }; + 46FDDAC9202ACC6A00931238 /* RenderBuffer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA5E202ACC6A00931238 /* RenderBuffer.cpp */; }; + 46FDDACA202ACC6A00931238 /* RenderBuffer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA5E202ACC6A00931238 /* RenderBuffer.cpp */; }; + 46FDDACB202ACC6A00931238 /* VertexFormat.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA5F202ACC6A00931238 /* VertexFormat.h */; }; + 46FDDACC202ACC6A00931238 /* VertexFormat.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA5F202ACC6A00931238 /* VertexFormat.h */; }; + 46FDDACD202ACC6A00931238 /* GraphicsHandle.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA60202ACC6A00931238 /* GraphicsHandle.h */; }; + 46FDDACE202ACC6A00931238 /* GraphicsHandle.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA60202ACC6A00931238 /* GraphicsHandle.h */; }; + 46FDDACF202ACC6A00931238 /* RenderBuffer.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA61202ACC6A00931238 /* RenderBuffer.h */; }; + 46FDDAD0202ACC6A00931238 /* RenderBuffer.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA61202ACC6A00931238 /* RenderBuffer.h */; }; + 46FDDAD1202ACC6A00931238 /* Texture.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA62202ACC6A00931238 /* Texture.h */; }; + 46FDDAD2202ACC6A00931238 /* Texture.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA62202ACC6A00931238 /* Texture.h */; }; + 46FDDAD3202ACC6A00931238 /* Texture2D.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA63202ACC6A00931238 /* Texture2D.cpp */; }; + 46FDDAD4202ACC6A00931238 /* Texture2D.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA63202ACC6A00931238 /* Texture2D.cpp */; }; + 46FDDAD5202ACC6A00931238 /* GraphicsHandle.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA64202ACC6A00931238 /* GraphicsHandle.cpp */; }; + 46FDDAD6202ACC6A00931238 /* GraphicsHandle.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA64202ACC6A00931238 /* GraphicsHandle.cpp */; }; + 46FDDAD7202ACC6A00931238 /* GFXUtils.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA65202ACC6A00931238 /* GFXUtils.h */; }; + 46FDDAD8202ACC6A00931238 /* GFXUtils.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA65202ACC6A00931238 /* GFXUtils.h */; }; + 46FDDAD9202ACC6A00931238 /* Program.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA66202ACC6A00931238 /* Program.h */; }; + 46FDDADA202ACC6A00931238 /* Program.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA66202ACC6A00931238 /* Program.h */; }; + 46FDDADB202ACC6A00931238 /* State.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA67202ACC6A00931238 /* State.h */; }; + 46FDDADC202ACC6A00931238 /* State.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA67202ACC6A00931238 /* State.h */; }; + 46FDDADD202ACC6A00931238 /* VertexBuffer.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA68202ACC6A00931238 /* VertexBuffer.h */; }; + 46FDDADE202ACC6A00931238 /* VertexBuffer.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA68202ACC6A00931238 /* VertexBuffer.h */; }; + 46FDDADF202ACC6A00931238 /* RenderTarget.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA69202ACC6A00931238 /* RenderTarget.h */; }; + 46FDDAE0202ACC6A00931238 /* RenderTarget.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDA69202ACC6A00931238 /* RenderTarget.h */; }; + 46FDDAE1202ACC6A00931238 /* GFXUtils.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA6A202ACC6A00931238 /* GFXUtils.cpp */; }; + 46FDDAE2202ACC6A00931238 /* GFXUtils.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA6A202ACC6A00931238 /* GFXUtils.cpp */; }; + 46FDDAE3202ACC6A00931238 /* GFX.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA6B202ACC6A00931238 /* GFX.cpp */; }; + 46FDDAE4202ACC6B00931238 /* GFX.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA6B202ACC6A00931238 /* GFX.cpp */; }; + 46FDDAE5202ACC6B00931238 /* IndexBuffer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA6C202ACC6A00931238 /* IndexBuffer.cpp */; }; + 46FDDAE6202ACC6B00931238 /* IndexBuffer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDA6C202ACC6A00931238 /* IndexBuffer.cpp */; }; + 46FDDB4B202ADDCE00931238 /* ccFPSImages.c in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDAEA202ADDCE00931238 /* ccFPSImages.c */; }; + 46FDDB4C202ADDCE00931238 /* ccFPSImages.c in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDAEA202ADDCE00931238 /* ccFPSImages.c */; }; + 46FDDB4D202ADDCE00931238 /* pvr.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDAEB202ADDCE00931238 /* pvr.h */; }; + 46FDDB4E202ADDCE00931238 /* pvr.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDAEB202ADDCE00931238 /* pvr.h */; }; + 46FDDB4F202ADDCE00931238 /* CCValue.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDAEC202ADDCE00931238 /* CCValue.h */; }; + 46FDDB50202ADDCE00931238 /* CCValue.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDAEC202ADDCE00931238 /* CCValue.h */; }; + 46FDDB53202ADDCE00931238 /* utlist.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDAEE202ADDCE00931238 /* utlist.h */; }; + 46FDDB54202ADDCE00931238 /* utlist.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDAEE202ADDCE00931238 /* utlist.h */; }; + 46FDDB5B202ADDCE00931238 /* CCData.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDAF2202ADDCE00931238 /* CCData.h */; }; + 46FDDB5C202ADDCE00931238 /* CCData.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDAF2202ADDCE00931238 /* CCData.h */; }; + 46FDDB5D202ADDCE00931238 /* ccMacros.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDAF3202ADDCE00931238 /* ccMacros.h */; }; + 46FDDB5E202ADDCE00931238 /* ccMacros.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDAF3202ADDCE00931238 /* ccMacros.h */; }; + 46FDDB65202ADDCE00931238 /* ccRandom.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDAF7202ADDCE00931238 /* ccRandom.cpp */; }; + 46FDDB66202ADDCE00931238 /* ccRandom.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDAF7202ADDCE00931238 /* ccRandom.cpp */; }; + 46FDDB6B202ADDCE00931238 /* base64.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDAFA202ADDCE00931238 /* base64.h */; }; + 46FDDB6C202ADDCE00931238 /* base64.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDAFA202ADDCE00931238 /* base64.h */; }; + 46FDDB6D202ADDCE00931238 /* etc1.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDAFB202ADDCE00931238 /* etc1.h */; }; + 46FDDB6E202ADDCE00931238 /* etc1.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDAFB202ADDCE00931238 /* etc1.h */; }; + 46FDDB6F202ADDCE00931238 /* ZipUtils.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDAFC202ADDCE00931238 /* ZipUtils.cpp */; }; + 46FDDB70202ADDCE00931238 /* ZipUtils.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDAFC202ADDCE00931238 /* ZipUtils.cpp */; }; + 46FDDB71202ADDCE00931238 /* base64.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDAFD202ADDCE00931238 /* base64.cpp */; }; + 46FDDB72202ADDCE00931238 /* base64.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDAFD202ADDCE00931238 /* base64.cpp */; }; + 46FDDB79202ADDCE00931238 /* CCGameController.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB01202ADDCE00931238 /* CCGameController.h */; }; + 46FDDB7A202ADDCE00931238 /* CCGameController.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB01202ADDCE00931238 /* CCGameController.h */; }; + 46FDDB7B202ADDCE00931238 /* CCRef.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDB02202ADDCE00931238 /* CCRef.cpp */; }; + 46FDDB7C202ADDCE00931238 /* CCRef.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDB02202ADDCE00931238 /* CCRef.cpp */; }; + 46FDDB81202ADDCE00931238 /* ccTypes.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB05202ADDCE00931238 /* ccTypes.h */; }; + 46FDDB82202ADDCE00931238 /* ccTypes.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB05202ADDCE00931238 /* ccTypes.h */; }; + 46FDDB83202ADDCE00931238 /* ccRandom.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB06202ADDCE00931238 /* ccRandom.h */; }; + 46FDDB84202ADDCE00931238 /* ccRandom.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB06202ADDCE00931238 /* ccRandom.h */; }; + 46FDDB89202ADDCE00931238 /* CCRef.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB09202ADDCE00931238 /* CCRef.h */; }; + 46FDDB8A202ADDCE00931238 /* CCRef.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB09202ADDCE00931238 /* CCRef.h */; }; + 46FDDB8B202ADDCE00931238 /* CCAutoreleasePool.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDB0A202ADDCE00931238 /* CCAutoreleasePool.cpp */; }; + 46FDDB8C202ADDCE00931238 /* CCAutoreleasePool.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDB0A202ADDCE00931238 /* CCAutoreleasePool.cpp */; }; + 46FDDB8D202ADDCE00931238 /* ccTypes.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDB0B202ADDCE00931238 /* ccTypes.cpp */; }; + 46FDDB8E202ADDCE00931238 /* ccTypes.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDB0B202ADDCE00931238 /* ccTypes.cpp */; }; + 46FDDB8F202ADDCE00931238 /* ccUtils.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDB0C202ADDCE00931238 /* ccUtils.cpp */; }; + 46FDDB90202ADDCE00931238 /* ccUtils.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDB0C202ADDCE00931238 /* ccUtils.cpp */; }; + 46FDDB93202ADDCE00931238 /* TGAlib.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDB0E202ADDCE00931238 /* TGAlib.cpp */; }; + 46FDDB94202ADDCE00931238 /* TGAlib.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDB0E202ADDCE00931238 /* TGAlib.cpp */; }; + 46FDDB99202ADDCE00931238 /* ccUTF8.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDB11202ADDCE00931238 /* ccUTF8.cpp */; }; + 46FDDB9A202ADDCE00931238 /* ccUTF8.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDB11202ADDCE00931238 /* ccUTF8.cpp */; }; + 46FDDB9B202ADDCE00931238 /* CCProfiling.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB12202ADDCE00931238 /* CCProfiling.h */; }; + 46FDDB9C202ADDCE00931238 /* CCProfiling.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB12202ADDCE00931238 /* CCProfiling.h */; }; + 46FDDB9D202ADDCE00931238 /* ObjectFactory.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB13202ADDCE00931238 /* ObjectFactory.h */; }; + 46FDDB9E202ADDCE00931238 /* ObjectFactory.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB13202ADDCE00931238 /* ObjectFactory.h */; }; + 46FDDB9F202ADDCE00931238 /* CCVector.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB14202ADDCE00931238 /* CCVector.h */; }; + 46FDDBA0202ADDCE00931238 /* CCVector.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB14202ADDCE00931238 /* CCVector.h */; }; + 46FDDBA1202ADDCE00931238 /* ObjectFactory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDB15202ADDCE00931238 /* ObjectFactory.cpp */; }; + 46FDDBA2202ADDCE00931238 /* ObjectFactory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDB15202ADDCE00931238 /* ObjectFactory.cpp */; }; + 46FDDBA3202ADDCE00931238 /* pvr.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDB16202ADDCE00931238 /* pvr.cpp */; }; + 46FDDBA4202ADDCE00931238 /* pvr.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDB16202ADDCE00931238 /* pvr.cpp */; }; + 46FDDBA9202ADDCE00931238 /* CCProfiling.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDB19202ADDCE00931238 /* CCProfiling.cpp */; }; + 46FDDBAA202ADDCE00931238 /* CCProfiling.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDB19202ADDCE00931238 /* CCProfiling.cpp */; }; + 46FDDBB3202ADDCE00931238 /* CCIMEDispatcher.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDB1E202ADDCE00931238 /* CCIMEDispatcher.cpp */; }; + 46FDDBB4202ADDCE00931238 /* CCIMEDispatcher.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDB1E202ADDCE00931238 /* CCIMEDispatcher.cpp */; }; + 46FDDBB5202ADDCE00931238 /* uthash.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB1F202ADDCE00931238 /* uthash.h */; }; + 46FDDBB6202ADDCE00931238 /* uthash.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB1F202ADDCE00931238 /* uthash.h */; }; + 46FDDBB7202ADDCE00931238 /* ccUtils.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB20202ADDCE00931238 /* ccUtils.h */; }; + 46FDDBB8202ADDCE00931238 /* ccUtils.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB20202ADDCE00931238 /* ccUtils.h */; }; + 46FDDBB9202ADDCE00931238 /* CCNS.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDB21202ADDCE00931238 /* CCNS.cpp */; }; + 46FDDBBA202ADDCE00931238 /* CCNS.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDB21202ADDCE00931238 /* CCNS.cpp */; }; + 46FDDBBB202ADDCE00931238 /* CCRefPtr.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB22202ADDCE00931238 /* CCRefPtr.h */; }; + 46FDDBBC202ADDCE00931238 /* CCRefPtr.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB22202ADDCE00931238 /* CCRefPtr.h */; }; + 46FDDBC3202ADDCE00931238 /* ccConfig.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB26202ADDCE00931238 /* ccConfig.h */; }; + 46FDDBC4202ADDCE00931238 /* ccConfig.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB26202ADDCE00931238 /* ccConfig.h */; }; + 46FDDBC9202ADDCE00931238 /* ccFPSImages.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB29202ADDCE00931238 /* ccFPSImages.h */; }; + 46FDDBCA202ADDCE00931238 /* ccFPSImages.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB29202ADDCE00931238 /* ccFPSImages.h */; }; + 46FDDBCB202ADDCE00931238 /* ZipUtils.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB2A202ADDCE00931238 /* ZipUtils.h */; }; + 46FDDBCC202ADDCE00931238 /* ZipUtils.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB2A202ADDCE00931238 /* ZipUtils.h */; }; + 46FDDBCF202ADDCE00931238 /* CCMap.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB2C202ADDCE00931238 /* CCMap.h */; }; + 46FDDBD0202ADDCE00931238 /* CCMap.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB2C202ADDCE00931238 /* CCMap.h */; }; + 46FDDBD1202ADDCE00931238 /* ccUTF8.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB2D202ADDCE00931238 /* ccUTF8.h */; }; + 46FDDBD2202ADDCE00931238 /* ccUTF8.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB2D202ADDCE00931238 /* ccUTF8.h */; }; + 46FDDBDD202ADDCE00931238 /* TGAlib.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB33202ADDCE00931238 /* TGAlib.h */; }; + 46FDDBDE202ADDCE00931238 /* TGAlib.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB33202ADDCE00931238 /* TGAlib.h */; }; + 46FDDBE3202ADDCE00931238 /* CCData.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDB36202ADDCE00931238 /* CCData.cpp */; }; + 46FDDBE4202ADDCE00931238 /* CCData.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDB36202ADDCE00931238 /* CCData.cpp */; }; + 46FDDBE5202ADDCE00931238 /* CCIMEDelegate.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB37202ADDCE00931238 /* CCIMEDelegate.h */; }; + 46FDDBE6202ADDCE00931238 /* CCIMEDelegate.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB37202ADDCE00931238 /* CCIMEDelegate.h */; }; + 46FDDBE7202ADDCE00931238 /* CCNS.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB38202ADDCE00931238 /* CCNS.h */; }; + 46FDDBE8202ADDCE00931238 /* CCNS.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB38202ADDCE00931238 /* CCNS.h */; }; + 46FDDBE9202ADDCE00931238 /* CCAutoreleasePool.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB39202ADDCE00931238 /* CCAutoreleasePool.h */; }; + 46FDDBEA202ADDCE00931238 /* CCAutoreleasePool.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB39202ADDCE00931238 /* CCAutoreleasePool.h */; }; + 46FDDBF9202ADDCE00931238 /* etc1.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDB41202ADDCE00931238 /* etc1.cpp */; }; + 46FDDBFA202ADDCE00931238 /* etc1.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDB41202ADDCE00931238 /* etc1.cpp */; }; + 46FDDBFB202ADDCE00931238 /* ccCArray.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDB42202ADDCE00931238 /* ccCArray.cpp */; }; + 46FDDBFC202ADDCE00931238 /* ccCArray.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDB42202ADDCE00931238 /* ccCArray.cpp */; }; + 46FDDBFD202ADDCE00931238 /* CCValue.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDB43202ADDCE00931238 /* CCValue.cpp */; }; + 46FDDBFE202ADDCE00931238 /* CCValue.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDB43202ADDCE00931238 /* CCValue.cpp */; }; + 46FDDBFF202ADDCE00931238 /* firePngData.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB44202ADDCE00931238 /* firePngData.h */; }; + 46FDDC00202ADDCE00931238 /* firePngData.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB44202ADDCE00931238 /* firePngData.h */; }; + 46FDDC01202ADDCE00931238 /* ccCArray.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB45202ADDCE00931238 /* ccCArray.h */; }; + 46FDDC02202ADDCE00931238 /* ccCArray.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB45202ADDCE00931238 /* ccCArray.h */; }; + 46FDDC0B202ADDCE00931238 /* CCIMEDispatcher.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB4A202ADDCE00931238 /* CCIMEDispatcher.h */; }; + 46FDDC0C202ADDCE00931238 /* CCIMEDispatcher.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDB4A202ADDCE00931238 /* CCIMEDispatcher.h */; }; + 46FDDC25202AEAC500931238 /* WebGLTexelConversions.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDC0E202AEAC500931238 /* WebGLTexelConversions.cpp */; }; + 46FDDC26202AEAC500931238 /* WebGLTexelConversions.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDC0E202AEAC500931238 /* WebGLTexelConversions.cpp */; }; + 46FDDC27202AEAC500931238 /* WebGLTypes.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDC0F202AEAC500931238 /* WebGLTypes.h */; }; + 46FDDC28202AEAC500931238 /* WebGLTypes.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDC0F202AEAC500931238 /* WebGLTypes.h */; }; + 46FDDC29202AEAC500931238 /* Casting.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDC11202AEAC500931238 /* Casting.h */; }; + 46FDDC2A202AEAC500931238 /* Casting.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDC11202AEAC500931238 /* Casting.h */; }; + 46FDDC2B202AEAC500931238 /* UniquePtr.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDC12202AEAC500931238 /* UniquePtr.h */; }; + 46FDDC2C202AEAC500931238 /* UniquePtr.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDC12202AEAC500931238 /* UniquePtr.h */; }; + 46FDDC2D202AEAC500931238 /* Compiler.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDC13202AEAC500931238 /* Compiler.h */; }; + 46FDDC2E202AEAC500931238 /* Compiler.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDC13202AEAC500931238 /* Compiler.h */; }; + 46FDDC2F202AEAC500931238 /* Assertions.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDC14202AEAC500931238 /* Assertions.h */; }; + 46FDDC30202AEAC500931238 /* Assertions.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDC14202AEAC500931238 /* Assertions.h */; }; + 46FDDC31202AEAC500931238 /* TypeTraits.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDC15202AEAC500931238 /* TypeTraits.h */; }; + 46FDDC32202AEAC500931238 /* TypeTraits.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDC15202AEAC500931238 /* TypeTraits.h */; }; + 46FDDC33202AEAC500931238 /* Types.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDC16202AEAC500931238 /* Types.h */; }; + 46FDDC34202AEAC500931238 /* Types.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDC16202AEAC500931238 /* Types.h */; }; + 46FDDC35202AEAC500931238 /* IntegerTypeTraits.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDC17202AEAC500931238 /* IntegerTypeTraits.h */; }; + 46FDDC36202AEAC500931238 /* IntegerTypeTraits.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDC17202AEAC500931238 /* IntegerTypeTraits.h */; }; + 46FDDC37202AEAC500931238 /* Assertions.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDC18202AEAC500931238 /* Assertions.cpp */; }; + 46FDDC38202AEAC500931238 /* Assertions.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDC18202AEAC500931238 /* Assertions.cpp */; }; + 46FDDC39202AEAC500931238 /* Attributes.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDC19202AEAC500931238 /* Attributes.h */; }; + 46FDDC3A202AEAC500931238 /* Attributes.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDC19202AEAC500931238 /* Attributes.h */; }; + 46FDDC3B202AEAC500931238 /* MacroArgs.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDC1A202AEAC500931238 /* MacroArgs.h */; }; + 46FDDC3C202AEAC500931238 /* MacroArgs.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDC1A202AEAC500931238 /* MacroArgs.h */; }; + 46FDDC3D202AEAC500931238 /* CheckedInt.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDC1B202AEAC500931238 /* CheckedInt.h */; }; + 46FDDC3E202AEAC500931238 /* CheckedInt.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDC1B202AEAC500931238 /* CheckedInt.h */; }; + 46FDDC3F202AEAC500931238 /* Likely.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDC1C202AEAC500931238 /* Likely.h */; }; + 46FDDC40202AEAC500931238 /* Likely.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDC1C202AEAC500931238 /* Likely.h */; }; + 46FDDC41202AEAC500931238 /* Atomics.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDC1D202AEAC500931238 /* Atomics.h */; }; + 46FDDC42202AEAC500931238 /* Atomics.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDC1D202AEAC500931238 /* Atomics.h */; }; + 46FDDC43202AEAC500931238 /* Pair.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDC1E202AEAC500931238 /* Pair.h */; }; + 46FDDC44202AEAC500931238 /* Pair.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDC1E202AEAC500931238 /* Pair.h */; }; + 46FDDC45202AEAC500931238 /* Move.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDC1F202AEAC500931238 /* Move.h */; }; + 46FDDC46202AEAC500931238 /* Move.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDC1F202AEAC500931238 /* Move.h */; }; + 46FDDC47202AEAC500931238 /* StaticAnalysisFunctions.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDC20202AEAC500931238 /* StaticAnalysisFunctions.h */; }; + 46FDDC48202AEAC500931238 /* StaticAnalysisFunctions.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDC20202AEAC500931238 /* StaticAnalysisFunctions.h */; }; + 46FDDC49202AEAC500931238 /* WebGLFormats.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDC21202AEAC500931238 /* WebGLFormats.h */; }; + 46FDDC4A202AEAC500931238 /* WebGLFormats.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDC21202AEAC500931238 /* WebGLFormats.h */; }; + 46FDDC4B202AEAC500931238 /* GLConsts.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDC22202AEAC500931238 /* GLConsts.h */; }; + 46FDDC4C202AEAC500931238 /* GLConsts.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDC22202AEAC500931238 /* GLConsts.h */; }; + 46FDDC4D202AEAC500931238 /* WebGLTexelConversions.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDC23202AEAC500931238 /* WebGLTexelConversions.h */; }; + 46FDDC4E202AEAC500931238 /* WebGLTexelConversions.h in Headers */ = {isa = PBXBuildFile; fileRef = 46FDDC23202AEAC500931238 /* WebGLTexelConversions.h */; }; + 46FDDC4F202AEAC500931238 /* WebGLFormats.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDC24202AEAC500931238 /* WebGLFormats.cpp */; }; + 46FDDC50202AEAC500931238 /* WebGLFormats.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46FDDC24202AEAC500931238 /* WebGLFormats.cpp */; }; 4DC57D211F7A58B5005B6546 /* xxtea.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4DC57D1F1F7A58B5005B6546 /* xxtea.cpp */; }; 4DC57D331F7B840E005B6546 /* xxtea.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4DC57D1F1F7A58B5005B6546 /* xxtea.cpp */; }; 4DED47D21DFFA4AF0070C5C4 /* Box2D.h in Headers */ = {isa = PBXBuildFile; fileRef = 4DED476B1DFFA4AF0070C5C4 /* Box2D.h */; }; @@ -681,52 +554,10 @@ 4DED48891DFFA4AF0070C5C4 /* b2Rope.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4DED47CF1DFFA4AF0070C5C4 /* b2Rope.cpp */; }; 4DED488A1DFFA4AF0070C5C4 /* b2Rope.h in Headers */ = {isa = PBXBuildFile; fileRef = 4DED47D01DFFA4AF0070C5C4 /* b2Rope.h */; }; 4DED488B1DFFA4AF0070C5C4 /* b2Rope.h in Headers */ = {isa = PBXBuildFile; fileRef = 4DED47D01DFFA4AF0070C5C4 /* b2Rope.h */; }; - 4DFA4C171CBCE34100E3B736 /* CCScale9Sprite.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4DFA4C151CBCE34100E3B736 /* CCScale9Sprite.cpp */; }; - 4DFA4C181CBCE34100E3B736 /* CCScale9Sprite.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4DFA4C151CBCE34100E3B736 /* CCScale9Sprite.cpp */; }; - 4DFA4C191CBCE34100E3B736 /* CCScale9Sprite.h in Headers */ = {isa = PBXBuildFile; fileRef = 4DFA4C161CBCE34100E3B736 /* CCScale9Sprite.h */; }; - 4DFA4C1A1CBCE34100E3B736 /* CCScale9Sprite.h in Headers */ = {isa = PBXBuildFile; fileRef = 4DFA4C161CBCE34100E3B736 /* CCScale9Sprite.h */; }; 5027253A190BF1B900AAF4ED /* cocos2d.h in Headers */ = {isa = PBXBuildFile; fileRef = 50272538190BF1B900AAF4ED /* cocos2d.h */; }; 5027253B190BF1B900AAF4ED /* cocos2d.h in Headers */ = {isa = PBXBuildFile; fileRef = 50272538190BF1B900AAF4ED /* cocos2d.h */; }; 5027253C190BF1B900AAF4ED /* cocos2d.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50272539190BF1B900AAF4ED /* cocos2d.cpp */; }; 5027253D190BF1B900AAF4ED /* cocos2d.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50272539190BF1B900AAF4ED /* cocos2d.cpp */; }; - 5034CA21191D591100CE6051 /* ccShader_PositionTextureColorAlphaTest.frag in Headers */ = {isa = PBXBuildFile; fileRef = 5034C9FB191D591000CE6051 /* ccShader_PositionTextureColorAlphaTest.frag */; }; - 5034CA22191D591100CE6051 /* ccShader_PositionTextureColorAlphaTest.frag in Headers */ = {isa = PBXBuildFile; fileRef = 5034C9FB191D591000CE6051 /* ccShader_PositionTextureColorAlphaTest.frag */; }; - 5034CA2B191D591100CE6051 /* ccShader_PositionTextureA8Color.vert in Headers */ = {isa = PBXBuildFile; fileRef = 5034CA00191D591000CE6051 /* ccShader_PositionTextureA8Color.vert */; }; - 5034CA2C191D591100CE6051 /* ccShader_PositionTextureA8Color.vert in Headers */ = {isa = PBXBuildFile; fileRef = 5034CA00191D591000CE6051 /* ccShader_PositionTextureA8Color.vert */; }; - 5034CA2D191D591100CE6051 /* ccShader_PositionTextureA8Color.frag in Headers */ = {isa = PBXBuildFile; fileRef = 5034CA01191D591000CE6051 /* ccShader_PositionTextureA8Color.frag */; }; - 5034CA2E191D591100CE6051 /* ccShader_PositionTextureA8Color.frag in Headers */ = {isa = PBXBuildFile; fileRef = 5034CA01191D591000CE6051 /* ccShader_PositionTextureA8Color.frag */; }; - 5034CA2F191D591100CE6051 /* ccShader_PositionTexture.vert in Headers */ = {isa = PBXBuildFile; fileRef = 5034CA02191D591000CE6051 /* ccShader_PositionTexture.vert */; }; - 5034CA30191D591100CE6051 /* ccShader_PositionTexture.vert in Headers */ = {isa = PBXBuildFile; fileRef = 5034CA02191D591000CE6051 /* ccShader_PositionTexture.vert */; }; - 5034CA31191D591100CE6051 /* ccShader_PositionTexture_uColor.vert in Headers */ = {isa = PBXBuildFile; fileRef = 5034CA03191D591000CE6051 /* ccShader_PositionTexture_uColor.vert */; }; - 5034CA33191D591100CE6051 /* ccShader_PositionTexture_uColor.frag in Headers */ = {isa = PBXBuildFile; fileRef = 5034CA04191D591000CE6051 /* ccShader_PositionTexture_uColor.frag */; }; - 5034CA34191D591100CE6051 /* ccShader_PositionTexture_uColor.frag in Headers */ = {isa = PBXBuildFile; fileRef = 5034CA04191D591000CE6051 /* ccShader_PositionTexture_uColor.frag */; }; - 5034CA35191D591100CE6051 /* ccShader_PositionTexture.frag in Headers */ = {isa = PBXBuildFile; fileRef = 5034CA05191D591000CE6051 /* ccShader_PositionTexture.frag */; }; - 5034CA36191D591100CE6051 /* ccShader_PositionTexture.frag in Headers */ = {isa = PBXBuildFile; fileRef = 5034CA05191D591000CE6051 /* ccShader_PositionTexture.frag */; }; - 5034CA37191D591100CE6051 /* ccShader_PositionColorLengthTexture.vert in Headers */ = {isa = PBXBuildFile; fileRef = 5034CA06191D591000CE6051 /* ccShader_PositionColorLengthTexture.vert */; }; - 5034CA38191D591100CE6051 /* ccShader_PositionColorLengthTexture.vert in Headers */ = {isa = PBXBuildFile; fileRef = 5034CA06191D591000CE6051 /* ccShader_PositionColorLengthTexture.vert */; }; - 5034CA39191D591100CE6051 /* ccShader_PositionColorLengthTexture.frag in Headers */ = {isa = PBXBuildFile; fileRef = 5034CA07191D591000CE6051 /* ccShader_PositionColorLengthTexture.frag */; }; - 5034CA3A191D591100CE6051 /* ccShader_PositionColorLengthTexture.frag in Headers */ = {isa = PBXBuildFile; fileRef = 5034CA07191D591000CE6051 /* ccShader_PositionColorLengthTexture.frag */; }; - 5034CA3B191D591100CE6051 /* ccShader_PositionColor.vert in Headers */ = {isa = PBXBuildFile; fileRef = 5034CA08191D591000CE6051 /* ccShader_PositionColor.vert */; }; - 5034CA3C191D591100CE6051 /* ccShader_PositionColor.vert in Headers */ = {isa = PBXBuildFile; fileRef = 5034CA08191D591000CE6051 /* ccShader_PositionColor.vert */; }; - 5034CA3D191D591100CE6051 /* ccShader_PositionColor.frag in Headers */ = {isa = PBXBuildFile; fileRef = 5034CA09191D591000CE6051 /* ccShader_PositionColor.frag */; }; - 5034CA3E191D591100CE6051 /* ccShader_PositionColor.frag in Headers */ = {isa = PBXBuildFile; fileRef = 5034CA09191D591000CE6051 /* ccShader_PositionColor.frag */; }; - 5034CA3F191D591100CE6051 /* ccShader_Position_uColor.vert in Headers */ = {isa = PBXBuildFile; fileRef = 5034CA0A191D591000CE6051 /* ccShader_Position_uColor.vert */; }; - 5034CA40191D591100CE6051 /* ccShader_Position_uColor.vert in Headers */ = {isa = PBXBuildFile; fileRef = 5034CA0A191D591000CE6051 /* ccShader_Position_uColor.vert */; }; - 5034CA41191D591100CE6051 /* ccShader_Position_uColor.frag in Headers */ = {isa = PBXBuildFile; fileRef = 5034CA0B191D591000CE6051 /* ccShader_Position_uColor.frag */; }; - 5034CA42191D591100CE6051 /* ccShader_Position_uColor.frag in Headers */ = {isa = PBXBuildFile; fileRef = 5034CA0B191D591000CE6051 /* ccShader_Position_uColor.frag */; }; - 5034CA43191D591100CE6051 /* ccShader_Label.vert in Headers */ = {isa = PBXBuildFile; fileRef = 5034CA0C191D591000CE6051 /* ccShader_Label.vert */; }; - 5034CA44191D591100CE6051 /* ccShader_Label.vert in Headers */ = {isa = PBXBuildFile; fileRef = 5034CA0C191D591000CE6051 /* ccShader_Label.vert */; }; - 5034CA45191D591100CE6051 /* ccShader_Label_outline.frag in Headers */ = {isa = PBXBuildFile; fileRef = 5034CA0D191D591000CE6051 /* ccShader_Label_outline.frag */; }; - 5034CA46191D591100CE6051 /* ccShader_Label_outline.frag in Headers */ = {isa = PBXBuildFile; fileRef = 5034CA0D191D591000CE6051 /* ccShader_Label_outline.frag */; }; - 5034CA47191D591100CE6051 /* ccShader_Label_normal.frag in Headers */ = {isa = PBXBuildFile; fileRef = 5034CA0E191D591000CE6051 /* ccShader_Label_normal.frag */; }; - 5034CA48191D591100CE6051 /* ccShader_Label_normal.frag in Headers */ = {isa = PBXBuildFile; fileRef = 5034CA0E191D591000CE6051 /* ccShader_Label_normal.frag */; }; - 5034CA49191D591100CE6051 /* ccShader_Label_df.frag in Headers */ = {isa = PBXBuildFile; fileRef = 5034CA0F191D591000CE6051 /* ccShader_Label_df.frag */; }; - 5034CA4A191D591100CE6051 /* ccShader_Label_df.frag in Headers */ = {isa = PBXBuildFile; fileRef = 5034CA0F191D591000CE6051 /* ccShader_Label_df.frag */; }; - 5034CA4B191D591100CE6051 /* ccShader_Label_df_glow.frag in Headers */ = {isa = PBXBuildFile; fileRef = 5034CA10191D591000CE6051 /* ccShader_Label_df_glow.frag */; }; - 5034CA4C191D591100CE6051 /* ccShader_Label_df_glow.frag in Headers */ = {isa = PBXBuildFile; fileRef = 5034CA10191D591000CE6051 /* ccShader_Label_df_glow.frag */; }; - 503DD8E01926736A00CD74DD /* CCApplication-ios.h in Headers */ = {isa = PBXBuildFile; fileRef = 503DD8CE1926736A00CD74DD /* CCApplication-ios.h */; }; - 503DD8E11926736A00CD74DD /* CCApplication-ios.mm in Sources */ = {isa = PBXBuildFile; fileRef = 503DD8CF1926736A00CD74DD /* CCApplication-ios.mm */; }; - 503DD8E21926736A00CD74DD /* CCCommon-ios.mm in Sources */ = {isa = PBXBuildFile; fileRef = 503DD8D01926736A00CD74DD /* CCCommon-ios.mm */; }; 503DD8E31926736A00CD74DD /* CCDevice-ios.mm in Sources */ = {isa = PBXBuildFile; fileRef = 503DD8D11926736A00CD74DD /* CCDevice-ios.mm */; }; 503DD8E41926736A00CD74DD /* CCDirectorCaller-ios.h in Headers */ = {isa = PBXBuildFile; fileRef = 503DD8D21926736A00CD74DD /* CCDirectorCaller-ios.h */; }; 503DD8E51926736A00CD74DD /* CCDirectorCaller-ios.mm in Sources */ = {isa = PBXBuildFile; fileRef = 503DD8D31926736A00CD74DD /* CCDirectorCaller-ios.mm */; }; @@ -736,32 +567,19 @@ 503DD8E91926736A00CD74DD /* CCES2Renderer-ios.m in Sources */ = {isa = PBXBuildFile; fileRef = 503DD8D71926736A00CD74DD /* CCES2Renderer-ios.m */; }; 503DD8EA1926736A00CD74DD /* CCESRenderer-ios.h in Headers */ = {isa = PBXBuildFile; fileRef = 503DD8D81926736A00CD74DD /* CCESRenderer-ios.h */; }; 503DD8EB1926736A00CD74DD /* CCGL-ios.h in Headers */ = {isa = PBXBuildFile; fileRef = 503DD8D91926736A00CD74DD /* CCGL-ios.h */; }; - 503DD8EC1926736A00CD74DD /* CCGLViewImpl-ios.h in Headers */ = {isa = PBXBuildFile; fileRef = 503DD8DA1926736A00CD74DD /* CCGLViewImpl-ios.h */; }; - 503DD8ED1926736A00CD74DD /* CCGLViewImpl-ios.mm in Sources */ = {isa = PBXBuildFile; fileRef = 503DD8DB1926736A00CD74DD /* CCGLViewImpl-ios.mm */; }; 503DD8EE1926736A00CD74DD /* CCImage-ios.mm in Sources */ = {isa = PBXBuildFile; fileRef = 503DD8DC1926736A00CD74DD /* CCImage-ios.mm */; }; 503DD8EF1926736A00CD74DD /* CCPlatformDefine-ios.h in Headers */ = {isa = PBXBuildFile; fileRef = 503DD8DD1926736A00CD74DD /* CCPlatformDefine-ios.h */; }; 503DD8F01926736A00CD74DD /* CCStdC-ios.h in Headers */ = {isa = PBXBuildFile; fileRef = 503DD8DE1926736A00CD74DD /* CCStdC-ios.h */; }; 503DD8F11926736A00CD74DD /* OpenGL_Internal-ios.h in Headers */ = {isa = PBXBuildFile; fileRef = 503DD8DF1926736A00CD74DD /* OpenGL_Internal-ios.h */; }; - 503DD8F51926B0DB00CD74DD /* CCIMEDelegate.h in Headers */ = {isa = PBXBuildFile; fileRef = 503DD8F21926B0DB00CD74DD /* CCIMEDelegate.h */; }; - 503DD8F61926B0DB00CD74DD /* CCIMEDelegate.h in Headers */ = {isa = PBXBuildFile; fileRef = 503DD8F21926B0DB00CD74DD /* CCIMEDelegate.h */; }; - 503DD8F71926B0DB00CD74DD /* CCIMEDispatcher.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 503DD8F31926B0DB00CD74DD /* CCIMEDispatcher.cpp */; }; - 503DD8F81926B0DB00CD74DD /* CCIMEDispatcher.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 503DD8F31926B0DB00CD74DD /* CCIMEDispatcher.cpp */; }; - 503DD8F91926B0DB00CD74DD /* CCIMEDispatcher.h in Headers */ = {isa = PBXBuildFile; fileRef = 503DD8F41926B0DB00CD74DD /* CCIMEDispatcher.h */; }; - 503DD8FA1926B0DB00CD74DD /* CCIMEDispatcher.h in Headers */ = {isa = PBXBuildFile; fileRef = 503DD8F41926B0DB00CD74DD /* CCIMEDispatcher.h */; }; 50643BD419BFAECF00EF68ED /* CCGL.h in Headers */ = {isa = PBXBuildFile; fileRef = 50643BD319BFAECF00EF68ED /* CCGL.h */; }; 50643BD519BFAECF00EF68ED /* CCGL.h in Headers */ = {isa = PBXBuildFile; fileRef = 50643BD319BFAECF00EF68ED /* CCGL.h */; }; 50643BD619BFAEDA00EF68ED /* CCPlatformDefine.h in Headers */ = {isa = PBXBuildFile; fileRef = 5091A7A219BFABA800AC8789 /* CCPlatformDefine.h */; }; - 50643BD919BFAF4400EF68ED /* CCApplication.h in Headers */ = {isa = PBXBuildFile; fileRef = 50643BD719BFAF4400EF68ED /* CCApplication.h */; }; - 50643BDA19BFAF4400EF68ED /* CCApplication.h in Headers */ = {isa = PBXBuildFile; fileRef = 50643BD719BFAF4400EF68ED /* CCApplication.h */; }; 50643BDB19BFAF4400EF68ED /* CCStdC.h in Headers */ = {isa = PBXBuildFile; fileRef = 50643BD819BFAF4400EF68ED /* CCStdC.h */; }; 50643BDC19BFAF4400EF68ED /* CCStdC.h in Headers */ = {isa = PBXBuildFile; fileRef = 50643BD819BFAF4400EF68ED /* CCStdC.h */; }; 50643BE219BFCF1800EF68ED /* CCPlatformConfig.h in Headers */ = {isa = PBXBuildFile; fileRef = 50643BE019BFCF1800EF68ED /* CCPlatformConfig.h */; }; 50643BE319BFCF1800EF68ED /* CCPlatformConfig.h in Headers */ = {isa = PBXBuildFile; fileRef = 50643BE019BFCF1800EF68ED /* CCPlatformConfig.h */; }; 50643BE419BFCF1800EF68ED /* CCPlatformMacros.h in Headers */ = {isa = PBXBuildFile; fileRef = 50643BE119BFCF1800EF68ED /* CCPlatformMacros.h */; }; 50643BE519BFCF1800EF68ED /* CCPlatformMacros.h in Headers */ = {isa = PBXBuildFile; fileRef = 50643BE119BFCF1800EF68ED /* CCPlatformMacros.h */; }; - 50693C5E1B6BF2AE005C5820 /* CCDownloader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50693C5C1B6BF2AE005C5820 /* CCDownloader.cpp */; }; - 50693C601B6BF2AE005C5820 /* CCDownloader.h in Headers */ = {isa = PBXBuildFile; fileRef = 50693C5D1B6BF2AE005C5820 /* CCDownloader.h */; }; - 50693C611B6BF2AE005C5820 /* CCDownloader.h in Headers */ = {isa = PBXBuildFile; fileRef = 50693C5D1B6BF2AE005C5820 /* CCDownloader.h */; }; 5091A7A319BFABA800AC8789 /* CCPlatformDefine.h in Headers */ = {isa = PBXBuildFile; fileRef = 5091A7A219BFABA800AC8789 /* CCPlatformDefine.h */; }; 50ABBD381925AB0000A911A9 /* CCAffineTransform.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBD1B1925AB0000A911A9 /* CCAffineTransform.cpp */; }; 50ABBD391925AB0000A911A9 /* CCAffineTransform.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBD1B1925AB0000A911A9 /* CCAffineTransform.cpp */; }; @@ -807,238 +625,6 @@ 50ABBD611925AB0000A911A9 /* Vec4.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBD351925AB0000A911A9 /* Vec4.cpp */; }; 50ABBD621925AB0000A911A9 /* Vec4.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBD361925AB0000A911A9 /* Vec4.h */; }; 50ABBD631925AB0000A911A9 /* Vec4.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBD361925AB0000A911A9 /* Vec4.h */; }; - 50ABBD831925AB4100A911A9 /* CCBatchCommand.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBD641925AB4100A911A9 /* CCBatchCommand.cpp */; }; - 50ABBD841925AB4100A911A9 /* CCBatchCommand.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBD641925AB4100A911A9 /* CCBatchCommand.cpp */; }; - 50ABBD851925AB4100A911A9 /* CCBatchCommand.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBD651925AB4100A911A9 /* CCBatchCommand.h */; }; - 50ABBD861925AB4100A911A9 /* CCBatchCommand.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBD651925AB4100A911A9 /* CCBatchCommand.h */; }; - 50ABBD871925AB4100A911A9 /* CCCustomCommand.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBD661925AB4100A911A9 /* CCCustomCommand.cpp */; }; - 50ABBD881925AB4100A911A9 /* CCCustomCommand.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBD661925AB4100A911A9 /* CCCustomCommand.cpp */; }; - 50ABBD891925AB4100A911A9 /* CCCustomCommand.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBD671925AB4100A911A9 /* CCCustomCommand.h */; }; - 50ABBD8A1925AB4100A911A9 /* CCCustomCommand.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBD671925AB4100A911A9 /* CCCustomCommand.h */; }; - 50ABBD8B1925AB4100A911A9 /* CCGLProgram.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBD681925AB4100A911A9 /* CCGLProgram.cpp */; }; - 50ABBD8C1925AB4100A911A9 /* CCGLProgram.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBD681925AB4100A911A9 /* CCGLProgram.cpp */; }; - 50ABBD8D1925AB4100A911A9 /* CCGLProgram.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBD691925AB4100A911A9 /* CCGLProgram.h */; }; - 50ABBD8E1925AB4100A911A9 /* CCGLProgram.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBD691925AB4100A911A9 /* CCGLProgram.h */; }; - 50ABBD8F1925AB4100A911A9 /* CCGLProgramCache.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBD6A1925AB4100A911A9 /* CCGLProgramCache.cpp */; }; - 50ABBD901925AB4100A911A9 /* CCGLProgramCache.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBD6A1925AB4100A911A9 /* CCGLProgramCache.cpp */; }; - 50ABBD911925AB4100A911A9 /* CCGLProgramCache.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBD6B1925AB4100A911A9 /* CCGLProgramCache.h */; }; - 50ABBD921925AB4100A911A9 /* CCGLProgramCache.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBD6B1925AB4100A911A9 /* CCGLProgramCache.h */; }; - 50ABBD931925AB4100A911A9 /* CCGLProgramState.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBD6C1925AB4100A911A9 /* CCGLProgramState.cpp */; }; - 50ABBD941925AB4100A911A9 /* CCGLProgramState.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBD6C1925AB4100A911A9 /* CCGLProgramState.cpp */; }; - 50ABBD951925AB4100A911A9 /* CCGLProgramState.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBD6D1925AB4100A911A9 /* CCGLProgramState.h */; }; - 50ABBD961925AB4100A911A9 /* CCGLProgramState.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBD6D1925AB4100A911A9 /* CCGLProgramState.h */; }; - 50ABBD971925AB4100A911A9 /* CCGLProgramStateCache.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBD6E1925AB4100A911A9 /* CCGLProgramStateCache.cpp */; }; - 50ABBD981925AB4100A911A9 /* CCGLProgramStateCache.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBD6E1925AB4100A911A9 /* CCGLProgramStateCache.cpp */; }; - 50ABBD991925AB4100A911A9 /* CCGLProgramStateCache.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBD6F1925AB4100A911A9 /* CCGLProgramStateCache.h */; }; - 50ABBD9A1925AB4100A911A9 /* CCGLProgramStateCache.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBD6F1925AB4100A911A9 /* CCGLProgramStateCache.h */; }; - 50ABBD9B1925AB4100A911A9 /* ccGLStateCache.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBD701925AB4100A911A9 /* ccGLStateCache.cpp */; }; - 50ABBD9C1925AB4100A911A9 /* ccGLStateCache.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBD701925AB4100A911A9 /* ccGLStateCache.cpp */; }; - 50ABBD9D1925AB4100A911A9 /* ccGLStateCache.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBD711925AB4100A911A9 /* ccGLStateCache.h */; }; - 50ABBD9E1925AB4100A911A9 /* ccGLStateCache.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBD711925AB4100A911A9 /* ccGLStateCache.h */; }; - 50ABBD9F1925AB4100A911A9 /* CCGroupCommand.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBD721925AB4100A911A9 /* CCGroupCommand.cpp */; }; - 50ABBDA01925AB4100A911A9 /* CCGroupCommand.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBD721925AB4100A911A9 /* CCGroupCommand.cpp */; }; - 50ABBDA11925AB4100A911A9 /* CCGroupCommand.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBD731925AB4100A911A9 /* CCGroupCommand.h */; }; - 50ABBDA21925AB4100A911A9 /* CCGroupCommand.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBD731925AB4100A911A9 /* CCGroupCommand.h */; }; - 50ABBDA31925AB4100A911A9 /* CCQuadCommand.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBD741925AB4100A911A9 /* CCQuadCommand.cpp */; }; - 50ABBDA41925AB4100A911A9 /* CCQuadCommand.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBD741925AB4100A911A9 /* CCQuadCommand.cpp */; }; - 50ABBDA51925AB4100A911A9 /* CCQuadCommand.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBD751925AB4100A911A9 /* CCQuadCommand.h */; }; - 50ABBDA61925AB4100A911A9 /* CCQuadCommand.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBD751925AB4100A911A9 /* CCQuadCommand.h */; }; - 50ABBDA71925AB4100A911A9 /* CCRenderCommand.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBD761925AB4100A911A9 /* CCRenderCommand.cpp */; }; - 50ABBDA81925AB4100A911A9 /* CCRenderCommand.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBD761925AB4100A911A9 /* CCRenderCommand.cpp */; }; - 50ABBDA91925AB4100A911A9 /* CCRenderCommand.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBD771925AB4100A911A9 /* CCRenderCommand.h */; }; - 50ABBDAA1925AB4100A911A9 /* CCRenderCommand.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBD771925AB4100A911A9 /* CCRenderCommand.h */; }; - 50ABBDAB1925AB4100A911A9 /* CCRenderCommandPool.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBD781925AB4100A911A9 /* CCRenderCommandPool.h */; }; - 50ABBDAC1925AB4100A911A9 /* CCRenderCommandPool.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBD781925AB4100A911A9 /* CCRenderCommandPool.h */; }; - 50ABBDAD1925AB4100A911A9 /* CCRenderer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBD791925AB4100A911A9 /* CCRenderer.cpp */; }; - 50ABBDAE1925AB4100A911A9 /* CCRenderer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBD791925AB4100A911A9 /* CCRenderer.cpp */; }; - 50ABBDAF1925AB4100A911A9 /* CCRenderer.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBD7A1925AB4100A911A9 /* CCRenderer.h */; }; - 50ABBDB01925AB4100A911A9 /* CCRenderer.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBD7A1925AB4100A911A9 /* CCRenderer.h */; }; - 50ABBDB11925AB4100A911A9 /* ccShaders.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBD7B1925AB4100A911A9 /* ccShaders.cpp */; }; - 50ABBDB21925AB4100A911A9 /* ccShaders.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBD7B1925AB4100A911A9 /* ccShaders.cpp */; }; - 50ABBDB31925AB4100A911A9 /* ccShaders.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBD7C1925AB4100A911A9 /* ccShaders.h */; }; - 50ABBDB41925AB4100A911A9 /* ccShaders.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBD7C1925AB4100A911A9 /* ccShaders.h */; }; - 50ABBDB51925AB4100A911A9 /* CCTexture2D.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBD7D1925AB4100A911A9 /* CCTexture2D.cpp */; }; - 50ABBDB61925AB4100A911A9 /* CCTexture2D.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBD7D1925AB4100A911A9 /* CCTexture2D.cpp */; }; - 50ABBDB71925AB4100A911A9 /* CCTexture2D.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBD7E1925AB4100A911A9 /* CCTexture2D.h */; }; - 50ABBDB81925AB4100A911A9 /* CCTexture2D.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBD7E1925AB4100A911A9 /* CCTexture2D.h */; }; - 50ABBDB91925AB4100A911A9 /* CCTextureAtlas.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBD7F1925AB4100A911A9 /* CCTextureAtlas.cpp */; }; - 50ABBDBA1925AB4100A911A9 /* CCTextureAtlas.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBD7F1925AB4100A911A9 /* CCTextureAtlas.cpp */; }; - 50ABBDBB1925AB4100A911A9 /* CCTextureAtlas.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBD801925AB4100A911A9 /* CCTextureAtlas.h */; }; - 50ABBDBC1925AB4100A911A9 /* CCTextureAtlas.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBD801925AB4100A911A9 /* CCTextureAtlas.h */; }; - 50ABBDBD1925AB4100A911A9 /* CCTextureCache.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBD811925AB4100A911A9 /* CCTextureCache.cpp */; }; - 50ABBDBE1925AB4100A911A9 /* CCTextureCache.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBD811925AB4100A911A9 /* CCTextureCache.cpp */; }; - 50ABBDBF1925AB4100A911A9 /* CCTextureCache.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBD821925AB4100A911A9 /* CCTextureCache.h */; }; - 50ABBDC01925AB4100A911A9 /* CCTextureCache.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBD821925AB4100A911A9 /* CCTextureCache.h */; }; - 50ABBE231925AB6F00A911A9 /* base64.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDC31925AB6E00A911A9 /* base64.cpp */; }; - 50ABBE241925AB6F00A911A9 /* base64.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDC31925AB6E00A911A9 /* base64.cpp */; }; - 50ABBE251925AB6F00A911A9 /* base64.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDC41925AB6E00A911A9 /* base64.h */; }; - 50ABBE261925AB6F00A911A9 /* base64.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDC41925AB6E00A911A9 /* base64.h */; }; - 50ABBE271925AB6F00A911A9 /* CCAutoreleasePool.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDC51925AB6E00A911A9 /* CCAutoreleasePool.cpp */; }; - 50ABBE281925AB6F00A911A9 /* CCAutoreleasePool.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDC51925AB6E00A911A9 /* CCAutoreleasePool.cpp */; }; - 50ABBE291925AB6F00A911A9 /* CCAutoreleasePool.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDC61925AB6E00A911A9 /* CCAutoreleasePool.h */; }; - 50ABBE2A1925AB6F00A911A9 /* CCAutoreleasePool.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDC61925AB6E00A911A9 /* CCAutoreleasePool.h */; }; - 50ABBE2B1925AB6F00A911A9 /* ccCArray.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDC71925AB6E00A911A9 /* ccCArray.cpp */; }; - 50ABBE2C1925AB6F00A911A9 /* ccCArray.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDC71925AB6E00A911A9 /* ccCArray.cpp */; }; - 50ABBE2D1925AB6F00A911A9 /* ccCArray.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDC81925AB6E00A911A9 /* ccCArray.h */; }; - 50ABBE2E1925AB6F00A911A9 /* ccCArray.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDC81925AB6E00A911A9 /* ccCArray.h */; }; - 50ABBE2F1925AB6F00A911A9 /* ccConfig.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDC91925AB6E00A911A9 /* ccConfig.h */; }; - 50ABBE301925AB6F00A911A9 /* ccConfig.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDC91925AB6E00A911A9 /* ccConfig.h */; }; - 50ABBE311925AB6F00A911A9 /* CCConfiguration.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDCA1925AB6E00A911A9 /* CCConfiguration.cpp */; }; - 50ABBE321925AB6F00A911A9 /* CCConfiguration.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDCA1925AB6E00A911A9 /* CCConfiguration.cpp */; }; - 50ABBE331925AB6F00A911A9 /* CCConfiguration.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDCB1925AB6E00A911A9 /* CCConfiguration.h */; }; - 50ABBE341925AB6F00A911A9 /* CCConfiguration.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDCB1925AB6E00A911A9 /* CCConfiguration.h */; }; - 50ABBE351925AB6F00A911A9 /* CCConsole.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDCC1925AB6E00A911A9 /* CCConsole.cpp */; }; - 50ABBE361925AB6F00A911A9 /* CCConsole.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDCC1925AB6E00A911A9 /* CCConsole.cpp */; }; - 50ABBE371925AB6F00A911A9 /* CCConsole.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDCD1925AB6E00A911A9 /* CCConsole.h */; }; - 50ABBE381925AB6F00A911A9 /* CCConsole.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDCD1925AB6E00A911A9 /* CCConsole.h */; }; - 50ABBE391925AB6F00A911A9 /* CCData.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDCE1925AB6E00A911A9 /* CCData.cpp */; }; - 50ABBE3A1925AB6F00A911A9 /* CCData.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDCE1925AB6E00A911A9 /* CCData.cpp */; }; - 50ABBE3B1925AB6F00A911A9 /* CCData.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDCF1925AB6E00A911A9 /* CCData.h */; }; - 50ABBE3C1925AB6F00A911A9 /* CCData.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDCF1925AB6E00A911A9 /* CCData.h */; }; - 50ABBE411925AB6F00A911A9 /* CCDirector.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDD21925AB6E00A911A9 /* CCDirector.cpp */; }; - 50ABBE421925AB6F00A911A9 /* CCDirector.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDD21925AB6E00A911A9 /* CCDirector.cpp */; }; - 50ABBE431925AB6F00A911A9 /* CCDirector.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDD31925AB6E00A911A9 /* CCDirector.h */; }; - 50ABBE441925AB6F00A911A9 /* CCDirector.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDD31925AB6E00A911A9 /* CCDirector.h */; }; - 50ABBE451925AB6F00A911A9 /* CCEvent.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDD41925AB6E00A911A9 /* CCEvent.cpp */; }; - 50ABBE461925AB6F00A911A9 /* CCEvent.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDD41925AB6E00A911A9 /* CCEvent.cpp */; }; - 50ABBE471925AB6F00A911A9 /* CCEvent.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDD51925AB6E00A911A9 /* CCEvent.h */; }; - 50ABBE481925AB6F00A911A9 /* CCEvent.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDD51925AB6E00A911A9 /* CCEvent.h */; }; - 50ABBE491925AB6F00A911A9 /* CCEventAcceleration.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDD61925AB6E00A911A9 /* CCEventAcceleration.cpp */; }; - 50ABBE4A1925AB6F00A911A9 /* CCEventAcceleration.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDD61925AB6E00A911A9 /* CCEventAcceleration.cpp */; }; - 50ABBE4B1925AB6F00A911A9 /* CCEventAcceleration.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDD71925AB6E00A911A9 /* CCEventAcceleration.h */; }; - 50ABBE4C1925AB6F00A911A9 /* CCEventAcceleration.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDD71925AB6E00A911A9 /* CCEventAcceleration.h */; }; - 50ABBE4D1925AB6F00A911A9 /* CCEventCustom.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDD81925AB6E00A911A9 /* CCEventCustom.cpp */; }; - 50ABBE4E1925AB6F00A911A9 /* CCEventCustom.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDD81925AB6E00A911A9 /* CCEventCustom.cpp */; }; - 50ABBE4F1925AB6F00A911A9 /* CCEventCustom.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDD91925AB6E00A911A9 /* CCEventCustom.h */; }; - 50ABBE501925AB6F00A911A9 /* CCEventCustom.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDD91925AB6E00A911A9 /* CCEventCustom.h */; }; - 50ABBE511925AB6F00A911A9 /* CCEventDispatcher.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDDA1925AB6E00A911A9 /* CCEventDispatcher.cpp */; }; - 50ABBE521925AB6F00A911A9 /* CCEventDispatcher.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDDA1925AB6E00A911A9 /* CCEventDispatcher.cpp */; }; - 50ABBE531925AB6F00A911A9 /* CCEventDispatcher.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDDB1925AB6E00A911A9 /* CCEventDispatcher.h */; }; - 50ABBE541925AB6F00A911A9 /* CCEventDispatcher.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDDB1925AB6E00A911A9 /* CCEventDispatcher.h */; }; - 50ABBE551925AB6F00A911A9 /* CCEventFocus.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDDC1925AB6E00A911A9 /* CCEventFocus.cpp */; }; - 50ABBE561925AB6F00A911A9 /* CCEventFocus.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDDC1925AB6E00A911A9 /* CCEventFocus.cpp */; }; - 50ABBE571925AB6F00A911A9 /* CCEventFocus.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDDD1925AB6E00A911A9 /* CCEventFocus.h */; }; - 50ABBE581925AB6F00A911A9 /* CCEventFocus.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDDD1925AB6E00A911A9 /* CCEventFocus.h */; }; - 50ABBE591925AB6F00A911A9 /* CCEventKeyboard.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDDE1925AB6E00A911A9 /* CCEventKeyboard.cpp */; }; - 50ABBE5A1925AB6F00A911A9 /* CCEventKeyboard.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDDE1925AB6E00A911A9 /* CCEventKeyboard.cpp */; }; - 50ABBE5B1925AB6F00A911A9 /* CCEventKeyboard.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDDF1925AB6E00A911A9 /* CCEventKeyboard.h */; }; - 50ABBE5C1925AB6F00A911A9 /* CCEventKeyboard.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDDF1925AB6E00A911A9 /* CCEventKeyboard.h */; }; - 50ABBE5D1925AB6F00A911A9 /* CCEventListener.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDE01925AB6E00A911A9 /* CCEventListener.cpp */; }; - 50ABBE5E1925AB6F00A911A9 /* CCEventListener.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDE01925AB6E00A911A9 /* CCEventListener.cpp */; }; - 50ABBE5F1925AB6F00A911A9 /* CCEventListener.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDE11925AB6E00A911A9 /* CCEventListener.h */; }; - 50ABBE601925AB6F00A911A9 /* CCEventListener.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDE11925AB6E00A911A9 /* CCEventListener.h */; }; - 50ABBE611925AB6F00A911A9 /* CCEventListenerAcceleration.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDE21925AB6E00A911A9 /* CCEventListenerAcceleration.cpp */; }; - 50ABBE621925AB6F00A911A9 /* CCEventListenerAcceleration.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDE21925AB6E00A911A9 /* CCEventListenerAcceleration.cpp */; }; - 50ABBE631925AB6F00A911A9 /* CCEventListenerAcceleration.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDE31925AB6E00A911A9 /* CCEventListenerAcceleration.h */; }; - 50ABBE641925AB6F00A911A9 /* CCEventListenerAcceleration.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDE31925AB6E00A911A9 /* CCEventListenerAcceleration.h */; }; - 50ABBE651925AB6F00A911A9 /* CCEventListenerCustom.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDE41925AB6E00A911A9 /* CCEventListenerCustom.cpp */; }; - 50ABBE661925AB6F00A911A9 /* CCEventListenerCustom.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDE41925AB6E00A911A9 /* CCEventListenerCustom.cpp */; }; - 50ABBE671925AB6F00A911A9 /* CCEventListenerCustom.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDE51925AB6E00A911A9 /* CCEventListenerCustom.h */; }; - 50ABBE681925AB6F00A911A9 /* CCEventListenerCustom.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDE51925AB6E00A911A9 /* CCEventListenerCustom.h */; }; - 50ABBE691925AB6F00A911A9 /* CCEventListenerFocus.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDE61925AB6E00A911A9 /* CCEventListenerFocus.cpp */; }; - 50ABBE6A1925AB6F00A911A9 /* CCEventListenerFocus.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDE61925AB6E00A911A9 /* CCEventListenerFocus.cpp */; }; - 50ABBE6B1925AB6F00A911A9 /* CCEventListenerFocus.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDE71925AB6E00A911A9 /* CCEventListenerFocus.h */; }; - 50ABBE6C1925AB6F00A911A9 /* CCEventListenerFocus.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDE71925AB6E00A911A9 /* CCEventListenerFocus.h */; }; - 50ABBE6D1925AB6F00A911A9 /* CCEventListenerKeyboard.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDE81925AB6E00A911A9 /* CCEventListenerKeyboard.cpp */; }; - 50ABBE6E1925AB6F00A911A9 /* CCEventListenerKeyboard.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDE81925AB6E00A911A9 /* CCEventListenerKeyboard.cpp */; }; - 50ABBE6F1925AB6F00A911A9 /* CCEventListenerKeyboard.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDE91925AB6E00A911A9 /* CCEventListenerKeyboard.h */; }; - 50ABBE701925AB6F00A911A9 /* CCEventListenerKeyboard.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDE91925AB6E00A911A9 /* CCEventListenerKeyboard.h */; }; - 50ABBE711925AB6F00A911A9 /* CCEventListenerMouse.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDEA1925AB6E00A911A9 /* CCEventListenerMouse.cpp */; }; - 50ABBE721925AB6F00A911A9 /* CCEventListenerMouse.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDEA1925AB6E00A911A9 /* CCEventListenerMouse.cpp */; }; - 50ABBE731925AB6F00A911A9 /* CCEventListenerMouse.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDEB1925AB6E00A911A9 /* CCEventListenerMouse.h */; }; - 50ABBE741925AB6F00A911A9 /* CCEventListenerMouse.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDEB1925AB6E00A911A9 /* CCEventListenerMouse.h */; }; - 50ABBE751925AB6F00A911A9 /* CCEventListenerTouch.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDEC1925AB6E00A911A9 /* CCEventListenerTouch.cpp */; }; - 50ABBE761925AB6F00A911A9 /* CCEventListenerTouch.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDEC1925AB6E00A911A9 /* CCEventListenerTouch.cpp */; }; - 50ABBE771925AB6F00A911A9 /* CCEventListenerTouch.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDED1925AB6E00A911A9 /* CCEventListenerTouch.h */; }; - 50ABBE781925AB6F00A911A9 /* CCEventListenerTouch.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDED1925AB6E00A911A9 /* CCEventListenerTouch.h */; }; - 50ABBE791925AB6F00A911A9 /* CCEventMouse.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDEE1925AB6E00A911A9 /* CCEventMouse.cpp */; }; - 50ABBE7A1925AB6F00A911A9 /* CCEventMouse.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDEE1925AB6E00A911A9 /* CCEventMouse.cpp */; }; - 50ABBE7B1925AB6F00A911A9 /* CCEventMouse.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDEF1925AB6E00A911A9 /* CCEventMouse.h */; }; - 50ABBE7C1925AB6F00A911A9 /* CCEventMouse.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDEF1925AB6E00A911A9 /* CCEventMouse.h */; }; - 50ABBE7D1925AB6F00A911A9 /* CCEventTouch.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDF01925AB6E00A911A9 /* CCEventTouch.cpp */; }; - 50ABBE7E1925AB6F00A911A9 /* CCEventTouch.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDF01925AB6E00A911A9 /* CCEventTouch.cpp */; }; - 50ABBE7F1925AB6F00A911A9 /* CCEventTouch.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDF11925AB6E00A911A9 /* CCEventTouch.h */; }; - 50ABBE801925AB6F00A911A9 /* CCEventTouch.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDF11925AB6E00A911A9 /* CCEventTouch.h */; }; - 50ABBE811925AB6F00A911A9 /* CCEventType.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDF21925AB6E00A911A9 /* CCEventType.h */; }; - 50ABBE821925AB6F00A911A9 /* CCEventType.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDF21925AB6E00A911A9 /* CCEventType.h */; }; - 50ABBE831925AB6F00A911A9 /* ccFPSImages.c in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDF31925AB6E00A911A9 /* ccFPSImages.c */; }; - 50ABBE841925AB6F00A911A9 /* ccFPSImages.c in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDF31925AB6E00A911A9 /* ccFPSImages.c */; }; - 50ABBE851925AB6F00A911A9 /* ccFPSImages.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDF41925AB6E00A911A9 /* ccFPSImages.h */; }; - 50ABBE861925AB6F00A911A9 /* ccFPSImages.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDF41925AB6E00A911A9 /* ccFPSImages.h */; }; - 50ABBE871925AB6F00A911A9 /* ccMacros.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDF51925AB6E00A911A9 /* ccMacros.h */; }; - 50ABBE881925AB6F00A911A9 /* ccMacros.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDF51925AB6E00A911A9 /* ccMacros.h */; }; - 50ABBE891925AB6F00A911A9 /* CCMap.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDF61925AB6E00A911A9 /* CCMap.h */; }; - 50ABBE8A1925AB6F00A911A9 /* CCMap.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDF61925AB6E00A911A9 /* CCMap.h */; }; - 50ABBE8B1925AB6F00A911A9 /* CCNS.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDF71925AB6E00A911A9 /* CCNS.cpp */; }; - 50ABBE8C1925AB6F00A911A9 /* CCNS.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDF71925AB6E00A911A9 /* CCNS.cpp */; }; - 50ABBE8D1925AB6F00A911A9 /* CCNS.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDF81925AB6E00A911A9 /* CCNS.h */; }; - 50ABBE8E1925AB6F00A911A9 /* CCNS.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDF81925AB6E00A911A9 /* CCNS.h */; }; - 50ABBE931925AB6F00A911A9 /* CCProfiling.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDFB1925AB6E00A911A9 /* CCProfiling.cpp */; }; - 50ABBE941925AB6F00A911A9 /* CCProfiling.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDFB1925AB6E00A911A9 /* CCProfiling.cpp */; }; - 50ABBE951925AB6F00A911A9 /* CCProfiling.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDFC1925AB6E00A911A9 /* CCProfiling.h */; }; - 50ABBE961925AB6F00A911A9 /* CCProfiling.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDFC1925AB6E00A911A9 /* CCProfiling.h */; }; - 50ABBE971925AB6F00A911A9 /* CCProtocols.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDFD1925AB6E00A911A9 /* CCProtocols.h */; }; - 50ABBE981925AB6F00A911A9 /* CCProtocols.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDFD1925AB6E00A911A9 /* CCProtocols.h */; }; - 50ABBE991925AB6F00A911A9 /* CCRef.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDFE1925AB6E00A911A9 /* CCRef.cpp */; }; - 50ABBE9A1925AB6F00A911A9 /* CCRef.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBDFE1925AB6E00A911A9 /* CCRef.cpp */; }; - 50ABBE9B1925AB6F00A911A9 /* CCRef.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDFF1925AB6E00A911A9 /* CCRef.h */; }; - 50ABBE9C1925AB6F00A911A9 /* CCRef.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBDFF1925AB6E00A911A9 /* CCRef.h */; }; - 50ABBE9D1925AB6F00A911A9 /* CCRefPtr.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBE001925AB6E00A911A9 /* CCRefPtr.h */; }; - 50ABBE9E1925AB6F00A911A9 /* CCRefPtr.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBE001925AB6E00A911A9 /* CCRefPtr.h */; }; - 50ABBE9F1925AB6F00A911A9 /* CCScheduler.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBE011925AB6E00A911A9 /* CCScheduler.cpp */; }; - 50ABBEA01925AB6F00A911A9 /* CCScheduler.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBE011925AB6E00A911A9 /* CCScheduler.cpp */; }; - 50ABBEA11925AB6F00A911A9 /* CCScheduler.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBE021925AB6E00A911A9 /* CCScheduler.h */; }; - 50ABBEA21925AB6F00A911A9 /* CCScheduler.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBE021925AB6E00A911A9 /* CCScheduler.h */; }; - 50ABBEA31925AB6F00A911A9 /* CCScriptSupport.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBE031925AB6E00A911A9 /* CCScriptSupport.cpp */; }; - 50ABBEA41925AB6F00A911A9 /* CCScriptSupport.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBE031925AB6E00A911A9 /* CCScriptSupport.cpp */; }; - 50ABBEA51925AB6F00A911A9 /* CCScriptSupport.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBE041925AB6E00A911A9 /* CCScriptSupport.h */; }; - 50ABBEA61925AB6F00A911A9 /* CCScriptSupport.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBE041925AB6E00A911A9 /* CCScriptSupport.h */; }; - 50ABBEA71925AB6F00A911A9 /* CCTouch.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBE051925AB6E00A911A9 /* CCTouch.cpp */; }; - 50ABBEA81925AB6F00A911A9 /* CCTouch.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBE051925AB6E00A911A9 /* CCTouch.cpp */; }; - 50ABBEA91925AB6F00A911A9 /* CCTouch.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBE061925AB6E00A911A9 /* CCTouch.h */; }; - 50ABBEAA1925AB6F00A911A9 /* CCTouch.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBE061925AB6E00A911A9 /* CCTouch.h */; }; - 50ABBEAB1925AB6F00A911A9 /* ccTypes.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBE071925AB6E00A911A9 /* ccTypes.cpp */; }; - 50ABBEAC1925AB6F00A911A9 /* ccTypes.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBE071925AB6E00A911A9 /* ccTypes.cpp */; }; - 50ABBEAD1925AB6F00A911A9 /* ccTypes.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBE081925AB6E00A911A9 /* ccTypes.h */; }; - 50ABBEAE1925AB6F00A911A9 /* ccTypes.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBE081925AB6E00A911A9 /* ccTypes.h */; }; - 50ABBEAF1925AB6F00A911A9 /* CCUserDefault.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBE091925AB6E00A911A9 /* CCUserDefault.cpp */; }; - 50ABBEB01925AB6F00A911A9 /* CCUserDefault.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBE091925AB6E00A911A9 /* CCUserDefault.cpp */; }; - 50ABBEB11925AB6F00A911A9 /* CCUserDefault.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBE0A1925AB6E00A911A9 /* CCUserDefault.h */; }; - 50ABBEB21925AB6F00A911A9 /* CCUserDefault.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBE0A1925AB6E00A911A9 /* CCUserDefault.h */; }; - 50ABBEB31925AB6F00A911A9 /* CCUserDefault-apple.mm in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBE0B1925AB6F00A911A9 /* CCUserDefault-apple.mm */; }; - 50ABBEB41925AB6F00A911A9 /* CCUserDefault-apple.mm in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBE0B1925AB6F00A911A9 /* CCUserDefault-apple.mm */; }; - 50ABBEB71925AB6F00A911A9 /* ccUTF8.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBE0D1925AB6F00A911A9 /* ccUTF8.cpp */; }; - 50ABBEB81925AB6F00A911A9 /* ccUTF8.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBE0D1925AB6F00A911A9 /* ccUTF8.cpp */; }; - 50ABBEB91925AB6F00A911A9 /* ccUTF8.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBE0E1925AB6F00A911A9 /* ccUTF8.h */; }; - 50ABBEBA1925AB6F00A911A9 /* ccUTF8.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBE0E1925AB6F00A911A9 /* ccUTF8.h */; }; - 50ABBEBB1925AB6F00A911A9 /* ccUtils.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBE0F1925AB6F00A911A9 /* ccUtils.cpp */; }; - 50ABBEBC1925AB6F00A911A9 /* ccUtils.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBE0F1925AB6F00A911A9 /* ccUtils.cpp */; }; - 50ABBEBD1925AB6F00A911A9 /* ccUtils.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBE101925AB6F00A911A9 /* ccUtils.h */; }; - 50ABBEBE1925AB6F00A911A9 /* ccUtils.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBE101925AB6F00A911A9 /* ccUtils.h */; }; - 50ABBEBF1925AB6F00A911A9 /* CCValue.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBE111925AB6F00A911A9 /* CCValue.cpp */; }; - 50ABBEC01925AB6F00A911A9 /* CCValue.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBE111925AB6F00A911A9 /* CCValue.cpp */; }; - 50ABBEC11925AB6F00A911A9 /* CCValue.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBE121925AB6F00A911A9 /* CCValue.h */; }; - 50ABBEC21925AB6F00A911A9 /* CCValue.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBE121925AB6F00A911A9 /* CCValue.h */; }; - 50ABBEC31925AB6F00A911A9 /* CCVector.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBE131925AB6F00A911A9 /* CCVector.h */; }; - 50ABBEC41925AB6F00A911A9 /* CCVector.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBE131925AB6F00A911A9 /* CCVector.h */; }; - 50ABBEC51925AB6F00A911A9 /* etc1.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBE141925AB6F00A911A9 /* etc1.cpp */; }; - 50ABBEC61925AB6F00A911A9 /* etc1.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBE141925AB6F00A911A9 /* etc1.cpp */; }; - 50ABBEC71925AB6F00A911A9 /* etc1.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBE151925AB6F00A911A9 /* etc1.h */; }; - 50ABBEC81925AB6F00A911A9 /* etc1.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBE151925AB6F00A911A9 /* etc1.h */; }; - 50ABBEC91925AB6F00A911A9 /* firePngData.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBE161925AB6F00A911A9 /* firePngData.h */; }; - 50ABBECA1925AB6F00A911A9 /* firePngData.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBE161925AB6F00A911A9 /* firePngData.h */; }; - 50ABBECF1925AB6F00A911A9 /* TGAlib.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBE191925AB6F00A911A9 /* TGAlib.cpp */; }; - 50ABBED01925AB6F00A911A9 /* TGAlib.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBE191925AB6F00A911A9 /* TGAlib.cpp */; }; - 50ABBED11925AB6F00A911A9 /* TGAlib.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBE1A1925AB6F00A911A9 /* TGAlib.h */; }; - 50ABBED21925AB6F00A911A9 /* TGAlib.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBE1A1925AB6F00A911A9 /* TGAlib.h */; }; - 50ABBED31925AB6F00A911A9 /* uthash.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBE1B1925AB6F00A911A9 /* uthash.h */; }; - 50ABBED41925AB6F00A911A9 /* uthash.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBE1B1925AB6F00A911A9 /* uthash.h */; }; - 50ABBED51925AB6F00A911A9 /* utlist.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBE1C1925AB6F00A911A9 /* utlist.h */; }; - 50ABBED61925AB6F00A911A9 /* utlist.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBE1C1925AB6F00A911A9 /* utlist.h */; }; - 50ABBED71925AB6F00A911A9 /* ZipUtils.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBE1D1925AB6F00A911A9 /* ZipUtils.cpp */; }; - 50ABBED81925AB6F00A911A9 /* ZipUtils.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBE1D1925AB6F00A911A9 /* ZipUtils.cpp */; }; - 50ABBED91925AB6F00A911A9 /* ZipUtils.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBE1E1925AB6F00A911A9 /* ZipUtils.h */; }; - 50ABBEDA1925AB6F00A911A9 /* ZipUtils.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBE1E1925AB6F00A911A9 /* ZipUtils.h */; }; 50ABBFFD1926664800A911A9 /* CCFileUtils-apple.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBF1B1926664700A911A9 /* CCFileUtils-apple.h */; }; 50ABBFFE1926664800A911A9 /* CCFileUtils-apple.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBF1B1926664700A911A9 /* CCFileUtils-apple.h */; }; 50ABBFFF1926664800A911A9 /* CCFileUtils-apple.mm in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBF1C1926664700A911A9 /* CCFileUtils-apple.mm */; }; @@ -1047,22 +633,12 @@ 50ABC0021926664800A911A9 /* CCLock-apple.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBF1D1926664700A911A9 /* CCLock-apple.cpp */; }; 50ABC0031926664800A911A9 /* CCLock-apple.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBF1E1926664700A911A9 /* CCLock-apple.h */; }; 50ABC0041926664800A911A9 /* CCLock-apple.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBF1E1926664700A911A9 /* CCLock-apple.h */; }; - 50ABC0051926664800A911A9 /* CCThread-apple.mm in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBF1F1926664700A911A9 /* CCThread-apple.mm */; }; - 50ABC0061926664800A911A9 /* CCThread-apple.mm in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBF1F1926664700A911A9 /* CCThread-apple.mm */; }; - 50ABC0071926664800A911A9 /* CCApplicationProtocol.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBF201926664700A911A9 /* CCApplicationProtocol.h */; }; - 50ABC0081926664800A911A9 /* CCApplicationProtocol.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBF201926664700A911A9 /* CCApplicationProtocol.h */; }; - 50ABC0091926664800A911A9 /* CCCommon.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBF211926664700A911A9 /* CCCommon.h */; }; - 50ABC00A1926664800A911A9 /* CCCommon.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBF211926664700A911A9 /* CCCommon.h */; }; 50ABC00B1926664800A911A9 /* CCDevice.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBF221926664700A911A9 /* CCDevice.h */; }; 50ABC00C1926664800A911A9 /* CCDevice.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBF221926664700A911A9 /* CCDevice.h */; }; 50ABC00D1926664800A911A9 /* CCFileUtils.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBF231926664700A911A9 /* CCFileUtils.cpp */; }; 50ABC00E1926664800A911A9 /* CCFileUtils.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBF231926664700A911A9 /* CCFileUtils.cpp */; }; 50ABC00F1926664800A911A9 /* CCFileUtils.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBF241926664700A911A9 /* CCFileUtils.h */; }; 50ABC0101926664800A911A9 /* CCFileUtils.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBF241926664700A911A9 /* CCFileUtils.h */; }; - 50ABC0111926664800A911A9 /* CCGLView.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBF251926664700A911A9 /* CCGLView.cpp */; }; - 50ABC0121926664800A911A9 /* CCGLView.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBF251926664700A911A9 /* CCGLView.cpp */; }; - 50ABC0131926664800A911A9 /* CCGLView.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBF261926664700A911A9 /* CCGLView.h */; }; - 50ABC0141926664800A911A9 /* CCGLView.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBF261926664700A911A9 /* CCGLView.h */; }; 50ABC0151926664800A911A9 /* CCImage.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBF271926664700A911A9 /* CCImage.cpp */; }; 50ABC0161926664800A911A9 /* CCImage.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBF271926664700A911A9 /* CCImage.cpp */; }; 50ABC0171926664800A911A9 /* CCImage.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBF281926664700A911A9 /* CCImage.h */; }; @@ -1071,135 +647,26 @@ 50ABC01A1926664800A911A9 /* CCSAXParser.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBF291926664700A911A9 /* CCSAXParser.cpp */; }; 50ABC01B1926664800A911A9 /* CCSAXParser.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBF2A1926664700A911A9 /* CCSAXParser.h */; }; 50ABC01C1926664800A911A9 /* CCSAXParser.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBF2A1926664700A911A9 /* CCSAXParser.h */; }; - 50ABC01D1926664800A911A9 /* CCThread.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBF2B1926664700A911A9 /* CCThread.cpp */; }; - 50ABC01E1926664800A911A9 /* CCThread.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBF2B1926664700A911A9 /* CCThread.cpp */; }; - 50ABC01F1926664800A911A9 /* CCThread.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBF2C1926664700A911A9 /* CCThread.h */; }; - 50ABC0201926664800A911A9 /* CCThread.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBF2C1926664700A911A9 /* CCThread.h */; }; - 50ABC0211926664800A911A9 /* CCGLViewImpl-desktop.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBF2E1926664700A911A9 /* CCGLViewImpl-desktop.cpp */; }; - 50ABC0231926664800A911A9 /* CCGLViewImpl-desktop.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBF2F1926664700A911A9 /* CCGLViewImpl-desktop.h */; }; - 50ABC05D1926664800A911A9 /* CCApplication-mac.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBF4F1926664700A911A9 /* CCApplication-mac.h */; }; - 50ABC05F1926664800A911A9 /* CCApplication-mac.mm in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBF501926664700A911A9 /* CCApplication-mac.mm */; }; - 50ABC0611926664800A911A9 /* CCCommon-mac.mm in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBF511926664700A911A9 /* CCCommon-mac.mm */; }; 50ABC0631926664800A911A9 /* CCDevice-mac.mm in Sources */ = {isa = PBXBuildFile; fileRef = 50ABBF521926664700A911A9 /* CCDevice-mac.mm */; }; 50ABC0651926664800A911A9 /* CCGL-mac.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBF531926664700A911A9 /* CCGL-mac.h */; }; 50ABC0671926664800A911A9 /* CCPlatformDefine-mac.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBF541926664700A911A9 /* CCPlatformDefine-mac.h */; }; 50ABC0691926664800A911A9 /* CCStdC-mac.h in Headers */ = {isa = PBXBuildFile; fileRef = 50ABBF551926664700A911A9 /* CCStdC-mac.h */; }; - 50CB247519D9C5A100687767 /* AudioCache.h in Headers */ = {isa = PBXBuildFile; fileRef = 50CB246F19D9C5A100687767 /* AudioCache.h */; }; - 50CB247619D9C5A100687767 /* AudioCache.h in Headers */ = {isa = PBXBuildFile; fileRef = 50CB246F19D9C5A100687767 /* AudioCache.h */; }; - 50CB247719D9C5A100687767 /* AudioCache.mm in Sources */ = {isa = PBXBuildFile; fileRef = 50CB247019D9C5A100687767 /* AudioCache.mm */; }; - 50CB247819D9C5A100687767 /* AudioCache.mm in Sources */ = {isa = PBXBuildFile; fileRef = 50CB247019D9C5A100687767 /* AudioCache.mm */; }; - 50CB247919D9C5A100687767 /* AudioEngine-inl.h in Headers */ = {isa = PBXBuildFile; fileRef = 50CB247119D9C5A100687767 /* AudioEngine-inl.h */; }; - 50CB247A19D9C5A100687767 /* AudioEngine-inl.h in Headers */ = {isa = PBXBuildFile; fileRef = 50CB247119D9C5A100687767 /* AudioEngine-inl.h */; }; - 50CB247B19D9C5A100687767 /* AudioEngine-inl.mm in Sources */ = {isa = PBXBuildFile; fileRef = 50CB247219D9C5A100687767 /* AudioEngine-inl.mm */; }; - 50CB247C19D9C5A100687767 /* AudioEngine-inl.mm in Sources */ = {isa = PBXBuildFile; fileRef = 50CB247219D9C5A100687767 /* AudioEngine-inl.mm */; }; - 50CB247D19D9C5A100687767 /* AudioPlayer.h in Headers */ = {isa = PBXBuildFile; fileRef = 50CB247319D9C5A100687767 /* AudioPlayer.h */; }; - 50CB247E19D9C5A100687767 /* AudioPlayer.h in Headers */ = {isa = PBXBuildFile; fileRef = 50CB247319D9C5A100687767 /* AudioPlayer.h */; }; - 50CB247F19D9C5A100687767 /* AudioPlayer.mm in Sources */ = {isa = PBXBuildFile; fileRef = 50CB247419D9C5A100687767 /* AudioPlayer.mm */; }; - 50CB248019D9C5A100687767 /* AudioPlayer.mm in Sources */ = {isa = PBXBuildFile; fileRef = 50CB247419D9C5A100687767 /* AudioPlayer.mm */; }; - 50ED2BDA19BE76D300A0AB90 /* UIVideoPlayer.h in Headers */ = {isa = PBXBuildFile; fileRef = 3EA0FB69191C841D00B170C8 /* UIVideoPlayer.h */; }; - 50ED2BDB19BE76D500A0AB90 /* UIVideoPlayer-ios.mm in Sources */ = {isa = PBXBuildFile; fileRef = 3EA0FB6A191C841D00B170C8 /* UIVideoPlayer-ios.mm */; }; - 52B47A2E1A5349A3004E4C60 /* HttpAsynConnection-apple.h in Headers */ = {isa = PBXBuildFile; fileRef = 52B47A291A5349A3004E4C60 /* HttpAsynConnection-apple.h */; }; - 52B47A2F1A5349A3004E4C60 /* HttpAsynConnection-apple.m in Sources */ = {isa = PBXBuildFile; fileRef = 52B47A2A1A5349A3004E4C60 /* HttpAsynConnection-apple.m */; }; - 52B47A301A5349A3004E4C60 /* HttpClient-apple.mm in Sources */ = {isa = PBXBuildFile; fileRef = 52B47A2B1A5349A3004E4C60 /* HttpClient-apple.mm */; }; - 52B47A311A5349A3004E4C60 /* HttpCookie.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 52B47A2C1A5349A3004E4C60 /* HttpCookie.cpp */; }; - 52B47A321A5349A3004E4C60 /* HttpCookie.h in Headers */ = {isa = PBXBuildFile; fileRef = 52B47A2D1A5349A3004E4C60 /* HttpCookie.h */; }; - 826294331AAF001C00CB7CF7 /* HttpAsynConnection-apple.m in Sources */ = {isa = PBXBuildFile; fileRef = 52B47A2A1A5349A3004E4C60 /* HttpAsynConnection-apple.m */; }; - 826294341AAF003E00CB7CF7 /* HttpClient-apple.mm in Sources */ = {isa = PBXBuildFile; fileRef = 52B47A2B1A5349A3004E4C60 /* HttpClient-apple.mm */; }; - 826294351AAF004C00CB7CF7 /* HttpCookie.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 52B47A2C1A5349A3004E4C60 /* HttpCookie.cpp */; }; - 844EB11F1F78D4CB00EFE4CD /* CCThreadPool.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 844EB11D1F78D4CA00EFE4CD /* CCThreadPool.cpp */; }; - 844EB1201F78D4CB00EFE4CD /* CCThreadPool.h in Headers */ = {isa = PBXBuildFile; fileRef = 844EB11E1F78D4CA00EFE4CD /* CCThreadPool.h */; }; - A0534A651B872FFD006B03E5 /* CCDownloader-apple.h in Headers */ = {isa = PBXBuildFile; fileRef = A0534A631B872FFD006B03E5 /* CCDownloader-apple.h */; }; - A0534A661B872FFD006B03E5 /* CCDownloader-apple.h in Headers */ = {isa = PBXBuildFile; fileRef = A0534A631B872FFD006B03E5 /* CCDownloader-apple.h */; }; - A0534A671B872FFD006B03E5 /* CCDownloader-apple.mm in Sources */ = {isa = PBXBuildFile; fileRef = A0534A641B872FFD006B03E5 /* CCDownloader-apple.mm */; }; - A0534A681B872FFD006B03E5 /* CCDownloader-apple.mm in Sources */ = {isa = PBXBuildFile; fileRef = A0534A641B872FFD006B03E5 /* CCDownloader-apple.mm */; }; - A0534A6A1B87306E006B03E5 /* CCIDownloaderImpl.h in Headers */ = {isa = PBXBuildFile; fileRef = A0534A691B87306E006B03E5 /* CCIDownloaderImpl.h */; }; - A0534A6B1B87306E006B03E5 /* CCIDownloaderImpl.h in Headers */ = {isa = PBXBuildFile; fileRef = A0534A691B87306E006B03E5 /* CCIDownloaderImpl.h */; }; - A05DCF9D1B90584E00EE040B /* CCDownloader-curl.cpp in Sources */ = {isa = PBXBuildFile; fileRef = A05DCF9B1B90584E00EE040B /* CCDownloader-curl.cpp */; }; - A05DCF9E1B90584E00EE040B /* CCDownloader-curl.h in Headers */ = {isa = PBXBuildFile; fileRef = A05DCF9C1B90584E00EE040B /* CCDownloader-curl.h */; }; A07A4CAF1783777C0073F6A7 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 1551A342158F2AB200E66CFE /* Foundation.framework */; }; - A0E749F71BA8FD7F001A8332 /* UIEditBoxImpl-common.cpp in Sources */ = {isa = PBXBuildFile; fileRef = A0E749F51BA8FD7F001A8332 /* UIEditBoxImpl-common.cpp */; }; - A0E749F81BA8FD7F001A8332 /* UIEditBoxImpl-common.cpp in Sources */ = {isa = PBXBuildFile; fileRef = A0E749F51BA8FD7F001A8332 /* UIEditBoxImpl-common.cpp */; }; - A0E749F91BA8FD7F001A8332 /* UIEditBoxImpl-common.h in Headers */ = {isa = PBXBuildFile; fileRef = A0E749F61BA8FD7F001A8332 /* UIEditBoxImpl-common.h */; }; - A0E749FA1BA8FD7F001A8332 /* UIEditBoxImpl-common.h in Headers */ = {isa = PBXBuildFile; fileRef = A0E749F61BA8FD7F001A8332 /* UIEditBoxImpl-common.h */; }; A60A9D661C200E5A0070800A /* libchipmunk.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A60A9D651C200E5A0070800A /* libchipmunk.a */; }; - A614E2E01C8E72360065A737 /* CCLabelTTF.h in Headers */ = {isa = PBXBuildFile; fileRef = A614E2DE1C8E72360065A737 /* CCLabelTTF.h */; }; - A614E2E11C8E761D0065A737 /* CCLabelTTF.h in Headers */ = {isa = PBXBuildFile; fileRef = A614E2DE1C8E72360065A737 /* CCLabelTTF.h */; }; - A63CF0041CD9CF3500A6971D /* CCUIEditBoxMac.h in Headers */ = {isa = PBXBuildFile; fileRef = A63CEFF91CD9CF3500A6971D /* CCUIEditBoxMac.h */; }; - A63CF0051CD9CF3500A6971D /* CCUIEditBoxMac.mm in Sources */ = {isa = PBXBuildFile; fileRef = A63CEFFA1CD9CF3500A6971D /* CCUIEditBoxMac.mm */; }; - A63CF0061CD9CF3500A6971D /* CCUIMultilineTextField.h in Headers */ = {isa = PBXBuildFile; fileRef = A63CEFFB1CD9CF3500A6971D /* CCUIMultilineTextField.h */; }; - A63CF0071CD9CF3500A6971D /* CCUIMultilineTextField.m in Sources */ = {isa = PBXBuildFile; fileRef = A63CEFFC1CD9CF3500A6971D /* CCUIMultilineTextField.m */; }; - A63CF0081CD9CF3500A6971D /* CCUIPasswordTextField.h in Headers */ = {isa = PBXBuildFile; fileRef = A63CEFFD1CD9CF3500A6971D /* CCUIPasswordTextField.h */; }; - A63CF0091CD9CF3500A6971D /* CCUIPasswordTextField.m in Sources */ = {isa = PBXBuildFile; fileRef = A63CEFFE1CD9CF3500A6971D /* CCUIPasswordTextField.m */; }; - A63CF00A1CD9CF3500A6971D /* CCUISingleLineTextField.h in Headers */ = {isa = PBXBuildFile; fileRef = A63CEFFF1CD9CF3500A6971D /* CCUISingleLineTextField.h */; }; - A63CF00B1CD9CF3500A6971D /* CCUISingleLineTextField.m in Sources */ = {isa = PBXBuildFile; fileRef = A63CF0001CD9CF3500A6971D /* CCUISingleLineTextField.m */; }; - A63CF00C1CD9CF3500A6971D /* CCUITextFieldFormatter.h in Headers */ = {isa = PBXBuildFile; fileRef = A63CF0011CD9CF3500A6971D /* CCUITextFieldFormatter.h */; }; - A63CF00D1CD9CF3500A6971D /* CCUITextFieldFormatter.m in Sources */ = {isa = PBXBuildFile; fileRef = A63CF0021CD9CF3500A6971D /* CCUITextFieldFormatter.m */; }; - A63CF00E1CD9CF3500A6971D /* CCUITextInput.h in Headers */ = {isa = PBXBuildFile; fileRef = A63CF0031CD9CF3500A6971D /* CCUITextInput.h */; }; A679D0D91C71D90A00620A6C /* libssl.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A6A554241C2A7C4400FDD954 /* libssl.a */; }; A679D0DA1C71D93200620A6C /* libcrypto.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A6A554221C2A7C3100FDD954 /* libcrypto.a */; }; A6A5541F1C2A7BF700FDD954 /* libchipmunk.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A6A5541E1C2A7BF700FDD954 /* libchipmunk.a */; }; A6A554211C2A7C1300FDD954 /* libcurl.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A6A554201C2A7C1300FDD954 /* libcurl.a */; }; - A6E018661CB7A7E000EC1419 /* CCDownloader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 50693C5C1B6BF2AE005C5820 /* CCDownloader.cpp */; }; - A6F0D7A11C2796020029CC44 /* CCStencilStateManager.cpp in Sources */ = {isa = PBXBuildFile; fileRef = A6F0D79F1C2796020029CC44 /* CCStencilStateManager.cpp */; }; - A6F0D7A21C2796020029CC44 /* CCStencilStateManager.hpp in Headers */ = {isa = PBXBuildFile; fileRef = A6F0D7A01C2796020029CC44 /* CCStencilStateManager.hpp */; }; - A6F0D7A31C2796060029CC44 /* CCStencilStateManager.cpp in Sources */ = {isa = PBXBuildFile; fileRef = A6F0D79F1C2796020029CC44 /* CCStencilStateManager.cpp */; }; - B2165EEA19921124000BE3E6 /* CCPrimitiveCommand.cpp in Sources */ = {isa = PBXBuildFile; fileRef = B257B45E198A353E00D9A687 /* CCPrimitiveCommand.cpp */; }; B217703C1977ECB4009EE11B /* IOKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = B217703B1977ECB4009EE11B /* IOKit.framework */; }; B21770401977ECE6009EE11B /* OpenGL.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = B217703F1977ECE6009EE11B /* OpenGL.framework */; }; B21770421977ECF8009EE11B /* ApplicationServices.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = B21770411977ECF8009EE11B /* ApplicationServices.framework */; }; B21770451977ED14009EE11B /* Cocoa.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = B21770431977ED07009EE11B /* Cocoa.framework */; }; B21770471977ED34009EE11B /* QuartzCore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = B21770461977ED34009EE11B /* QuartzCore.framework */; }; - B230ED7119B417AE00364AA8 /* CCTrianglesCommand.cpp in Sources */ = {isa = PBXBuildFile; fileRef = B230ED6F19B417AE00364AA8 /* CCTrianglesCommand.cpp */; }; - B230ED7219B417AE00364AA8 /* CCTrianglesCommand.cpp in Sources */ = {isa = PBXBuildFile; fileRef = B230ED6F19B417AE00364AA8 /* CCTrianglesCommand.cpp */; }; - B230ED7319B417AE00364AA8 /* CCTrianglesCommand.h in Headers */ = {isa = PBXBuildFile; fileRef = B230ED7019B417AE00364AA8 /* CCTrianglesCommand.h */; }; - B230ED7419B417AE00364AA8 /* CCTrianglesCommand.h in Headers */ = {isa = PBXBuildFile; fileRef = B230ED7019B417AE00364AA8 /* CCTrianglesCommand.h */; }; - B24AA985195A675C007B4522 /* CCFastTMXLayer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = B24AA981195A675C007B4522 /* CCFastTMXLayer.cpp */; }; - B24AA986195A675C007B4522 /* CCFastTMXLayer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = B24AA981195A675C007B4522 /* CCFastTMXLayer.cpp */; }; - B24AA987195A675C007B4522 /* CCFastTMXLayer.h in Headers */ = {isa = PBXBuildFile; fileRef = B24AA982195A675C007B4522 /* CCFastTMXLayer.h */; }; - B24AA988195A675C007B4522 /* CCFastTMXLayer.h in Headers */ = {isa = PBXBuildFile; fileRef = B24AA982195A675C007B4522 /* CCFastTMXLayer.h */; }; - B24AA989195A675C007B4522 /* CCFastTMXTiledMap.cpp in Sources */ = {isa = PBXBuildFile; fileRef = B24AA983195A675C007B4522 /* CCFastTMXTiledMap.cpp */; }; - B24AA98A195A675C007B4522 /* CCFastTMXTiledMap.cpp in Sources */ = {isa = PBXBuildFile; fileRef = B24AA983195A675C007B4522 /* CCFastTMXTiledMap.cpp */; }; - B24AA98B195A675C007B4522 /* CCFastTMXTiledMap.h in Headers */ = {isa = PBXBuildFile; fileRef = B24AA984195A675C007B4522 /* CCFastTMXTiledMap.h */; }; - B24AA98C195A675C007B4522 /* CCFastTMXTiledMap.h in Headers */ = {isa = PBXBuildFile; fileRef = B24AA984195A675C007B4522 /* CCFastTMXTiledMap.h */; }; - B257B44E1989D5E800D9A687 /* CCPrimitive.cpp in Sources */ = {isa = PBXBuildFile; fileRef = B257B44C1989D5E800D9A687 /* CCPrimitive.cpp */; }; - B257B44F1989D5E800D9A687 /* CCPrimitive.cpp in Sources */ = {isa = PBXBuildFile; fileRef = B257B44C1989D5E800D9A687 /* CCPrimitive.cpp */; }; - B257B4501989D5E800D9A687 /* CCPrimitive.h in Headers */ = {isa = PBXBuildFile; fileRef = B257B44D1989D5E800D9A687 /* CCPrimitive.h */; }; - B257B4511989D5E800D9A687 /* CCPrimitive.h in Headers */ = {isa = PBXBuildFile; fileRef = B257B44D1989D5E800D9A687 /* CCPrimitive.h */; }; - B257B460198A353E00D9A687 /* CCPrimitiveCommand.cpp in Sources */ = {isa = PBXBuildFile; fileRef = B257B45E198A353E00D9A687 /* CCPrimitiveCommand.cpp */; }; - B257B461198A353E00D9A687 /* CCPrimitiveCommand.h in Headers */ = {isa = PBXBuildFile; fileRef = B257B45F198A353E00D9A687 /* CCPrimitiveCommand.h */; }; - B276EF5F1988D1D500CD400F /* CCVertexIndexData.h in Headers */ = {isa = PBXBuildFile; fileRef = B276EF5B1988D1D500CD400F /* CCVertexIndexData.h */; }; - B276EF601988D1D500CD400F /* CCVertexIndexData.h in Headers */ = {isa = PBXBuildFile; fileRef = B276EF5B1988D1D500CD400F /* CCVertexIndexData.h */; }; - B276EF611988D1D500CD400F /* CCVertexIndexData.cpp in Sources */ = {isa = PBXBuildFile; fileRef = B276EF5C1988D1D500CD400F /* CCVertexIndexData.cpp */; }; - B276EF621988D1D500CD400F /* CCVertexIndexData.cpp in Sources */ = {isa = PBXBuildFile; fileRef = B276EF5C1988D1D500CD400F /* CCVertexIndexData.cpp */; }; - B276EF631988D1D500CD400F /* CCVertexIndexBuffer.h in Headers */ = {isa = PBXBuildFile; fileRef = B276EF5D1988D1D500CD400F /* CCVertexIndexBuffer.h */; }; - B276EF641988D1D500CD400F /* CCVertexIndexBuffer.h in Headers */ = {isa = PBXBuildFile; fileRef = B276EF5D1988D1D500CD400F /* CCVertexIndexBuffer.h */; }; - B276EF651988D1D500CD400F /* CCVertexIndexBuffer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = B276EF5E1988D1D500CD400F /* CCVertexIndexBuffer.cpp */; }; - B276EF661988D1D500CD400F /* CCVertexIndexBuffer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = B276EF5E1988D1D500CD400F /* CCVertexIndexBuffer.cpp */; }; B291B51B1D4A106A00BBB345 /* libjpeg.a in Frameworks */ = {isa = PBXBuildFile; fileRef = B291B5171D4A106A00BBB345 /* libjpeg.a */; }; B291B51C1D4A106A00BBB345 /* libpng.a in Frameworks */ = {isa = PBXBuildFile; fileRef = B291B5181D4A106A00BBB345 /* libpng.a */; }; B291B51D1D4A106A00BBB345 /* libtiff.a in Frameworks */ = {isa = PBXBuildFile; fileRef = B291B5191D4A106A00BBB345 /* libtiff.a */; }; B291B51E1D4A106A00BBB345 /* libwebp.a in Frameworks */ = {isa = PBXBuildFile; fileRef = B291B51A1D4A106A00BBB345 /* libwebp.a */; }; - B63990CC1A490AFE00B07923 /* CCAsyncTaskPool.cpp in Sources */ = {isa = PBXBuildFile; fileRef = B63990CA1A490AFE00B07923 /* CCAsyncTaskPool.cpp */; }; - B63990CD1A490AFE00B07923 /* CCAsyncTaskPool.cpp in Sources */ = {isa = PBXBuildFile; fileRef = B63990CA1A490AFE00B07923 /* CCAsyncTaskPool.cpp */; }; - B63990CE1A490AFE00B07923 /* CCAsyncTaskPool.h in Headers */ = {isa = PBXBuildFile; fileRef = B63990CB1A490AFE00B07923 /* CCAsyncTaskPool.h */; }; - B63990CF1A490AFE00B07923 /* CCAsyncTaskPool.h in Headers */ = {isa = PBXBuildFile; fileRef = B63990CB1A490AFE00B07923 /* CCAsyncTaskPool.h */; }; BA0DAAEF1DB76F2C00EE23AD /* libwebp.a in Frameworks */ = {isa = PBXBuildFile; fileRef = BA0DAAEE1DB76F2C00EE23AD /* libwebp.a */; }; - BA679B301CEC373000F875FA /* AssetsManagerEx.cpp in Sources */ = {isa = PBXBuildFile; fileRef = BA679B281CEC373000F875FA /* AssetsManagerEx.cpp */; }; - BA679B311CEC373000F875FA /* AssetsManagerEx.cpp in Sources */ = {isa = PBXBuildFile; fileRef = BA679B281CEC373000F875FA /* AssetsManagerEx.cpp */; }; - BA679B321CEC373000F875FA /* AssetsManagerEx.h in Headers */ = {isa = PBXBuildFile; fileRef = BA679B291CEC373000F875FA /* AssetsManagerEx.h */; }; - BA679B331CEC373000F875FA /* AssetsManagerEx.h in Headers */ = {isa = PBXBuildFile; fileRef = BA679B291CEC373000F875FA /* AssetsManagerEx.h */; }; - BA679B341CEC373000F875FA /* CCEventAssetsManagerEx.cpp in Sources */ = {isa = PBXBuildFile; fileRef = BA679B2A1CEC373000F875FA /* CCEventAssetsManagerEx.cpp */; }; - BA679B351CEC373000F875FA /* CCEventAssetsManagerEx.cpp in Sources */ = {isa = PBXBuildFile; fileRef = BA679B2A1CEC373000F875FA /* CCEventAssetsManagerEx.cpp */; }; - BA679B361CEC373000F875FA /* CCEventAssetsManagerEx.h in Headers */ = {isa = PBXBuildFile; fileRef = BA679B2B1CEC373000F875FA /* CCEventAssetsManagerEx.h */; }; - BA679B371CEC373000F875FA /* CCEventAssetsManagerEx.h in Headers */ = {isa = PBXBuildFile; fileRef = BA679B2B1CEC373000F875FA /* CCEventAssetsManagerEx.h */; }; - BA679B381CEC373000F875FA /* CCEventListenerAssetsManagerEx.cpp in Sources */ = {isa = PBXBuildFile; fileRef = BA679B2C1CEC373000F875FA /* CCEventListenerAssetsManagerEx.cpp */; }; - BA679B391CEC373000F875FA /* CCEventListenerAssetsManagerEx.cpp in Sources */ = {isa = PBXBuildFile; fileRef = BA679B2C1CEC373000F875FA /* CCEventListenerAssetsManagerEx.cpp */; }; - BA679B3A1CEC373000F875FA /* CCEventListenerAssetsManagerEx.h in Headers */ = {isa = PBXBuildFile; fileRef = BA679B2D1CEC373000F875FA /* CCEventListenerAssetsManagerEx.h */; }; - BA679B3B1CEC373000F875FA /* CCEventListenerAssetsManagerEx.h in Headers */ = {isa = PBXBuildFile; fileRef = BA679B2D1CEC373000F875FA /* CCEventListenerAssetsManagerEx.h */; }; - BA679B3C1CEC373000F875FA /* Manifest.cpp in Sources */ = {isa = PBXBuildFile; fileRef = BA679B2E1CEC373000F875FA /* Manifest.cpp */; }; - BA679B3D1CEC373000F875FA /* Manifest.cpp in Sources */ = {isa = PBXBuildFile; fileRef = BA679B2E1CEC373000F875FA /* Manifest.cpp */; }; - BA679B3E1CEC373000F875FA /* Manifest.h in Headers */ = {isa = PBXBuildFile; fileRef = BA679B2F1CEC373000F875FA /* Manifest.h */; }; - BA679B3F1CEC373000F875FA /* Manifest.h in Headers */ = {isa = PBXBuildFile; fileRef = BA679B2F1CEC373000F875FA /* Manifest.h */; }; BA68D77D1D62F4A500B7A3F9 /* shapes.cc in Sources */ = {isa = PBXBuildFile; fileRef = BA68D7701D62F4A500B7A3F9 /* shapes.cc */; }; BA68D77E1D62F4A500B7A3F9 /* shapes.cc in Sources */ = {isa = PBXBuildFile; fileRef = BA68D7701D62F4A500B7A3F9 /* shapes.cc */; }; BA68D77F1D62F4A500B7A3F9 /* shapes.h in Headers */ = {isa = PBXBuildFile; fileRef = BA68D7711D62F4A500B7A3F9 /* shapes.h */; }; @@ -1228,164 +695,8 @@ BA68D7991D62F4B600B7A3F9 /* clipper.cpp in Sources */ = {isa = PBXBuildFile; fileRef = BA68D7961D62F4B600B7A3F9 /* clipper.cpp */; }; BA68D79A1D62F4B700B7A3F9 /* clipper.hpp in Headers */ = {isa = PBXBuildFile; fileRef = BA68D7971D62F4B600B7A3F9 /* clipper.hpp */; }; BA68D79B1D62F4B700B7A3F9 /* clipper.hpp in Headers */ = {isa = PBXBuildFile; fileRef = BA68D7971D62F4B600B7A3F9 /* clipper.hpp */; }; - BA8122AB1D77C4150010BEE9 /* CCLabelTTF.cpp in Sources */ = {isa = PBXBuildFile; fileRef = BA8122AA1D77C4150010BEE9 /* CCLabelTTF.cpp */; }; - BA8122AC1D77C4160010BEE9 /* CCLabelTTF.cpp in Sources */ = {isa = PBXBuildFile; fileRef = BA8122AA1D77C4150010BEE9 /* CCLabelTTF.cpp */; }; BAEA45551E279D5C00FA219F /* tinydir.h in Headers */ = {isa = PBXBuildFile; fileRef = BAEA45541E279D5C00FA219F /* tinydir.h */; }; BAEA45561E279D5C00FA219F /* tinydir.h in Headers */ = {isa = PBXBuildFile; fileRef = BAEA45541E279D5C00FA219F /* tinydir.h */; }; - BAFF7D461D5C1CF80051B92F /* Animation.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7CFB1D5C1CF80051B92F /* Animation.c */; }; - BAFF7D471D5C1CF80051B92F /* Animation.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7CFB1D5C1CF80051B92F /* Animation.c */; }; - BAFF7D481D5C1CF80051B92F /* Animation.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7CFC1D5C1CF80051B92F /* Animation.h */; }; - BAFF7D491D5C1CF80051B92F /* Animation.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7CFC1D5C1CF80051B92F /* Animation.h */; }; - BAFF7D4A1D5C1CF80051B92F /* AnimationState.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7CFD1D5C1CF80051B92F /* AnimationState.c */; }; - BAFF7D4B1D5C1CF80051B92F /* AnimationState.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7CFD1D5C1CF80051B92F /* AnimationState.c */; }; - BAFF7D4C1D5C1CF80051B92F /* AnimationState.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7CFE1D5C1CF80051B92F /* AnimationState.h */; }; - BAFF7D4D1D5C1CF80051B92F /* AnimationState.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7CFE1D5C1CF80051B92F /* AnimationState.h */; }; - BAFF7D4E1D5C1CF80051B92F /* AnimationStateData.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7CFF1D5C1CF80051B92F /* AnimationStateData.c */; }; - BAFF7D4F1D5C1CF80051B92F /* AnimationStateData.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7CFF1D5C1CF80051B92F /* AnimationStateData.c */; }; - BAFF7D501D5C1CF80051B92F /* AnimationStateData.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D001D5C1CF80051B92F /* AnimationStateData.h */; }; - BAFF7D511D5C1CF80051B92F /* AnimationStateData.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D001D5C1CF80051B92F /* AnimationStateData.h */; }; - BAFF7D521D5C1CF80051B92F /* Atlas.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D011D5C1CF80051B92F /* Atlas.c */; }; - BAFF7D531D5C1CF80051B92F /* Atlas.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D011D5C1CF80051B92F /* Atlas.c */; }; - BAFF7D541D5C1CF80051B92F /* Atlas.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D021D5C1CF80051B92F /* Atlas.h */; }; - BAFF7D551D5C1CF80051B92F /* Atlas.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D021D5C1CF80051B92F /* Atlas.h */; }; - BAFF7D561D5C1CF80051B92F /* AtlasAttachmentLoader.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D031D5C1CF80051B92F /* AtlasAttachmentLoader.c */; }; - BAFF7D571D5C1CF80051B92F /* AtlasAttachmentLoader.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D031D5C1CF80051B92F /* AtlasAttachmentLoader.c */; }; - BAFF7D581D5C1CF80051B92F /* AtlasAttachmentLoader.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D041D5C1CF80051B92F /* AtlasAttachmentLoader.h */; }; - BAFF7D591D5C1CF80051B92F /* AtlasAttachmentLoader.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D041D5C1CF80051B92F /* AtlasAttachmentLoader.h */; }; - BAFF7D5A1D5C1CF80051B92F /* Attachment.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D051D5C1CF80051B92F /* Attachment.c */; }; - BAFF7D5B1D5C1CF80051B92F /* Attachment.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D051D5C1CF80051B92F /* Attachment.c */; }; - BAFF7D5C1D5C1CF80051B92F /* Attachment.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D061D5C1CF80051B92F /* Attachment.h */; }; - BAFF7D5D1D5C1CF80051B92F /* Attachment.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D061D5C1CF80051B92F /* Attachment.h */; }; - BAFF7D5E1D5C1CF80051B92F /* AttachmentLoader.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D071D5C1CF80051B92F /* AttachmentLoader.c */; }; - BAFF7D5F1D5C1CF80051B92F /* AttachmentLoader.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D071D5C1CF80051B92F /* AttachmentLoader.c */; }; - BAFF7D601D5C1CF80051B92F /* AttachmentLoader.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D081D5C1CF80051B92F /* AttachmentLoader.h */; }; - BAFF7D611D5C1CF80051B92F /* AttachmentLoader.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D081D5C1CF80051B92F /* AttachmentLoader.h */; }; - BAFF7D621D5C1CF80051B92F /* AttachmentVertices.cpp in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D091D5C1CF80051B92F /* AttachmentVertices.cpp */; }; - BAFF7D631D5C1CF80051B92F /* AttachmentVertices.cpp in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D091D5C1CF80051B92F /* AttachmentVertices.cpp */; }; - BAFF7D641D5C1CF80051B92F /* AttachmentVertices.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D0A1D5C1CF80051B92F /* AttachmentVertices.h */; }; - BAFF7D651D5C1CF80051B92F /* AttachmentVertices.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D0A1D5C1CF80051B92F /* AttachmentVertices.h */; }; - BAFF7D661D5C1CF80051B92F /* Bone.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D0B1D5C1CF80051B92F /* Bone.c */; }; - BAFF7D671D5C1CF80051B92F /* Bone.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D0B1D5C1CF80051B92F /* Bone.c */; }; - BAFF7D681D5C1CF80051B92F /* Bone.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D0C1D5C1CF80051B92F /* Bone.h */; }; - BAFF7D691D5C1CF80051B92F /* Bone.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D0C1D5C1CF80051B92F /* Bone.h */; }; - BAFF7D6A1D5C1CF80051B92F /* BoneData.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D0D1D5C1CF80051B92F /* BoneData.c */; }; - BAFF7D6B1D5C1CF80051B92F /* BoneData.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D0D1D5C1CF80051B92F /* BoneData.c */; }; - BAFF7D6C1D5C1CF80051B92F /* BoneData.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D0E1D5C1CF80051B92F /* BoneData.h */; }; - BAFF7D6D1D5C1CF80051B92F /* BoneData.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D0E1D5C1CF80051B92F /* BoneData.h */; }; - BAFF7D6E1D5C1CF80051B92F /* BoundingBoxAttachment.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D0F1D5C1CF80051B92F /* BoundingBoxAttachment.c */; }; - BAFF7D6F1D5C1CF80051B92F /* BoundingBoxAttachment.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D0F1D5C1CF80051B92F /* BoundingBoxAttachment.c */; }; - BAFF7D701D5C1CF80051B92F /* BoundingBoxAttachment.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D101D5C1CF80051B92F /* BoundingBoxAttachment.h */; }; - BAFF7D711D5C1CF80051B92F /* BoundingBoxAttachment.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D101D5C1CF80051B92F /* BoundingBoxAttachment.h */; }; - BAFF7D721D5C1CF80051B92F /* Cocos2dAttachmentLoader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D111D5C1CF80051B92F /* Cocos2dAttachmentLoader.cpp */; }; - BAFF7D731D5C1CF80051B92F /* Cocos2dAttachmentLoader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D111D5C1CF80051B92F /* Cocos2dAttachmentLoader.cpp */; }; - BAFF7D741D5C1CF80051B92F /* Cocos2dAttachmentLoader.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D121D5C1CF80051B92F /* Cocos2dAttachmentLoader.h */; }; - BAFF7D751D5C1CF80051B92F /* Cocos2dAttachmentLoader.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D121D5C1CF80051B92F /* Cocos2dAttachmentLoader.h */; }; - BAFF7D761D5C1CF80051B92F /* Event.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D131D5C1CF80051B92F /* Event.c */; }; - BAFF7D771D5C1CF80051B92F /* Event.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D131D5C1CF80051B92F /* Event.c */; }; - BAFF7D781D5C1CF80051B92F /* Event.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D141D5C1CF80051B92F /* Event.h */; }; - BAFF7D791D5C1CF80051B92F /* Event.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D141D5C1CF80051B92F /* Event.h */; }; - BAFF7D7A1D5C1CF80051B92F /* EventData.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D151D5C1CF80051B92F /* EventData.c */; }; - BAFF7D7B1D5C1CF80051B92F /* EventData.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D151D5C1CF80051B92F /* EventData.c */; }; - BAFF7D7C1D5C1CF80051B92F /* EventData.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D161D5C1CF80051B92F /* EventData.h */; }; - BAFF7D7D1D5C1CF80051B92F /* EventData.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D161D5C1CF80051B92F /* EventData.h */; }; - BAFF7D7E1D5C1CF80051B92F /* extension.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D171D5C1CF80051B92F /* extension.c */; }; - BAFF7D7F1D5C1CF80051B92F /* extension.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D171D5C1CF80051B92F /* extension.c */; }; - BAFF7D801D5C1CF80051B92F /* extension.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D181D5C1CF80051B92F /* extension.h */; }; - BAFF7D811D5C1CF80051B92F /* extension.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D181D5C1CF80051B92F /* extension.h */; }; - BAFF7D821D5C1CF80051B92F /* IkConstraint.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D191D5C1CF80051B92F /* IkConstraint.c */; }; - BAFF7D831D5C1CF80051B92F /* IkConstraint.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D191D5C1CF80051B92F /* IkConstraint.c */; }; - BAFF7D841D5C1CF80051B92F /* IkConstraint.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D1A1D5C1CF80051B92F /* IkConstraint.h */; }; - BAFF7D851D5C1CF80051B92F /* IkConstraint.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D1A1D5C1CF80051B92F /* IkConstraint.h */; }; - BAFF7D861D5C1CF80051B92F /* IkConstraintData.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D1B1D5C1CF80051B92F /* IkConstraintData.c */; }; - BAFF7D871D5C1CF80051B92F /* IkConstraintData.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D1B1D5C1CF80051B92F /* IkConstraintData.c */; }; - BAFF7D881D5C1CF80051B92F /* IkConstraintData.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D1C1D5C1CF80051B92F /* IkConstraintData.h */; }; - BAFF7D891D5C1CF80051B92F /* IkConstraintData.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D1C1D5C1CF80051B92F /* IkConstraintData.h */; }; - BAFF7D8A1D5C1CF80051B92F /* Json.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D1D1D5C1CF80051B92F /* Json.c */; }; - BAFF7D8B1D5C1CF80051B92F /* Json.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D1D1D5C1CF80051B92F /* Json.c */; }; - BAFF7D8C1D5C1CF80051B92F /* Json.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D1E1D5C1CF80051B92F /* Json.h */; }; - BAFF7D8D1D5C1CF80051B92F /* Json.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D1E1D5C1CF80051B92F /* Json.h */; }; - BAFF7D8E1D5C1CF80051B92F /* MeshAttachment.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D1F1D5C1CF80051B92F /* MeshAttachment.c */; }; - BAFF7D8F1D5C1CF80051B92F /* MeshAttachment.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D1F1D5C1CF80051B92F /* MeshAttachment.c */; }; - BAFF7D901D5C1CF80051B92F /* MeshAttachment.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D201D5C1CF80051B92F /* MeshAttachment.h */; }; - BAFF7D911D5C1CF80051B92F /* MeshAttachment.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D201D5C1CF80051B92F /* MeshAttachment.h */; }; - BAFF7D921D5C1CF80051B92F /* PathAttachment.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D211D5C1CF80051B92F /* PathAttachment.c */; }; - BAFF7D931D5C1CF80051B92F /* PathAttachment.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D211D5C1CF80051B92F /* PathAttachment.c */; }; - BAFF7D941D5C1CF80051B92F /* PathAttachment.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D221D5C1CF80051B92F /* PathAttachment.h */; }; - BAFF7D951D5C1CF80051B92F /* PathAttachment.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D221D5C1CF80051B92F /* PathAttachment.h */; }; - BAFF7D961D5C1CF80051B92F /* PathConstraint.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D231D5C1CF80051B92F /* PathConstraint.c */; }; - BAFF7D971D5C1CF80051B92F /* PathConstraint.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D231D5C1CF80051B92F /* PathConstraint.c */; }; - BAFF7D981D5C1CF80051B92F /* PathConstraint.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D241D5C1CF80051B92F /* PathConstraint.h */; }; - BAFF7D991D5C1CF80051B92F /* PathConstraint.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D241D5C1CF80051B92F /* PathConstraint.h */; }; - BAFF7D9A1D5C1CF80051B92F /* PathConstraintData.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D251D5C1CF80051B92F /* PathConstraintData.c */; }; - BAFF7D9B1D5C1CF80051B92F /* PathConstraintData.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D251D5C1CF80051B92F /* PathConstraintData.c */; }; - BAFF7D9C1D5C1CF80051B92F /* PathConstraintData.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D261D5C1CF80051B92F /* PathConstraintData.h */; }; - BAFF7D9D1D5C1CF80051B92F /* PathConstraintData.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D261D5C1CF80051B92F /* PathConstraintData.h */; }; - BAFF7D9E1D5C1CF80051B92F /* RegionAttachment.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D271D5C1CF80051B92F /* RegionAttachment.c */; }; - BAFF7D9F1D5C1CF80051B92F /* RegionAttachment.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D271D5C1CF80051B92F /* RegionAttachment.c */; }; - BAFF7DA01D5C1CF80051B92F /* RegionAttachment.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D281D5C1CF80051B92F /* RegionAttachment.h */; }; - BAFF7DA11D5C1CF80051B92F /* RegionAttachment.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D281D5C1CF80051B92F /* RegionAttachment.h */; }; - BAFF7DA21D5C1CF80051B92F /* Skeleton.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D291D5C1CF80051B92F /* Skeleton.c */; }; - BAFF7DA31D5C1CF80051B92F /* Skeleton.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D291D5C1CF80051B92F /* Skeleton.c */; }; - BAFF7DA41D5C1CF80051B92F /* Skeleton.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D2A1D5C1CF80051B92F /* Skeleton.h */; }; - BAFF7DA51D5C1CF80051B92F /* Skeleton.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D2A1D5C1CF80051B92F /* Skeleton.h */; }; - BAFF7DA61D5C1CF80051B92F /* SkeletonAnimation.cpp in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D2B1D5C1CF80051B92F /* SkeletonAnimation.cpp */; }; - BAFF7DA71D5C1CF80051B92F /* SkeletonAnimation.cpp in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D2B1D5C1CF80051B92F /* SkeletonAnimation.cpp */; }; - BAFF7DA81D5C1CF80051B92F /* SkeletonAnimation.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D2C1D5C1CF80051B92F /* SkeletonAnimation.h */; }; - BAFF7DA91D5C1CF80051B92F /* SkeletonAnimation.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D2C1D5C1CF80051B92F /* SkeletonAnimation.h */; }; - BAFF7DAA1D5C1CF80051B92F /* SkeletonBatch.cpp in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D2D1D5C1CF80051B92F /* SkeletonBatch.cpp */; }; - BAFF7DAB1D5C1CF80051B92F /* SkeletonBatch.cpp in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D2D1D5C1CF80051B92F /* SkeletonBatch.cpp */; }; - BAFF7DAC1D5C1CF80051B92F /* SkeletonBatch.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D2E1D5C1CF80051B92F /* SkeletonBatch.h */; }; - BAFF7DAD1D5C1CF80051B92F /* SkeletonBatch.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D2E1D5C1CF80051B92F /* SkeletonBatch.h */; }; - BAFF7DAE1D5C1CF80051B92F /* SkeletonBounds.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D2F1D5C1CF80051B92F /* SkeletonBounds.c */; }; - BAFF7DAF1D5C1CF80051B92F /* SkeletonBounds.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D2F1D5C1CF80051B92F /* SkeletonBounds.c */; }; - BAFF7DB01D5C1CF80051B92F /* SkeletonBounds.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D301D5C1CF80051B92F /* SkeletonBounds.h */; }; - BAFF7DB11D5C1CF80051B92F /* SkeletonBounds.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D301D5C1CF80051B92F /* SkeletonBounds.h */; }; - BAFF7DB21D5C1CF80051B92F /* SkeletonData.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D311D5C1CF80051B92F /* SkeletonData.c */; }; - BAFF7DB31D5C1CF80051B92F /* SkeletonData.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D311D5C1CF80051B92F /* SkeletonData.c */; }; - BAFF7DB41D5C1CF80051B92F /* SkeletonData.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D321D5C1CF80051B92F /* SkeletonData.h */; }; - BAFF7DB51D5C1CF80051B92F /* SkeletonData.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D321D5C1CF80051B92F /* SkeletonData.h */; }; - BAFF7DB61D5C1CF80051B92F /* SkeletonJson.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D331D5C1CF80051B92F /* SkeletonJson.c */; }; - BAFF7DB71D5C1CF80051B92F /* SkeletonJson.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D331D5C1CF80051B92F /* SkeletonJson.c */; }; - BAFF7DB81D5C1CF80051B92F /* SkeletonJson.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D341D5C1CF80051B92F /* SkeletonJson.h */; }; - BAFF7DB91D5C1CF80051B92F /* SkeletonJson.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D341D5C1CF80051B92F /* SkeletonJson.h */; }; - BAFF7DBA1D5C1CF80051B92F /* SkeletonRenderer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D351D5C1CF80051B92F /* SkeletonRenderer.cpp */; }; - BAFF7DBB1D5C1CF80051B92F /* SkeletonRenderer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D351D5C1CF80051B92F /* SkeletonRenderer.cpp */; }; - BAFF7DBC1D5C1CF80051B92F /* SkeletonRenderer.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D361D5C1CF80051B92F /* SkeletonRenderer.h */; }; - BAFF7DBD1D5C1CF80051B92F /* SkeletonRenderer.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D361D5C1CF80051B92F /* SkeletonRenderer.h */; }; - BAFF7DBE1D5C1CF80051B92F /* Skin.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D371D5C1CF80051B92F /* Skin.c */; }; - BAFF7DBF1D5C1CF80051B92F /* Skin.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D371D5C1CF80051B92F /* Skin.c */; }; - BAFF7DC01D5C1CF80051B92F /* Skin.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D381D5C1CF80051B92F /* Skin.h */; }; - BAFF7DC11D5C1CF80051B92F /* Skin.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D381D5C1CF80051B92F /* Skin.h */; }; - BAFF7DC21D5C1CF80051B92F /* Slot.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D391D5C1CF80051B92F /* Slot.c */; }; - BAFF7DC31D5C1CF80051B92F /* Slot.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D391D5C1CF80051B92F /* Slot.c */; }; - BAFF7DC41D5C1CF80051B92F /* Slot.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D3A1D5C1CF80051B92F /* Slot.h */; }; - BAFF7DC51D5C1CF80051B92F /* Slot.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D3A1D5C1CF80051B92F /* Slot.h */; }; - BAFF7DC61D5C1CF80051B92F /* SlotData.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D3B1D5C1CF80051B92F /* SlotData.c */; }; - BAFF7DC71D5C1CF80051B92F /* SlotData.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D3B1D5C1CF80051B92F /* SlotData.c */; }; - BAFF7DC81D5C1CF80051B92F /* SlotData.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D3C1D5C1CF80051B92F /* SlotData.h */; }; - BAFF7DC91D5C1CF80051B92F /* SlotData.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D3C1D5C1CF80051B92F /* SlotData.h */; }; - BAFF7DCA1D5C1CF80051B92F /* spine-cocos2dx.cpp in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D3D1D5C1CF80051B92F /* spine-cocos2dx.cpp */; }; - BAFF7DCB1D5C1CF80051B92F /* spine-cocos2dx.cpp in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D3D1D5C1CF80051B92F /* spine-cocos2dx.cpp */; }; - BAFF7DCC1D5C1CF80051B92F /* spine-cocos2dx.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D3E1D5C1CF80051B92F /* spine-cocos2dx.h */; }; - BAFF7DCD1D5C1CF80051B92F /* spine-cocos2dx.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D3E1D5C1CF80051B92F /* spine-cocos2dx.h */; }; - BAFF7DCE1D5C1CF80051B92F /* spine.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D3F1D5C1CF80051B92F /* spine.h */; }; - BAFF7DCF1D5C1CF80051B92F /* spine.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D3F1D5C1CF80051B92F /* spine.h */; }; - BAFF7DD01D5C1CF80051B92F /* TransformConstraint.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D401D5C1CF80051B92F /* TransformConstraint.c */; }; - BAFF7DD11D5C1CF80051B92F /* TransformConstraint.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D401D5C1CF80051B92F /* TransformConstraint.c */; }; - BAFF7DD21D5C1CF80051B92F /* TransformConstraint.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D411D5C1CF80051B92F /* TransformConstraint.h */; }; - BAFF7DD31D5C1CF80051B92F /* TransformConstraint.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D411D5C1CF80051B92F /* TransformConstraint.h */; }; - BAFF7DD41D5C1CF80051B92F /* TransformConstraintData.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D421D5C1CF80051B92F /* TransformConstraintData.c */; }; - BAFF7DD51D5C1CF80051B92F /* TransformConstraintData.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D421D5C1CF80051B92F /* TransformConstraintData.c */; }; - BAFF7DD61D5C1CF80051B92F /* TransformConstraintData.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D431D5C1CF80051B92F /* TransformConstraintData.h */; }; - BAFF7DD71D5C1CF80051B92F /* TransformConstraintData.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D431D5C1CF80051B92F /* TransformConstraintData.h */; }; - BAFF7DD81D5C1CF80051B92F /* VertexAttachment.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D441D5C1CF80051B92F /* VertexAttachment.c */; }; - BAFF7DD91D5C1CF80051B92F /* VertexAttachment.c in Sources */ = {isa = PBXBuildFile; fileRef = BAFF7D441D5C1CF80051B92F /* VertexAttachment.c */; }; - BAFF7DDA1D5C1CF80051B92F /* VertexAttachment.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D451D5C1CF80051B92F /* VertexAttachment.h */; }; - BAFF7DDB1D5C1CF80051B92F /* VertexAttachment.h in Headers */ = {isa = PBXBuildFile; fileRef = BAFF7D451D5C1CF80051B92F /* VertexAttachment.h */; }; - DABC9FA919E7DFA900FA252C /* CCClippingRectangleNode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = DABC9FA719E7DFA900FA252C /* CCClippingRectangleNode.cpp */; }; - DABC9FAA19E7DFA900FA252C /* CCClippingRectangleNode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = DABC9FA719E7DFA900FA252C /* CCClippingRectangleNode.cpp */; }; - DABC9FAB19E7DFA900FA252C /* CCClippingRectangleNode.h in Headers */ = {isa = PBXBuildFile; fileRef = DABC9FA819E7DFA900FA252C /* CCClippingRectangleNode.h */; }; - DABC9FAC19E7DFA900FA252C /* CCClippingRectangleNode.h in Headers */ = {isa = PBXBuildFile; fileRef = DABC9FA819E7DFA900FA252C /* CCClippingRectangleNode.h */; }; ED30577D1BEC76C90083C3ED /* crypt.h in Headers */ = {isa = PBXBuildFile; fileRef = ED3057761BEC76C90083C3ED /* crypt.h */; }; ED30577E1BEC76C90083C3ED /* ioapi_mem.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED3057771BEC76C90083C3ED /* ioapi_mem.cpp */; }; ED30577F1BEC76C90083C3ED /* ioapi_mem.h in Headers */ = {isa = PBXBuildFile; fileRef = ED3057781BEC76C90083C3ED /* ioapi_mem.h */; }; @@ -1417,147 +728,12 @@ ED3057D21BEC7DA80083C3ED /* libtiff.a in Frameworks */ = {isa = PBXBuildFile; fileRef = ED3057CC1BEC7DA80083C3ED /* libtiff.a */; }; ED3057D31BEC7DA80083C3ED /* libwebsockets.a in Frameworks */ = {isa = PBXBuildFile; fileRef = ED3057CD1BEC7DA80083C3ED /* libwebsockets.a */; }; ED6822341BECB14500ED75EA /* libfreetype.a in Frameworks */ = {isa = PBXBuildFile; fileRef = ED3057BE1BEC78580083C3ED /* libfreetype.a */; }; - ED9C6A9418599AD8000A5232 /* CCNodeGrid.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED9C6A9218599AD8000A5232 /* CCNodeGrid.cpp */; }; - ED9C6A9518599AD8000A5232 /* CCNodeGrid.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED9C6A9218599AD8000A5232 /* CCNodeGrid.cpp */; }; - ED9C6A9618599AD8000A5232 /* CCNodeGrid.h in Headers */ = {isa = PBXBuildFile; fileRef = ED9C6A9318599AD8000A5232 /* CCNodeGrid.h */; }; - ED9C6A9718599AD8000A5232 /* CCNodeGrid.h in Headers */ = {isa = PBXBuildFile; fileRef = ED9C6A9318599AD8000A5232 /* CCNodeGrid.h */; }; EDE5DFF81C0D6B3F0014147A /* libwebsockets.a in Frameworks */ = {isa = PBXBuildFile; fileRef = EDE5DFF71C0D6B3F0014147A /* libwebsockets.a */; }; - FA6F1B411D80F858007DD223 /* Animation.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1AF91D80F858007DD223 /* Animation.cpp */; }; - FA6F1B421D80F858007DD223 /* Animation.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1AF91D80F858007DD223 /* Animation.cpp */; }; - FA6F1B431D80F858007DD223 /* Animation.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1AFA1D80F858007DD223 /* Animation.h */; }; - FA6F1B441D80F858007DD223 /* Animation.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1AFA1D80F858007DD223 /* Animation.h */; }; - FA6F1B451D80F858007DD223 /* AnimationState.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1AFB1D80F858007DD223 /* AnimationState.cpp */; }; - FA6F1B461D80F858007DD223 /* AnimationState.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1AFB1D80F858007DD223 /* AnimationState.cpp */; }; - FA6F1B471D80F858007DD223 /* AnimationState.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1AFC1D80F858007DD223 /* AnimationState.h */; }; - FA6F1B481D80F858007DD223 /* AnimationState.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1AFC1D80F858007DD223 /* AnimationState.h */; }; - FA6F1B491D80F858007DD223 /* BaseTimelineState.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1AFD1D80F858007DD223 /* BaseTimelineState.h */; }; - FA6F1B4A1D80F858007DD223 /* BaseTimelineState.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1AFD1D80F858007DD223 /* BaseTimelineState.h */; }; - FA6F1B4B1D80F858007DD223 /* IAnimateble.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1AFE1D80F858007DD223 /* IAnimateble.h */; }; - FA6F1B4C1D80F858007DD223 /* IAnimateble.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1AFE1D80F858007DD223 /* IAnimateble.h */; }; - FA6F1B4D1D80F858007DD223 /* TimelineState.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1AFF1D80F858007DD223 /* TimelineState.cpp */; }; - FA6F1B4E1D80F858007DD223 /* TimelineState.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1AFF1D80F858007DD223 /* TimelineState.cpp */; }; - FA6F1B4F1D80F858007DD223 /* TimelineState.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B001D80F858007DD223 /* TimelineState.h */; }; - FA6F1B501D80F858007DD223 /* TimelineState.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B001D80F858007DD223 /* TimelineState.h */; }; - FA6F1B511D80F858007DD223 /* WorldClock.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1B011D80F858007DD223 /* WorldClock.cpp */; }; - FA6F1B521D80F858007DD223 /* WorldClock.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1B011D80F858007DD223 /* WorldClock.cpp */; }; - FA6F1B531D80F858007DD223 /* WorldClock.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B021D80F858007DD223 /* WorldClock.h */; }; - FA6F1B541D80F858007DD223 /* WorldClock.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B021D80F858007DD223 /* WorldClock.h */; }; - FA6F1B551D80F858007DD223 /* Armature.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1B041D80F858007DD223 /* Armature.cpp */; }; - FA6F1B561D80F858007DD223 /* Armature.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1B041D80F858007DD223 /* Armature.cpp */; }; - FA6F1B571D80F858007DD223 /* Armature.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B051D80F858007DD223 /* Armature.h */; }; - FA6F1B581D80F858007DD223 /* Armature.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B051D80F858007DD223 /* Armature.h */; }; - FA6F1B591D80F858007DD223 /* Bone.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1B061D80F858007DD223 /* Bone.cpp */; }; - FA6F1B5A1D80F858007DD223 /* Bone.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1B061D80F858007DD223 /* Bone.cpp */; }; - FA6F1B5B1D80F858007DD223 /* Bone.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B071D80F858007DD223 /* Bone.h */; }; - FA6F1B5C1D80F858007DD223 /* Bone.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B071D80F858007DD223 /* Bone.h */; }; - FA6F1B5D1D80F858007DD223 /* IArmatureDisplay.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B081D80F858007DD223 /* IArmatureDisplay.h */; }; - FA6F1B5E1D80F858007DD223 /* IArmatureDisplay.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B081D80F858007DD223 /* IArmatureDisplay.h */; }; - FA6F1B5F1D80F858007DD223 /* Slot.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1B091D80F858007DD223 /* Slot.cpp */; }; - FA6F1B601D80F858007DD223 /* Slot.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1B091D80F858007DD223 /* Slot.cpp */; }; - FA6F1B611D80F858007DD223 /* Slot.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B0A1D80F858007DD223 /* Slot.h */; }; - FA6F1B621D80F858007DD223 /* Slot.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B0A1D80F858007DD223 /* Slot.h */; }; - FA6F1B631D80F858007DD223 /* TransformObject.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B0B1D80F858007DD223 /* TransformObject.h */; }; - FA6F1B641D80F858007DD223 /* TransformObject.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B0B1D80F858007DD223 /* TransformObject.h */; }; - FA6F1B651D80F858007DD223 /* CCArmatureDisplay.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1B0D1D80F858007DD223 /* CCArmatureDisplay.cpp */; }; - FA6F1B661D80F858007DD223 /* CCArmatureDisplay.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1B0D1D80F858007DD223 /* CCArmatureDisplay.cpp */; }; - FA6F1B671D80F858007DD223 /* CCArmatureDisplay.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B0E1D80F858007DD223 /* CCArmatureDisplay.h */; }; - FA6F1B681D80F858007DD223 /* CCArmatureDisplay.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B0E1D80F858007DD223 /* CCArmatureDisplay.h */; }; - FA6F1B691D80F858007DD223 /* CCDragonBonesHeaders.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B0F1D80F858007DD223 /* CCDragonBonesHeaders.h */; }; - FA6F1B6A1D80F858007DD223 /* CCDragonBonesHeaders.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B0F1D80F858007DD223 /* CCDragonBonesHeaders.h */; }; - FA6F1B6B1D80F858007DD223 /* CCFactory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1B101D80F858007DD223 /* CCFactory.cpp */; }; - FA6F1B6C1D80F858007DD223 /* CCFactory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1B101D80F858007DD223 /* CCFactory.cpp */; }; - FA6F1B6D1D80F858007DD223 /* CCFactory.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B111D80F858007DD223 /* CCFactory.h */; }; - FA6F1B6E1D80F858007DD223 /* CCFactory.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B111D80F858007DD223 /* CCFactory.h */; }; - FA6F1B6F1D80F858007DD223 /* CCSlot.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1B121D80F858007DD223 /* CCSlot.cpp */; }; - FA6F1B701D80F858007DD223 /* CCSlot.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1B121D80F858007DD223 /* CCSlot.cpp */; }; - FA6F1B711D80F858007DD223 /* CCSlot.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B131D80F858007DD223 /* CCSlot.h */; }; - FA6F1B721D80F858007DD223 /* CCSlot.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B131D80F858007DD223 /* CCSlot.h */; }; - FA6F1B731D80F858007DD223 /* CCTextureData.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1B141D80F858007DD223 /* CCTextureData.cpp */; }; - FA6F1B741D80F858007DD223 /* CCTextureData.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1B141D80F858007DD223 /* CCTextureData.cpp */; }; - FA6F1B751D80F858007DD223 /* CCTextureData.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B151D80F858007DD223 /* CCTextureData.h */; }; - FA6F1B761D80F858007DD223 /* CCTextureData.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B151D80F858007DD223 /* CCTextureData.h */; }; - FA6F1B771D80F858007DD223 /* BaseObject.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1B171D80F858007DD223 /* BaseObject.cpp */; }; - FA6F1B781D80F858007DD223 /* BaseObject.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1B171D80F858007DD223 /* BaseObject.cpp */; }; - FA6F1B791D80F858007DD223 /* BaseObject.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B181D80F858007DD223 /* BaseObject.h */; }; - FA6F1B7A1D80F858007DD223 /* BaseObject.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B181D80F858007DD223 /* BaseObject.h */; }; - FA6F1B7B1D80F858007DD223 /* DragonBones.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B191D80F858007DD223 /* DragonBones.h */; }; - FA6F1B7C1D80F858007DD223 /* DragonBones.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B191D80F858007DD223 /* DragonBones.h */; }; - FA6F1B7D1D80F858007DD223 /* DragonBonesHeaders.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B1A1D80F858007DD223 /* DragonBonesHeaders.h */; }; - FA6F1B7E1D80F858007DD223 /* DragonBonesHeaders.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B1A1D80F858007DD223 /* DragonBonesHeaders.h */; }; - FA6F1B7F1D80F858007DD223 /* EventObject.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1B1C1D80F858007DD223 /* EventObject.cpp */; }; - FA6F1B801D80F858007DD223 /* EventObject.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1B1C1D80F858007DD223 /* EventObject.cpp */; }; - FA6F1B811D80F858007DD223 /* EventObject.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B1D1D80F858007DD223 /* EventObject.h */; }; - FA6F1B821D80F858007DD223 /* EventObject.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B1D1D80F858007DD223 /* EventObject.h */; }; - FA6F1B831D80F858007DD223 /* BaseFactory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1B1F1D80F858007DD223 /* BaseFactory.cpp */; }; - FA6F1B841D80F858007DD223 /* BaseFactory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1B1F1D80F858007DD223 /* BaseFactory.cpp */; }; - FA6F1B851D80F858007DD223 /* BaseFactory.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B201D80F858007DD223 /* BaseFactory.h */; }; - FA6F1B861D80F858007DD223 /* BaseFactory.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B201D80F858007DD223 /* BaseFactory.h */; }; - FA6F1B871D80F858007DD223 /* ColorTransform.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B221D80F858007DD223 /* ColorTransform.h */; }; - FA6F1B881D80F858007DD223 /* ColorTransform.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B221D80F858007DD223 /* ColorTransform.h */; }; - FA6F1B891D80F858007DD223 /* Matrix.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B231D80F858007DD223 /* Matrix.h */; }; - FA6F1B8A1D80F858007DD223 /* Matrix.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B231D80F858007DD223 /* Matrix.h */; }; - FA6F1B8B1D80F858007DD223 /* Point.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B241D80F858007DD223 /* Point.h */; }; - FA6F1B8C1D80F858007DD223 /* Point.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B241D80F858007DD223 /* Point.h */; }; - FA6F1B8D1D80F858007DD223 /* Rectangle.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B251D80F858007DD223 /* Rectangle.h */; }; - FA6F1B8E1D80F858007DD223 /* Rectangle.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B251D80F858007DD223 /* Rectangle.h */; }; - FA6F1B8F1D80F858007DD223 /* Transform.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B261D80F858007DD223 /* Transform.h */; }; - FA6F1B901D80F858007DD223 /* Transform.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B261D80F858007DD223 /* Transform.h */; }; - FA6F1B911D80F858007DD223 /* AnimationData.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1B281D80F858007DD223 /* AnimationData.cpp */; }; - FA6F1B921D80F858007DD223 /* AnimationData.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1B281D80F858007DD223 /* AnimationData.cpp */; }; - FA6F1B931D80F858007DD223 /* AnimationData.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B291D80F858007DD223 /* AnimationData.h */; }; - FA6F1B941D80F858007DD223 /* AnimationData.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B291D80F858007DD223 /* AnimationData.h */; }; - FA6F1B951D80F858007DD223 /* ArmatureData.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1B2A1D80F858007DD223 /* ArmatureData.cpp */; }; - FA6F1B961D80F858007DD223 /* ArmatureData.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1B2A1D80F858007DD223 /* ArmatureData.cpp */; }; - FA6F1B971D80F858007DD223 /* ArmatureData.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B2B1D80F858007DD223 /* ArmatureData.h */; }; - FA6F1B981D80F858007DD223 /* ArmatureData.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B2B1D80F858007DD223 /* ArmatureData.h */; }; - FA6F1B991D80F858007DD223 /* DragonBonesData.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1B2C1D80F858007DD223 /* DragonBonesData.cpp */; }; - FA6F1B9A1D80F858007DD223 /* DragonBonesData.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1B2C1D80F858007DD223 /* DragonBonesData.cpp */; }; - FA6F1B9B1D80F858007DD223 /* DragonBonesData.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B2D1D80F858007DD223 /* DragonBonesData.h */; }; - FA6F1B9C1D80F858007DD223 /* DragonBonesData.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B2D1D80F858007DD223 /* DragonBonesData.h */; }; - FA6F1B9D1D80F858007DD223 /* FrameData.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1B2E1D80F858007DD223 /* FrameData.cpp */; }; - FA6F1B9E1D80F858007DD223 /* FrameData.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1B2E1D80F858007DD223 /* FrameData.cpp */; }; - FA6F1B9F1D80F858007DD223 /* FrameData.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B2F1D80F858007DD223 /* FrameData.h */; }; - FA6F1BA01D80F858007DD223 /* FrameData.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B2F1D80F858007DD223 /* FrameData.h */; }; - FA6F1BA11D80F858007DD223 /* TimelineData.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1B301D80F858007DD223 /* TimelineData.cpp */; }; - FA6F1BA21D80F858007DD223 /* TimelineData.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1B301D80F858007DD223 /* TimelineData.cpp */; }; - FA6F1BA31D80F858007DD223 /* TimelineData.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B311D80F858007DD223 /* TimelineData.h */; }; - FA6F1BA41D80F858007DD223 /* TimelineData.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B311D80F858007DD223 /* TimelineData.h */; }; - FA6F1BA51D80F858007DD223 /* DataParser.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1B331D80F858007DD223 /* DataParser.cpp */; }; - FA6F1BA61D80F858007DD223 /* DataParser.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1B331D80F858007DD223 /* DataParser.cpp */; }; - FA6F1BA71D80F858007DD223 /* DataParser.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B341D80F858007DD223 /* DataParser.h */; }; - FA6F1BA81D80F858007DD223 /* DataParser.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B341D80F858007DD223 /* DataParser.h */; }; - FA6F1BA91D80F858007DD223 /* JSONDataParser.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1B351D80F858007DD223 /* JSONDataParser.cpp */; }; - FA6F1BAA1D80F858007DD223 /* JSONDataParser.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1B351D80F858007DD223 /* JSONDataParser.cpp */; }; - FA6F1BAB1D80F858007DD223 /* JSONDataParser.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B361D80F858007DD223 /* JSONDataParser.h */; }; - FA6F1BAC1D80F858007DD223 /* JSONDataParser.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B361D80F858007DD223 /* JSONDataParser.h */; }; - FA6F1BAD1D80F858007DD223 /* TextureData.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1B3F1D80F858007DD223 /* TextureData.cpp */; }; - FA6F1BAE1D80F858007DD223 /* TextureData.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FA6F1B3F1D80F858007DD223 /* TextureData.cpp */; }; - FA6F1BAF1D80F858007DD223 /* TextureData.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B401D80F858007DD223 /* TextureData.h */; }; - FA6F1BB01D80F858007DD223 /* TextureData.h in Headers */ = {isa = PBXBuildFile; fileRef = FA6F1B401D80F858007DD223 /* TextureData.h */; }; - FAC8F25C1D339EB70061CEDD /* CCTMXLayer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FAC8F2581D339EB70061CEDD /* CCTMXLayer.cpp */; }; - FAC8F25D1D339EB70061CEDD /* CCTMXLayer.h in Headers */ = {isa = PBXBuildFile; fileRef = FAC8F2591D339EB70061CEDD /* CCTMXLayer.h */; }; - FAC8F25E1D339EB70061CEDD /* CCTMXTiledMap.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FAC8F25A1D339EB70061CEDD /* CCTMXTiledMap.cpp */; }; - FAC8F25F1D339EB70061CEDD /* CCTMXTiledMap.h in Headers */ = {isa = PBXBuildFile; fileRef = FAC8F25B1D339EB70061CEDD /* CCTMXTiledMap.h */; }; - FAC8F2601D339EBF0061CEDD /* CCTMXLayer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FAC8F2581D339EB70061CEDD /* CCTMXLayer.cpp */; }; - FAC8F2611D339EC20061CEDD /* CCTMXLayer.h in Headers */ = {isa = PBXBuildFile; fileRef = FAC8F2591D339EB70061CEDD /* CCTMXLayer.h */; }; - FAC8F2621D339EC50061CEDD /* CCTMXTiledMap.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FAC8F25A1D339EB70061CEDD /* CCTMXTiledMap.cpp */; }; - FAC8F2631D339EC80061CEDD /* CCTMXTiledMap.h in Headers */ = {isa = PBXBuildFile; fileRef = FAC8F25B1D339EB70061CEDD /* CCTMXTiledMap.h */; }; - FAC8F6681E1DF15D002B17E8 /* kvec.h in Headers */ = {isa = PBXBuildFile; fileRef = FAC8F6651E1DF15D002B17E8 /* kvec.h */; }; - FAC8F6691E1DF15D002B17E8 /* kvec.h in Headers */ = {isa = PBXBuildFile; fileRef = FAC8F6651E1DF15D002B17E8 /* kvec.h */; }; - FAC8F66A1E1DF15D002B17E8 /* SkeletonBinary.c in Sources */ = {isa = PBXBuildFile; fileRef = FAC8F6661E1DF15D002B17E8 /* SkeletonBinary.c */; }; - FAC8F66B1E1DF15D002B17E8 /* SkeletonBinary.c in Sources */ = {isa = PBXBuildFile; fileRef = FAC8F6661E1DF15D002B17E8 /* SkeletonBinary.c */; }; - FAC8F66C1E1DF15D002B17E8 /* SkeletonBinary.h in Headers */ = {isa = PBXBuildFile; fileRef = FAC8F6671E1DF15D002B17E8 /* SkeletonBinary.h */; }; - FAC8F66D1E1DF15D002B17E8 /* SkeletonBinary.h in Headers */ = {isa = PBXBuildFile; fileRef = FAC8F6671E1DF15D002B17E8 /* SkeletonBinary.h */; }; /* End PBXBuildFile section */ /* Begin PBXFileReference section */ 1551A33F158F2AB200E66CFE /* libcocos2d Mac.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libcocos2d Mac.a"; sourceTree = BUILT_PRODUCTS_DIR; }; 1551A342158F2AB200E66CFE /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; }; - 15EFA20F198A2BB5000C57D3 /* CCProtectedNode.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCProtectedNode.cpp; sourceTree = ""; }; - 15EFA210198A2BB5000C57D3 /* CCProtectedNode.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCProtectedNode.h; sourceTree = ""; }; - 15FB20721AE7BF8600C31518 /* CCAutoPolygon.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCAutoPolygon.cpp; sourceTree = ""; }; - 15FB20731AE7BF8600C31518 /* CCAutoPolygon.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCAutoPolygon.h; sourceTree = ""; }; - 1A28FF191F20AF94007A1D9D /* WebSocket-apple.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = "WebSocket-apple.mm"; sourceTree = ""; }; 1A28FF1F1F20AFAB007A1D9D /* SRDelegateController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SRDelegateController.h; sourceTree = ""; }; 1A28FF201F20AFAB007A1D9D /* SRDelegateController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SRDelegateController.m; sourceTree = ""; }; 1A28FF221F20AFAB007A1D9D /* SRIOConsumer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SRIOConsumer.h; sourceTree = ""; }; @@ -1601,218 +777,146 @@ 1A28FF4C1F20AFAB007A1D9D /* SRWebSocket.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SRWebSocket.m; sourceTree = ""; }; 1A37E9C3200DD0680078AF72 /* CCReachability.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCReachability.h; sourceTree = ""; }; 1A37E9C4200DD0680078AF72 /* CCReachability.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCReachability.cpp; sourceTree = ""; }; - 1A570047180BC5A10088DEC7 /* CCAction.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCAction.cpp; sourceTree = ""; }; - 1A570048180BC5A10088DEC7 /* CCAction.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCAction.h; sourceTree = ""; }; - 1A570049180BC5A10088DEC7 /* CCActionCamera.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCActionCamera.cpp; sourceTree = ""; }; - 1A57004A180BC5A10088DEC7 /* CCActionCamera.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCActionCamera.h; sourceTree = ""; }; - 1A57004B180BC5A10088DEC7 /* CCActionCatmullRom.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCActionCatmullRom.cpp; sourceTree = ""; }; - 1A57004C180BC5A10088DEC7 /* CCActionCatmullRom.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCActionCatmullRom.h; sourceTree = ""; }; - 1A57004D180BC5A10088DEC7 /* CCActionEase.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCActionEase.cpp; sourceTree = ""; }; - 1A57004E180BC5A10088DEC7 /* CCActionEase.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCActionEase.h; sourceTree = ""; }; - 1A57004F180BC5A10088DEC7 /* CCActionGrid.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCActionGrid.cpp; sourceTree = ""; }; - 1A570050180BC5A10088DEC7 /* CCActionGrid.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCActionGrid.h; sourceTree = ""; }; - 1A570051180BC5A10088DEC7 /* CCActionGrid3D.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCActionGrid3D.cpp; sourceTree = ""; }; - 1A570052180BC5A10088DEC7 /* CCActionGrid3D.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCActionGrid3D.h; sourceTree = ""; }; - 1A570053180BC5A10088DEC7 /* CCActionInstant.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCActionInstant.cpp; sourceTree = ""; }; - 1A570054180BC5A10088DEC7 /* CCActionInstant.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCActionInstant.h; sourceTree = ""; }; - 1A570055180BC5A10088DEC7 /* CCActionInterval.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCActionInterval.cpp; sourceTree = ""; }; - 1A570056180BC5A10088DEC7 /* CCActionInterval.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCActionInterval.h; sourceTree = ""; }; - 1A570057180BC5A10088DEC7 /* CCActionManager.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCActionManager.cpp; sourceTree = ""; }; - 1A570058180BC5A10088DEC7 /* CCActionManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCActionManager.h; sourceTree = ""; }; - 1A570059180BC5A10088DEC7 /* CCActionPageTurn3D.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCActionPageTurn3D.cpp; sourceTree = ""; }; - 1A57005A180BC5A10088DEC7 /* CCActionPageTurn3D.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCActionPageTurn3D.h; sourceTree = ""; }; - 1A57005B180BC5A10088DEC7 /* CCActionProgressTimer.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCActionProgressTimer.cpp; sourceTree = ""; }; - 1A57005C180BC5A10088DEC7 /* CCActionProgressTimer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCActionProgressTimer.h; sourceTree = ""; }; - 1A57005D180BC5A10088DEC7 /* CCActionTiledGrid.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCActionTiledGrid.cpp; sourceTree = ""; }; - 1A57005E180BC5A10088DEC7 /* CCActionTiledGrid.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCActionTiledGrid.h; sourceTree = ""; }; - 1A57005F180BC5A10088DEC7 /* CCActionTween.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCActionTween.cpp; sourceTree = ""; }; - 1A570060180BC5A10088DEC7 /* CCActionTween.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCActionTween.h; sourceTree = ""; }; - 1A570096180BC5C10088DEC7 /* CCAtlasNode.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCAtlasNode.cpp; sourceTree = ""; }; - 1A570097180BC5C10088DEC7 /* CCAtlasNode.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCAtlasNode.h; sourceTree = ""; }; - 1A57009C180BC5D20088DEC7 /* CCNode.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCNode.cpp; sourceTree = ""; }; - 1A57009D180BC5D20088DEC7 /* CCNode.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCNode.h; sourceTree = ""; }; - 1A57010A180BC8ED0088DEC7 /* CCDrawingPrimitives.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCDrawingPrimitives.cpp; sourceTree = ""; }; - 1A57010B180BC8EE0088DEC7 /* CCDrawingPrimitives.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCDrawingPrimitives.h; sourceTree = ""; }; - 1A57010C180BC8EE0088DEC7 /* CCDrawNode.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; lineEnding = 0; path = CCDrawNode.cpp; sourceTree = ""; xcLanguageSpecificationIdentifier = xcode.lang.cpp; }; - 1A57010D180BC8EE0088DEC7 /* CCDrawNode.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCDrawNode.h; sourceTree = ""; }; - 1A570117180BC90D0088DEC7 /* CCGrabber.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCGrabber.cpp; sourceTree = ""; }; - 1A570118180BC90D0088DEC7 /* CCGrabber.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCGrabber.h; sourceTree = ""; }; - 1A570119180BC90D0088DEC7 /* CCGrid.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCGrid.cpp; sourceTree = ""; }; - 1A57011A180BC90D0088DEC7 /* CCGrid.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCGrid.h; sourceTree = ""; }; - 1A570182180BCB590088DEC7 /* CCFont.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCFont.cpp; sourceTree = ""; }; - 1A570183180BCB590088DEC7 /* CCFont.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCFont.h; sourceTree = ""; }; - 1A570184180BCB590088DEC7 /* CCFontAtlas.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCFontAtlas.cpp; sourceTree = ""; }; - 1A570185180BCB590088DEC7 /* CCFontAtlas.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCFontAtlas.h; sourceTree = ""; }; - 1A570186180BCB590088DEC7 /* CCFontAtlasCache.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCFontAtlasCache.cpp; sourceTree = ""; }; - 1A570187180BCB590088DEC7 /* CCFontAtlasCache.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCFontAtlasCache.h; sourceTree = ""; }; - 1A57018C180BCB590088DEC7 /* CCFontFNT.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCFontFNT.cpp; sourceTree = ""; }; - 1A57018D180BCB590088DEC7 /* CCFontFNT.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCFontFNT.h; sourceTree = ""; }; - 1A57018E180BCB590088DEC7 /* CCFontFreeType.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCFontFreeType.cpp; sourceTree = ""; }; - 1A57018F180BCB590088DEC7 /* CCFontFreeType.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCFontFreeType.h; sourceTree = ""; }; - 1A570190180BCB590088DEC7 /* CCLabel.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; lineEnding = 0; path = CCLabel.cpp; sourceTree = ""; xcLanguageSpecificationIdentifier = xcode.lang.cpp; }; - 1A570191180BCB590088DEC7 /* CCLabel.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCLabel.h; sourceTree = ""; }; - 1A570192180BCB590088DEC7 /* CCLabelAtlas.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCLabelAtlas.cpp; sourceTree = ""; }; - 1A570193180BCB590088DEC7 /* CCLabelAtlas.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCLabelAtlas.h; sourceTree = ""; }; - 1A570197180BCB590088DEC7 /* CCLabelTextFormatter.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCLabelTextFormatter.cpp; sourceTree = ""; }; - 1A570198180BCB590088DEC7 /* CCLabelTextFormatter.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCLabelTextFormatter.h; sourceTree = ""; }; - 1A5701D4180BCB8C0088DEC7 /* CCLayer.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; lineEnding = 0; path = CCLayer.cpp; sourceTree = ""; xcLanguageSpecificationIdentifier = xcode.lang.cpp; }; - 1A5701D5180BCB8C0088DEC7 /* CCLayer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCLayer.h; sourceTree = ""; }; - 1A5701D6180BCB8C0088DEC7 /* CCScene.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCScene.cpp; sourceTree = ""; }; - 1A5701D7180BCB8C0088DEC7 /* CCScene.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCScene.h; sourceTree = ""; }; - 1A5701D8180BCB8C0088DEC7 /* CCTransition.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCTransition.cpp; sourceTree = ""; }; - 1A5701D9180BCB8C0088DEC7 /* CCTransition.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCTransition.h; sourceTree = ""; }; - 1A5701DA180BCB8C0088DEC7 /* CCTransitionPageTurn.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; lineEnding = 0; path = CCTransitionPageTurn.cpp; sourceTree = ""; xcLanguageSpecificationIdentifier = xcode.lang.cpp; }; - 1A5701DB180BCB8C0088DEC7 /* CCTransitionPageTurn.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCTransitionPageTurn.h; sourceTree = ""; }; - 1A5701DC180BCB8C0088DEC7 /* CCTransitionProgress.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCTransitionProgress.cpp; sourceTree = ""; }; - 1A5701DD180BCB8C0088DEC7 /* CCTransitionProgress.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCTransitionProgress.h; sourceTree = ""; }; - 1A5701F3180BCBAD0088DEC7 /* CCMenu.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCMenu.cpp; sourceTree = ""; }; - 1A5701F4180BCBAD0088DEC7 /* CCMenu.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCMenu.h; sourceTree = ""; }; - 1A5701F5180BCBAD0088DEC7 /* CCMenuItem.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCMenuItem.cpp; sourceTree = ""; }; - 1A5701F6180BCBAD0088DEC7 /* CCMenuItem.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCMenuItem.h; sourceTree = ""; }; - 1A570200180BCBD40088DEC7 /* CCClippingNode.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; lineEnding = 0; path = CCClippingNode.cpp; sourceTree = ""; xcLanguageSpecificationIdentifier = xcode.lang.cpp; }; - 1A570201180BCBD40088DEC7 /* CCClippingNode.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCClippingNode.h; sourceTree = ""; }; - 1A570206180BCBDF0088DEC7 /* CCMotionStreak.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; lineEnding = 0; path = CCMotionStreak.cpp; sourceTree = ""; xcLanguageSpecificationIdentifier = xcode.lang.cpp; }; - 1A570207180BCBDF0088DEC7 /* CCMotionStreak.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCMotionStreak.h; sourceTree = ""; }; - 1A57020C180BCBF40088DEC7 /* CCProgressTimer.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; lineEnding = 0; path = CCProgressTimer.cpp; sourceTree = ""; xcLanguageSpecificationIdentifier = xcode.lang.cpp; }; - 1A57020D180BCBF40088DEC7 /* CCProgressTimer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCProgressTimer.h; sourceTree = ""; }; - 1A57020E180BCBF40088DEC7 /* CCRenderTexture.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; lineEnding = 0; path = CCRenderTexture.cpp; sourceTree = ""; xcLanguageSpecificationIdentifier = xcode.lang.cpp; }; - 1A57020F180BCBF40088DEC7 /* CCRenderTexture.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCRenderTexture.h; sourceTree = ""; }; - 1A570219180BCC1A0088DEC7 /* CCParticleBatchNode.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCParticleBatchNode.cpp; sourceTree = ""; }; - 1A57021A180BCC1A0088DEC7 /* CCParticleBatchNode.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCParticleBatchNode.h; sourceTree = ""; }; - 1A57021B180BCC1A0088DEC7 /* CCParticleExamples.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCParticleExamples.cpp; sourceTree = ""; }; - 1A57021C180BCC1A0088DEC7 /* CCParticleExamples.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCParticleExamples.h; sourceTree = ""; }; - 1A57021D180BCC1A0088DEC7 /* CCParticleSystem.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCParticleSystem.cpp; sourceTree = ""; }; - 1A57021E180BCC1A0088DEC7 /* CCParticleSystem.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCParticleSystem.h; sourceTree = ""; }; - 1A57021F180BCC1A0088DEC7 /* CCParticleSystemQuad.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; lineEnding = 0; path = CCParticleSystemQuad.cpp; sourceTree = ""; xcLanguageSpecificationIdentifier = xcode.lang.cpp; }; - 1A570220180BCC1A0088DEC7 /* CCParticleSystemQuad.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCParticleSystemQuad.h; sourceTree = ""; }; - 1A570276180BCC900088DEC7 /* CCSprite.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; lineEnding = 0; path = CCSprite.cpp; sourceTree = ""; xcLanguageSpecificationIdentifier = xcode.lang.cpp; }; - 1A570277180BCC900088DEC7 /* CCSprite.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCSprite.h; sourceTree = ""; }; - 1A570278180BCC900088DEC7 /* CCSpriteBatchNode.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCSpriteBatchNode.cpp; sourceTree = ""; }; - 1A570279180BCC900088DEC7 /* CCSpriteBatchNode.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCSpriteBatchNode.h; sourceTree = ""; }; - 1A57027A180BCC900088DEC7 /* CCSpriteFrame.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCSpriteFrame.cpp; sourceTree = ""; }; - 1A57027B180BCC900088DEC7 /* CCSpriteFrame.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCSpriteFrame.h; sourceTree = ""; }; - 1A57027C180BCC900088DEC7 /* CCSpriteFrameCache.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCSpriteFrameCache.cpp; sourceTree = ""; }; - 1A57027D180BCC900088DEC7 /* CCSpriteFrameCache.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCSpriteFrameCache.h; sourceTree = ""; }; - 1A57028E180BCCAB0088DEC7 /* CCAnimation.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCAnimation.cpp; sourceTree = ""; }; - 1A57028F180BCCAB0088DEC7 /* CCAnimation.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCAnimation.h; sourceTree = ""; }; - 1A570290180BCCAB0088DEC7 /* CCAnimationCache.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCAnimationCache.cpp; sourceTree = ""; }; - 1A570291180BCCAB0088DEC7 /* CCAnimationCache.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCAnimationCache.h; sourceTree = ""; }; - 1A5702C6180BCE370088DEC7 /* CCTextFieldTTF.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; lineEnding = 0; path = CCTextFieldTTF.cpp; sourceTree = ""; xcLanguageSpecificationIdentifier = xcode.lang.cpp; }; - 1A5702C7180BCE370088DEC7 /* CCTextFieldTTF.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCTextFieldTTF.h; sourceTree = ""; }; - 1A5702E0180BCE750088DEC7 /* CCTileMapAtlas.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCTileMapAtlas.cpp; sourceTree = ""; }; - 1A5702E1180BCE750088DEC7 /* CCTileMapAtlas.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCTileMapAtlas.h; sourceTree = ""; }; - 1A5702E4180BCE750088DEC7 /* CCTMXObjectGroup.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCTMXObjectGroup.cpp; sourceTree = ""; }; - 1A5702E5180BCE750088DEC7 /* CCTMXObjectGroup.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCTMXObjectGroup.h; sourceTree = ""; }; - 1A5702E8180BCE750088DEC7 /* CCTMXXMLParser.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCTMXXMLParser.cpp; sourceTree = ""; }; - 1A5702E9180BCE750088DEC7 /* CCTMXXMLParser.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; lineEnding = 0; path = CCTMXXMLParser.h; sourceTree = ""; xcLanguageSpecificationIdentifier = xcode.lang.objcpp; }; - 1A5702FE180BCE890088DEC7 /* CCParallaxNode.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCParallaxNode.cpp; sourceTree = ""; }; - 1A5702FF180BCE890088DEC7 /* CCParallaxNode.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCParallaxNode.h; sourceTree = ""; }; - 1A570308180BCF190088DEC7 /* CCComponent.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCComponent.cpp; sourceTree = ""; }; - 1A570309180BCF190088DEC7 /* CCComponent.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCComponent.h; sourceTree = ""; }; - 1A57030A180BCF190088DEC7 /* CCComponentContainer.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCComponentContainer.cpp; sourceTree = ""; }; - 1A57030B180BCF190088DEC7 /* CCComponentContainer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCComponentContainer.h; sourceTree = ""; }; - 1A5FB7C71DF10E3500C918C1 /* AudioDecoder.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = AudioDecoder.mm; sourceTree = ""; }; - 1A5FB7C81DF10E3500C918C1 /* AudioDecoder.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AudioDecoder.h; sourceTree = ""; }; - 1A5FB7C91DF10E3500C918C1 /* AudioMacros.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AudioMacros.h; sourceTree = ""; }; - 1A8D254E1F399C61002CC0A8 /* WebSocket-libwebsockets.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = "WebSocket-libwebsockets.cpp"; sourceTree = ""; }; 1A97ABFC1A1D962A0076D9CC /* MathUtilNeon64.inl */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = MathUtilNeon64.inl; sourceTree = ""; }; 1A97ABFD1A1D962A0076D9CC /* MathUtilSSE.inl */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = MathUtilSSE.inl; sourceTree = ""; }; 1A9A4C6D1F98B1C000C14552 /* libcocosanalytics.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libcocosanalytics.a; path = ../external/ios/libs/libcocosanalytics.a; sourceTree = ""; }; - 1A9DCA02180E6955007A3AD4 /* CCGLBufferedNode.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCGLBufferedNode.cpp; sourceTree = ""; }; - 1A9DCA03180E6955007A3AD4 /* CCGLBufferedNode.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCGLBufferedNode.h; sourceTree = ""; }; 1A9F0F951F301DE200A499E1 /* b2ObjectDestroyNotifier.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2ObjectDestroyNotifier.cpp; sourceTree = ""; }; 1A9F0F961F301DE200A499E1 /* b2ObjectDestroyNotifier.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2ObjectDestroyNotifier.h; sourceTree = ""; }; - 1AAF5363180E3374000584C8 /* HttpClient.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = HttpClient.h; sourceTree = ""; }; - 1AAF5364180E3374000584C8 /* HttpRequest.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = HttpRequest.h; sourceTree = ""; }; - 1AAF5365180E3374000584C8 /* HttpResponse.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = HttpResponse.h; sourceTree = ""; }; - 1AAF5366180E3374000584C8 /* SocketIO.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = SocketIO.cpp; sourceTree = ""; }; - 1AAF5367180E3374000584C8 /* SocketIO.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SocketIO.h; sourceTree = ""; }; - 1AAF5369180E3374000584C8 /* WebSocket.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebSocket.h; sourceTree = ""; }; - 1AAF584C180E40B9000584C8 /* LocalStorage.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = LocalStorage.cpp; sourceTree = ""; }; - 1AAF584D180E40B9000584C8 /* LocalStorage.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = LocalStorage.h; sourceTree = ""; }; - 1ABA68AC1888D700007D1BB4 /* CCFontCharMap.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCFontCharMap.cpp; sourceTree = ""; }; - 1ABA68AD1888D700007D1BB4 /* CCFontCharMap.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCFontCharMap.h; sourceTree = ""; }; 1ACF6A3A1E4AFDC80033C137 /* libcrypto.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libcrypto.a; path = ../external/ios/libs/libcrypto.a; sourceTree = ""; }; 1ACF6A3B1E4AFDC80033C137 /* libssl.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libssl.a; path = ../external/ios/libs/libssl.a; sourceTree = ""; }; - 1AD473AA1EAD9A5200202582 /* Uri.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Uri.cpp; sourceTree = ""; }; - 1AD473AB1EAD9A5200202582 /* Uri.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Uri.h; sourceTree = ""; }; - 2905F9E918CF08D000240AA3 /* CocosGUI.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CocosGUI.cpp; sourceTree = ""; }; - 2905F9EA18CF08D000240AA3 /* CocosGUI.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CocosGUI.h; sourceTree = ""; }; - 2905F9EB18CF08D000240AA3 /* GUIDefine.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = GUIDefine.h; sourceTree = ""; }; - 2905F9F418CF08D000240AA3 /* UIHelper.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = UIHelper.cpp; sourceTree = ""; }; - 2905F9F518CF08D000240AA3 /* UIHelper.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UIHelper.h; sourceTree = ""; }; - 2905FA1318CF08D100240AA3 /* UIWidget.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = UIWidget.cpp; sourceTree = ""; }; - 2905FA1418CF08D100240AA3 /* UIWidget.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UIWidget.h; sourceTree = ""; }; - 291901411B05895600F8B4BA /* CCNinePatchImageParser.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCNinePatchImageParser.h; path = ../base/CCNinePatchImageParser.h; sourceTree = ""; }; - 291901421B05895600F8B4BA /* CCNinePatchImageParser.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CCNinePatchImageParser.cpp; path = ../base/CCNinePatchImageParser.cpp; sourceTree = ""; }; - 292DB12F19B4574100A80320 /* UIEditBox.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = UIEditBox.cpp; sourceTree = ""; }; - 292DB13019B4574100A80320 /* UIEditBox.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UIEditBox.h; sourceTree = ""; }; - 292DB13119B4574100A80320 /* UIEditBoxImpl.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UIEditBoxImpl.h; sourceTree = ""; }; - 292DB13219B4574100A80320 /* UIEditBoxImpl-android.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = "UIEditBoxImpl-android.cpp"; sourceTree = ""; }; - 292DB13319B4574100A80320 /* UIEditBoxImpl-android.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UIEditBoxImpl-android.h"; sourceTree = ""; }; - 292DB13419B4574100A80320 /* UIEditBoxImpl-ios.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UIEditBoxImpl-ios.h"; sourceTree = ""; }; - 292DB13519B4574100A80320 /* UIEditBoxImpl-ios.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = "UIEditBoxImpl-ios.mm"; sourceTree = ""; }; - 292DB13619B4574100A80320 /* UIEditBoxImpl-mac.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UIEditBoxImpl-mac.h"; sourceTree = ""; }; - 292DB13719B4574100A80320 /* UIEditBoxImpl-mac.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = "UIEditBoxImpl-mac.mm"; sourceTree = ""; }; - 29394CEC19B01DBA00D2DE1A /* UIWebView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UIWebView.h; sourceTree = ""; }; - 29394CED19B01DBA00D2DE1A /* UIWebView.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = UIWebView.mm; sourceTree = ""; }; - 29394CEE19B01DBA00D2DE1A /* UIWebViewImpl-ios.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UIWebViewImpl-ios.h"; sourceTree = ""; }; - 29394CEF19B01DBA00D2DE1A /* UIWebViewImpl-ios.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = "UIWebViewImpl-ios.mm"; sourceTree = ""; }; 294D7D981D0E93A2002CE7B7 /* CCDevice-apple.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "CCDevice-apple.h"; sourceTree = ""; }; 294D7D991D0E93A2002CE7B7 /* CCDevice-apple.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = "CCDevice-apple.mm"; sourceTree = ""; }; - 2958244919873D8E00F9746D /* UIScale9Sprite.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = UIScale9Sprite.cpp; sourceTree = ""; }; - 2958244A19873D8E00F9746D /* UIScale9Sprite.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UIScale9Sprite.h; sourceTree = ""; }; - 2980F0171BA9A5550059E678 /* CCUIEditBoxIOS.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCUIEditBoxIOS.h; sourceTree = ""; }; - 2980F0181BA9A5550059E678 /* CCUIEditBoxIOS.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = CCUIEditBoxIOS.mm; sourceTree = ""; }; - 2980F0191BA9A5550059E678 /* CCUIMultilineTextField.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCUIMultilineTextField.h; sourceTree = ""; }; - 2980F01A1BA9A5550059E678 /* CCUIMultilineTextField.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = CCUIMultilineTextField.mm; sourceTree = ""; }; - 2980F01B1BA9A5550059E678 /* CCUISingleLineTextField.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCUISingleLineTextField.h; sourceTree = ""; }; - 2980F01C1BA9A5550059E678 /* CCUISingleLineTextField.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = CCUISingleLineTextField.mm; sourceTree = ""; }; - 2980F01D1BA9A5550059E678 /* CCUITextInput.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCUITextInput.h; sourceTree = ""; }; - 2980F01E1BA9A5550059E678 /* UITextField+CCUITextInput.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UITextField+CCUITextInput.h"; sourceTree = ""; }; - 2980F01F1BA9A5550059E678 /* UITextField+CCUITextInput.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = "UITextField+CCUITextInput.mm"; sourceTree = ""; }; - 2980F0201BA9A5550059E678 /* UITextView+CCUITextInput.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UITextView+CCUITextInput.h"; sourceTree = ""; }; - 2980F0211BA9A5550059E678 /* UITextView+CCUITextInput.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = "UITextView+CCUITextInput.mm"; sourceTree = ""; }; - 2986667818B1B079000E39CA /* CCTweenFunction.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCTweenFunction.cpp; sourceTree = ""; }; - 2986667918B1B079000E39CA /* CCTweenFunction.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCTweenFunction.h; sourceTree = ""; }; - 299754F2193EC95400A54AC3 /* ObjectFactory.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = ObjectFactory.cpp; path = ../base/ObjectFactory.cpp; sourceTree = ""; }; - 299754F3193EC95400A54AC3 /* ObjectFactory.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = ObjectFactory.h; path = ../base/ObjectFactory.h; sourceTree = ""; }; - 299CF1F919A434BC00C378C1 /* ccRandom.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = ccRandom.cpp; path = ../base/ccRandom.cpp; sourceTree = ""; }; - 299CF1FA19A434BC00C378C1 /* ccRandom.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = ccRandom.h; path = ../base/ccRandom.h; sourceTree = ""; }; - 29D57CFC1D7FE03C001735C5 /* ccShader_UI_Gray.frag */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.glsl; path = ccShader_UI_Gray.frag; sourceTree = ""; }; - 29D57CFF1D7FEC1C001735C5 /* ccShader_SpriteDistortion.frag */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.glsl; path = ccShader_SpriteDistortion.frag; sourceTree = ""; }; - 3E2BDADD19C030ED0055CDCD /* AudioEngine.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AudioEngine.h; sourceTree = ""; }; - 3E2BDAEB19C0436F0055CDCD /* AudioEngine.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = AudioEngine.cpp; sourceTree = ""; }; - 3EA0FB69191C841D00B170C8 /* UIVideoPlayer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UIVideoPlayer.h; sourceTree = ""; }; - 3EA0FB6A191C841D00B170C8 /* UIVideoPlayer-ios.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = "UIVideoPlayer-ios.mm"; sourceTree = ""; }; - 464AD6E3197EBB1400E502D8 /* pvr.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = pvr.cpp; path = ../base/pvr.cpp; sourceTree = ""; }; - 464AD6E4197EBB1400E502D8 /* pvr.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = pvr.h; path = ../base/pvr.h; sourceTree = ""; }; - 46A15FE11807A56F005B8026 /* Export.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = Export.h; sourceTree = ""; }; - 46A167D21807AF4D005B8026 /* cocos-ext.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "cocos-ext.h"; sourceTree = ""; }; - 46A168321807AF4E005B8026 /* ExtensionMacros.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = ExtensionMacros.h; sourceTree = ""; }; - 4D2816641E8CBB7200F26B06 /* CCPhysicsContactImpulse.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCPhysicsContactImpulse.cpp; sourceTree = ""; }; - 4D2816651E8CBB7200F26B06 /* CCPhysicsContactImpulse.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCPhysicsContactImpulse.h; sourceTree = ""; }; - 4D2E69031CC543B40032DD5C /* CCGraphicsNode.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CCGraphicsNode.cpp; path = creator/CCGraphicsNode.cpp; sourceTree = ""; }; - 4D2E69041CC543B40032DD5C /* CCGraphicsNode.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCGraphicsNode.h; path = creator/CCGraphicsNode.h; sourceTree = ""; }; - 4D2E69051CC543B40032DD5C /* Triangulate.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = Triangulate.cpp; path = creator/Triangulate.cpp; sourceTree = ""; }; - 4D2E69061CC543B40032DD5C /* Triangulate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = Triangulate.h; path = creator/Triangulate.h; sourceTree = ""; }; - 4D6CF4351E83AAD5003327D4 /* CCCameraNode.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CCCameraNode.cpp; path = creator/CCCameraNode.cpp; sourceTree = ""; }; - 4D6CF4361E83AAD5003327D4 /* CCCameraNode.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCCameraNode.h; path = creator/CCCameraNode.h; sourceTree = ""; }; - 4DC06BC11E8A68D400CA08B1 /* CCPhysicsAABBQueryCallback.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCPhysicsAABBQueryCallback.cpp; sourceTree = ""; }; - 4DC06BC21E8A68D400CA08B1 /* CCPhysicsAABBQueryCallback.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCPhysicsAABBQueryCallback.h; sourceTree = ""; }; - 4DC06BC31E8A68D400CA08B1 /* CCPhysicsContactListener.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCPhysicsContactListener.cpp; sourceTree = ""; }; - 4DC06BC41E8A68D400CA08B1 /* CCPhysicsContactListener.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCPhysicsContactListener.h; sourceTree = ""; }; - 4DC06BC71E8A68D400CA08B1 /* CCPhysicsDebugDraw.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCPhysicsDebugDraw.cpp; sourceTree = ""; }; - 4DC06BC81E8A68D400CA08B1 /* CCPhysicsDebugDraw.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCPhysicsDebugDraw.h; sourceTree = ""; }; - 4DC06BC91E8A68D400CA08B1 /* CCPhysicsRayCastCallback.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCPhysicsRayCastCallback.cpp; sourceTree = ""; }; - 4DC06BCA1E8A68D400CA08B1 /* CCPhysicsRayCastCallback.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCPhysicsRayCastCallback.h; sourceTree = ""; }; - 4DC06BCB1E8A68D400CA08B1 /* CCPhysicsUtils.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCPhysicsUtils.cpp; sourceTree = ""; }; - 4DC06BCC1E8A68D400CA08B1 /* CCPhysicsUtils.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCPhysicsUtils.h; sourceTree = ""; }; - 4DC06BCD1E8A68D400CA08B1 /* CCPhysicsWorldManifoldWrapper.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCPhysicsWorldManifoldWrapper.cpp; sourceTree = ""; }; - 4DC06BCE1E8A68D400CA08B1 /* CCPhysicsWorldManifoldWrapper.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCPhysicsWorldManifoldWrapper.h; sourceTree = ""; }; - 4DC06BEB1E8B604B00CA08B1 /* CCPhysicsManifoldWrapper.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCPhysicsManifoldWrapper.cpp; sourceTree = ""; }; - 4DC06BEC1E8B604B00CA08B1 /* CCPhysicsManifoldWrapper.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCPhysicsManifoldWrapper.h; sourceTree = ""; }; - 4DC06BF11E8B8D1300CA08B1 /* CCPhysicsDefine.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = CCPhysicsDefine.h; sourceTree = ""; }; + 46FDDA2E202ACC6A00931238 /* INode.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = INode.h; sourceTree = ""; }; + 46FDDA2F202ACC6A00931238 /* Pass.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Pass.cpp; sourceTree = ""; }; + 46FDDA30202ACC6A00931238 /* Scene.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Scene.cpp; sourceTree = ""; }; + 46FDDA31202ACC6A00931238 /* ProgramLib.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ProgramLib.h; sourceTree = ""; }; + 46FDDA32202ACC6A00931238 /* Config.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Config.h; sourceTree = ""; }; + 46FDDA33202ACC6A00931238 /* Light.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Light.h; sourceTree = ""; }; + 46FDDA34202ACC6A00931238 /* Camera.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Camera.cpp; sourceTree = ""; }; + 46FDDA35202ACC6A00931238 /* Camera.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Camera.h; sourceTree = ""; }; + 46FDDA36202ACC6A00931238 /* Light.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Light.cpp; sourceTree = ""; }; + 46FDDA37202ACC6A00931238 /* Renderer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Renderer.h; sourceTree = ""; }; + 46FDDA38202ACC6A00931238 /* RendererUtils.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RendererUtils.h; sourceTree = ""; }; + 46FDDA39202ACC6A00931238 /* Technique.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Technique.h; sourceTree = ""; }; + 46FDDA3A202ACC6A00931238 /* View.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = View.h; sourceTree = ""; }; + 46FDDA3B202ACC6A00931238 /* View.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = View.cpp; sourceTree = ""; }; + 46FDDA3C202ACC6A00931238 /* Effect.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Effect.cpp; sourceTree = ""; }; + 46FDDA3D202ACC6A00931238 /* ForwardRenderer.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ForwardRenderer.cpp; sourceTree = ""; }; + 46FDDA3E202ACC6A00931238 /* Config.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Config.cpp; sourceTree = ""; }; + 46FDDA3F202ACC6A00931238 /* BaseRenderer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = BaseRenderer.h; sourceTree = ""; }; + 46FDDA40202ACC6A00931238 /* Pass.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Pass.h; sourceTree = ""; }; + 46FDDA41202ACC6A00931238 /* Technique.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Technique.cpp; sourceTree = ""; }; + 46FDDA42202ACC6A00931238 /* RendererUtils.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = RendererUtils.cpp; sourceTree = ""; }; + 46FDDA43202ACC6A00931238 /* Model.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Model.h; sourceTree = ""; }; + 46FDDA44202ACC6A00931238 /* Model.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Model.cpp; sourceTree = ""; }; + 46FDDA45202ACC6A00931238 /* Effect.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Effect.h; sourceTree = ""; }; + 46FDDA46202ACC6A00931238 /* BaseRenderer.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = BaseRenderer.cpp; sourceTree = ""; }; + 46FDDA47202ACC6A00931238 /* ProgramLib.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ProgramLib.cpp; sourceTree = ""; }; + 46FDDA48202ACC6A00931238 /* InputAssembler.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = InputAssembler.h; sourceTree = ""; }; + 46FDDA49202ACC6A00931238 /* InputAssembler.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = InputAssembler.cpp; sourceTree = ""; }; + 46FDDA4A202ACC6A00931238 /* Scene.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Scene.h; sourceTree = ""; }; + 46FDDA4B202ACC6A00931238 /* ForwardRenderer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ForwardRenderer.h; sourceTree = ""; }; + 46FDDA4C202ACC6A00931238 /* Types.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Types.cpp; sourceTree = ""; }; + 46FDDA4E202ACC6A00931238 /* Types.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Types.h; sourceTree = ""; }; + 46FDDA4F202ACC6A00931238 /* Macro.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Macro.h; sourceTree = ""; }; + 46FDDA51202ACC6A00931238 /* Texture2D.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Texture2D.h; sourceTree = ""; }; + 46FDDA52202ACC6A00931238 /* DeviceGraphics.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = DeviceGraphics.cpp; sourceTree = ""; }; + 46FDDA53202ACC6A00931238 /* VertexBuffer.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = VertexBuffer.cpp; sourceTree = ""; }; + 46FDDA54202ACC6A00931238 /* Program.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Program.cpp; sourceTree = ""; }; + 46FDDA55202ACC6A00931238 /* IndexBuffer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = IndexBuffer.h; sourceTree = ""; }; + 46FDDA56202ACC6A00931238 /* FrameBuffer.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = FrameBuffer.cpp; sourceTree = ""; }; + 46FDDA57202ACC6A00931238 /* VertexFormat.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = VertexFormat.cpp; sourceTree = ""; }; + 46FDDA58202ACC6A00931238 /* DeviceGraphics.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DeviceGraphics.h; sourceTree = ""; }; + 46FDDA59202ACC6A00931238 /* State.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = State.cpp; sourceTree = ""; }; + 46FDDA5A202ACC6A00931238 /* Texture.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Texture.cpp; sourceTree = ""; }; + 46FDDA5B202ACC6A00931238 /* FrameBuffer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = FrameBuffer.h; sourceTree = ""; }; + 46FDDA5C202ACC6A00931238 /* RenderTarget.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = RenderTarget.cpp; sourceTree = ""; }; + 46FDDA5D202ACC6A00931238 /* GFX.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = GFX.h; sourceTree = ""; }; + 46FDDA5E202ACC6A00931238 /* RenderBuffer.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = RenderBuffer.cpp; sourceTree = ""; }; + 46FDDA5F202ACC6A00931238 /* VertexFormat.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = VertexFormat.h; sourceTree = ""; }; + 46FDDA60202ACC6A00931238 /* GraphicsHandle.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = GraphicsHandle.h; sourceTree = ""; }; + 46FDDA61202ACC6A00931238 /* RenderBuffer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RenderBuffer.h; sourceTree = ""; }; + 46FDDA62202ACC6A00931238 /* Texture.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Texture.h; sourceTree = ""; }; + 46FDDA63202ACC6A00931238 /* Texture2D.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Texture2D.cpp; sourceTree = ""; }; + 46FDDA64202ACC6A00931238 /* GraphicsHandle.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = GraphicsHandle.cpp; sourceTree = ""; }; + 46FDDA65202ACC6A00931238 /* GFXUtils.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = GFXUtils.h; sourceTree = ""; }; + 46FDDA66202ACC6A00931238 /* Program.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Program.h; sourceTree = ""; }; + 46FDDA67202ACC6A00931238 /* State.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = State.h; sourceTree = ""; }; + 46FDDA68202ACC6A00931238 /* VertexBuffer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = VertexBuffer.h; sourceTree = ""; }; + 46FDDA69202ACC6A00931238 /* RenderTarget.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RenderTarget.h; sourceTree = ""; }; + 46FDDA6A202ACC6A00931238 /* GFXUtils.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = GFXUtils.cpp; sourceTree = ""; }; + 46FDDA6B202ACC6A00931238 /* GFX.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = GFX.cpp; sourceTree = ""; }; + 46FDDA6C202ACC6A00931238 /* IndexBuffer.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = IndexBuffer.cpp; sourceTree = ""; }; + 46FDDAEA202ADDCE00931238 /* ccFPSImages.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = ccFPSImages.c; sourceTree = ""; }; + 46FDDAEB202ADDCE00931238 /* pvr.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = pvr.h; sourceTree = ""; }; + 46FDDAEC202ADDCE00931238 /* CCValue.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCValue.h; sourceTree = ""; }; + 46FDDAEE202ADDCE00931238 /* utlist.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = utlist.h; sourceTree = ""; }; + 46FDDAF2202ADDCE00931238 /* CCData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCData.h; sourceTree = ""; }; + 46FDDAF3202ADDCE00931238 /* ccMacros.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ccMacros.h; sourceTree = ""; }; + 46FDDAF7202ADDCE00931238 /* ccRandom.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ccRandom.cpp; sourceTree = ""; }; + 46FDDAFA202ADDCE00931238 /* base64.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = base64.h; sourceTree = ""; }; + 46FDDAFB202ADDCE00931238 /* etc1.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = etc1.h; sourceTree = ""; }; + 46FDDAFC202ADDCE00931238 /* ZipUtils.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ZipUtils.cpp; sourceTree = ""; }; + 46FDDAFD202ADDCE00931238 /* base64.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = base64.cpp; sourceTree = ""; }; + 46FDDB01202ADDCE00931238 /* CCGameController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCGameController.h; sourceTree = ""; }; + 46FDDB02202ADDCE00931238 /* CCRef.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCRef.cpp; sourceTree = ""; }; + 46FDDB05202ADDCE00931238 /* ccTypes.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ccTypes.h; sourceTree = ""; }; + 46FDDB06202ADDCE00931238 /* ccRandom.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ccRandom.h; sourceTree = ""; }; + 46FDDB09202ADDCE00931238 /* CCRef.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCRef.h; sourceTree = ""; }; + 46FDDB0A202ADDCE00931238 /* CCAutoreleasePool.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCAutoreleasePool.cpp; sourceTree = ""; }; + 46FDDB0B202ADDCE00931238 /* ccTypes.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ccTypes.cpp; sourceTree = ""; }; + 46FDDB0C202ADDCE00931238 /* ccUtils.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ccUtils.cpp; sourceTree = ""; }; + 46FDDB0E202ADDCE00931238 /* TGAlib.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = TGAlib.cpp; sourceTree = ""; }; + 46FDDB11202ADDCE00931238 /* ccUTF8.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ccUTF8.cpp; sourceTree = ""; }; + 46FDDB12202ADDCE00931238 /* CCProfiling.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCProfiling.h; sourceTree = ""; }; + 46FDDB13202ADDCE00931238 /* ObjectFactory.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ObjectFactory.h; sourceTree = ""; }; + 46FDDB14202ADDCE00931238 /* CCVector.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCVector.h; sourceTree = ""; }; + 46FDDB15202ADDCE00931238 /* ObjectFactory.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ObjectFactory.cpp; sourceTree = ""; }; + 46FDDB16202ADDCE00931238 /* pvr.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = pvr.cpp; sourceTree = ""; }; + 46FDDB19202ADDCE00931238 /* CCProfiling.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCProfiling.cpp; sourceTree = ""; }; + 46FDDB1E202ADDCE00931238 /* CCIMEDispatcher.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCIMEDispatcher.cpp; sourceTree = ""; }; + 46FDDB1F202ADDCE00931238 /* uthash.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = uthash.h; sourceTree = ""; }; + 46FDDB20202ADDCE00931238 /* ccUtils.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ccUtils.h; sourceTree = ""; }; + 46FDDB21202ADDCE00931238 /* CCNS.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCNS.cpp; sourceTree = ""; }; + 46FDDB22202ADDCE00931238 /* CCRefPtr.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCRefPtr.h; sourceTree = ""; }; + 46FDDB26202ADDCE00931238 /* ccConfig.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ccConfig.h; sourceTree = ""; }; + 46FDDB29202ADDCE00931238 /* ccFPSImages.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ccFPSImages.h; sourceTree = ""; }; + 46FDDB2A202ADDCE00931238 /* ZipUtils.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ZipUtils.h; sourceTree = ""; }; + 46FDDB2C202ADDCE00931238 /* CCMap.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCMap.h; sourceTree = ""; }; + 46FDDB2D202ADDCE00931238 /* ccUTF8.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ccUTF8.h; sourceTree = ""; }; + 46FDDB33202ADDCE00931238 /* TGAlib.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TGAlib.h; sourceTree = ""; }; + 46FDDB36202ADDCE00931238 /* CCData.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCData.cpp; sourceTree = ""; }; + 46FDDB37202ADDCE00931238 /* CCIMEDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCIMEDelegate.h; sourceTree = ""; }; + 46FDDB38202ADDCE00931238 /* CCNS.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCNS.h; sourceTree = ""; }; + 46FDDB39202ADDCE00931238 /* CCAutoreleasePool.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCAutoreleasePool.h; sourceTree = ""; }; + 46FDDB41202ADDCE00931238 /* etc1.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = etc1.cpp; sourceTree = ""; }; + 46FDDB42202ADDCE00931238 /* ccCArray.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ccCArray.cpp; sourceTree = ""; }; + 46FDDB43202ADDCE00931238 /* CCValue.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCValue.cpp; sourceTree = ""; }; + 46FDDB44202ADDCE00931238 /* firePngData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = firePngData.h; sourceTree = ""; }; + 46FDDB45202ADDCE00931238 /* ccCArray.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ccCArray.h; sourceTree = ""; }; + 46FDDB4A202ADDCE00931238 /* CCIMEDispatcher.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCIMEDispatcher.h; sourceTree = ""; }; + 46FDDC0E202AEAC500931238 /* WebGLTexelConversions.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = WebGLTexelConversions.cpp; sourceTree = ""; }; + 46FDDC0F202AEAC500931238 /* WebGLTypes.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebGLTypes.h; sourceTree = ""; }; + 46FDDC11202AEAC500931238 /* Casting.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Casting.h; sourceTree = ""; }; + 46FDDC12202AEAC500931238 /* UniquePtr.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UniquePtr.h; sourceTree = ""; }; + 46FDDC13202AEAC500931238 /* Compiler.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Compiler.h; sourceTree = ""; }; + 46FDDC14202AEAC500931238 /* Assertions.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Assertions.h; sourceTree = ""; }; + 46FDDC15202AEAC500931238 /* TypeTraits.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TypeTraits.h; sourceTree = ""; }; + 46FDDC16202AEAC500931238 /* Types.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Types.h; sourceTree = ""; }; + 46FDDC17202AEAC500931238 /* IntegerTypeTraits.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = IntegerTypeTraits.h; sourceTree = ""; }; + 46FDDC18202AEAC500931238 /* Assertions.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Assertions.cpp; sourceTree = ""; }; + 46FDDC19202AEAC500931238 /* Attributes.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Attributes.h; sourceTree = ""; }; + 46FDDC1A202AEAC500931238 /* MacroArgs.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MacroArgs.h; sourceTree = ""; }; + 46FDDC1B202AEAC500931238 /* CheckedInt.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CheckedInt.h; sourceTree = ""; }; + 46FDDC1C202AEAC500931238 /* Likely.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Likely.h; sourceTree = ""; }; + 46FDDC1D202AEAC500931238 /* Atomics.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Atomics.h; sourceTree = ""; }; + 46FDDC1E202AEAC500931238 /* Pair.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Pair.h; sourceTree = ""; }; + 46FDDC1F202AEAC500931238 /* Move.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Move.h; sourceTree = ""; }; + 46FDDC20202AEAC500931238 /* StaticAnalysisFunctions.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = StaticAnalysisFunctions.h; sourceTree = ""; }; + 46FDDC21202AEAC500931238 /* WebGLFormats.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebGLFormats.h; sourceTree = ""; }; + 46FDDC22202AEAC500931238 /* GLConsts.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = GLConsts.h; sourceTree = ""; }; + 46FDDC23202AEAC500931238 /* WebGLTexelConversions.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebGLTexelConversions.h; sourceTree = ""; }; + 46FDDC24202AEAC500931238 /* WebGLFormats.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = WebGLFormats.cpp; sourceTree = ""; }; 4DC57D1F1F7A58B5005B6546 /* xxtea.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = xxtea.cpp; sourceTree = ""; }; 4DC57D201F7A58B5005B6546 /* xxtea.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = xxtea.h; sourceTree = ""; }; 4DED476B1DFFA4AF0070C5C4 /* Box2D.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Box2D.h; sourceTree = ""; }; @@ -1911,35 +1015,8 @@ 4DED47CF1DFFA4AF0070C5C4 /* b2Rope.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2Rope.cpp; sourceTree = ""; }; 4DED47D01DFFA4AF0070C5C4 /* b2Rope.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2Rope.h; sourceTree = ""; }; 4DED47D11DFFA4AF0070C5C4 /* UseBox2D.cmake */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = UseBox2D.cmake; sourceTree = ""; }; - 4DFA4C151CBCE34100E3B736 /* CCScale9Sprite.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CCScale9Sprite.cpp; path = creator/CCScale9Sprite.cpp; sourceTree = ""; }; - 4DFA4C161CBCE34100E3B736 /* CCScale9Sprite.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCScale9Sprite.h; path = creator/CCScale9Sprite.h; sourceTree = ""; }; 50272538190BF1B900AAF4ED /* cocos2d.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = cocos2d.h; path = ../cocos/cocos2d.h; sourceTree = ""; }; 50272539190BF1B900AAF4ED /* cocos2d.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = cocos2d.cpp; path = ../cocos/cocos2d.cpp; sourceTree = ""; }; - 5034C9FB191D591000CE6051 /* ccShader_PositionTextureColorAlphaTest.frag */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.glsl; path = ccShader_PositionTextureColorAlphaTest.frag; sourceTree = ""; }; - 5034CA00191D591000CE6051 /* ccShader_PositionTextureA8Color.vert */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.glsl; path = ccShader_PositionTextureA8Color.vert; sourceTree = ""; }; - 5034CA01191D591000CE6051 /* ccShader_PositionTextureA8Color.frag */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.glsl; path = ccShader_PositionTextureA8Color.frag; sourceTree = ""; }; - 5034CA02191D591000CE6051 /* ccShader_PositionTexture.vert */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.glsl; path = ccShader_PositionTexture.vert; sourceTree = ""; }; - 5034CA03191D591000CE6051 /* ccShader_PositionTexture_uColor.vert */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.glsl; path = ccShader_PositionTexture_uColor.vert; sourceTree = ""; }; - 5034CA04191D591000CE6051 /* ccShader_PositionTexture_uColor.frag */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.glsl; path = ccShader_PositionTexture_uColor.frag; sourceTree = ""; }; - 5034CA05191D591000CE6051 /* ccShader_PositionTexture.frag */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.glsl; path = ccShader_PositionTexture.frag; sourceTree = ""; }; - 5034CA06191D591000CE6051 /* ccShader_PositionColorLengthTexture.vert */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.glsl; path = ccShader_PositionColorLengthTexture.vert; sourceTree = ""; }; - 5034CA07191D591000CE6051 /* ccShader_PositionColorLengthTexture.frag */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.glsl; path = ccShader_PositionColorLengthTexture.frag; sourceTree = ""; }; - 5034CA08191D591000CE6051 /* ccShader_PositionColor.vert */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.glsl; path = ccShader_PositionColor.vert; sourceTree = ""; }; - 5034CA09191D591000CE6051 /* ccShader_PositionColor.frag */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.glsl; path = ccShader_PositionColor.frag; sourceTree = ""; }; - 5034CA0A191D591000CE6051 /* ccShader_Position_uColor.vert */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.glsl; path = ccShader_Position_uColor.vert; sourceTree = ""; }; - 5034CA0B191D591000CE6051 /* ccShader_Position_uColor.frag */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.glsl; path = ccShader_Position_uColor.frag; sourceTree = ""; }; - 5034CA0C191D591000CE6051 /* ccShader_Label.vert */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.glsl; path = ccShader_Label.vert; sourceTree = ""; }; - 5034CA0D191D591000CE6051 /* ccShader_Label_outline.frag */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.glsl; path = ccShader_Label_outline.frag; sourceTree = ""; }; - 5034CA0E191D591000CE6051 /* ccShader_Label_normal.frag */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.glsl; path = ccShader_Label_normal.frag; sourceTree = ""; }; - 5034CA0F191D591000CE6051 /* ccShader_Label_df.frag */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.glsl; path = ccShader_Label_df.frag; sourceTree = ""; }; - 5034CA10191D591000CE6051 /* ccShader_Label_df_glow.frag */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.glsl; path = ccShader_Label_df_glow.frag; sourceTree = ""; }; - 5034CA60191D91CF00CE6051 /* ccShader_PositionTextureColor.vert */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.glsl; path = ccShader_PositionTextureColor.vert; sourceTree = ""; }; - 5034CA61191D91CF00CE6051 /* ccShader_PositionTextureColor.frag */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.glsl; path = ccShader_PositionTextureColor.frag; sourceTree = ""; }; - 5034CA62191D91CF00CE6051 /* ccShader_PositionTextureColor_noMVP.vert */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.glsl; path = ccShader_PositionTextureColor_noMVP.vert; sourceTree = ""; }; - 5034CA63191D91CF00CE6051 /* ccShader_PositionTextureColor_noMVP.frag */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.glsl; path = ccShader_PositionTextureColor_noMVP.frag; sourceTree = ""; }; - 503DD8CE1926736A00CD74DD /* CCApplication-ios.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "CCApplication-ios.h"; sourceTree = ""; }; - 503DD8CF1926736A00CD74DD /* CCApplication-ios.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = "CCApplication-ios.mm"; sourceTree = ""; }; - 503DD8D01926736A00CD74DD /* CCCommon-ios.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = "CCCommon-ios.mm"; sourceTree = ""; }; 503DD8D11926736A00CD74DD /* CCDevice-ios.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = "CCDevice-ios.mm"; sourceTree = ""; }; 503DD8D21926736A00CD74DD /* CCDirectorCaller-ios.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "CCDirectorCaller-ios.h"; sourceTree = ""; }; 503DD8D31926736A00CD74DD /* CCDirectorCaller-ios.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = "CCDirectorCaller-ios.mm"; sourceTree = ""; }; @@ -1949,23 +1026,14 @@ 503DD8D71926736A00CD74DD /* CCES2Renderer-ios.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "CCES2Renderer-ios.m"; sourceTree = ""; }; 503DD8D81926736A00CD74DD /* CCESRenderer-ios.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "CCESRenderer-ios.h"; sourceTree = ""; }; 503DD8D91926736A00CD74DD /* CCGL-ios.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "CCGL-ios.h"; sourceTree = ""; }; - 503DD8DA1926736A00CD74DD /* CCGLViewImpl-ios.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "CCGLViewImpl-ios.h"; sourceTree = ""; }; - 503DD8DB1926736A00CD74DD /* CCGLViewImpl-ios.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = "CCGLViewImpl-ios.mm"; sourceTree = ""; }; 503DD8DC1926736A00CD74DD /* CCImage-ios.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = "CCImage-ios.mm"; sourceTree = ""; }; 503DD8DD1926736A00CD74DD /* CCPlatformDefine-ios.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "CCPlatformDefine-ios.h"; sourceTree = ""; }; 503DD8DE1926736A00CD74DD /* CCStdC-ios.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "CCStdC-ios.h"; sourceTree = ""; }; 503DD8DF1926736A00CD74DD /* OpenGL_Internal-ios.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "OpenGL_Internal-ios.h"; sourceTree = ""; }; - 503DD8F21926B0DB00CD74DD /* CCIMEDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCIMEDelegate.h; path = ../base/CCIMEDelegate.h; sourceTree = ""; }; - 503DD8F31926B0DB00CD74DD /* CCIMEDispatcher.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CCIMEDispatcher.cpp; path = ../base/CCIMEDispatcher.cpp; sourceTree = ""; }; - 503DD8F41926B0DB00CD74DD /* CCIMEDispatcher.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCIMEDispatcher.h; path = ../base/CCIMEDispatcher.h; sourceTree = ""; }; 50643BD319BFAECF00EF68ED /* CCGL.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCGL.h; sourceTree = ""; }; - 50643BD719BFAF4400EF68ED /* CCApplication.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCApplication.h; sourceTree = ""; }; 50643BD819BFAF4400EF68ED /* CCStdC.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCStdC.h; sourceTree = ""; }; 50643BE019BFCF1800EF68ED /* CCPlatformConfig.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCPlatformConfig.h; sourceTree = ""; }; 50643BE119BFCF1800EF68ED /* CCPlatformMacros.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCPlatformMacros.h; sourceTree = ""; }; - 50693C5C1B6BF2AE005C5820 /* CCDownloader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCDownloader.cpp; sourceTree = ""; }; - 50693C5D1B6BF2AE005C5820 /* CCDownloader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCDownloader.h; sourceTree = ""; }; - 507003181B69735200E83DDD /* HttpClient.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = HttpClient.cpp; sourceTree = ""; }; 5091A7A219BFABA800AC8789 /* CCPlatformDefine.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCPlatformDefine.h; sourceTree = ""; }; 50ABBD1B1925AB0000A911A9 /* CCAffineTransform.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCAffineTransform.cpp; sourceTree = ""; }; 50ABBD1C1925AB0000A911A9 /* CCAffineTransform.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCAffineTransform.h; sourceTree = ""; }; @@ -1996,229 +1064,38 @@ 50ABBD351925AB0000A911A9 /* Vec4.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Vec4.cpp; sourceTree = ""; }; 50ABBD361925AB0000A911A9 /* Vec4.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Vec4.h; sourceTree = ""; }; 50ABBD371925AB0000A911A9 /* Vec4.inl */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = Vec4.inl; sourceTree = ""; }; - 50ABBD641925AB4100A911A9 /* CCBatchCommand.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCBatchCommand.cpp; sourceTree = ""; }; - 50ABBD651925AB4100A911A9 /* CCBatchCommand.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCBatchCommand.h; sourceTree = ""; }; - 50ABBD661925AB4100A911A9 /* CCCustomCommand.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCCustomCommand.cpp; sourceTree = ""; }; - 50ABBD671925AB4100A911A9 /* CCCustomCommand.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCCustomCommand.h; sourceTree = ""; }; - 50ABBD681925AB4100A911A9 /* CCGLProgram.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCGLProgram.cpp; sourceTree = ""; }; - 50ABBD691925AB4100A911A9 /* CCGLProgram.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCGLProgram.h; sourceTree = ""; }; - 50ABBD6A1925AB4100A911A9 /* CCGLProgramCache.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCGLProgramCache.cpp; sourceTree = ""; }; - 50ABBD6B1925AB4100A911A9 /* CCGLProgramCache.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCGLProgramCache.h; sourceTree = ""; }; - 50ABBD6C1925AB4100A911A9 /* CCGLProgramState.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCGLProgramState.cpp; sourceTree = ""; }; - 50ABBD6D1925AB4100A911A9 /* CCGLProgramState.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCGLProgramState.h; sourceTree = ""; }; - 50ABBD6E1925AB4100A911A9 /* CCGLProgramStateCache.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCGLProgramStateCache.cpp; sourceTree = ""; }; - 50ABBD6F1925AB4100A911A9 /* CCGLProgramStateCache.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCGLProgramStateCache.h; sourceTree = ""; }; - 50ABBD701925AB4100A911A9 /* ccGLStateCache.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ccGLStateCache.cpp; sourceTree = ""; }; - 50ABBD711925AB4100A911A9 /* ccGLStateCache.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ccGLStateCache.h; sourceTree = ""; }; - 50ABBD721925AB4100A911A9 /* CCGroupCommand.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCGroupCommand.cpp; sourceTree = ""; }; - 50ABBD731925AB4100A911A9 /* CCGroupCommand.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCGroupCommand.h; sourceTree = ""; }; - 50ABBD741925AB4100A911A9 /* CCQuadCommand.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCQuadCommand.cpp; sourceTree = ""; }; - 50ABBD751925AB4100A911A9 /* CCQuadCommand.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCQuadCommand.h; sourceTree = ""; }; - 50ABBD761925AB4100A911A9 /* CCRenderCommand.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCRenderCommand.cpp; sourceTree = ""; }; - 50ABBD771925AB4100A911A9 /* CCRenderCommand.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCRenderCommand.h; sourceTree = ""; }; - 50ABBD781925AB4100A911A9 /* CCRenderCommandPool.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCRenderCommandPool.h; sourceTree = ""; }; - 50ABBD791925AB4100A911A9 /* CCRenderer.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCRenderer.cpp; sourceTree = ""; }; - 50ABBD7A1925AB4100A911A9 /* CCRenderer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCRenderer.h; sourceTree = ""; }; - 50ABBD7B1925AB4100A911A9 /* ccShaders.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ccShaders.cpp; sourceTree = ""; }; - 50ABBD7C1925AB4100A911A9 /* ccShaders.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ccShaders.h; sourceTree = ""; }; - 50ABBD7D1925AB4100A911A9 /* CCTexture2D.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCTexture2D.cpp; sourceTree = ""; }; - 50ABBD7E1925AB4100A911A9 /* CCTexture2D.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCTexture2D.h; sourceTree = ""; }; - 50ABBD7F1925AB4100A911A9 /* CCTextureAtlas.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCTextureAtlas.cpp; sourceTree = ""; }; - 50ABBD801925AB4100A911A9 /* CCTextureAtlas.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCTextureAtlas.h; sourceTree = ""; }; - 50ABBD811925AB4100A911A9 /* CCTextureCache.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCTextureCache.cpp; sourceTree = ""; }; - 50ABBD821925AB4100A911A9 /* CCTextureCache.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCTextureCache.h; sourceTree = ""; }; - 50ABBDC31925AB6E00A911A9 /* base64.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = base64.cpp; path = ../base/base64.cpp; sourceTree = ""; }; - 50ABBDC41925AB6E00A911A9 /* base64.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = base64.h; path = ../base/base64.h; sourceTree = ""; }; - 50ABBDC51925AB6E00A911A9 /* CCAutoreleasePool.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CCAutoreleasePool.cpp; path = ../base/CCAutoreleasePool.cpp; sourceTree = ""; }; - 50ABBDC61925AB6E00A911A9 /* CCAutoreleasePool.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCAutoreleasePool.h; path = ../base/CCAutoreleasePool.h; sourceTree = ""; }; - 50ABBDC71925AB6E00A911A9 /* ccCArray.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = ccCArray.cpp; path = ../base/ccCArray.cpp; sourceTree = ""; }; - 50ABBDC81925AB6E00A911A9 /* ccCArray.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = ccCArray.h; path = ../base/ccCArray.h; sourceTree = ""; }; - 50ABBDC91925AB6E00A911A9 /* ccConfig.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = ccConfig.h; path = ../base/ccConfig.h; sourceTree = ""; }; - 50ABBDCA1925AB6E00A911A9 /* CCConfiguration.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CCConfiguration.cpp; path = ../base/CCConfiguration.cpp; sourceTree = ""; }; - 50ABBDCB1925AB6E00A911A9 /* CCConfiguration.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCConfiguration.h; path = ../base/CCConfiguration.h; sourceTree = ""; }; - 50ABBDCC1925AB6E00A911A9 /* CCConsole.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CCConsole.cpp; path = ../base/CCConsole.cpp; sourceTree = ""; }; - 50ABBDCD1925AB6E00A911A9 /* CCConsole.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCConsole.h; path = ../base/CCConsole.h; sourceTree = ""; }; - 50ABBDCE1925AB6E00A911A9 /* CCData.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CCData.cpp; path = ../base/CCData.cpp; sourceTree = ""; }; - 50ABBDCF1925AB6E00A911A9 /* CCData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCData.h; path = ../base/CCData.h; sourceTree = ""; }; - 50ABBDD21925AB6E00A911A9 /* CCDirector.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CCDirector.cpp; path = ../base/CCDirector.cpp; sourceTree = ""; }; - 50ABBDD31925AB6E00A911A9 /* CCDirector.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCDirector.h; path = ../base/CCDirector.h; sourceTree = ""; }; - 50ABBDD41925AB6E00A911A9 /* CCEvent.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CCEvent.cpp; path = ../base/CCEvent.cpp; sourceTree = ""; }; - 50ABBDD51925AB6E00A911A9 /* CCEvent.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCEvent.h; path = ../base/CCEvent.h; sourceTree = ""; }; - 50ABBDD61925AB6E00A911A9 /* CCEventAcceleration.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CCEventAcceleration.cpp; path = ../base/CCEventAcceleration.cpp; sourceTree = ""; }; - 50ABBDD71925AB6E00A911A9 /* CCEventAcceleration.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCEventAcceleration.h; path = ../base/CCEventAcceleration.h; sourceTree = ""; }; - 50ABBDD81925AB6E00A911A9 /* CCEventCustom.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CCEventCustom.cpp; path = ../base/CCEventCustom.cpp; sourceTree = ""; }; - 50ABBDD91925AB6E00A911A9 /* CCEventCustom.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCEventCustom.h; path = ../base/CCEventCustom.h; sourceTree = ""; }; - 50ABBDDA1925AB6E00A911A9 /* CCEventDispatcher.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CCEventDispatcher.cpp; path = ../base/CCEventDispatcher.cpp; sourceTree = ""; }; - 50ABBDDB1925AB6E00A911A9 /* CCEventDispatcher.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCEventDispatcher.h; path = ../base/CCEventDispatcher.h; sourceTree = ""; }; - 50ABBDDC1925AB6E00A911A9 /* CCEventFocus.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CCEventFocus.cpp; path = ../base/CCEventFocus.cpp; sourceTree = ""; }; - 50ABBDDD1925AB6E00A911A9 /* CCEventFocus.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCEventFocus.h; path = ../base/CCEventFocus.h; sourceTree = ""; }; - 50ABBDDE1925AB6E00A911A9 /* CCEventKeyboard.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CCEventKeyboard.cpp; path = ../base/CCEventKeyboard.cpp; sourceTree = ""; }; - 50ABBDDF1925AB6E00A911A9 /* CCEventKeyboard.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCEventKeyboard.h; path = ../base/CCEventKeyboard.h; sourceTree = ""; }; - 50ABBDE01925AB6E00A911A9 /* CCEventListener.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CCEventListener.cpp; path = ../base/CCEventListener.cpp; sourceTree = ""; }; - 50ABBDE11925AB6E00A911A9 /* CCEventListener.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCEventListener.h; path = ../base/CCEventListener.h; sourceTree = ""; }; - 50ABBDE21925AB6E00A911A9 /* CCEventListenerAcceleration.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CCEventListenerAcceleration.cpp; path = ../base/CCEventListenerAcceleration.cpp; sourceTree = ""; }; - 50ABBDE31925AB6E00A911A9 /* CCEventListenerAcceleration.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCEventListenerAcceleration.h; path = ../base/CCEventListenerAcceleration.h; sourceTree = ""; }; - 50ABBDE41925AB6E00A911A9 /* CCEventListenerCustom.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CCEventListenerCustom.cpp; path = ../base/CCEventListenerCustom.cpp; sourceTree = ""; }; - 50ABBDE51925AB6E00A911A9 /* CCEventListenerCustom.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCEventListenerCustom.h; path = ../base/CCEventListenerCustom.h; sourceTree = ""; }; - 50ABBDE61925AB6E00A911A9 /* CCEventListenerFocus.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CCEventListenerFocus.cpp; path = ../base/CCEventListenerFocus.cpp; sourceTree = ""; }; - 50ABBDE71925AB6E00A911A9 /* CCEventListenerFocus.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCEventListenerFocus.h; path = ../base/CCEventListenerFocus.h; sourceTree = ""; }; - 50ABBDE81925AB6E00A911A9 /* CCEventListenerKeyboard.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CCEventListenerKeyboard.cpp; path = ../base/CCEventListenerKeyboard.cpp; sourceTree = ""; }; - 50ABBDE91925AB6E00A911A9 /* CCEventListenerKeyboard.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCEventListenerKeyboard.h; path = ../base/CCEventListenerKeyboard.h; sourceTree = ""; }; - 50ABBDEA1925AB6E00A911A9 /* CCEventListenerMouse.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CCEventListenerMouse.cpp; path = ../base/CCEventListenerMouse.cpp; sourceTree = ""; }; - 50ABBDEB1925AB6E00A911A9 /* CCEventListenerMouse.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCEventListenerMouse.h; path = ../base/CCEventListenerMouse.h; sourceTree = ""; }; - 50ABBDEC1925AB6E00A911A9 /* CCEventListenerTouch.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CCEventListenerTouch.cpp; path = ../base/CCEventListenerTouch.cpp; sourceTree = ""; }; - 50ABBDED1925AB6E00A911A9 /* CCEventListenerTouch.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCEventListenerTouch.h; path = ../base/CCEventListenerTouch.h; sourceTree = ""; }; - 50ABBDEE1925AB6E00A911A9 /* CCEventMouse.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CCEventMouse.cpp; path = ../base/CCEventMouse.cpp; sourceTree = ""; }; - 50ABBDEF1925AB6E00A911A9 /* CCEventMouse.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCEventMouse.h; path = ../base/CCEventMouse.h; sourceTree = ""; }; - 50ABBDF01925AB6E00A911A9 /* CCEventTouch.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CCEventTouch.cpp; path = ../base/CCEventTouch.cpp; sourceTree = ""; }; - 50ABBDF11925AB6E00A911A9 /* CCEventTouch.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCEventTouch.h; path = ../base/CCEventTouch.h; sourceTree = ""; }; - 50ABBDF21925AB6E00A911A9 /* CCEventType.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCEventType.h; path = ../base/CCEventType.h; sourceTree = ""; }; - 50ABBDF31925AB6E00A911A9 /* ccFPSImages.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = ccFPSImages.c; path = ../base/ccFPSImages.c; sourceTree = ""; }; - 50ABBDF41925AB6E00A911A9 /* ccFPSImages.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = ccFPSImages.h; path = ../base/ccFPSImages.h; sourceTree = ""; }; - 50ABBDF51925AB6E00A911A9 /* ccMacros.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = ccMacros.h; path = ../base/ccMacros.h; sourceTree = ""; }; - 50ABBDF61925AB6E00A911A9 /* CCMap.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCMap.h; path = ../base/CCMap.h; sourceTree = ""; }; - 50ABBDF71925AB6E00A911A9 /* CCNS.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CCNS.cpp; path = ../base/CCNS.cpp; sourceTree = ""; }; - 50ABBDF81925AB6E00A911A9 /* CCNS.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCNS.h; path = ../base/CCNS.h; sourceTree = ""; }; - 50ABBDFB1925AB6E00A911A9 /* CCProfiling.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CCProfiling.cpp; path = ../base/CCProfiling.cpp; sourceTree = ""; }; - 50ABBDFC1925AB6E00A911A9 /* CCProfiling.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCProfiling.h; path = ../base/CCProfiling.h; sourceTree = ""; }; - 50ABBDFD1925AB6E00A911A9 /* CCProtocols.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCProtocols.h; path = ../base/CCProtocols.h; sourceTree = ""; }; - 50ABBDFE1925AB6E00A911A9 /* CCRef.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CCRef.cpp; path = ../base/CCRef.cpp; sourceTree = ""; }; - 50ABBDFF1925AB6E00A911A9 /* CCRef.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCRef.h; path = ../base/CCRef.h; sourceTree = ""; }; - 50ABBE001925AB6E00A911A9 /* CCRefPtr.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCRefPtr.h; path = ../base/CCRefPtr.h; sourceTree = ""; }; - 50ABBE011925AB6E00A911A9 /* CCScheduler.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CCScheduler.cpp; path = ../base/CCScheduler.cpp; sourceTree = ""; }; - 50ABBE021925AB6E00A911A9 /* CCScheduler.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCScheduler.h; path = ../base/CCScheduler.h; sourceTree = ""; }; - 50ABBE031925AB6E00A911A9 /* CCScriptSupport.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CCScriptSupport.cpp; path = ../base/CCScriptSupport.cpp; sourceTree = ""; }; - 50ABBE041925AB6E00A911A9 /* CCScriptSupport.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCScriptSupport.h; path = ../base/CCScriptSupport.h; sourceTree = ""; }; - 50ABBE051925AB6E00A911A9 /* CCTouch.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CCTouch.cpp; path = ../base/CCTouch.cpp; sourceTree = ""; }; - 50ABBE061925AB6E00A911A9 /* CCTouch.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCTouch.h; path = ../base/CCTouch.h; sourceTree = ""; }; - 50ABBE071925AB6E00A911A9 /* ccTypes.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = ccTypes.cpp; path = ../base/ccTypes.cpp; sourceTree = ""; }; - 50ABBE081925AB6E00A911A9 /* ccTypes.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = ccTypes.h; path = ../base/ccTypes.h; sourceTree = ""; }; - 50ABBE091925AB6E00A911A9 /* CCUserDefault.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CCUserDefault.cpp; path = ../base/CCUserDefault.cpp; sourceTree = ""; }; - 50ABBE0A1925AB6E00A911A9 /* CCUserDefault.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCUserDefault.h; path = ../base/CCUserDefault.h; sourceTree = ""; }; - 50ABBE0B1925AB6F00A911A9 /* CCUserDefault-apple.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; name = "CCUserDefault-apple.mm"; path = "../base/CCUserDefault-apple.mm"; sourceTree = ""; }; - 50ABBE0D1925AB6F00A911A9 /* ccUTF8.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = ccUTF8.cpp; path = ../base/ccUTF8.cpp; sourceTree = ""; }; - 50ABBE0E1925AB6F00A911A9 /* ccUTF8.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = ccUTF8.h; path = ../base/ccUTF8.h; sourceTree = ""; }; - 50ABBE0F1925AB6F00A911A9 /* ccUtils.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = ccUtils.cpp; path = ../base/ccUtils.cpp; sourceTree = ""; }; - 50ABBE101925AB6F00A911A9 /* ccUtils.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = ccUtils.h; path = ../base/ccUtils.h; sourceTree = ""; }; - 50ABBE111925AB6F00A911A9 /* CCValue.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CCValue.cpp; path = ../base/CCValue.cpp; sourceTree = ""; }; - 50ABBE121925AB6F00A911A9 /* CCValue.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCValue.h; path = ../base/CCValue.h; sourceTree = ""; }; - 50ABBE131925AB6F00A911A9 /* CCVector.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCVector.h; path = ../base/CCVector.h; sourceTree = ""; }; - 50ABBE141925AB6F00A911A9 /* etc1.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = etc1.cpp; path = ../base/etc1.cpp; sourceTree = ""; }; - 50ABBE151925AB6F00A911A9 /* etc1.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = etc1.h; path = ../base/etc1.h; sourceTree = ""; }; - 50ABBE161925AB6F00A911A9 /* firePngData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = firePngData.h; path = ../base/firePngData.h; sourceTree = ""; }; - 50ABBE191925AB6F00A911A9 /* TGAlib.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = TGAlib.cpp; path = ../base/TGAlib.cpp; sourceTree = ""; }; - 50ABBE1A1925AB6F00A911A9 /* TGAlib.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = TGAlib.h; path = ../base/TGAlib.h; sourceTree = ""; }; - 50ABBE1B1925AB6F00A911A9 /* uthash.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = uthash.h; path = ../base/uthash.h; sourceTree = ""; }; - 50ABBE1C1925AB6F00A911A9 /* utlist.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = utlist.h; path = ../base/utlist.h; sourceTree = ""; }; - 50ABBE1D1925AB6F00A911A9 /* ZipUtils.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = ZipUtils.cpp; path = ../base/ZipUtils.cpp; sourceTree = ""; }; - 50ABBE1E1925AB6F00A911A9 /* ZipUtils.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = ZipUtils.h; path = ../base/ZipUtils.h; sourceTree = ""; }; 50ABBF1B1926664700A911A9 /* CCFileUtils-apple.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "CCFileUtils-apple.h"; sourceTree = ""; }; 50ABBF1C1926664700A911A9 /* CCFileUtils-apple.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = "CCFileUtils-apple.mm"; sourceTree = ""; }; 50ABBF1D1926664700A911A9 /* CCLock-apple.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = "CCLock-apple.cpp"; sourceTree = ""; }; 50ABBF1E1926664700A911A9 /* CCLock-apple.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "CCLock-apple.h"; sourceTree = ""; }; - 50ABBF1F1926664700A911A9 /* CCThread-apple.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = "CCThread-apple.mm"; sourceTree = ""; }; - 50ABBF201926664700A911A9 /* CCApplicationProtocol.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCApplicationProtocol.h; sourceTree = ""; }; - 50ABBF211926664700A911A9 /* CCCommon.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCCommon.h; sourceTree = ""; }; 50ABBF221926664700A911A9 /* CCDevice.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCDevice.h; sourceTree = ""; }; 50ABBF231926664700A911A9 /* CCFileUtils.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCFileUtils.cpp; sourceTree = ""; }; 50ABBF241926664700A911A9 /* CCFileUtils.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCFileUtils.h; sourceTree = ""; }; - 50ABBF251926664700A911A9 /* CCGLView.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCGLView.cpp; sourceTree = ""; }; - 50ABBF261926664700A911A9 /* CCGLView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCGLView.h; sourceTree = ""; }; 50ABBF271926664700A911A9 /* CCImage.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCImage.cpp; sourceTree = ""; }; 50ABBF281926664700A911A9 /* CCImage.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCImage.h; sourceTree = ""; }; 50ABBF291926664700A911A9 /* CCSAXParser.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCSAXParser.cpp; sourceTree = ""; }; 50ABBF2A1926664700A911A9 /* CCSAXParser.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCSAXParser.h; sourceTree = ""; }; - 50ABBF2B1926664700A911A9 /* CCThread.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCThread.cpp; sourceTree = ""; }; - 50ABBF2C1926664700A911A9 /* CCThread.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCThread.h; sourceTree = ""; }; - 50ABBF2E1926664700A911A9 /* CCGLViewImpl-desktop.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = "CCGLViewImpl-desktop.cpp"; sourceTree = ""; }; - 50ABBF2F1926664700A911A9 /* CCGLViewImpl-desktop.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "CCGLViewImpl-desktop.h"; sourceTree = ""; }; - 50ABBF4F1926664700A911A9 /* CCApplication-mac.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "CCApplication-mac.h"; sourceTree = ""; }; - 50ABBF501926664700A911A9 /* CCApplication-mac.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = "CCApplication-mac.mm"; sourceTree = ""; }; - 50ABBF511926664700A911A9 /* CCCommon-mac.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = "CCCommon-mac.mm"; sourceTree = ""; }; 50ABBF521926664700A911A9 /* CCDevice-mac.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = "CCDevice-mac.mm"; sourceTree = ""; }; 50ABBF531926664700A911A9 /* CCGL-mac.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "CCGL-mac.h"; sourceTree = ""; }; 50ABBF541926664700A911A9 /* CCPlatformDefine-mac.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "CCPlatformDefine-mac.h"; sourceTree = ""; }; 50ABBF551926664700A911A9 /* CCStdC-mac.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "CCStdC-mac.h"; sourceTree = ""; }; - 50CB246F19D9C5A100687767 /* AudioCache.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AudioCache.h; sourceTree = ""; }; - 50CB247019D9C5A100687767 /* AudioCache.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = AudioCache.mm; sourceTree = ""; }; - 50CB247119D9C5A100687767 /* AudioEngine-inl.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "AudioEngine-inl.h"; sourceTree = ""; }; - 50CB247219D9C5A100687767 /* AudioEngine-inl.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = "AudioEngine-inl.mm"; sourceTree = ""; }; - 50CB247319D9C5A100687767 /* AudioPlayer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AudioPlayer.h; sourceTree = ""; }; - 50CB247419D9C5A100687767 /* AudioPlayer.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = AudioPlayer.mm; sourceTree = ""; }; - 50ED2BDC19BEAF7900A0AB90 /* UIEditBoxImpl-win32.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UIEditBoxImpl-win32.h"; sourceTree = ""; }; - 50ED2BDE19BEAF7900A0AB90 /* UIEditBoxImpl-win32.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = "UIEditBoxImpl-win32.cpp"; sourceTree = ""; }; - 52B47A291A5349A3004E4C60 /* HttpAsynConnection-apple.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "HttpAsynConnection-apple.h"; sourceTree = ""; }; - 52B47A2A1A5349A3004E4C60 /* HttpAsynConnection-apple.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "HttpAsynConnection-apple.m"; sourceTree = ""; }; - 52B47A2B1A5349A3004E4C60 /* HttpClient-apple.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = "HttpClient-apple.mm"; sourceTree = ""; }; - 52B47A2C1A5349A3004E4C60 /* HttpCookie.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = HttpCookie.cpp; sourceTree = ""; }; - 52B47A2D1A5349A3004E4C60 /* HttpCookie.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = HttpCookie.h; sourceTree = ""; }; - 844EB11D1F78D4CA00EFE4CD /* CCThreadPool.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CCThreadPool.cpp; path = ../base/CCThreadPool.cpp; sourceTree = ""; }; - 844EB11E1F78D4CA00EFE4CD /* CCThreadPool.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCThreadPool.h; path = ../base/CCThreadPool.h; sourceTree = ""; }; - A0534A631B872FFD006B03E5 /* CCDownloader-apple.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "CCDownloader-apple.h"; sourceTree = ""; }; - A0534A641B872FFD006B03E5 /* CCDownloader-apple.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = "CCDownloader-apple.mm"; sourceTree = ""; }; - A0534A691B87306E006B03E5 /* CCIDownloaderImpl.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCIDownloaderImpl.h; sourceTree = ""; }; - A05DCF9B1B90584E00EE040B /* CCDownloader-curl.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = "CCDownloader-curl.cpp"; sourceTree = ""; }; - A05DCF9C1B90584E00EE040B /* CCDownloader-curl.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "CCDownloader-curl.h"; sourceTree = ""; }; A07A4D641783777C0073F6A7 /* libcocos2d iOS.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libcocos2d iOS.a"; sourceTree = BUILT_PRODUCTS_DIR; }; - A0E749F51BA8FD7F001A8332 /* UIEditBoxImpl-common.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = "UIEditBoxImpl-common.cpp"; sourceTree = ""; }; - A0E749F61BA8FD7F001A8332 /* UIEditBoxImpl-common.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UIEditBoxImpl-common.h"; sourceTree = ""; }; A60A9D651C200E5A0070800A /* libchipmunk.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libchipmunk.a; path = ../external/ios/libs/libchipmunk.a; sourceTree = ""; }; - A614E2DE1C8E72360065A737 /* CCLabelTTF.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCLabelTTF.h; sourceTree = ""; }; - A63CEFF91CD9CF3500A6971D /* CCUIEditBoxMac.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCUIEditBoxMac.h; path = Mac/CCUIEditBoxMac.h; sourceTree = ""; }; - A63CEFFA1CD9CF3500A6971D /* CCUIEditBoxMac.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; name = CCUIEditBoxMac.mm; path = Mac/CCUIEditBoxMac.mm; sourceTree = ""; }; - A63CEFFB1CD9CF3500A6971D /* CCUIMultilineTextField.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCUIMultilineTextField.h; path = Mac/CCUIMultilineTextField.h; sourceTree = ""; }; - A63CEFFC1CD9CF3500A6971D /* CCUIMultilineTextField.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = CCUIMultilineTextField.m; path = Mac/CCUIMultilineTextField.m; sourceTree = ""; }; - A63CEFFD1CD9CF3500A6971D /* CCUIPasswordTextField.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCUIPasswordTextField.h; path = Mac/CCUIPasswordTextField.h; sourceTree = ""; }; - A63CEFFE1CD9CF3500A6971D /* CCUIPasswordTextField.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = CCUIPasswordTextField.m; path = Mac/CCUIPasswordTextField.m; sourceTree = ""; }; - A63CEFFF1CD9CF3500A6971D /* CCUISingleLineTextField.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCUISingleLineTextField.h; path = Mac/CCUISingleLineTextField.h; sourceTree = ""; }; - A63CF0001CD9CF3500A6971D /* CCUISingleLineTextField.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = CCUISingleLineTextField.m; path = Mac/CCUISingleLineTextField.m; sourceTree = ""; }; - A63CF0011CD9CF3500A6971D /* CCUITextFieldFormatter.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCUITextFieldFormatter.h; path = Mac/CCUITextFieldFormatter.h; sourceTree = ""; }; - A63CF0021CD9CF3500A6971D /* CCUITextFieldFormatter.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = CCUITextFieldFormatter.m; path = Mac/CCUITextFieldFormatter.m; sourceTree = ""; }; - A63CF0031CD9CF3500A6971D /* CCUITextInput.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCUITextInput.h; path = Mac/CCUITextInput.h; sourceTree = ""; }; A6A5541E1C2A7BF700FDD954 /* libchipmunk.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libchipmunk.a; path = ../external/mac/libs/libchipmunk.a; sourceTree = ""; }; A6A554201C2A7C1300FDD954 /* libcurl.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libcurl.a; path = ../external/mac/libs/libcurl.a; sourceTree = ""; }; A6A554221C2A7C3100FDD954 /* libcrypto.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libcrypto.a; path = ../external/mac/libs/libcrypto.a; sourceTree = ""; }; A6A554241C2A7C4400FDD954 /* libssl.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libssl.a; path = ../external/mac/libs/libssl.a; sourceTree = ""; }; - A6F0D79F1C2796020029CC44 /* CCStencilStateManager.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CCStencilStateManager.cpp; path = ../base/CCStencilStateManager.cpp; sourceTree = ""; }; - A6F0D7A01C2796020029CC44 /* CCStencilStateManager.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; name = CCStencilStateManager.hpp; path = ../base/CCStencilStateManager.hpp; sourceTree = ""; }; - B20564AA1A6E5744001C1B6E /* ccShader_PositionColorTextureAsPointsize.vert */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.glsl; path = ccShader_PositionColorTextureAsPointsize.vert; sourceTree = ""; }; B217703B1977ECB4009EE11B /* IOKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = IOKit.framework; path = System/Library/Frameworks/IOKit.framework; sourceTree = SDKROOT; }; B217703D1977ECC1009EE11B /* AudioToolbox.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AudioToolbox.framework; path = System/Library/Frameworks/AudioToolbox.framework; sourceTree = SDKROOT; }; B217703F1977ECE6009EE11B /* OpenGL.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = OpenGL.framework; path = System/Library/Frameworks/OpenGL.framework; sourceTree = SDKROOT; }; B21770411977ECF8009EE11B /* ApplicationServices.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = ApplicationServices.framework; path = System/Library/Frameworks/ApplicationServices.framework; sourceTree = SDKROOT; }; B21770431977ED07009EE11B /* Cocoa.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Cocoa.framework; path = System/Library/Frameworks/Cocoa.framework; sourceTree = SDKROOT; }; B21770461977ED34009EE11B /* QuartzCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = QuartzCore.framework; path = System/Library/Frameworks/QuartzCore.framework; sourceTree = SDKROOT; }; - B230ED6F19B417AE00364AA8 /* CCTrianglesCommand.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCTrianglesCommand.cpp; sourceTree = ""; }; - B230ED7019B417AE00364AA8 /* CCTrianglesCommand.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCTrianglesCommand.h; sourceTree = ""; }; - B241A6E21AFB0BE700C5623C /* ccShader_CameraClear.frag */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.glsl; path = ccShader_CameraClear.frag; sourceTree = ""; }; - B241A6E31AFB0BE700C5623C /* ccShader_CameraClear.vert */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.glsl; path = ccShader_CameraClear.vert; sourceTree = ""; }; - B24AA981195A675C007B4522 /* CCFastTMXLayer.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCFastTMXLayer.cpp; sourceTree = ""; }; - B24AA982195A675C007B4522 /* CCFastTMXLayer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCFastTMXLayer.h; sourceTree = ""; }; - B24AA983195A675C007B4522 /* CCFastTMXTiledMap.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCFastTMXTiledMap.cpp; sourceTree = ""; }; - B24AA984195A675C007B4522 /* CCFastTMXTiledMap.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCFastTMXTiledMap.h; sourceTree = ""; }; - B257B44C1989D5E800D9A687 /* CCPrimitive.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCPrimitive.cpp; sourceTree = ""; }; - B257B44D1989D5E800D9A687 /* CCPrimitive.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCPrimitive.h; sourceTree = ""; }; - B257B45E198A353E00D9A687 /* CCPrimitiveCommand.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCPrimitiveCommand.cpp; sourceTree = ""; }; - B257B45F198A353E00D9A687 /* CCPrimitiveCommand.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCPrimitiveCommand.h; sourceTree = ""; }; - B276EF5B1988D1D500CD400F /* CCVertexIndexData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCVertexIndexData.h; sourceTree = ""; }; - B276EF5C1988D1D500CD400F /* CCVertexIndexData.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCVertexIndexData.cpp; sourceTree = ""; }; - B276EF5D1988D1D500CD400F /* CCVertexIndexBuffer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCVertexIndexBuffer.h; sourceTree = ""; }; - B276EF5E1988D1D500CD400F /* CCVertexIndexBuffer.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCVertexIndexBuffer.cpp; sourceTree = ""; }; B291B5171D4A106A00BBB345 /* libjpeg.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libjpeg.a; path = ../external/ios/libs/libjpeg.a; sourceTree = ""; }; B291B5181D4A106A00BBB345 /* libpng.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libpng.a; path = ../external/ios/libs/libpng.a; sourceTree = ""; }; B291B5191D4A106A00BBB345 /* libtiff.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libtiff.a; path = ../external/ios/libs/libtiff.a; sourceTree = ""; }; B291B51A1D4A106A00BBB345 /* libwebp.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libwebp.a; path = ../external/ios/libs/libwebp.a; sourceTree = ""; }; - B63990CA1A490AFE00B07923 /* CCAsyncTaskPool.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CCAsyncTaskPool.cpp; path = ../base/CCAsyncTaskPool.cpp; sourceTree = ""; }; - B63990CB1A490AFE00B07923 /* CCAsyncTaskPool.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCAsyncTaskPool.h; path = ../base/CCAsyncTaskPool.h; sourceTree = ""; }; BA0DAAEE1DB76F2C00EE23AD /* libwebp.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libwebp.a; path = ../external/mac/libs/libwebp.a; sourceTree = ""; }; - BA679B281CEC373000F875FA /* AssetsManagerEx.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = AssetsManagerEx.cpp; path = "assets-manager/AssetsManagerEx.cpp"; sourceTree = ""; }; - BA679B291CEC373000F875FA /* AssetsManagerEx.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = AssetsManagerEx.h; path = "assets-manager/AssetsManagerEx.h"; sourceTree = ""; }; - BA679B2A1CEC373000F875FA /* CCEventAssetsManagerEx.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CCEventAssetsManagerEx.cpp; path = "assets-manager/CCEventAssetsManagerEx.cpp"; sourceTree = ""; }; - BA679B2B1CEC373000F875FA /* CCEventAssetsManagerEx.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCEventAssetsManagerEx.h; path = "assets-manager/CCEventAssetsManagerEx.h"; sourceTree = ""; }; - BA679B2C1CEC373000F875FA /* CCEventListenerAssetsManagerEx.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CCEventListenerAssetsManagerEx.cpp; path = "assets-manager/CCEventListenerAssetsManagerEx.cpp"; sourceTree = ""; }; - BA679B2D1CEC373000F875FA /* CCEventListenerAssetsManagerEx.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCEventListenerAssetsManagerEx.h; path = "assets-manager/CCEventListenerAssetsManagerEx.h"; sourceTree = ""; }; - BA679B2E1CEC373000F875FA /* Manifest.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = Manifest.cpp; path = "assets-manager/Manifest.cpp"; sourceTree = ""; }; - BA679B2F1CEC373000F875FA /* Manifest.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = Manifest.h; path = "assets-manager/Manifest.h"; sourceTree = ""; }; BA68D7701D62F4A500B7A3F9 /* shapes.cc */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = shapes.cc; sourceTree = ""; }; BA68D7711D62F4A500B7A3F9 /* shapes.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = shapes.h; sourceTree = ""; }; BA68D7721D62F4A500B7A3F9 /* utils.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = utils.h; sourceTree = ""; }; @@ -2233,87 +1110,9 @@ BA68D77C1D62F4A500B7A3F9 /* sweep_context.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = sweep_context.h; sourceTree = ""; }; BA68D7961D62F4B600B7A3F9 /* clipper.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = clipper.cpp; sourceTree = ""; }; BA68D7971D62F4B600B7A3F9 /* clipper.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = clipper.hpp; sourceTree = ""; }; - BA8122AA1D77C4150010BEE9 /* CCLabelTTF.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCLabelTTF.cpp; sourceTree = ""; }; BAEA45521E279D5C00FA219F /* COPYING */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = COPYING; sourceTree = ""; }; BAEA45531E279D5C00FA219F /* package.json */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.json; path = package.json; sourceTree = ""; }; BAEA45541E279D5C00FA219F /* tinydir.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = tinydir.h; sourceTree = ""; }; - BAFF7CFB1D5C1CF80051B92F /* Animation.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = Animation.c; sourceTree = ""; }; - BAFF7CFC1D5C1CF80051B92F /* Animation.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Animation.h; sourceTree = ""; }; - BAFF7CFD1D5C1CF80051B92F /* AnimationState.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = AnimationState.c; sourceTree = ""; }; - BAFF7CFE1D5C1CF80051B92F /* AnimationState.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AnimationState.h; sourceTree = ""; }; - BAFF7CFF1D5C1CF80051B92F /* AnimationStateData.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = AnimationStateData.c; sourceTree = ""; }; - BAFF7D001D5C1CF80051B92F /* AnimationStateData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AnimationStateData.h; sourceTree = ""; }; - BAFF7D011D5C1CF80051B92F /* Atlas.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = Atlas.c; sourceTree = ""; }; - BAFF7D021D5C1CF80051B92F /* Atlas.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Atlas.h; sourceTree = ""; }; - BAFF7D031D5C1CF80051B92F /* AtlasAttachmentLoader.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = AtlasAttachmentLoader.c; sourceTree = ""; }; - BAFF7D041D5C1CF80051B92F /* AtlasAttachmentLoader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AtlasAttachmentLoader.h; sourceTree = ""; }; - BAFF7D051D5C1CF80051B92F /* Attachment.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = Attachment.c; sourceTree = ""; }; - BAFF7D061D5C1CF80051B92F /* Attachment.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Attachment.h; sourceTree = ""; }; - BAFF7D071D5C1CF80051B92F /* AttachmentLoader.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = AttachmentLoader.c; sourceTree = ""; }; - BAFF7D081D5C1CF80051B92F /* AttachmentLoader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AttachmentLoader.h; sourceTree = ""; }; - BAFF7D091D5C1CF80051B92F /* AttachmentVertices.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = AttachmentVertices.cpp; sourceTree = ""; }; - BAFF7D0A1D5C1CF80051B92F /* AttachmentVertices.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AttachmentVertices.h; sourceTree = ""; }; - BAFF7D0B1D5C1CF80051B92F /* Bone.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = Bone.c; sourceTree = ""; }; - BAFF7D0C1D5C1CF80051B92F /* Bone.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Bone.h; sourceTree = ""; }; - BAFF7D0D1D5C1CF80051B92F /* BoneData.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = BoneData.c; sourceTree = ""; }; - BAFF7D0E1D5C1CF80051B92F /* BoneData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = BoneData.h; sourceTree = ""; }; - BAFF7D0F1D5C1CF80051B92F /* BoundingBoxAttachment.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = BoundingBoxAttachment.c; sourceTree = ""; }; - BAFF7D101D5C1CF80051B92F /* BoundingBoxAttachment.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = BoundingBoxAttachment.h; sourceTree = ""; }; - BAFF7D111D5C1CF80051B92F /* Cocos2dAttachmentLoader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Cocos2dAttachmentLoader.cpp; sourceTree = ""; }; - BAFF7D121D5C1CF80051B92F /* Cocos2dAttachmentLoader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Cocos2dAttachmentLoader.h; sourceTree = ""; }; - BAFF7D131D5C1CF80051B92F /* Event.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = Event.c; sourceTree = ""; }; - BAFF7D141D5C1CF80051B92F /* Event.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Event.h; sourceTree = ""; }; - BAFF7D151D5C1CF80051B92F /* EventData.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = EventData.c; sourceTree = ""; }; - BAFF7D161D5C1CF80051B92F /* EventData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = EventData.h; sourceTree = ""; }; - BAFF7D171D5C1CF80051B92F /* extension.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = extension.c; sourceTree = ""; }; - BAFF7D181D5C1CF80051B92F /* extension.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = extension.h; sourceTree = ""; }; - BAFF7D191D5C1CF80051B92F /* IkConstraint.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = IkConstraint.c; sourceTree = ""; }; - BAFF7D1A1D5C1CF80051B92F /* IkConstraint.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = IkConstraint.h; sourceTree = ""; }; - BAFF7D1B1D5C1CF80051B92F /* IkConstraintData.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = IkConstraintData.c; sourceTree = ""; }; - BAFF7D1C1D5C1CF80051B92F /* IkConstraintData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = IkConstraintData.h; sourceTree = ""; }; - BAFF7D1D1D5C1CF80051B92F /* Json.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = Json.c; sourceTree = ""; }; - BAFF7D1E1D5C1CF80051B92F /* Json.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Json.h; sourceTree = ""; }; - BAFF7D1F1D5C1CF80051B92F /* MeshAttachment.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = MeshAttachment.c; sourceTree = ""; }; - BAFF7D201D5C1CF80051B92F /* MeshAttachment.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MeshAttachment.h; sourceTree = ""; }; - BAFF7D211D5C1CF80051B92F /* PathAttachment.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = PathAttachment.c; sourceTree = ""; }; - BAFF7D221D5C1CF80051B92F /* PathAttachment.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PathAttachment.h; sourceTree = ""; }; - BAFF7D231D5C1CF80051B92F /* PathConstraint.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = PathConstraint.c; sourceTree = ""; }; - BAFF7D241D5C1CF80051B92F /* PathConstraint.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PathConstraint.h; sourceTree = ""; }; - BAFF7D251D5C1CF80051B92F /* PathConstraintData.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = PathConstraintData.c; sourceTree = ""; }; - BAFF7D261D5C1CF80051B92F /* PathConstraintData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PathConstraintData.h; sourceTree = ""; }; - BAFF7D271D5C1CF80051B92F /* RegionAttachment.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = RegionAttachment.c; sourceTree = ""; }; - BAFF7D281D5C1CF80051B92F /* RegionAttachment.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RegionAttachment.h; sourceTree = ""; }; - BAFF7D291D5C1CF80051B92F /* Skeleton.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = Skeleton.c; sourceTree = ""; }; - BAFF7D2A1D5C1CF80051B92F /* Skeleton.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Skeleton.h; sourceTree = ""; }; - BAFF7D2B1D5C1CF80051B92F /* SkeletonAnimation.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = SkeletonAnimation.cpp; sourceTree = ""; }; - BAFF7D2C1D5C1CF80051B92F /* SkeletonAnimation.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SkeletonAnimation.h; sourceTree = ""; }; - BAFF7D2D1D5C1CF80051B92F /* SkeletonBatch.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = SkeletonBatch.cpp; sourceTree = ""; }; - BAFF7D2E1D5C1CF80051B92F /* SkeletonBatch.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SkeletonBatch.h; sourceTree = ""; }; - BAFF7D2F1D5C1CF80051B92F /* SkeletonBounds.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = SkeletonBounds.c; sourceTree = ""; }; - BAFF7D301D5C1CF80051B92F /* SkeletonBounds.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SkeletonBounds.h; sourceTree = ""; }; - BAFF7D311D5C1CF80051B92F /* SkeletonData.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = SkeletonData.c; sourceTree = ""; }; - BAFF7D321D5C1CF80051B92F /* SkeletonData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SkeletonData.h; sourceTree = ""; }; - BAFF7D331D5C1CF80051B92F /* SkeletonJson.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = SkeletonJson.c; sourceTree = ""; }; - BAFF7D341D5C1CF80051B92F /* SkeletonJson.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SkeletonJson.h; sourceTree = ""; }; - BAFF7D351D5C1CF80051B92F /* SkeletonRenderer.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = SkeletonRenderer.cpp; sourceTree = ""; }; - BAFF7D361D5C1CF80051B92F /* SkeletonRenderer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SkeletonRenderer.h; sourceTree = ""; }; - BAFF7D371D5C1CF80051B92F /* Skin.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = Skin.c; sourceTree = ""; }; - BAFF7D381D5C1CF80051B92F /* Skin.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Skin.h; sourceTree = ""; }; - BAFF7D391D5C1CF80051B92F /* Slot.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = Slot.c; sourceTree = ""; }; - BAFF7D3A1D5C1CF80051B92F /* Slot.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Slot.h; sourceTree = ""; }; - BAFF7D3B1D5C1CF80051B92F /* SlotData.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = SlotData.c; sourceTree = ""; }; - BAFF7D3C1D5C1CF80051B92F /* SlotData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SlotData.h; sourceTree = ""; }; - BAFF7D3D1D5C1CF80051B92F /* spine-cocos2dx.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = "spine-cocos2dx.cpp"; sourceTree = ""; }; - BAFF7D3E1D5C1CF80051B92F /* spine-cocos2dx.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "spine-cocos2dx.h"; sourceTree = ""; }; - BAFF7D3F1D5C1CF80051B92F /* spine.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = spine.h; sourceTree = ""; }; - BAFF7D401D5C1CF80051B92F /* TransformConstraint.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = TransformConstraint.c; sourceTree = ""; }; - BAFF7D411D5C1CF80051B92F /* TransformConstraint.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TransformConstraint.h; sourceTree = ""; }; - BAFF7D421D5C1CF80051B92F /* TransformConstraintData.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = TransformConstraintData.c; sourceTree = ""; }; - BAFF7D431D5C1CF80051B92F /* TransformConstraintData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TransformConstraintData.h; sourceTree = ""; }; - BAFF7D441D5C1CF80051B92F /* VertexAttachment.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = VertexAttachment.c; sourceTree = ""; }; - BAFF7D451D5C1CF80051B92F /* VertexAttachment.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = VertexAttachment.h; sourceTree = ""; }; - DABC9FA719E7DFA900FA252C /* CCClippingRectangleNode.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCClippingRectangleNode.cpp; sourceTree = ""; }; - DABC9FA819E7DFA900FA252C /* CCClippingRectangleNode.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCClippingRectangleNode.h; sourceTree = ""; }; ED3057761BEC76C90083C3ED /* crypt.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = crypt.h; path = ../external/sources/unzip/crypt.h; sourceTree = ""; }; ED3057771BEC76C90083C3ED /* ioapi_mem.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = ioapi_mem.cpp; path = ../external/sources/unzip/ioapi_mem.cpp; sourceTree = ""; }; ED3057781BEC76C90083C3ED /* ioapi_mem.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = ioapi_mem.h; path = ../external/sources/unzip/ioapi_mem.h; sourceTree = ""; }; @@ -2337,72 +1136,7 @@ ED3057CB1BEC7DA80083C3ED /* libpng.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libpng.a; path = ../external/mac/libs/libpng.a; sourceTree = ""; }; ED3057CC1BEC7DA80083C3ED /* libtiff.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libtiff.a; path = ../external/mac/libs/libtiff.a; sourceTree = ""; }; ED3057CD1BEC7DA80083C3ED /* libwebsockets.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libwebsockets.a; path = ../external/mac/libs/libwebsockets.a; sourceTree = ""; }; - ED9C6A9218599AD8000A5232 /* CCNodeGrid.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; lineEnding = 0; path = CCNodeGrid.cpp; sourceTree = ""; xcLanguageSpecificationIdentifier = xcode.lang.cpp; }; - ED9C6A9318599AD8000A5232 /* CCNodeGrid.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCNodeGrid.h; sourceTree = ""; }; EDE5DFF71C0D6B3F0014147A /* libwebsockets.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libwebsockets.a; path = ../external/ios/libs/libwebsockets.a; sourceTree = ""; }; - FA6F1AF91D80F858007DD223 /* Animation.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Animation.cpp; sourceTree = ""; }; - FA6F1AFA1D80F858007DD223 /* Animation.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Animation.h; sourceTree = ""; }; - FA6F1AFB1D80F858007DD223 /* AnimationState.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = AnimationState.cpp; sourceTree = ""; }; - FA6F1AFC1D80F858007DD223 /* AnimationState.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AnimationState.h; sourceTree = ""; }; - FA6F1AFD1D80F858007DD223 /* BaseTimelineState.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = BaseTimelineState.h; sourceTree = ""; }; - FA6F1AFE1D80F858007DD223 /* IAnimateble.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = IAnimateble.h; sourceTree = ""; }; - FA6F1AFF1D80F858007DD223 /* TimelineState.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = TimelineState.cpp; sourceTree = ""; }; - FA6F1B001D80F858007DD223 /* TimelineState.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TimelineState.h; sourceTree = ""; }; - FA6F1B011D80F858007DD223 /* WorldClock.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = WorldClock.cpp; sourceTree = ""; }; - FA6F1B021D80F858007DD223 /* WorldClock.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WorldClock.h; sourceTree = ""; }; - FA6F1B041D80F858007DD223 /* Armature.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Armature.cpp; sourceTree = ""; }; - FA6F1B051D80F858007DD223 /* Armature.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Armature.h; sourceTree = ""; }; - FA6F1B061D80F858007DD223 /* Bone.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Bone.cpp; sourceTree = ""; }; - FA6F1B071D80F858007DD223 /* Bone.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Bone.h; sourceTree = ""; }; - FA6F1B081D80F858007DD223 /* IArmatureDisplay.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = IArmatureDisplay.h; sourceTree = ""; }; - FA6F1B091D80F858007DD223 /* Slot.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Slot.cpp; sourceTree = ""; }; - FA6F1B0A1D80F858007DD223 /* Slot.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Slot.h; sourceTree = ""; }; - FA6F1B0B1D80F858007DD223 /* TransformObject.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TransformObject.h; sourceTree = ""; }; - FA6F1B0D1D80F858007DD223 /* CCArmatureDisplay.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCArmatureDisplay.cpp; sourceTree = ""; }; - FA6F1B0E1D80F858007DD223 /* CCArmatureDisplay.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCArmatureDisplay.h; sourceTree = ""; }; - FA6F1B0F1D80F858007DD223 /* CCDragonBonesHeaders.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCDragonBonesHeaders.h; sourceTree = ""; }; - FA6F1B101D80F858007DD223 /* CCFactory.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCFactory.cpp; sourceTree = ""; }; - FA6F1B111D80F858007DD223 /* CCFactory.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCFactory.h; sourceTree = ""; }; - FA6F1B121D80F858007DD223 /* CCSlot.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCSlot.cpp; sourceTree = ""; }; - FA6F1B131D80F858007DD223 /* CCSlot.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCSlot.h; sourceTree = ""; }; - FA6F1B141D80F858007DD223 /* CCTextureData.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCTextureData.cpp; sourceTree = ""; }; - FA6F1B151D80F858007DD223 /* CCTextureData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCTextureData.h; sourceTree = ""; }; - FA6F1B171D80F858007DD223 /* BaseObject.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = BaseObject.cpp; sourceTree = ""; }; - FA6F1B181D80F858007DD223 /* BaseObject.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = BaseObject.h; sourceTree = ""; }; - FA6F1B191D80F858007DD223 /* DragonBones.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DragonBones.h; sourceTree = ""; }; - FA6F1B1A1D80F858007DD223 /* DragonBonesHeaders.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DragonBonesHeaders.h; sourceTree = ""; }; - FA6F1B1C1D80F858007DD223 /* EventObject.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = EventObject.cpp; sourceTree = ""; }; - FA6F1B1D1D80F858007DD223 /* EventObject.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = EventObject.h; sourceTree = ""; }; - FA6F1B1F1D80F858007DD223 /* BaseFactory.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = BaseFactory.cpp; sourceTree = ""; }; - FA6F1B201D80F858007DD223 /* BaseFactory.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = BaseFactory.h; sourceTree = ""; }; - FA6F1B221D80F858007DD223 /* ColorTransform.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ColorTransform.h; sourceTree = ""; }; - FA6F1B231D80F858007DD223 /* Matrix.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Matrix.h; sourceTree = ""; }; - FA6F1B241D80F858007DD223 /* Point.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Point.h; sourceTree = ""; }; - FA6F1B251D80F858007DD223 /* Rectangle.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Rectangle.h; sourceTree = ""; }; - FA6F1B261D80F858007DD223 /* Transform.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Transform.h; sourceTree = ""; }; - FA6F1B281D80F858007DD223 /* AnimationData.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = AnimationData.cpp; sourceTree = ""; }; - FA6F1B291D80F858007DD223 /* AnimationData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AnimationData.h; sourceTree = ""; }; - FA6F1B2A1D80F858007DD223 /* ArmatureData.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ArmatureData.cpp; sourceTree = ""; }; - FA6F1B2B1D80F858007DD223 /* ArmatureData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ArmatureData.h; sourceTree = ""; }; - FA6F1B2C1D80F858007DD223 /* DragonBonesData.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = DragonBonesData.cpp; sourceTree = ""; }; - FA6F1B2D1D80F858007DD223 /* DragonBonesData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DragonBonesData.h; sourceTree = ""; }; - FA6F1B2E1D80F858007DD223 /* FrameData.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = FrameData.cpp; sourceTree = ""; }; - FA6F1B2F1D80F858007DD223 /* FrameData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = FrameData.h; sourceTree = ""; }; - FA6F1B301D80F858007DD223 /* TimelineData.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = TimelineData.cpp; sourceTree = ""; }; - FA6F1B311D80F858007DD223 /* TimelineData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TimelineData.h; sourceTree = ""; }; - FA6F1B331D80F858007DD223 /* DataParser.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = DataParser.cpp; sourceTree = ""; }; - FA6F1B341D80F858007DD223 /* DataParser.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DataParser.h; sourceTree = ""; }; - FA6F1B351D80F858007DD223 /* JSONDataParser.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JSONDataParser.cpp; sourceTree = ""; }; - FA6F1B361D80F858007DD223 /* JSONDataParser.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JSONDataParser.h; sourceTree = ""; }; - FA6F1B3F1D80F858007DD223 /* TextureData.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = TextureData.cpp; sourceTree = ""; }; - FA6F1B401D80F858007DD223 /* TextureData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TextureData.h; sourceTree = ""; }; - FAC8F2581D339EB70061CEDD /* CCTMXLayer.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCTMXLayer.cpp; sourceTree = ""; }; - FAC8F2591D339EB70061CEDD /* CCTMXLayer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCTMXLayer.h; sourceTree = ""; }; - FAC8F25A1D339EB70061CEDD /* CCTMXTiledMap.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCTMXTiledMap.cpp; sourceTree = ""; }; - FAC8F25B1D339EB70061CEDD /* CCTMXTiledMap.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCTMXTiledMap.h; sourceTree = ""; }; - FAC8F6651E1DF15D002B17E8 /* kvec.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = kvec.h; sourceTree = ""; }; - FAC8F6661E1DF15D002B17E8 /* SkeletonBinary.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = SkeletonBinary.c; sourceTree = ""; }; - FAC8F6671E1DF15D002B17E8 /* SkeletonBinary.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SkeletonBinary.h; sourceTree = ""; }; /* End PBXFileReference section */ /* Begin PBXFrameworksBuildPhase section */ @@ -2455,20 +1189,13 @@ children = ( 50272539190BF1B900AAF4ED /* cocos2d.cpp */, 50272538190BF1B900AAF4ED /* cocos2d.h */, - 46A169A11807B037005B8026 /* 2d */, - 46A15FD01807A56F005B8026 /* audio */, - 1A5700A2180BC5E60088DEC7 /* base */, - 1AD71CF7180E26E600808F54 /* editor-support */, - 46A167981807AF4D005B8026 /* extensions */, + 46FDDAE9202ADDCE00931238 /* base */, + 46FDDA2C202ACC6A00931238 /* renderer */, 1A57033E180BD0490088DEC7 /* external */, 1551A341158F2AB200E66CFE /* Frameworks */, 46A170851807CE87005B8026 /* math */, - 1AAF5360180E3374000584C8 /* network */, 50ABBEDB1926664700A911A9 /* platform */, 1551A340158F2AB200E66CFE /* Products */, - 500DC89819105D41007B91BF /* renderer */, - 1AAF5849180E40B8000584C8 /* storage */, - 2905F9E618CF08D000240AA3 /* ui */, ); sourceTree = ""; usesTabs = 0; @@ -2606,342 +1333,10 @@ path = Utilities; sourceTree = ""; }; - 1A570046180BC59A0088DEC7 /* actions */ = { - isa = PBXGroup; - children = ( - 2986667818B1B079000E39CA /* CCTweenFunction.cpp */, - 2986667918B1B079000E39CA /* CCTweenFunction.h */, - 1A570047180BC5A10088DEC7 /* CCAction.cpp */, - 1A570048180BC5A10088DEC7 /* CCAction.h */, - 1A570049180BC5A10088DEC7 /* CCActionCamera.cpp */, - 1A57004A180BC5A10088DEC7 /* CCActionCamera.h */, - 1A57004B180BC5A10088DEC7 /* CCActionCatmullRom.cpp */, - 1A57004C180BC5A10088DEC7 /* CCActionCatmullRom.h */, - 1A57004D180BC5A10088DEC7 /* CCActionEase.cpp */, - 1A57004E180BC5A10088DEC7 /* CCActionEase.h */, - 1A57004F180BC5A10088DEC7 /* CCActionGrid.cpp */, - 1A570050180BC5A10088DEC7 /* CCActionGrid.h */, - 1A570051180BC5A10088DEC7 /* CCActionGrid3D.cpp */, - 1A570052180BC5A10088DEC7 /* CCActionGrid3D.h */, - 1A570053180BC5A10088DEC7 /* CCActionInstant.cpp */, - 1A570054180BC5A10088DEC7 /* CCActionInstant.h */, - 1A570055180BC5A10088DEC7 /* CCActionInterval.cpp */, - 1A570056180BC5A10088DEC7 /* CCActionInterval.h */, - 1A570057180BC5A10088DEC7 /* CCActionManager.cpp */, - 1A570058180BC5A10088DEC7 /* CCActionManager.h */, - 1A570059180BC5A10088DEC7 /* CCActionPageTurn3D.cpp */, - 1A57005A180BC5A10088DEC7 /* CCActionPageTurn3D.h */, - 1A57005B180BC5A10088DEC7 /* CCActionProgressTimer.cpp */, - 1A57005C180BC5A10088DEC7 /* CCActionProgressTimer.h */, - 1A57005D180BC5A10088DEC7 /* CCActionTiledGrid.cpp */, - 1A57005E180BC5A10088DEC7 /* CCActionTiledGrid.h */, - 1A57005F180BC5A10088DEC7 /* CCActionTween.cpp */, - 1A570060180BC5A10088DEC7 /* CCActionTween.h */, - ); - name = actions; - sourceTree = ""; - }; - 1A570095180BC5B00088DEC7 /* base-nodes */ = { - isa = PBXGroup; - children = ( - 15EFA20F198A2BB5000C57D3 /* CCProtectedNode.cpp */, - 15EFA210198A2BB5000C57D3 /* CCProtectedNode.h */, - 1A57009C180BC5D20088DEC7 /* CCNode.cpp */, - 1A57009D180BC5D20088DEC7 /* CCNode.h */, - 1A570096180BC5C10088DEC7 /* CCAtlasNode.cpp */, - 1A570097180BC5C10088DEC7 /* CCAtlasNode.h */, - ); - name = "base-nodes"; - sourceTree = ""; - }; - 1A5700A2180BC5E60088DEC7 /* base */ = { - isa = PBXGroup; - children = ( - 844EB11D1F78D4CA00EFE4CD /* CCThreadPool.cpp */, - 844EB11E1F78D4CA00EFE4CD /* CCThreadPool.h */, - A6F0D79F1C2796020029CC44 /* CCStencilStateManager.cpp */, - A6F0D7A01C2796020029CC44 /* CCStencilStateManager.hpp */, - 291901411B05895600F8B4BA /* CCNinePatchImageParser.h */, - 291901421B05895600F8B4BA /* CCNinePatchImageParser.cpp */, - B63990CA1A490AFE00B07923 /* CCAsyncTaskPool.cpp */, - B63990CB1A490AFE00B07923 /* CCAsyncTaskPool.h */, - 299CF1F919A434BC00C378C1 /* ccRandom.cpp */, - 299CF1FA19A434BC00C378C1 /* ccRandom.h */, - 464AD6E3197EBB1400E502D8 /* pvr.cpp */, - 464AD6E4197EBB1400E502D8 /* pvr.h */, - 299754F2193EC95400A54AC3 /* ObjectFactory.cpp */, - 299754F3193EC95400A54AC3 /* ObjectFactory.h */, - 50ABBDC31925AB6E00A911A9 /* base64.cpp */, - 50ABBDC41925AB6E00A911A9 /* base64.h */, - 50ABBDC51925AB6E00A911A9 /* CCAutoreleasePool.cpp */, - 50ABBDC61925AB6E00A911A9 /* CCAutoreleasePool.h */, - 50ABBDC71925AB6E00A911A9 /* ccCArray.cpp */, - 50ABBDC81925AB6E00A911A9 /* ccCArray.h */, - 50ABBDC91925AB6E00A911A9 /* ccConfig.h */, - 50ABBDCA1925AB6E00A911A9 /* CCConfiguration.cpp */, - 50ABBDCB1925AB6E00A911A9 /* CCConfiguration.h */, - 50ABBDCC1925AB6E00A911A9 /* CCConsole.cpp */, - 50ABBDCD1925AB6E00A911A9 /* CCConsole.h */, - 50ABBDCE1925AB6E00A911A9 /* CCData.cpp */, - 50ABBDCF1925AB6E00A911A9 /* CCData.h */, - 50ABBDD21925AB6E00A911A9 /* CCDirector.cpp */, - 50ABBDD31925AB6E00A911A9 /* CCDirector.h */, - 50ABBDD41925AB6E00A911A9 /* CCEvent.cpp */, - 50ABBDD51925AB6E00A911A9 /* CCEvent.h */, - 50ABBDD61925AB6E00A911A9 /* CCEventAcceleration.cpp */, - 50ABBDD71925AB6E00A911A9 /* CCEventAcceleration.h */, - 50ABBDD81925AB6E00A911A9 /* CCEventCustom.cpp */, - 50ABBDD91925AB6E00A911A9 /* CCEventCustom.h */, - 50ABBDDA1925AB6E00A911A9 /* CCEventDispatcher.cpp */, - 50ABBDDB1925AB6E00A911A9 /* CCEventDispatcher.h */, - 50ABBDDC1925AB6E00A911A9 /* CCEventFocus.cpp */, - 50ABBDDD1925AB6E00A911A9 /* CCEventFocus.h */, - 50ABBDDE1925AB6E00A911A9 /* CCEventKeyboard.cpp */, - 50ABBDDF1925AB6E00A911A9 /* CCEventKeyboard.h */, - 50ABBDE01925AB6E00A911A9 /* CCEventListener.cpp */, - 50ABBDE11925AB6E00A911A9 /* CCEventListener.h */, - 50ABBDE21925AB6E00A911A9 /* CCEventListenerAcceleration.cpp */, - 50ABBDE31925AB6E00A911A9 /* CCEventListenerAcceleration.h */, - 50ABBDE41925AB6E00A911A9 /* CCEventListenerCustom.cpp */, - 50ABBDE51925AB6E00A911A9 /* CCEventListenerCustom.h */, - 50ABBDE61925AB6E00A911A9 /* CCEventListenerFocus.cpp */, - 50ABBDE71925AB6E00A911A9 /* CCEventListenerFocus.h */, - 50ABBDE81925AB6E00A911A9 /* CCEventListenerKeyboard.cpp */, - 50ABBDE91925AB6E00A911A9 /* CCEventListenerKeyboard.h */, - 50ABBDEA1925AB6E00A911A9 /* CCEventListenerMouse.cpp */, - 50ABBDEB1925AB6E00A911A9 /* CCEventListenerMouse.h */, - 50ABBDEC1925AB6E00A911A9 /* CCEventListenerTouch.cpp */, - 50ABBDED1925AB6E00A911A9 /* CCEventListenerTouch.h */, - 50ABBDEE1925AB6E00A911A9 /* CCEventMouse.cpp */, - 50ABBDEF1925AB6E00A911A9 /* CCEventMouse.h */, - 50ABBDF01925AB6E00A911A9 /* CCEventTouch.cpp */, - 50ABBDF11925AB6E00A911A9 /* CCEventTouch.h */, - 50ABBDF21925AB6E00A911A9 /* CCEventType.h */, - 50ABBDF31925AB6E00A911A9 /* ccFPSImages.c */, - 50ABBDF41925AB6E00A911A9 /* ccFPSImages.h */, - 503DD8F21926B0DB00CD74DD /* CCIMEDelegate.h */, - 503DD8F31926B0DB00CD74DD /* CCIMEDispatcher.cpp */, - 503DD8F41926B0DB00CD74DD /* CCIMEDispatcher.h */, - 50ABBDF51925AB6E00A911A9 /* ccMacros.h */, - 50ABBDF61925AB6E00A911A9 /* CCMap.h */, - 50ABBDF71925AB6E00A911A9 /* CCNS.cpp */, - 50ABBDF81925AB6E00A911A9 /* CCNS.h */, - 50ABBDFB1925AB6E00A911A9 /* CCProfiling.cpp */, - 50ABBDFC1925AB6E00A911A9 /* CCProfiling.h */, - 50ABBDFD1925AB6E00A911A9 /* CCProtocols.h */, - 50ABBDFE1925AB6E00A911A9 /* CCRef.cpp */, - 50ABBDFF1925AB6E00A911A9 /* CCRef.h */, - 50ABBE001925AB6E00A911A9 /* CCRefPtr.h */, - 50ABBE011925AB6E00A911A9 /* CCScheduler.cpp */, - 50ABBE021925AB6E00A911A9 /* CCScheduler.h */, - 50ABBE031925AB6E00A911A9 /* CCScriptSupport.cpp */, - 50ABBE041925AB6E00A911A9 /* CCScriptSupport.h */, - 50ABBE051925AB6E00A911A9 /* CCTouch.cpp */, - 50ABBE061925AB6E00A911A9 /* CCTouch.h */, - 50ABBE071925AB6E00A911A9 /* ccTypes.cpp */, - 50ABBE081925AB6E00A911A9 /* ccTypes.h */, - 50ABBE091925AB6E00A911A9 /* CCUserDefault.cpp */, - 50ABBE0A1925AB6E00A911A9 /* CCUserDefault.h */, - 50ABBE0B1925AB6F00A911A9 /* CCUserDefault-apple.mm */, - 50ABBE0D1925AB6F00A911A9 /* ccUTF8.cpp */, - 50ABBE0E1925AB6F00A911A9 /* ccUTF8.h */, - 50ABBE0F1925AB6F00A911A9 /* ccUtils.cpp */, - 50ABBE101925AB6F00A911A9 /* ccUtils.h */, - 50ABBE111925AB6F00A911A9 /* CCValue.cpp */, - 50ABBE121925AB6F00A911A9 /* CCValue.h */, - 50ABBE131925AB6F00A911A9 /* CCVector.h */, - 50ABBE141925AB6F00A911A9 /* etc1.cpp */, - 50ABBE151925AB6F00A911A9 /* etc1.h */, - 50ABBE161925AB6F00A911A9 /* firePngData.h */, - 50ABBE191925AB6F00A911A9 /* TGAlib.cpp */, - 50ABBE1A1925AB6F00A911A9 /* TGAlib.h */, - 50ABBE1B1925AB6F00A911A9 /* uthash.h */, - 50ABBE1C1925AB6F00A911A9 /* utlist.h */, - 50ABBE1D1925AB6F00A911A9 /* ZipUtils.cpp */, - 50ABBE1E1925AB6F00A911A9 /* ZipUtils.h */, - ); - name = base; - path = ../cocos/2d; - sourceTree = ""; - }; - 1A570109180BC8DC0088DEC7 /* draw-nodes */ = { - isa = PBXGroup; - children = ( - 1A57010A180BC8ED0088DEC7 /* CCDrawingPrimitives.cpp */, - 1A57010B180BC8EE0088DEC7 /* CCDrawingPrimitives.h */, - 1A57010C180BC8EE0088DEC7 /* CCDrawNode.cpp */, - 1A57010D180BC8EE0088DEC7 /* CCDrawNode.h */, - ); - name = "draw-nodes"; - sourceTree = ""; - }; - 1A570116180BC8FE0088DEC7 /* effects */ = { - isa = PBXGroup; - children = ( - 1A570117180BC90D0088DEC7 /* CCGrabber.cpp */, - 1A570118180BC90D0088DEC7 /* CCGrabber.h */, - 1A570119180BC90D0088DEC7 /* CCGrid.cpp */, - 1A57011A180BC90D0088DEC7 /* CCGrid.h */, - ); - name = effects; - sourceTree = ""; - }; - 1A570181180BCB170088DEC7 /* label-nodes */ = { - isa = PBXGroup; - children = ( - A614E2DE1C8E72360065A737 /* CCLabelTTF.h */, - BA8122AA1D77C4150010BEE9 /* CCLabelTTF.cpp */, - 1A570182180BCB590088DEC7 /* CCFont.cpp */, - 1A570183180BCB590088DEC7 /* CCFont.h */, - 1A570184180BCB590088DEC7 /* CCFontAtlas.cpp */, - 1A570185180BCB590088DEC7 /* CCFontAtlas.h */, - 1A570186180BCB590088DEC7 /* CCFontAtlasCache.cpp */, - 1A570187180BCB590088DEC7 /* CCFontAtlasCache.h */, - 1ABA68AC1888D700007D1BB4 /* CCFontCharMap.cpp */, - 1ABA68AD1888D700007D1BB4 /* CCFontCharMap.h */, - 1A57018C180BCB590088DEC7 /* CCFontFNT.cpp */, - 1A57018D180BCB590088DEC7 /* CCFontFNT.h */, - 1A57018E180BCB590088DEC7 /* CCFontFreeType.cpp */, - 1A57018F180BCB590088DEC7 /* CCFontFreeType.h */, - 1A570190180BCB590088DEC7 /* CCLabel.cpp */, - 1A570191180BCB590088DEC7 /* CCLabel.h */, - 1A570192180BCB590088DEC7 /* CCLabelAtlas.cpp */, - 1A570193180BCB590088DEC7 /* CCLabelAtlas.h */, - 1A570197180BCB590088DEC7 /* CCLabelTextFormatter.cpp */, - 1A570198180BCB590088DEC7 /* CCLabelTextFormatter.h */, - ); - name = "label-nodes"; - sourceTree = ""; - }; - 1A5701D3180BCB670088DEC7 /* layers-scenes-transitions-nodes */ = { - isa = PBXGroup; - children = ( - 1A5701D4180BCB8C0088DEC7 /* CCLayer.cpp */, - 1A5701D5180BCB8C0088DEC7 /* CCLayer.h */, - 1A5701D6180BCB8C0088DEC7 /* CCScene.cpp */, - 1A5701D7180BCB8C0088DEC7 /* CCScene.h */, - 1A5701D8180BCB8C0088DEC7 /* CCTransition.cpp */, - 1A5701D9180BCB8C0088DEC7 /* CCTransition.h */, - 1A5701DA180BCB8C0088DEC7 /* CCTransitionPageTurn.cpp */, - 1A5701DB180BCB8C0088DEC7 /* CCTransitionPageTurn.h */, - 1A5701DC180BCB8C0088DEC7 /* CCTransitionProgress.cpp */, - 1A5701DD180BCB8C0088DEC7 /* CCTransitionProgress.h */, - ); - name = "layers-scenes-transitions-nodes"; - sourceTree = ""; - }; - 1A5701F2180BCB970088DEC7 /* menu-nodes */ = { - isa = PBXGroup; - children = ( - 1A5701F3180BCBAD0088DEC7 /* CCMenu.cpp */, - 1A5701F4180BCBAD0088DEC7 /* CCMenu.h */, - 1A5701F5180BCBAD0088DEC7 /* CCMenuItem.cpp */, - 1A5701F6180BCBAD0088DEC7 /* CCMenuItem.h */, - ); - name = "menu-nodes"; - sourceTree = ""; - }; - 1A5701FF180BCBBD0088DEC7 /* misc-nodes */ = { - isa = PBXGroup; - children = ( - DABC9FA719E7DFA900FA252C /* CCClippingRectangleNode.cpp */, - DABC9FA819E7DFA900FA252C /* CCClippingRectangleNode.h */, - ED9C6A9218599AD8000A5232 /* CCNodeGrid.cpp */, - ED9C6A9318599AD8000A5232 /* CCNodeGrid.h */, - 1A57020C180BCBF40088DEC7 /* CCProgressTimer.cpp */, - 1A57020D180BCBF40088DEC7 /* CCProgressTimer.h */, - 1A57020E180BCBF40088DEC7 /* CCRenderTexture.cpp */, - 1A57020F180BCBF40088DEC7 /* CCRenderTexture.h */, - 1A570206180BCBDF0088DEC7 /* CCMotionStreak.cpp */, - 1A570207180BCBDF0088DEC7 /* CCMotionStreak.h */, - 1A570200180BCBD40088DEC7 /* CCClippingNode.cpp */, - 1A570201180BCBD40088DEC7 /* CCClippingNode.h */, - ); - name = "misc-nodes"; - sourceTree = ""; - }; - 1A570218180BCC000088DEC7 /* particle-nodes */ = { - isa = PBXGroup; - children = ( - 1A570219180BCC1A0088DEC7 /* CCParticleBatchNode.cpp */, - 1A57021A180BCC1A0088DEC7 /* CCParticleBatchNode.h */, - 1A57021B180BCC1A0088DEC7 /* CCParticleExamples.cpp */, - 1A57021C180BCC1A0088DEC7 /* CCParticleExamples.h */, - 1A57021D180BCC1A0088DEC7 /* CCParticleSystem.cpp */, - 1A57021E180BCC1A0088DEC7 /* CCParticleSystem.h */, - 1A57021F180BCC1A0088DEC7 /* CCParticleSystemQuad.cpp */, - 1A570220180BCC1A0088DEC7 /* CCParticleSystemQuad.h */, - ); - name = "particle-nodes"; - sourceTree = ""; - }; - 1A570275180BCC840088DEC7 /* sprite-nodes */ = { - isa = PBXGroup; - children = ( - 15FB20721AE7BF8600C31518 /* CCAutoPolygon.cpp */, - 15FB20731AE7BF8600C31518 /* CCAutoPolygon.h */, - 1A57028E180BCCAB0088DEC7 /* CCAnimation.cpp */, - 1A57028F180BCCAB0088DEC7 /* CCAnimation.h */, - 1A570290180BCCAB0088DEC7 /* CCAnimationCache.cpp */, - 1A570291180BCCAB0088DEC7 /* CCAnimationCache.h */, - 1A570276180BCC900088DEC7 /* CCSprite.cpp */, - 1A570277180BCC900088DEC7 /* CCSprite.h */, - 1A570278180BCC900088DEC7 /* CCSpriteBatchNode.cpp */, - 1A570279180BCC900088DEC7 /* CCSpriteBatchNode.h */, - 1A57027A180BCC900088DEC7 /* CCSpriteFrame.cpp */, - 1A57027B180BCC900088DEC7 /* CCSpriteFrame.h */, - 1A57027C180BCC900088DEC7 /* CCSpriteFrameCache.cpp */, - 1A57027D180BCC900088DEC7 /* CCSpriteFrameCache.h */, - ); - name = "sprite-nodes"; - sourceTree = ""; - }; - 1A57029A180BCD4F0088DEC7 /* support */ = { - isa = PBXGroup; - children = ( - 1A570308180BCF190088DEC7 /* CCComponent.cpp */, - 1A570309180BCF190088DEC7 /* CCComponent.h */, - 1A57030A180BCF190088DEC7 /* CCComponentContainer.cpp */, - 1A57030B180BCF190088DEC7 /* CCComponentContainer.h */, - ); - name = support; - sourceTree = ""; - }; - 1A5702BC180BCE0A0088DEC7 /* text-input-node */ = { - isa = PBXGroup; - children = ( - 1A5702C6180BCE370088DEC7 /* CCTextFieldTTF.cpp */, - 1A5702C7180BCE370088DEC7 /* CCTextFieldTTF.h */, - ); - name = "text-input-node"; - sourceTree = ""; - }; - 1A5702DF180BCE610088DEC7 /* tilemap-parallax-nodes */ = { - isa = PBXGroup; - children = ( - FAC8F2581D339EB70061CEDD /* CCTMXLayer.cpp */, - FAC8F2591D339EB70061CEDD /* CCTMXLayer.h */, - FAC8F25A1D339EB70061CEDD /* CCTMXTiledMap.cpp */, - FAC8F25B1D339EB70061CEDD /* CCTMXTiledMap.h */, - B24AA981195A675C007B4522 /* CCFastTMXLayer.cpp */, - B24AA982195A675C007B4522 /* CCFastTMXLayer.h */, - B24AA983195A675C007B4522 /* CCFastTMXTiledMap.cpp */, - B24AA984195A675C007B4522 /* CCFastTMXTiledMap.h */, - 1A5702FE180BCE890088DEC7 /* CCParallaxNode.cpp */, - 1A5702FF180BCE890088DEC7 /* CCParallaxNode.h */, - 1A5702E0180BCE750088DEC7 /* CCTileMapAtlas.cpp */, - 1A5702E1180BCE750088DEC7 /* CCTileMapAtlas.h */, - 1A5702E4180BCE750088DEC7 /* CCTMXObjectGroup.cpp */, - 1A5702E5180BCE750088DEC7 /* CCTMXObjectGroup.h */, - 1A5702E8180BCE750088DEC7 /* CCTMXXMLParser.cpp */, - 1A5702E9180BCE750088DEC7 /* CCTMXXMLParser.h */, - ); - name = "tilemap-parallax-nodes"; - sourceTree = ""; - }; 1A57033E180BD0490088DEC7 /* external */ = { isa = PBXGroup; children = ( + 46FDDC0D202AEAC500931238 /* firefox */, 4DC57D1E1F7A58B5005B6546 /* xxtea */, 1A28FF1C1F20AFAB007A1D9D /* SocketRocket */, 4DED476A1DFFA4AF0070C5C4 /* Box2D */, @@ -2957,268 +1352,6 @@ name = external; sourceTree = ""; }; - 1AAF5360180E3374000584C8 /* network */ = { - isa = PBXGroup; - children = ( - 1AD473AA1EAD9A5200202582 /* Uri.cpp */, - 1AD473AB1EAD9A5200202582 /* Uri.h */, - 507003251B69820100E83DDD /* HttpClient */, - 507003261B69820B00E83DDD /* SocketIO */, - 507003271B69821300E83DDD /* WebSocket */, - 50693C621B6BF2BC005C5820 /* Downloader */, - ); - name = network; - path = ../cocos/network; - sourceTree = ""; - }; - 1AAF5849180E40B8000584C8 /* storage */ = { - isa = PBXGroup; - children = ( - 1AAF584A180E40B9000584C8 /* local-storage */, - ); - name = storage; - path = ../cocos/storage; - sourceTree = ""; - }; - 1AAF584A180E40B9000584C8 /* local-storage */ = { - isa = PBXGroup; - children = ( - 1AAF584C180E40B9000584C8 /* LocalStorage.cpp */, - 1AAF584D180E40B9000584C8 /* LocalStorage.h */, - ); - path = "local-storage"; - sourceTree = ""; - }; - 1AD71CF7180E26E600808F54 /* editor-support */ = { - isa = PBXGroup; - children = ( - FA6F1AF71D80F858007DD223 /* dragonbones */, - 4DFA4C141CBCE32800E3B736 /* creator */, - 1AD71D7C180E26E600808F54 /* spine */, - ); - name = "editor-support"; - path = "../cocos/editor-support"; - sourceTree = ""; - }; - 1AD71D7C180E26E600808F54 /* spine */ = { - isa = PBXGroup; - children = ( - FAC8F6651E1DF15D002B17E8 /* kvec.h */, - FAC8F6661E1DF15D002B17E8 /* SkeletonBinary.c */, - FAC8F6671E1DF15D002B17E8 /* SkeletonBinary.h */, - BAFF7CFB1D5C1CF80051B92F /* Animation.c */, - BAFF7CFC1D5C1CF80051B92F /* Animation.h */, - BAFF7CFD1D5C1CF80051B92F /* AnimationState.c */, - BAFF7CFE1D5C1CF80051B92F /* AnimationState.h */, - BAFF7CFF1D5C1CF80051B92F /* AnimationStateData.c */, - BAFF7D001D5C1CF80051B92F /* AnimationStateData.h */, - BAFF7D011D5C1CF80051B92F /* Atlas.c */, - BAFF7D021D5C1CF80051B92F /* Atlas.h */, - BAFF7D031D5C1CF80051B92F /* AtlasAttachmentLoader.c */, - BAFF7D041D5C1CF80051B92F /* AtlasAttachmentLoader.h */, - BAFF7D051D5C1CF80051B92F /* Attachment.c */, - BAFF7D061D5C1CF80051B92F /* Attachment.h */, - BAFF7D071D5C1CF80051B92F /* AttachmentLoader.c */, - BAFF7D081D5C1CF80051B92F /* AttachmentLoader.h */, - BAFF7D091D5C1CF80051B92F /* AttachmentVertices.cpp */, - BAFF7D0A1D5C1CF80051B92F /* AttachmentVertices.h */, - BAFF7D0B1D5C1CF80051B92F /* Bone.c */, - BAFF7D0C1D5C1CF80051B92F /* Bone.h */, - BAFF7D0D1D5C1CF80051B92F /* BoneData.c */, - BAFF7D0E1D5C1CF80051B92F /* BoneData.h */, - BAFF7D0F1D5C1CF80051B92F /* BoundingBoxAttachment.c */, - BAFF7D101D5C1CF80051B92F /* BoundingBoxAttachment.h */, - BAFF7D111D5C1CF80051B92F /* Cocos2dAttachmentLoader.cpp */, - BAFF7D121D5C1CF80051B92F /* Cocos2dAttachmentLoader.h */, - BAFF7D131D5C1CF80051B92F /* Event.c */, - BAFF7D141D5C1CF80051B92F /* Event.h */, - BAFF7D151D5C1CF80051B92F /* EventData.c */, - BAFF7D161D5C1CF80051B92F /* EventData.h */, - BAFF7D171D5C1CF80051B92F /* extension.c */, - BAFF7D181D5C1CF80051B92F /* extension.h */, - BAFF7D191D5C1CF80051B92F /* IkConstraint.c */, - BAFF7D1A1D5C1CF80051B92F /* IkConstraint.h */, - BAFF7D1B1D5C1CF80051B92F /* IkConstraintData.c */, - BAFF7D1C1D5C1CF80051B92F /* IkConstraintData.h */, - BAFF7D1D1D5C1CF80051B92F /* Json.c */, - BAFF7D1E1D5C1CF80051B92F /* Json.h */, - BAFF7D1F1D5C1CF80051B92F /* MeshAttachment.c */, - BAFF7D201D5C1CF80051B92F /* MeshAttachment.h */, - BAFF7D211D5C1CF80051B92F /* PathAttachment.c */, - BAFF7D221D5C1CF80051B92F /* PathAttachment.h */, - BAFF7D231D5C1CF80051B92F /* PathConstraint.c */, - BAFF7D241D5C1CF80051B92F /* PathConstraint.h */, - BAFF7D251D5C1CF80051B92F /* PathConstraintData.c */, - BAFF7D261D5C1CF80051B92F /* PathConstraintData.h */, - BAFF7D271D5C1CF80051B92F /* RegionAttachment.c */, - BAFF7D281D5C1CF80051B92F /* RegionAttachment.h */, - BAFF7D291D5C1CF80051B92F /* Skeleton.c */, - BAFF7D2A1D5C1CF80051B92F /* Skeleton.h */, - BAFF7D2B1D5C1CF80051B92F /* SkeletonAnimation.cpp */, - BAFF7D2C1D5C1CF80051B92F /* SkeletonAnimation.h */, - BAFF7D2D1D5C1CF80051B92F /* SkeletonBatch.cpp */, - BAFF7D2E1D5C1CF80051B92F /* SkeletonBatch.h */, - BAFF7D2F1D5C1CF80051B92F /* SkeletonBounds.c */, - BAFF7D301D5C1CF80051B92F /* SkeletonBounds.h */, - BAFF7D311D5C1CF80051B92F /* SkeletonData.c */, - BAFF7D321D5C1CF80051B92F /* SkeletonData.h */, - BAFF7D331D5C1CF80051B92F /* SkeletonJson.c */, - BAFF7D341D5C1CF80051B92F /* SkeletonJson.h */, - BAFF7D351D5C1CF80051B92F /* SkeletonRenderer.cpp */, - BAFF7D361D5C1CF80051B92F /* SkeletonRenderer.h */, - BAFF7D371D5C1CF80051B92F /* Skin.c */, - BAFF7D381D5C1CF80051B92F /* Skin.h */, - BAFF7D391D5C1CF80051B92F /* Slot.c */, - BAFF7D3A1D5C1CF80051B92F /* Slot.h */, - BAFF7D3B1D5C1CF80051B92F /* SlotData.c */, - BAFF7D3C1D5C1CF80051B92F /* SlotData.h */, - BAFF7D3D1D5C1CF80051B92F /* spine-cocos2dx.cpp */, - BAFF7D3E1D5C1CF80051B92F /* spine-cocos2dx.h */, - BAFF7D3F1D5C1CF80051B92F /* spine.h */, - BAFF7D401D5C1CF80051B92F /* TransformConstraint.c */, - BAFF7D411D5C1CF80051B92F /* TransformConstraint.h */, - BAFF7D421D5C1CF80051B92F /* TransformConstraintData.c */, - BAFF7D431D5C1CF80051B92F /* TransformConstraintData.h */, - BAFF7D441D5C1CF80051B92F /* VertexAttachment.c */, - BAFF7D451D5C1CF80051B92F /* VertexAttachment.h */, - ); - path = spine; - sourceTree = ""; - }; - 2905F9E618CF08D000240AA3 /* ui */ = { - isa = PBXGroup; - children = ( - 292DB12E19B4574100A80320 /* UIEditBox */, - 29CB8F521929D65500C841D6 /* experimental */, - 29CB8F511929D64500C841D6 /* base */, - 2905F9E918CF08D000240AA3 /* CocosGUI.cpp */, - 2905F9EA18CF08D000240AA3 /* CocosGUI.h */, - ); - name = ui; - path = ../cocos/ui; - sourceTree = ""; - }; - 292DB12E19B4574100A80320 /* UIEditBox */ = { - isa = PBXGroup; - children = ( - A63CEFF81CD9CF2700A6971D /* Mac */, - 2980F0161BA9A5550059E678 /* iOS */, - A0E749F51BA8FD7F001A8332 /* UIEditBoxImpl-common.cpp */, - A0E749F61BA8FD7F001A8332 /* UIEditBoxImpl-common.h */, - 50ED2BDC19BEAF7900A0AB90 /* UIEditBoxImpl-win32.h */, - 50ED2BDE19BEAF7900A0AB90 /* UIEditBoxImpl-win32.cpp */, - 292DB12F19B4574100A80320 /* UIEditBox.cpp */, - 292DB13019B4574100A80320 /* UIEditBox.h */, - 292DB13119B4574100A80320 /* UIEditBoxImpl.h */, - 292DB13219B4574100A80320 /* UIEditBoxImpl-android.cpp */, - 292DB13319B4574100A80320 /* UIEditBoxImpl-android.h */, - 292DB13419B4574100A80320 /* UIEditBoxImpl-ios.h */, - 292DB13519B4574100A80320 /* UIEditBoxImpl-ios.mm */, - 292DB13619B4574100A80320 /* UIEditBoxImpl-mac.h */, - 292DB13719B4574100A80320 /* UIEditBoxImpl-mac.mm */, - ); - path = UIEditBox; - sourceTree = ""; - }; - 2980F0161BA9A5550059E678 /* iOS */ = { - isa = PBXGroup; - children = ( - 2980F0171BA9A5550059E678 /* CCUIEditBoxIOS.h */, - 2980F0181BA9A5550059E678 /* CCUIEditBoxIOS.mm */, - 2980F0191BA9A5550059E678 /* CCUIMultilineTextField.h */, - 2980F01A1BA9A5550059E678 /* CCUIMultilineTextField.mm */, - 2980F01B1BA9A5550059E678 /* CCUISingleLineTextField.h */, - 2980F01C1BA9A5550059E678 /* CCUISingleLineTextField.mm */, - 2980F01D1BA9A5550059E678 /* CCUITextInput.h */, - 2980F01E1BA9A5550059E678 /* UITextField+CCUITextInput.h */, - 2980F01F1BA9A5550059E678 /* UITextField+CCUITextInput.mm */, - 2980F0201BA9A5550059E678 /* UITextView+CCUITextInput.h */, - 2980F0211BA9A5550059E678 /* UITextView+CCUITextInput.mm */, - ); - path = iOS; - sourceTree = ""; - }; - 29CB8F511929D64500C841D6 /* base */ = { - isa = PBXGroup; - children = ( - 2958244919873D8E00F9746D /* UIScale9Sprite.cpp */, - 2958244A19873D8E00F9746D /* UIScale9Sprite.h */, - 2905FA1318CF08D100240AA3 /* UIWidget.cpp */, - 2905FA1418CF08D100240AA3 /* UIWidget.h */, - 2905F9F418CF08D000240AA3 /* UIHelper.cpp */, - 2905F9F518CF08D000240AA3 /* UIHelper.h */, - 2905F9EB18CF08D000240AA3 /* GUIDefine.h */, - ); - name = base; - sourceTree = ""; - }; - 29CB8F521929D65500C841D6 /* experimental */ = { - isa = PBXGroup; - children = ( - 29394CEC19B01DBA00D2DE1A /* UIWebView.h */, - 29394CED19B01DBA00D2DE1A /* UIWebView.mm */, - 29394CEE19B01DBA00D2DE1A /* UIWebViewImpl-ios.h */, - 29394CEF19B01DBA00D2DE1A /* UIWebViewImpl-ios.mm */, - 3EA0FB69191C841D00B170C8 /* UIVideoPlayer.h */, - 3EA0FB6A191C841D00B170C8 /* UIVideoPlayer-ios.mm */, - ); - name = experimental; - sourceTree = ""; - }; - 46A15FD01807A56F005B8026 /* audio */ = { - isa = PBXGroup; - children = ( - 3E2BDAEB19C0436F0055CDCD /* AudioEngine.cpp */, - 46A15FE01807A56F005B8026 /* include */, - 50CB246E19D9C5A100687767 /* apple */, - ); - name = audio; - path = ../cocos/audio; - sourceTree = ""; - }; - 46A15FE01807A56F005B8026 /* include */ = { - isa = PBXGroup; - children = ( - 3E2BDADD19C030ED0055CDCD /* AudioEngine.h */, - 46A15FE11807A56F005B8026 /* Export.h */, - ); - path = include; - sourceTree = ""; - }; - 46A167981807AF4D005B8026 /* extensions */ = { - isa = PBXGroup; - children = ( - BA679B271CEC371100F875FA /* assets-manager */, - 46A167D21807AF4D005B8026 /* cocos-ext.h */, - 46A168321807AF4E005B8026 /* ExtensionMacros.h */, - ); - name = extensions; - path = ../extensions; - sourceTree = ""; - }; - 46A169A11807B037005B8026 /* 2d */ = { - isa = PBXGroup; - children = ( - 1A9DCA02180E6955007A3AD4 /* CCGLBufferedNode.cpp */, - 1A9DCA03180E6955007A3AD4 /* CCGLBufferedNode.h */, - 1A570046180BC59A0088DEC7 /* actions */, - 1A570095180BC5B00088DEC7 /* base-nodes */, - 1A570109180BC8DC0088DEC7 /* draw-nodes */, - 1A570116180BC8FE0088DEC7 /* effects */, - 1A570181180BCB170088DEC7 /* label-nodes */, - 1A5701D3180BCB670088DEC7 /* layers-scenes-transitions-nodes */, - 1A5701F2180BCB970088DEC7 /* menu-nodes */, - 1A5701FF180BCBBD0088DEC7 /* misc-nodes */, - 1A570218180BCC000088DEC7 /* particle-nodes */, - 1A570275180BCC840088DEC7 /* sprite-nodes */, - 1A57029A180BCD4F0088DEC7 /* support */, - 1A5702BC180BCE0A0088DEC7 /* text-input-node */, - 1A5702DF180BCE610088DEC7 /* tilemap-parallax-nodes */, - ); - name = 2d; - path = ../cocos/2d; - sourceTree = ""; - }; 46A170851807CE87005B8026 /* math */ = { isa = PBXGroup; children = ( @@ -3258,29 +1391,183 @@ path = ../cocos/math; sourceTree = ""; }; - 4DC06BC01E8A68D400CA08B1 /* physics */ = { + 46FDDA2C202ACC6A00931238 /* renderer */ = { isa = PBXGroup; children = ( - 4DC06BC11E8A68D400CA08B1 /* CCPhysicsAABBQueryCallback.cpp */, - 4DC06BC21E8A68D400CA08B1 /* CCPhysicsAABBQueryCallback.h */, - 4DC06BC31E8A68D400CA08B1 /* CCPhysicsContactListener.cpp */, - 4DC06BC41E8A68D400CA08B1 /* CCPhysicsContactListener.h */, - 4D2816641E8CBB7200F26B06 /* CCPhysicsContactImpulse.cpp */, - 4D2816651E8CBB7200F26B06 /* CCPhysicsContactImpulse.h */, - 4DC06BCD1E8A68D400CA08B1 /* CCPhysicsWorldManifoldWrapper.cpp */, - 4DC06BCE1E8A68D400CA08B1 /* CCPhysicsWorldManifoldWrapper.h */, - 4DC06BEB1E8B604B00CA08B1 /* CCPhysicsManifoldWrapper.cpp */, - 4DC06BEC1E8B604B00CA08B1 /* CCPhysicsManifoldWrapper.h */, - 4DC06BC71E8A68D400CA08B1 /* CCPhysicsDebugDraw.cpp */, - 4DC06BC81E8A68D400CA08B1 /* CCPhysicsDebugDraw.h */, - 4DC06BC91E8A68D400CA08B1 /* CCPhysicsRayCastCallback.cpp */, - 4DC06BCA1E8A68D400CA08B1 /* CCPhysicsRayCastCallback.h */, - 4DC06BCB1E8A68D400CA08B1 /* CCPhysicsUtils.cpp */, - 4DC06BCC1E8A68D400CA08B1 /* CCPhysicsUtils.h */, - 4DC06BF11E8B8D1300CA08B1 /* CCPhysicsDefine.h */, + 46FDDA2D202ACC6A00931238 /* renderer */, + 46FDDA4C202ACC6A00931238 /* Types.cpp */, + 46FDDA4E202ACC6A00931238 /* Types.h */, + 46FDDA4F202ACC6A00931238 /* Macro.h */, + 46FDDA50202ACC6A00931238 /* gfx */, ); - name = physics; - path = creator/physics; + name = renderer; + path = ../cocos/renderer; + sourceTree = ""; + }; + 46FDDA2D202ACC6A00931238 /* renderer */ = { + isa = PBXGroup; + children = ( + 46FDDA2E202ACC6A00931238 /* INode.h */, + 46FDDA2F202ACC6A00931238 /* Pass.cpp */, + 46FDDA30202ACC6A00931238 /* Scene.cpp */, + 46FDDA31202ACC6A00931238 /* ProgramLib.h */, + 46FDDA32202ACC6A00931238 /* Config.h */, + 46FDDA33202ACC6A00931238 /* Light.h */, + 46FDDA34202ACC6A00931238 /* Camera.cpp */, + 46FDDA35202ACC6A00931238 /* Camera.h */, + 46FDDA36202ACC6A00931238 /* Light.cpp */, + 46FDDA37202ACC6A00931238 /* Renderer.h */, + 46FDDA38202ACC6A00931238 /* RendererUtils.h */, + 46FDDA39202ACC6A00931238 /* Technique.h */, + 46FDDA3A202ACC6A00931238 /* View.h */, + 46FDDA3B202ACC6A00931238 /* View.cpp */, + 46FDDA3C202ACC6A00931238 /* Effect.cpp */, + 46FDDA3D202ACC6A00931238 /* ForwardRenderer.cpp */, + 46FDDA3E202ACC6A00931238 /* Config.cpp */, + 46FDDA3F202ACC6A00931238 /* BaseRenderer.h */, + 46FDDA40202ACC6A00931238 /* Pass.h */, + 46FDDA41202ACC6A00931238 /* Technique.cpp */, + 46FDDA42202ACC6A00931238 /* RendererUtils.cpp */, + 46FDDA43202ACC6A00931238 /* Model.h */, + 46FDDA44202ACC6A00931238 /* Model.cpp */, + 46FDDA45202ACC6A00931238 /* Effect.h */, + 46FDDA46202ACC6A00931238 /* BaseRenderer.cpp */, + 46FDDA47202ACC6A00931238 /* ProgramLib.cpp */, + 46FDDA48202ACC6A00931238 /* InputAssembler.h */, + 46FDDA49202ACC6A00931238 /* InputAssembler.cpp */, + 46FDDA4A202ACC6A00931238 /* Scene.h */, + 46FDDA4B202ACC6A00931238 /* ForwardRenderer.h */, + ); + path = renderer; + sourceTree = ""; + }; + 46FDDA50202ACC6A00931238 /* gfx */ = { + isa = PBXGroup; + children = ( + 46FDDA51202ACC6A00931238 /* Texture2D.h */, + 46FDDA52202ACC6A00931238 /* DeviceGraphics.cpp */, + 46FDDA53202ACC6A00931238 /* VertexBuffer.cpp */, + 46FDDA54202ACC6A00931238 /* Program.cpp */, + 46FDDA55202ACC6A00931238 /* IndexBuffer.h */, + 46FDDA56202ACC6A00931238 /* FrameBuffer.cpp */, + 46FDDA57202ACC6A00931238 /* VertexFormat.cpp */, + 46FDDA58202ACC6A00931238 /* DeviceGraphics.h */, + 46FDDA59202ACC6A00931238 /* State.cpp */, + 46FDDA5A202ACC6A00931238 /* Texture.cpp */, + 46FDDA5B202ACC6A00931238 /* FrameBuffer.h */, + 46FDDA5C202ACC6A00931238 /* RenderTarget.cpp */, + 46FDDA5D202ACC6A00931238 /* GFX.h */, + 46FDDA5E202ACC6A00931238 /* RenderBuffer.cpp */, + 46FDDA5F202ACC6A00931238 /* VertexFormat.h */, + 46FDDA60202ACC6A00931238 /* GraphicsHandle.h */, + 46FDDA61202ACC6A00931238 /* RenderBuffer.h */, + 46FDDA62202ACC6A00931238 /* Texture.h */, + 46FDDA63202ACC6A00931238 /* Texture2D.cpp */, + 46FDDA64202ACC6A00931238 /* GraphicsHandle.cpp */, + 46FDDA65202ACC6A00931238 /* GFXUtils.h */, + 46FDDA66202ACC6A00931238 /* Program.h */, + 46FDDA67202ACC6A00931238 /* State.h */, + 46FDDA68202ACC6A00931238 /* VertexBuffer.h */, + 46FDDA69202ACC6A00931238 /* RenderTarget.h */, + 46FDDA6A202ACC6A00931238 /* GFXUtils.cpp */, + 46FDDA6B202ACC6A00931238 /* GFX.cpp */, + 46FDDA6C202ACC6A00931238 /* IndexBuffer.cpp */, + ); + path = gfx; + sourceTree = ""; + }; + 46FDDAE9202ADDCE00931238 /* base */ = { + isa = PBXGroup; + children = ( + 46FDDAEA202ADDCE00931238 /* ccFPSImages.c */, + 46FDDAEB202ADDCE00931238 /* pvr.h */, + 46FDDAEC202ADDCE00931238 /* CCValue.h */, + 46FDDAEE202ADDCE00931238 /* utlist.h */, + 46FDDAF2202ADDCE00931238 /* CCData.h */, + 46FDDAF3202ADDCE00931238 /* ccMacros.h */, + 46FDDAF7202ADDCE00931238 /* ccRandom.cpp */, + 46FDDAFA202ADDCE00931238 /* base64.h */, + 46FDDAFB202ADDCE00931238 /* etc1.h */, + 46FDDAFC202ADDCE00931238 /* ZipUtils.cpp */, + 46FDDAFD202ADDCE00931238 /* base64.cpp */, + 46FDDB01202ADDCE00931238 /* CCGameController.h */, + 46FDDB02202ADDCE00931238 /* CCRef.cpp */, + 46FDDB05202ADDCE00931238 /* ccTypes.h */, + 46FDDB06202ADDCE00931238 /* ccRandom.h */, + 46FDDB09202ADDCE00931238 /* CCRef.h */, + 46FDDB0A202ADDCE00931238 /* CCAutoreleasePool.cpp */, + 46FDDB0B202ADDCE00931238 /* ccTypes.cpp */, + 46FDDB0C202ADDCE00931238 /* ccUtils.cpp */, + 46FDDB0E202ADDCE00931238 /* TGAlib.cpp */, + 46FDDB11202ADDCE00931238 /* ccUTF8.cpp */, + 46FDDB12202ADDCE00931238 /* CCProfiling.h */, + 46FDDB13202ADDCE00931238 /* ObjectFactory.h */, + 46FDDB14202ADDCE00931238 /* CCVector.h */, + 46FDDB15202ADDCE00931238 /* ObjectFactory.cpp */, + 46FDDB16202ADDCE00931238 /* pvr.cpp */, + 46FDDB19202ADDCE00931238 /* CCProfiling.cpp */, + 46FDDB1E202ADDCE00931238 /* CCIMEDispatcher.cpp */, + 46FDDB1F202ADDCE00931238 /* uthash.h */, + 46FDDB20202ADDCE00931238 /* ccUtils.h */, + 46FDDB21202ADDCE00931238 /* CCNS.cpp */, + 46FDDB22202ADDCE00931238 /* CCRefPtr.h */, + 46FDDB26202ADDCE00931238 /* ccConfig.h */, + 46FDDB29202ADDCE00931238 /* ccFPSImages.h */, + 46FDDB2A202ADDCE00931238 /* ZipUtils.h */, + 46FDDB2C202ADDCE00931238 /* CCMap.h */, + 46FDDB2D202ADDCE00931238 /* ccUTF8.h */, + 46FDDB33202ADDCE00931238 /* TGAlib.h */, + 46FDDB36202ADDCE00931238 /* CCData.cpp */, + 46FDDB37202ADDCE00931238 /* CCIMEDelegate.h */, + 46FDDB38202ADDCE00931238 /* CCNS.h */, + 46FDDB39202ADDCE00931238 /* CCAutoreleasePool.h */, + 46FDDB41202ADDCE00931238 /* etc1.cpp */, + 46FDDB42202ADDCE00931238 /* ccCArray.cpp */, + 46FDDB43202ADDCE00931238 /* CCValue.cpp */, + 46FDDB44202ADDCE00931238 /* firePngData.h */, + 46FDDB45202ADDCE00931238 /* ccCArray.h */, + 46FDDB4A202ADDCE00931238 /* CCIMEDispatcher.h */, + ); + name = base; + path = ../cocos/base; + sourceTree = ""; + }; + 46FDDC0D202AEAC500931238 /* firefox */ = { + isa = PBXGroup; + children = ( + 46FDDC0E202AEAC500931238 /* WebGLTexelConversions.cpp */, + 46FDDC0F202AEAC500931238 /* WebGLTypes.h */, + 46FDDC10202AEAC500931238 /* mozilla */, + 46FDDC21202AEAC500931238 /* WebGLFormats.h */, + 46FDDC22202AEAC500931238 /* GLConsts.h */, + 46FDDC23202AEAC500931238 /* WebGLTexelConversions.h */, + 46FDDC24202AEAC500931238 /* WebGLFormats.cpp */, + ); + name = firefox; + path = ../external/sources/firefox; + sourceTree = ""; + }; + 46FDDC10202AEAC500931238 /* mozilla */ = { + isa = PBXGroup; + children = ( + 46FDDC11202AEAC500931238 /* Casting.h */, + 46FDDC12202AEAC500931238 /* UniquePtr.h */, + 46FDDC13202AEAC500931238 /* Compiler.h */, + 46FDDC14202AEAC500931238 /* Assertions.h */, + 46FDDC15202AEAC500931238 /* TypeTraits.h */, + 46FDDC16202AEAC500931238 /* Types.h */, + 46FDDC17202AEAC500931238 /* IntegerTypeTraits.h */, + 46FDDC18202AEAC500931238 /* Assertions.cpp */, + 46FDDC19202AEAC500931238 /* Attributes.h */, + 46FDDC1A202AEAC500931238 /* MacroArgs.h */, + 46FDDC1B202AEAC500931238 /* CheckedInt.h */, + 46FDDC1C202AEAC500931238 /* Likely.h */, + 46FDDC1D202AEAC500931238 /* Atomics.h */, + 46FDDC1E202AEAC500931238 /* Pair.h */, + 46FDDC1F202AEAC500931238 /* Move.h */, + 46FDDC20202AEAC500931238 /* StaticAnalysisFunctions.h */, + ); + path = mozilla; sourceTree = ""; }; 4DC57D1E1F7A58B5005B6546 /* xxtea */ = { @@ -3455,114 +1742,11 @@ path = Rope; sourceTree = ""; }; - 4DFA4C141CBCE32800E3B736 /* creator */ = { - isa = PBXGroup; - children = ( - 4DC06BC01E8A68D400CA08B1 /* physics */, - 4D2E69031CC543B40032DD5C /* CCGraphicsNode.cpp */, - 4D2E69041CC543B40032DD5C /* CCGraphicsNode.h */, - 4D2E69051CC543B40032DD5C /* Triangulate.cpp */, - 4D2E69061CC543B40032DD5C /* Triangulate.h */, - 4DFA4C151CBCE34100E3B736 /* CCScale9Sprite.cpp */, - 4DFA4C161CBCE34100E3B736 /* CCScale9Sprite.h */, - 4D6CF4351E83AAD5003327D4 /* CCCameraNode.cpp */, - 4D6CF4361E83AAD5003327D4 /* CCCameraNode.h */, - ); - name = creator; - sourceTree = ""; - }; - 500DC89819105D41007B91BF /* renderer */ = { - isa = PBXGroup; - children = ( - 5034CA5D191D591900CE6051 /* shaders */, - B276EF5B1988D1D500CD400F /* CCVertexIndexData.h */, - B276EF5C1988D1D500CD400F /* CCVertexIndexData.cpp */, - B276EF5D1988D1D500CD400F /* CCVertexIndexBuffer.h */, - B276EF5E1988D1D500CD400F /* CCVertexIndexBuffer.cpp */, - 50ABBD641925AB4100A911A9 /* CCBatchCommand.cpp */, - 50ABBD651925AB4100A911A9 /* CCBatchCommand.h */, - 50ABBD661925AB4100A911A9 /* CCCustomCommand.cpp */, - 50ABBD671925AB4100A911A9 /* CCCustomCommand.h */, - 50ABBD681925AB4100A911A9 /* CCGLProgram.cpp */, - 50ABBD691925AB4100A911A9 /* CCGLProgram.h */, - 50ABBD6A1925AB4100A911A9 /* CCGLProgramCache.cpp */, - 50ABBD6B1925AB4100A911A9 /* CCGLProgramCache.h */, - 50ABBD6C1925AB4100A911A9 /* CCGLProgramState.cpp */, - 50ABBD6D1925AB4100A911A9 /* CCGLProgramState.h */, - 50ABBD6E1925AB4100A911A9 /* CCGLProgramStateCache.cpp */, - 50ABBD6F1925AB4100A911A9 /* CCGLProgramStateCache.h */, - 50ABBD701925AB4100A911A9 /* ccGLStateCache.cpp */, - 50ABBD711925AB4100A911A9 /* ccGLStateCache.h */, - 50ABBD721925AB4100A911A9 /* CCGroupCommand.cpp */, - 50ABBD731925AB4100A911A9 /* CCGroupCommand.h */, - B230ED6F19B417AE00364AA8 /* CCTrianglesCommand.cpp */, - B230ED7019B417AE00364AA8 /* CCTrianglesCommand.h */, - 50ABBD741925AB4100A911A9 /* CCQuadCommand.cpp */, - 50ABBD751925AB4100A911A9 /* CCQuadCommand.h */, - 50ABBD761925AB4100A911A9 /* CCRenderCommand.cpp */, - 50ABBD771925AB4100A911A9 /* CCRenderCommand.h */, - 50ABBD781925AB4100A911A9 /* CCRenderCommandPool.h */, - 50ABBD791925AB4100A911A9 /* CCRenderer.cpp */, - 50ABBD7A1925AB4100A911A9 /* CCRenderer.h */, - 50ABBD7B1925AB4100A911A9 /* ccShaders.cpp */, - 50ABBD7C1925AB4100A911A9 /* ccShaders.h */, - 50ABBD7D1925AB4100A911A9 /* CCTexture2D.cpp */, - 50ABBD7E1925AB4100A911A9 /* CCTexture2D.h */, - 50ABBD7F1925AB4100A911A9 /* CCTextureAtlas.cpp */, - 50ABBD801925AB4100A911A9 /* CCTextureAtlas.h */, - 50ABBD811925AB4100A911A9 /* CCTextureCache.cpp */, - 50ABBD821925AB4100A911A9 /* CCTextureCache.h */, - B257B44C1989D5E800D9A687 /* CCPrimitive.cpp */, - B257B44D1989D5E800D9A687 /* CCPrimitive.h */, - B257B45E198A353E00D9A687 /* CCPrimitiveCommand.cpp */, - B257B45F198A353E00D9A687 /* CCPrimitiveCommand.h */, - ); - name = renderer; - path = ../cocos/renderer; - sourceTree = ""; - }; - 5034CA5D191D591900CE6051 /* shaders */ = { - isa = PBXGroup; - children = ( - 29D57CFF1D7FEC1C001735C5 /* ccShader_SpriteDistortion.frag */, - 29D57CFC1D7FE03C001735C5 /* ccShader_UI_Gray.frag */, - B241A6E21AFB0BE700C5623C /* ccShader_CameraClear.frag */, - B241A6E31AFB0BE700C5623C /* ccShader_CameraClear.vert */, - B20564AA1A6E5744001C1B6E /* ccShader_PositionColorTextureAsPointsize.vert */, - 5034CA60191D91CF00CE6051 /* ccShader_PositionTextureColor.vert */, - 5034CA61191D91CF00CE6051 /* ccShader_PositionTextureColor.frag */, - 5034CA62191D91CF00CE6051 /* ccShader_PositionTextureColor_noMVP.vert */, - 5034CA63191D91CF00CE6051 /* ccShader_PositionTextureColor_noMVP.frag */, - 5034C9FB191D591000CE6051 /* ccShader_PositionTextureColorAlphaTest.frag */, - 5034CA00191D591000CE6051 /* ccShader_PositionTextureA8Color.vert */, - 5034CA01191D591000CE6051 /* ccShader_PositionTextureA8Color.frag */, - 5034CA02191D591000CE6051 /* ccShader_PositionTexture.vert */, - 5034CA05191D591000CE6051 /* ccShader_PositionTexture.frag */, - 5034CA03191D591000CE6051 /* ccShader_PositionTexture_uColor.vert */, - 5034CA04191D591000CE6051 /* ccShader_PositionTexture_uColor.frag */, - 5034CA06191D591000CE6051 /* ccShader_PositionColorLengthTexture.vert */, - 5034CA07191D591000CE6051 /* ccShader_PositionColorLengthTexture.frag */, - 5034CA08191D591000CE6051 /* ccShader_PositionColor.vert */, - 5034CA09191D591000CE6051 /* ccShader_PositionColor.frag */, - 5034CA0A191D591000CE6051 /* ccShader_Position_uColor.vert */, - 5034CA0B191D591000CE6051 /* ccShader_Position_uColor.frag */, - 5034CA0C191D591000CE6051 /* ccShader_Label.vert */, - 5034CA0D191D591000CE6051 /* ccShader_Label_outline.frag */, - 5034CA0E191D591000CE6051 /* ccShader_Label_normal.frag */, - 5034CA0F191D591000CE6051 /* ccShader_Label_df.frag */, - 5034CA10191D591000CE6051 /* ccShader_Label_df_glow.frag */, - ); - name = shaders; - sourceTree = ""; - }; 503DD8CD1926736A00CD74DD /* ios */ = { isa = PBXGroup; children = ( 1A37E9C3200DD0680078AF72 /* CCReachability.h */, 1A37E9C4200DD0680078AF72 /* CCReachability.cpp */, - 503DD8CE1926736A00CD74DD /* CCApplication-ios.h */, - 503DD8CF1926736A00CD74DD /* CCApplication-ios.mm */, - 503DD8D01926736A00CD74DD /* CCCommon-ios.mm */, 503DD8D11926736A00CD74DD /* CCDevice-ios.mm */, 503DD8D21926736A00CD74DD /* CCDirectorCaller-ios.h */, 503DD8D31926736A00CD74DD /* CCDirectorCaller-ios.mm */, @@ -3572,8 +1756,6 @@ 503DD8D71926736A00CD74DD /* CCES2Renderer-ios.m */, 503DD8D81926736A00CD74DD /* CCESRenderer-ios.h */, 503DD8D91926736A00CD74DD /* CCGL-ios.h */, - 503DD8DA1926736A00CD74DD /* CCGLViewImpl-ios.h */, - 503DD8DB1926736A00CD74DD /* CCGLViewImpl-ios.mm */, 503DD8DC1926736A00CD74DD /* CCImage-ios.mm */, 503DD8DD1926736A00CD74DD /* CCPlatformDefine-ios.h */, 503DD8DE1926736A00CD74DD /* CCStdC-ios.h */, @@ -3582,81 +1764,24 @@ path = ios; sourceTree = ""; }; - 50693C621B6BF2BC005C5820 /* Downloader */ = { - isa = PBXGroup; - children = ( - A05DCF9B1B90584E00EE040B /* CCDownloader-curl.cpp */, - A05DCF9C1B90584E00EE040B /* CCDownloader-curl.h */, - A0534A691B87306E006B03E5 /* CCIDownloaderImpl.h */, - A0534A631B872FFD006B03E5 /* CCDownloader-apple.h */, - A0534A641B872FFD006B03E5 /* CCDownloader-apple.mm */, - 50693C5C1B6BF2AE005C5820 /* CCDownloader.cpp */, - 50693C5D1B6BF2AE005C5820 /* CCDownloader.h */, - ); - name = Downloader; - sourceTree = ""; - }; - 507003251B69820100E83DDD /* HttpClient */ = { - isa = PBXGroup; - children = ( - 52B47A2B1A5349A3004E4C60 /* HttpClient-apple.mm */, - 507003181B69735200E83DDD /* HttpClient.cpp */, - 1AAF5363180E3374000584C8 /* HttpClient.h */, - 52B47A291A5349A3004E4C60 /* HttpAsynConnection-apple.h */, - 52B47A2A1A5349A3004E4C60 /* HttpAsynConnection-apple.m */, - 52B47A2C1A5349A3004E4C60 /* HttpCookie.cpp */, - 52B47A2D1A5349A3004E4C60 /* HttpCookie.h */, - 1AAF5364180E3374000584C8 /* HttpRequest.h */, - 1AAF5365180E3374000584C8 /* HttpResponse.h */, - ); - name = HttpClient; - sourceTree = ""; - }; - 507003261B69820B00E83DDD /* SocketIO */ = { - isa = PBXGroup; - children = ( - 1AAF5366180E3374000584C8 /* SocketIO.cpp */, - 1AAF5367180E3374000584C8 /* SocketIO.h */, - ); - name = SocketIO; - sourceTree = ""; - }; - 507003271B69821300E83DDD /* WebSocket */ = { - isa = PBXGroup; - children = ( - 1A8D254E1F399C61002CC0A8 /* WebSocket-libwebsockets.cpp */, - 1A28FF191F20AF94007A1D9D /* WebSocket-apple.mm */, - 1AAF5369180E3374000584C8 /* WebSocket.h */, - ); - name = WebSocket; - sourceTree = ""; - }; 50ABBEDB1926664700A911A9 /* platform */ = { isa = PBXGroup; children = ( 503DD8CD1926736A00CD74DD /* ios */, - 50ABBF2D1926664700A911A9 /* desktop */, 50ABBF4E1926664700A911A9 /* mac */, 50ABBF1A1926664700A911A9 /* apple */, 50643BE019BFCF1800EF68ED /* CCPlatformConfig.h */, 50643BE119BFCF1800EF68ED /* CCPlatformMacros.h */, 5091A7A219BFABA800AC8789 /* CCPlatformDefine.h */, 50643BD319BFAECF00EF68ED /* CCGL.h */, - 50643BD719BFAF4400EF68ED /* CCApplication.h */, 50643BD819BFAF4400EF68ED /* CCStdC.h */, - 50ABBF201926664700A911A9 /* CCApplicationProtocol.h */, - 50ABBF211926664700A911A9 /* CCCommon.h */, 50ABBF221926664700A911A9 /* CCDevice.h */, 50ABBF231926664700A911A9 /* CCFileUtils.cpp */, 50ABBF241926664700A911A9 /* CCFileUtils.h */, - 50ABBF251926664700A911A9 /* CCGLView.cpp */, - 50ABBF261926664700A911A9 /* CCGLView.h */, 50ABBF271926664700A911A9 /* CCImage.cpp */, 50ABBF281926664700A911A9 /* CCImage.h */, 50ABBF291926664700A911A9 /* CCSAXParser.cpp */, 50ABBF2A1926664700A911A9 /* CCSAXParser.h */, - 50ABBF2B1926664700A911A9 /* CCThread.cpp */, - 50ABBF2C1926664700A911A9 /* CCThread.h */, ); name = platform; path = ../cocos/platform; @@ -3671,26 +1796,13 @@ 50ABBF1C1926664700A911A9 /* CCFileUtils-apple.mm */, 50ABBF1D1926664700A911A9 /* CCLock-apple.cpp */, 50ABBF1E1926664700A911A9 /* CCLock-apple.h */, - 50ABBF1F1926664700A911A9 /* CCThread-apple.mm */, ); path = apple; sourceTree = ""; }; - 50ABBF2D1926664700A911A9 /* desktop */ = { - isa = PBXGroup; - children = ( - 50ABBF2E1926664700A911A9 /* CCGLViewImpl-desktop.cpp */, - 50ABBF2F1926664700A911A9 /* CCGLViewImpl-desktop.h */, - ); - path = desktop; - sourceTree = ""; - }; 50ABBF4E1926664700A911A9 /* mac */ = { isa = PBXGroup; children = ( - 50ABBF4F1926664700A911A9 /* CCApplication-mac.h */, - 50ABBF501926664700A911A9 /* CCApplication-mac.mm */, - 50ABBF511926664700A911A9 /* CCCommon-mac.mm */, 50ABBF521926664700A911A9 /* CCDevice-mac.mm */, 50ABBF531926664700A911A9 /* CCGL-mac.h */, 50ABBF541926664700A911A9 /* CCPlatformDefine-mac.h */, @@ -3699,40 +1811,6 @@ path = mac; sourceTree = ""; }; - 50CB246E19D9C5A100687767 /* apple */ = { - isa = PBXGroup; - children = ( - 50CB246F19D9C5A100687767 /* AudioCache.h */, - 50CB247019D9C5A100687767 /* AudioCache.mm */, - 1A5FB7C81DF10E3500C918C1 /* AudioDecoder.h */, - 1A5FB7C71DF10E3500C918C1 /* AudioDecoder.mm */, - 50CB247119D9C5A100687767 /* AudioEngine-inl.h */, - 50CB247219D9C5A100687767 /* AudioEngine-inl.mm */, - 1A5FB7C91DF10E3500C918C1 /* AudioMacros.h */, - 50CB247319D9C5A100687767 /* AudioPlayer.h */, - 50CB247419D9C5A100687767 /* AudioPlayer.mm */, - ); - path = apple; - sourceTree = ""; - }; - A63CEFF81CD9CF2700A6971D /* Mac */ = { - isa = PBXGroup; - children = ( - A63CEFF91CD9CF3500A6971D /* CCUIEditBoxMac.h */, - A63CEFFA1CD9CF3500A6971D /* CCUIEditBoxMac.mm */, - A63CEFFB1CD9CF3500A6971D /* CCUIMultilineTextField.h */, - A63CEFFC1CD9CF3500A6971D /* CCUIMultilineTextField.m */, - A63CEFFD1CD9CF3500A6971D /* CCUIPasswordTextField.h */, - A63CEFFE1CD9CF3500A6971D /* CCUIPasswordTextField.m */, - A63CEFFF1CD9CF3500A6971D /* CCUISingleLineTextField.h */, - A63CF0001CD9CF3500A6971D /* CCUISingleLineTextField.m */, - A63CF0011CD9CF3500A6971D /* CCUITextFieldFormatter.h */, - A63CF0021CD9CF3500A6971D /* CCUITextFieldFormatter.m */, - A63CF0031CD9CF3500A6971D /* CCUITextInput.h */, - ); - name = Mac; - sourceTree = ""; - }; B291B5151D4A0FE300BBB345 /* mac */ = { isa = PBXGroup; children = ( @@ -3765,21 +1843,6 @@ name = ios; sourceTree = ""; }; - BA679B271CEC371100F875FA /* assets-manager */ = { - isa = PBXGroup; - children = ( - BA679B281CEC373000F875FA /* AssetsManagerEx.cpp */, - BA679B291CEC373000F875FA /* AssetsManagerEx.h */, - BA679B2A1CEC373000F875FA /* CCEventAssetsManagerEx.cpp */, - BA679B2B1CEC373000F875FA /* CCEventAssetsManagerEx.h */, - BA679B2C1CEC373000F875FA /* CCEventListenerAssetsManagerEx.cpp */, - BA679B2D1CEC373000F875FA /* CCEventListenerAssetsManagerEx.h */, - BA679B2E1CEC373000F875FA /* Manifest.cpp */, - BA679B2F1CEC373000F875FA /* Manifest.h */, - ); - name = "assets-manager"; - sourceTree = ""; - }; BA68D76E1D62F4A500B7A3F9 /* poly2tri */ = { isa = PBXGroup; children = ( @@ -3888,149 +1951,6 @@ name = ConvertUTF; sourceTree = ""; }; - FA6F1AF71D80F858007DD223 /* dragonbones */ = { - isa = PBXGroup; - children = ( - FA6F1AF81D80F858007DD223 /* animation */, - FA6F1B031D80F858007DD223 /* armature */, - FA6F1B0C1D80F858007DD223 /* cocos2dx */, - FA6F1B161D80F858007DD223 /* core */, - FA6F1B1A1D80F858007DD223 /* DragonBonesHeaders.h */, - FA6F1B1B1D80F858007DD223 /* events */, - FA6F1B1E1D80F858007DD223 /* factories */, - FA6F1B211D80F858007DD223 /* geom */, - FA6F1B271D80F858007DD223 /* model */, - FA6F1B321D80F858007DD223 /* parsers */, - FA6F1B3E1D80F858007DD223 /* textures */, - ); - path = dragonbones; - sourceTree = ""; - }; - FA6F1AF81D80F858007DD223 /* animation */ = { - isa = PBXGroup; - children = ( - FA6F1AF91D80F858007DD223 /* Animation.cpp */, - FA6F1AFA1D80F858007DD223 /* Animation.h */, - FA6F1AFB1D80F858007DD223 /* AnimationState.cpp */, - FA6F1AFC1D80F858007DD223 /* AnimationState.h */, - FA6F1AFD1D80F858007DD223 /* BaseTimelineState.h */, - FA6F1AFE1D80F858007DD223 /* IAnimateble.h */, - FA6F1AFF1D80F858007DD223 /* TimelineState.cpp */, - FA6F1B001D80F858007DD223 /* TimelineState.h */, - FA6F1B011D80F858007DD223 /* WorldClock.cpp */, - FA6F1B021D80F858007DD223 /* WorldClock.h */, - ); - path = animation; - sourceTree = ""; - }; - FA6F1B031D80F858007DD223 /* armature */ = { - isa = PBXGroup; - children = ( - FA6F1B041D80F858007DD223 /* Armature.cpp */, - FA6F1B051D80F858007DD223 /* Armature.h */, - FA6F1B061D80F858007DD223 /* Bone.cpp */, - FA6F1B071D80F858007DD223 /* Bone.h */, - FA6F1B081D80F858007DD223 /* IArmatureDisplay.h */, - FA6F1B091D80F858007DD223 /* Slot.cpp */, - FA6F1B0A1D80F858007DD223 /* Slot.h */, - FA6F1B0B1D80F858007DD223 /* TransformObject.h */, - ); - path = armature; - sourceTree = ""; - }; - FA6F1B0C1D80F858007DD223 /* cocos2dx */ = { - isa = PBXGroup; - children = ( - FA6F1B0D1D80F858007DD223 /* CCArmatureDisplay.cpp */, - FA6F1B0E1D80F858007DD223 /* CCArmatureDisplay.h */, - FA6F1B0F1D80F858007DD223 /* CCDragonBonesHeaders.h */, - FA6F1B101D80F858007DD223 /* CCFactory.cpp */, - FA6F1B111D80F858007DD223 /* CCFactory.h */, - FA6F1B121D80F858007DD223 /* CCSlot.cpp */, - FA6F1B131D80F858007DD223 /* CCSlot.h */, - FA6F1B141D80F858007DD223 /* CCTextureData.cpp */, - FA6F1B151D80F858007DD223 /* CCTextureData.h */, - ); - path = cocos2dx; - sourceTree = ""; - }; - FA6F1B161D80F858007DD223 /* core */ = { - isa = PBXGroup; - children = ( - FA6F1B171D80F858007DD223 /* BaseObject.cpp */, - FA6F1B181D80F858007DD223 /* BaseObject.h */, - FA6F1B191D80F858007DD223 /* DragonBones.h */, - ); - path = core; - sourceTree = ""; - }; - FA6F1B1B1D80F858007DD223 /* events */ = { - isa = PBXGroup; - children = ( - FA6F1B1C1D80F858007DD223 /* EventObject.cpp */, - FA6F1B1D1D80F858007DD223 /* EventObject.h */, - ); - path = events; - sourceTree = ""; - }; - FA6F1B1E1D80F858007DD223 /* factories */ = { - isa = PBXGroup; - children = ( - FA6F1B1F1D80F858007DD223 /* BaseFactory.cpp */, - FA6F1B201D80F858007DD223 /* BaseFactory.h */, - ); - path = factories; - sourceTree = ""; - }; - FA6F1B211D80F858007DD223 /* geom */ = { - isa = PBXGroup; - children = ( - FA6F1B221D80F858007DD223 /* ColorTransform.h */, - FA6F1B231D80F858007DD223 /* Matrix.h */, - FA6F1B241D80F858007DD223 /* Point.h */, - FA6F1B251D80F858007DD223 /* Rectangle.h */, - FA6F1B261D80F858007DD223 /* Transform.h */, - ); - path = geom; - sourceTree = ""; - }; - FA6F1B271D80F858007DD223 /* model */ = { - isa = PBXGroup; - children = ( - FA6F1B281D80F858007DD223 /* AnimationData.cpp */, - FA6F1B291D80F858007DD223 /* AnimationData.h */, - FA6F1B2A1D80F858007DD223 /* ArmatureData.cpp */, - FA6F1B2B1D80F858007DD223 /* ArmatureData.h */, - FA6F1B2C1D80F858007DD223 /* DragonBonesData.cpp */, - FA6F1B2D1D80F858007DD223 /* DragonBonesData.h */, - FA6F1B2E1D80F858007DD223 /* FrameData.cpp */, - FA6F1B2F1D80F858007DD223 /* FrameData.h */, - FA6F1B301D80F858007DD223 /* TimelineData.cpp */, - FA6F1B311D80F858007DD223 /* TimelineData.h */, - ); - path = model; - sourceTree = ""; - }; - FA6F1B321D80F858007DD223 /* parsers */ = { - isa = PBXGroup; - children = ( - FA6F1B331D80F858007DD223 /* DataParser.cpp */, - FA6F1B341D80F858007DD223 /* DataParser.h */, - FA6F1B351D80F858007DD223 /* JSONDataParser.cpp */, - FA6F1B361D80F858007DD223 /* JSONDataParser.h */, - ); - path = parsers; - sourceTree = ""; - }; - FA6F1B3E1D80F858007DD223 /* textures */ = { - isa = PBXGroup; - children = ( - FA6F1B3F1D80F858007DD223 /* TextureData.cpp */, - FA6F1B401D80F858007DD223 /* TextureData.h */, - ); - path = textures; - sourceTree = ""; - }; /* End PBXGroup section */ /* Begin PBXHeadersBuildPhase section */ @@ -4039,417 +1959,200 @@ buildActionMask = 2147483647; files = ( 1A28FF891F20AFAB007A1D9D /* SRURLUtilities.h in Headers */, - 50ABBE9B1925AB6F00A911A9 /* CCRef.h in Headers */, - 50ABBE851925AB6F00A911A9 /* ccFPSImages.h in Headers */, - FA6F1B811D80F858007DD223 /* EventObject.h in Headers */, - 5034CA39191D591100CE6051 /* ccShader_PositionColorLengthTexture.frag in Headers */, - 292DB14B19B4574100A80320 /* UIEditBoxImpl-mac.h in Headers */, - 50ABBE891925AB6F00A911A9 /* CCMap.h in Headers */, + 46FDDAA7202ACC6A00931238 /* ForwardRenderer.h in Headers */, 4DED48101DFFA4AF0070C5C4 /* b2Settings.h in Headers */, 4DED486A1DFFA4AF0070C5C4 /* b2MotorJoint.h in Headers */, - 50ABBE8D1925AB6F00A911A9 /* CCNS.h in Headers */, - 50ABBEA51925AB6F00A911A9 /* CCScriptSupport.h in Headers */, - BAFF7DCC1D5C1CF80051B92F /* spine-cocos2dx.h in Headers */, + 46FDDB9D202ADDCE00931238 /* ObjectFactory.h in Headers */, + 46FDDC41202AEAC500931238 /* Atomics.h in Headers */, + 46FDDBC3202ADDCE00931238 /* ccConfig.h in Headers */, + 46FDDA77202ACC6A00931238 /* Light.h in Headers */, 1A28FF5D1F20AFAB007A1D9D /* SRProxyConnect.h in Headers */, - 1ABA68B01888D700007D1BB4 /* CCFontCharMap.h in Headers */, - FA6F1B4F1D80F858007DD223 /* TimelineState.h in Headers */, - BAFF7DAC1D5C1CF80051B92F /* SkeletonBatch.h in Headers */, + 46FDDBFF202ADDCE00931238 /* firePngData.h in Headers */, + 46FDDACF202ACC6A00931238 /* RenderBuffer.h in Headers */, + 46FDDAAF202ACC6A00931238 /* Texture2D.h in Headers */, 5091A7A319BFABA800AC8789 /* CCPlatformDefine.h in Headers */, - 5034CA3F191D591100CE6051 /* ccShader_Position_uColor.vert in Headers */, + 46FDDBCF202ADDCE00931238 /* CCMap.h in Headers */, 4DED48621DFFA4AF0070C5C4 /* b2GearJoint.h in Headers */, 50ABBD461925AB0000A911A9 /* CCVertex.h in Headers */, - BAFF7DA81D5C1CF80051B92F /* SkeletonAnimation.h in Headers */, - FA6F1B7D1D80F858007DD223 /* DragonBonesHeaders.h in Headers */, - B63990CE1A490AFE00B07923 /* CCAsyncTaskPool.h in Headers */, - A63CF0041CD9CF3500A6971D /* CCUIEditBoxMac.h in Headers */, - FA6F1BAB1D80F858007DD223 /* JSONDataParser.h in Headers */, - FA6F1B431D80F858007DD223 /* Animation.h in Headers */, - 15AE1B6F19AADA9900C27E9E /* GUIDefine.h in Headers */, + 46FDDC0B202ADDCE00931238 /* CCIMEDispatcher.h in Headers */, + 46FDDA9B202ACC6A00931238 /* Effect.h in Headers */, 50ABBD3E1925AB0000A911A9 /* CCGeometry.h in Headers */, - 50ABBE631925AB6F00A911A9 /* CCEventListenerAcceleration.h in Headers */, + 46FDDAD9202ACC6A00931238 /* Program.h in Headers */, ED30579B1BEC77B70083C3ED /* ConvertUTF.h in Headers */, - 50ABBED31925AB6F00A911A9 /* uthash.h in Headers */, - A63CF00A1CD9CF3500A6971D /* CCUISingleLineTextField.h in Headers */, - 3E2F27A719CFBFE400E7C490 /* AudioEngine.h in Headers */, - 15FB20761AE7BF8600C31518 /* CCAutoPolygon.h in Headers */, - DABC9FAB19E7DFA900FA252C /* CCClippingRectangleNode.h in Headers */, - BAFF7D941D5C1CF80051B92F /* PathAttachment.h in Headers */, - 50ABBEC11925AB6F00A911A9 /* CCValue.h in Headers */, - B276EF631988D1D500CD400F /* CCVertexIndexBuffer.h in Headers */, - 50ABBE871925AB6F00A911A9 /* ccMacros.h in Headers */, - FA6F1B8B1D80F858007DD223 /* Point.h in Headers */, + 46FDDA75202ACC6A00931238 /* Config.h in Headers */, + 46FDDAC3202ACC6A00931238 /* FrameBuffer.h in Headers */, + 46FDDC2B202AEAC500931238 /* UniquePtr.h in Headers */, BA68D7831D62F4A500B7A3F9 /* poly2tri.h in Headers */, - 50ABBE731925AB6F00A911A9 /* CCEventListenerMouse.h in Headers */, - 1A570063180BC5A10088DEC7 /* CCAction.h in Headers */, ED3057811BEC76C90083C3ED /* ioapi.h in Headers */, - 1A570067180BC5A10088DEC7 /* CCActionCamera.h in Headers */, - 1A57006B180BC5A10088DEC7 /* CCActionCatmullRom.h in Headers */, - 4DC06BEF1E8B604B00CA08B1 /* CCPhysicsManifoldWrapper.h in Headers */, 4DED487A1DFFA4AF0070C5C4 /* b2RevoluteJoint.h in Headers */, + 46FDDC4B202AEAC500931238 /* GLConsts.h in Headers */, 4DED487E1DFFA4AF0070C5C4 /* b2RopeJoint.h in Headers */, - 1A57006F180BC5A10088DEC7 /* CCActionEase.h in Headers */, - FA6F1B4B1D80F858007DD223 /* IAnimateble.h in Headers */, - 15AE1B6E19AADA9900C27E9E /* UIHelper.h in Headers */, - B230ED7319B417AE00364AA8 /* CCTrianglesCommand.h in Headers */, - 1A570073180BC5A10088DEC7 /* CCActionGrid.h in Headers */, - FA6F1B751D80F858007DD223 /* CCTextureData.h in Headers */, - 5034CA3B191D591100CE6051 /* ccShader_PositionColor.vert in Headers */, - 1A570077180BC5A10088DEC7 /* CCActionGrid3D.h in Headers */, - 1A57007B180BC5A10088DEC7 /* CCActionInstant.h in Headers */, - FA6F1B791D80F858007DD223 /* BaseObject.h in Headers */, - B276EF5F1988D1D500CD400F /* CCVertexIndexData.h in Headers */, - 1A57007F180BC5A10088DEC7 /* CCActionInterval.h in Headers */, - 4D2E690D1CC543B40032DD5C /* Triangulate.h in Headers */, + 46FDDA73202ACC6A00931238 /* ProgramLib.h in Headers */, 1A28FF751F20AFAB007A1D9D /* SRHTTPConnectMessage.h in Headers */, - 1A570083180BC5A10088DEC7 /* CCActionManager.h in Headers */, - 4DC06BE51E8A68D400CA08B1 /* CCPhysicsUtils.h in Headers */, + 46FDDADF202ACC6A00931238 /* RenderTarget.h in Headers */, 4DED483E1DFFA4AF0070C5C4 /* b2CircleContact.h in Headers */, - 4DFA4C191CBCE34100E3B736 /* CCScale9Sprite.h in Headers */, 4DED48181DFFA4AF0070C5C4 /* b2Timer.h in Headers */, - 1A570087180BC5A10088DEC7 /* CCActionPageTurn3D.h in Headers */, - 50ABBD911925AB4100A911A9 /* CCGLProgramCache.h in Headers */, - 50ED2BDA19BE76D300A0AB90 /* UIVideoPlayer.h in Headers */, - ED9C6A9618599AD8000A5232 /* CCNodeGrid.h in Headers */, - 50ABBEC31925AB6F00A911A9 /* CCVector.h in Headers */, - 1A57008B180BC5A10088DEC7 /* CCActionProgressTimer.h in Headers */, - 50ABBD8D1925AB4100A911A9 /* CCGLProgram.h in Headers */, 1A28FF5B1F20AFAB007A1D9D /* NSURLRequest+SRWebSocketPrivate.h in Headers */, - 50ABBEA11925AB6F00A911A9 /* CCScheduler.h in Headers */, - BAFF7D841D5C1CF80051B92F /* IkConstraint.h in Headers */, + 46FDDBE7202ADDCE00931238 /* CCNS.h in Headers */, + 46FDDAAB202ACC6A00931238 /* Types.h in Headers */, ED30577D1BEC76C90083C3ED /* crypt.h in Headers */, 1A9F0F991F301DE200A499E1 /* b2ObjectDestroyNotifier.h in Headers */, - 50ABBDB71925AB4100A911A9 /* CCTexture2D.h in Headers */, - 50ABBE811925AB6F00A911A9 /* CCEventType.h in Headers */, - 1A57008F180BC5A10088DEC7 /* CCActionTiledGrid.h in Headers */, - 15AE1BB619AADFEF00C27E9E /* SocketIO.h in Headers */, 4DED47F01DFFA4AF0070C5C4 /* b2ChainShape.h in Headers */, - 1A570093180BC5A10088DEC7 /* CCActionTween.h in Headers */, + 46FDDA97202ACC6A00931238 /* Model.h in Headers */, 50ABBD4A1925AB0000A911A9 /* Mat4.h in Headers */, - 29394CF419B01DBA00D2DE1A /* UIWebViewImpl-ios.h in Headers */, - 1A57009A180BC5C10088DEC7 /* CCAtlasNode.h in Headers */, + 46FDDC3B202AEAC500931238 /* MacroArgs.h in Headers */, + 46FDDA83202ACC6A00931238 /* Technique.h in Headers */, + 46FDDC43202AEAC500931238 /* Pair.h in Headers */, 4DED480C1DFFA4AF0070C5C4 /* b2Math.h in Headers */, - 1A5700A0180BC5D20088DEC7 /* CCNode.h in Headers */, + 46FDDA6D202ACC6A00931238 /* INode.h in Headers */, 1A28FF811F20AFAB007A1D9D /* SRRandom.h in Headers */, 50ABC0671926664800A911A9 /* CCPlatformDefine-mac.h in Headers */, - BAFF7DB01D5C1CF80051B92F /* SkeletonBounds.h in Headers */, 4DED48461DFFA4AF0070C5C4 /* b2ContactSolver.h in Headers */, - 1A570110180BC8EE0088DEC7 /* CCDrawingPrimitives.h in Headers */, - 50CB247D19D9C5A100687767 /* AudioPlayer.h in Headers */, - 1A570114180BC8EE0088DEC7 /* CCDrawNode.h in Headers */, + 46FDDB4D202ADDCE00931238 /* pvr.h in Headers */, 4DED48061DFFA4AF0070C5C4 /* b2Draw.h in Headers */, + 46FDDC45202AEAC500931238 /* Move.h in Headers */, 4DED48721DFFA4AF0070C5C4 /* b2PrismaticJoint.h in Headers */, + 46FDDC2F202AEAC500931238 /* Assertions.h in Headers */, 1A28FF551F20AFAB007A1D9D /* SRIOConsumerPool.h in Headers */, + 46FDDB9B202ADDCE00931238 /* CCProfiling.h in Headers */, + 46FDDC2D202AEAC500931238 /* Compiler.h in Headers */, + 46FDDBDD202ADDCE00931238 /* TGAlib.h in Headers */, BAEA45551E279D5C00FA219F /* tinydir.h in Headers */, - 1A57011D180BC90D0088DEC7 /* CCGrabber.h in Headers */, - 15AE1B6819AADA9900C27E9E /* UIScale9Sprite.h in Headers */, - A63CF00C1CD9CF3500A6971D /* CCUITextFieldFormatter.h in Headers */, - 1A570121180BC90D0088DEC7 /* CCGrid.h in Headers */, - 5034CA2D191D591100CE6051 /* ccShader_PositionTextureA8Color.frag in Headers */, - FA6F1B571D80F858007DD223 /* Armature.h in Headers */, - 50ABBED11925AB6F00A911A9 /* TGAlib.h in Headers */, - BA679B321CEC373000F875FA /* AssetsManagerEx.h in Headers */, + 46FDDAB7202ACC6A00931238 /* IndexBuffer.h in Headers */, + 46FDDA7B202ACC6A00931238 /* Camera.h in Headers */, + 46FDDAA5202ACC6A00931238 /* Scene.h in Headers */, + 46FDDB53202ADDCE00931238 /* utlist.h in Headers */, 4DED47F41DFFA4AF0070C5C4 /* b2CircleShape.h in Headers */, - 1A57019F180BCB590088DEC7 /* CCFont.h in Headers */, + 46FDDB5D202ADDCE00931238 /* ccMacros.h in Headers */, + 46FDDC27202AEAC500931238 /* WebGLTypes.h in Headers */, 4DED48321DFFA4AF0070C5C4 /* b2WorldCallbacks.h in Headers */, - 1A5701A3180BCB590088DEC7 /* CCFontAtlas.h in Headers */, - FA6F1B531D80F858007DD223 /* WorldClock.h in Headers */, - 1A5701A7180BCB590088DEC7 /* CCFontAtlasCache.h in Headers */, + 46FDDC47202AEAC500931238 /* StaticAnalysisFunctions.h in Headers */, + 46FDDABD202ACC6A00931238 /* DeviceGraphics.h in Headers */, 4DED47E01DFFA4AF0070C5C4 /* b2Collision.h in Headers */, 4DED482E1DFFA4AF0070C5C4 /* b2World.h in Headers */, - FA6F1B6D1D80F858007DD223 /* CCFactory.h in Headers */, - 15AE1B6C19AADA9900C27E9E /* UIWidget.h in Headers */, - FA6F1B711D80F858007DD223 /* CCSlot.h in Headers */, - 1A5701B3180BCB590088DEC7 /* CCFontFNT.h in Headers */, - FA6F1BA31D80F858007DD223 /* TimelineData.h in Headers */, - 5034CA47191D591100CE6051 /* ccShader_Label_normal.frag in Headers */, - BAFF7DDA1D5C1CF80051B92F /* VertexAttachment.h in Headers */, + 46FDDC01202ADDCE00931238 /* ccCArray.h in Headers */, + 46FDDC39202AEAC500931238 /* Attributes.h in Headers */, 4DED48141DFFA4AF0070C5C4 /* b2StackAllocator.h in Headers */, - 15AE1BB819AADFEF00C27E9E /* WebSocket.h in Headers */, - 1A5701B7180BCB5A0088DEC7 /* CCFontFreeType.h in Headers */, - 1A5701BB180BCB5A0088DEC7 /* CCLabel.h in Headers */, - 15AE1BC119AADFFB00C27E9E /* cocos-ext.h in Headers */, - 1A5701BF180BCB5A0088DEC7 /* CCLabelAtlas.h in Headers */, - 50ABBED91925AB6F00A911A9 /* ZipUtils.h in Headers */, 50643BDB19BFAF4400EF68ED /* CCStdC.h in Headers */, - 50ABBE5F1925AB6F00A911A9 /* CCEventListener.h in Headers */, - 1A5701C9180BCB5A0088DEC7 /* CCLabelTextFormatter.h in Headers */, 1A28FF591F20AFAB007A1D9D /* NSRunLoop+SRWebSocketPrivate.h in Headers */, - 5034CA37191D591100CE6051 /* ccShader_PositionColorLengthTexture.vert in Headers */, - 1A5701E0180BCB8C0088DEC7 /* CCLayer.h in Headers */, - BAFF7D8C1D5C1CF80051B92F /* Json.h in Headers */, + 46FDDB5B202ADDCE00931238 /* CCData.h in Headers */, 4DED488A1DFFA4AF0070C5C4 /* b2Rope.h in Headers */, + 46FDDC29202AEAC500931238 /* Casting.h in Headers */, 4DED48361DFFA4AF0070C5C4 /* b2ChainAndCircleContact.h in Headers */, - 1A5701E4180BCB8C0088DEC7 /* CCScene.h in Headers */, + 46FDDB83202ADDCE00931238 /* ccRandom.h in Headers */, 294D7D9A1D0E93A2002CE7B7 /* CCDevice-apple.h in Headers */, - FA6F1B971D80F858007DD223 /* ArmatureData.h in Headers */, - A6F0D7A21C2796020029CC44 /* CCStencilStateManager.hpp in Headers */, - 50ABBEAD1925AB6F00A911A9 /* ccTypes.h in Headers */, BA68D78F1D62F4A500B7A3F9 /* sweep.h in Headers */, - 1A5701E8180BCB8C0088DEC7 /* CCTransition.h in Headers */, - 1A5701EC180BCB8C0088DEC7 /* CCTransitionPageTurn.h in Headers */, - FA6F1B871D80F858007DD223 /* ColorTransform.h in Headers */, - BAFF7DD21D5C1CF80051B92F /* TransformConstraint.h in Headers */, 1A28FF851F20AFAB007A1D9D /* SRSIMDHelpers.h in Headers */, - 1A5701F0180BCB8C0088DEC7 /* CCTransitionProgress.h in Headers */, - 1A5701F9180BCBAD0088DEC7 /* CCMenu.h in Headers */, 50ABBD401925AB0000A911A9 /* CCMath.h in Headers */, - FA6F1B5D1D80F858007DD223 /* IArmatureDisplay.h in Headers */, - FA6F1B691D80F858007DD223 /* CCDragonBonesHeaders.h in Headers */, - 1A5701FD180BCBAD0088DEC7 /* CCMenuItem.h in Headers */, - A63CF00E1CD9CF3500A6971D /* CCUITextInput.h in Headers */, - 1A5FB7CB1DF10E3500C918C1 /* AudioDecoder.h in Headers */, ED3057831BEC76C90083C3ED /* unzip.h in Headers */, - 1A570204180BCBD40088DEC7 /* CCClippingNode.h in Headers */, 50643BE419BFCF1800EF68ED /* CCPlatformMacros.h in Headers */, - BAFF7DA41D5C1CF80051B92F /* Skeleton.h in Headers */, 1A28FF511F20AFAB007A1D9D /* SRIOConsumer.h in Headers */, - 1A57020A180BCBDF0088DEC7 /* CCMotionStreak.h in Headers */, - 1A570212180BCBF40088DEC7 /* CCProgressTimer.h in Headers */, 4DED47EC1DFFA4AF0070C5C4 /* b2TimeOfImpact.h in Headers */, - 1A570216180BCBF40088DEC7 /* CCRenderTexture.h in Headers */, - 4D2E69091CC543B40032DD5C /* CCGraphicsNode.h in Headers */, - 1A570223180BCC1A0088DEC7 /* CCParticleBatchNode.h in Headers */, - 4D6CF4391E83AAD5003327D4 /* CCCameraNode.h in Headers */, - FAC8F6681E1DF15D002B17E8 /* kvec.h in Headers */, - 4DC06BE11E8A68D400CA08B1 /* CCPhysicsRayCastCallback.h in Headers */, - 50ABBD891925AB4100A911A9 /* CCCustomCommand.h in Headers */, - 5034CA43191D591100CE6051 /* ccShader_Label.vert in Headers */, - 4DC06BDD1E8A68D400CA08B1 /* CCPhysicsDebugDraw.h in Headers */, - 1A570227180BCC1A0088DEC7 /* CCParticleExamples.h in Headers */, - FA6F1B851D80F858007DD223 /* BaseFactory.h in Headers */, - 1A57022B180BCC1A0088DEC7 /* CCParticleSystem.h in Headers */, - 5034CA2F191D591100CE6051 /* ccShader_PositionTexture.vert in Headers */, - 50ABBE951925AB6F00A911A9 /* CCProfiling.h in Headers */, - 5034CA4B191D591100CE6051 /* ccShader_Label_df_glow.frag in Headers */, - 50ABBE4F1925AB6F00A911A9 /* CCEventCustom.h in Headers */, - A614E2E01C8E72360065A737 /* CCLabelTTF.h in Headers */, + 46FDDA7F202ACC6A00931238 /* Renderer.h in Headers */, + 46FDDAA1202ACC6A00931238 /* InputAssembler.h in Headers */, + 46FDDA91202ACC6A00931238 /* Pass.h in Headers */, + 46FDDC35202AEAC500931238 /* IntegerTypeTraits.h in Headers */, + 46FDDAC7202ACC6A00931238 /* GFX.h in Headers */, 4DED48081DFFA4AF0070C5C4 /* b2GrowableStack.h in Headers */, BA68D79A1D62F4B700B7A3F9 /* clipper.hpp in Headers */, 50ABBD521925AB0000A911A9 /* Quaternion.h in Headers */, - 1A57022F180BCC1A0088DEC7 /* CCParticleSystemQuad.h in Headers */, BA68D7931D62F4A500B7A3F9 /* sweep_context.h in Headers */, 4DED482A1DFFA4AF0070C5C4 /* b2TimeStep.h in Headers */, 1A28FF9B1F20AFAB007A1D9D /* SRWebSocket.h in Headers */, 50643BE219BFCF1800EF68ED /* CCPlatformConfig.h in Headers */, - BAFF7DB41D5C1CF80051B92F /* SkeletonData.h in Headers */, - A63CF0061CD9CF3500A6971D /* CCUIMultilineTextField.h in Headers */, - 5034CA49191D591100CE6051 /* ccShader_Label_df.frag in Headers */, - 292DB14119B4574100A80320 /* UIEditBoxImpl.h in Headers */, - 50CB247919D9C5A100687767 /* AudioEngine-inl.h in Headers */, 1A28FF611F20AFAB007A1D9D /* SRRunLoopThread.h in Headers */, 50ABBD561925AB0000A911A9 /* TransformUtils.h in Headers */, - 299754F6193EC95400A54AC3 /* ObjectFactory.h in Headers */, - 50ABBD991925AB4100A911A9 /* CCGLProgramStateCache.h in Headers */, - FA6F1B671D80F858007DD223 /* CCArmatureDisplay.h in Headers */, - BAFF7D7C1D5C1CF80051B92F /* EventData.h in Headers */, - 5034CA3D191D591100CE6051 /* ccShader_PositionColor.frag in Headers */, - A0534A6A1B87306E006B03E5 /* CCIDownloaderImpl.h in Headers */, - BAFF7D4C1D5C1CF80051B92F /* AnimationState.h in Headers */, - BAFF7D541D5C1CF80051B92F /* Atlas.h in Headers */, - 1A570280180BCC900088DEC7 /* CCSprite.h in Headers */, - 1A570284180BCC900088DEC7 /* CCSpriteBatchNode.h in Headers */, - 5034CA2B191D591100CE6051 /* ccShader_PositionTextureA8Color.vert in Headers */, - FA6F1B8D1D80F858007DD223 /* Rectangle.h in Headers */, - 1A570288180BCC900088DEC7 /* CCSpriteFrame.h in Headers */, - 1A57028C180BCC900088DEC7 /* CCSpriteFrameCache.h in Headers */, + 46FDDBBB202ADDCE00931238 /* CCRefPtr.h in Headers */, + 46FDDADB202ACC6A00931238 /* State.h in Headers */, + 46FDDC33202AEAC500931238 /* Types.h in Headers */, + 46FDDACB202ACC6A00931238 /* VertexFormat.h in Headers */, + 46FDDA81202ACC6A00931238 /* RendererUtils.h in Headers */, + 46FDDAD1202ACC6A00931238 /* Texture.h in Headers */, 4DED48421DFFA4AF0070C5C4 /* b2Contact.h in Headers */, 1A28FF971F20AFAB007A1D9D /* SRSecurityPolicy.h in Headers */, - FA6F1B931D80F858007DD223 /* AnimationData.h in Headers */, 5027253A190BF1B900AAF4ED /* cocos2d.h in Headers */, - 15AE184A19AAD30500C27E9E /* Export.h in Headers */, - 1A570294180BCCAB0088DEC7 /* CCAnimation.h in Headers */, 50ABBD421925AB0000A911A9 /* CCMathBase.h in Headers */, - 1A570298180BCCAB0088DEC7 /* CCAnimationCache.h in Headers */, - 50ABC05D1926664800A911A9 /* CCApplication-mac.h in Headers */, 4DED48021DFFA4AF0070C5C4 /* b2BlockAllocator.h in Headers */, - BA679B3A1CEC373000F875FA /* CCEventListenerAssetsManagerEx.h in Headers */, - BAFF7D901D5C1CF80051B92F /* MeshAttachment.h in Headers */, - FA6F1B471D80F858007DD223 /* AnimationState.h in Headers */, - FAC8F25F1D339EB70061CEDD /* CCTMXTiledMap.h in Headers */, - BAFF7D501D5C1CF80051B92F /* AnimationStateData.h in Headers */, - BAFF7D881D5C1CF80051B92F /* IkConstraintData.h in Headers */, - 50ABC0071926664800A911A9 /* CCApplicationProtocol.h in Headers */, 4DED48761DFFA4AF0070C5C4 /* b2PulleyJoint.h in Headers */, 4DED47D61DFFA4AF0070C5C4 /* b2BroadPhase.h in Headers */, - FA6F1B5B1D80F858007DD223 /* Bone.h in Headers */, - BAFF7D601D5C1CF80051B92F /* AttachmentLoader.h in Headers */, - BAFF7DC41D5C1CF80051B92F /* Slot.h in Headers */, 4DED47F81DFFA4AF0070C5C4 /* b2EdgeShape.h in Headers */, 50ABBD4E1925AB0000A911A9 /* MathUtil.h in Headers */, - 15AE1BC219AADFFB00C27E9E /* ExtensionMacros.h in Headers */, 4DED48241DFFA4AF0070C5C4 /* b2Fixture.h in Headers */, - BAFF7D9C1D5C1CF80051B92F /* PathConstraintData.h in Headers */, - 50ABBE431925AB6F00A911A9 /* CCDirector.h in Headers */, 1A28FF911F20AFAB007A1D9D /* NSURLRequest+SRWebSocket.h in Headers */, BA68D7871D62F4A500B7A3F9 /* advancing_front.h in Headers */, - 1A12775B18DFCC540005F345 /* CCTweenFunction.h in Headers */, - 1A5702CA180BCE370088DEC7 /* CCTextFieldTTF.h in Headers */, - 4DC06BD51E8A68D400CA08B1 /* CCPhysicsContactListener.h in Headers */, - BAFF7D741D5C1CF80051B92F /* Cocos2dAttachmentLoader.h in Headers */, - 15EFA213198A2BB5000C57D3 /* CCProtectedNode.h in Headers */, - 1A5702EC180BCE750088DEC7 /* CCTileMapAtlas.h in Headers */, + 46FDDAAD202ACC6A00931238 /* Macro.h in Headers */, BA68D77F1D62F4A500B7A3F9 /* shapes.h in Headers */, 50ABC01B1926664800A911A9 /* CCSAXParser.h in Headers */, - 50ABBED51925AB6F00A911A9 /* utlist.h in Headers */, - 1A5702F4180BCE750088DEC7 /* CCTMXObjectGroup.h in Headers */, - 50ABBDAF1925AB4100A911A9 /* CCRenderer.h in Headers */, - 5034CA21191D591100CE6051 /* ccShader_PositionTextureColorAlphaTest.frag in Headers */, 4DED48201DFFA4AF0070C5C4 /* b2ContactManager.h in Headers */, - 50ABBDA11925AB4100A911A9 /* CCGroupCommand.h in Headers */, - BAFF7D6C1D5C1CF80051B92F /* BoneData.h in Headers */, - 29394CF019B01DBA00D2DE1A /* UIWebView.h in Headers */, - 1A5FB7CC1DF10E3500C918C1 /* AudioMacros.h in Headers */, - BAFF7DBC1D5C1CF80051B92F /* SkeletonRenderer.h in Headers */, 1A28FF691F20AFAB007A1D9D /* SRConstants.h in Headers */, - 1A5702FC180BCE750088DEC7 /* CCTMXXMLParser.h in Headers */, - FA6F1B8F1D80F858007DD223 /* Transform.h in Headers */, - BAFF7DD61D5C1CF80051B92F /* TransformConstraintData.h in Headers */, 4DED47E81DFFA4AF0070C5C4 /* b2DynamicTree.h in Headers */, - BA679B3E1CEC373000F875FA /* Manifest.h in Headers */, - BAFF7D781D5C1CF80051B92F /* Event.h in Headers */, - BAFF7DA01D5C1CF80051B92F /* RegionAttachment.h in Headers */, 4DED47FE1DFFA4AF0070C5C4 /* b2Shape.h in Headers */, ED3057891BEC773E0083C3ED /* tinyxml2.h in Headers */, - 50ABBDBB1925AB4100A911A9 /* CCTextureAtlas.h in Headers */, 4DED481C1DFFA4AF0070C5C4 /* b2Body.h in Headers */, - 1A570302180BCE890088DEC7 /* CCParallaxNode.h in Headers */, - 50ABBE4B1925AB6F00A911A9 /* CCEventAcceleration.h in Headers */, 4DED47FC1DFFA4AF0070C5C4 /* b2PolygonShape.h in Headers */, - 1A57030E180BCF190088DEC7 /* CCComponent.h in Headers */, - 1A570312180BCF190088DEC7 /* CCComponentContainer.h in Headers */, - BAFF7DB81D5C1CF80051B92F /* SkeletonJson.h in Headers */, - FA6F1B9B1D80F858007DD223 /* DragonBonesData.h in Headers */, - 15AE1B7119AADA9900C27E9E /* CocosGUI.h in Headers */, 4DED485E1DFFA4AF0070C5C4 /* b2FrictionJoint.h in Headers */, - 50ABBD851925AB4100A911A9 /* CCBatchCommand.h in Headers */, 50ABC0651926664800A911A9 /* CCGL-mac.h in Headers */, 50643BD419BFAECF00EF68ED /* CCGL.h in Headers */, 50ABBD621925AB0000A911A9 /* Vec4.h in Headers */, - FA6F1B611D80F858007DD223 /* Slot.h in Headers */, - 50ABBE331925AB6F00A911A9 /* CCConfiguration.h in Headers */, - 4D2816681E8CBB7200F26B06 /* CCPhysicsContactImpulse.h in Headers */, - 50CB247519D9C5A100687767 /* AudioCache.h in Headers */, - 50ABC01F1926664800A911A9 /* CCThread.h in Headers */, - BAFF7DC81D5C1CF80051B92F /* SlotData.h in Headers */, - 50ABBDBF1925AB4100A911A9 /* CCTextureCache.h in Headers */, - BAFF7D701D5C1CF80051B92F /* BoundingBoxAttachment.h in Headers */, - 5034CA35191D591100CE6051 /* ccShader_PositionTexture.frag in Headers */, - BAFF7D981D5C1CF80051B92F /* PathConstraint.h in Headers */, - 15AE1BB219AADFEF00C27E9E /* HttpClient.h in Headers */, 4DED483A1DFFA4AF0070C5C4 /* b2ChainAndPolygonContact.h in Headers */, 4DED48561DFFA4AF0070C5C4 /* b2PolygonContact.h in Headers */, 1A28FF791F20AFAB007A1D9D /* SRLog.h in Headers */, - 50ABBE6F1925AB6F00A911A9 /* CCEventListenerKeyboard.h in Headers */, - 4DC06BE91E8A68D400CA08B1 /* CCPhysicsWorldManifoldWrapper.h in Headers */, - 50ABBE9D1925AB6F00A911A9 /* CCRefPtr.h in Headers */, + 46FDDC31202AEAC500931238 /* TypeTraits.h in Headers */, + 46FDDB6D202ADDCE00931238 /* etc1.h in Headers */, + 46FDDBB7202ADDCE00931238 /* ccUtils.h in Headers */, + 46FDDB6B202ADDCE00931238 /* base64.h in Headers */, + 46FDDC3F202AEAC500931238 /* Likely.h in Headers */, 4DED484A1DFFA4AF0070C5C4 /* b2EdgeAndCircleContact.h in Headers */, - FA6F1B631D80F858007DD223 /* TransformObject.h in Headers */, 1A28FF6D1F20AFAB007A1D9D /* SRError.h in Headers */, - B257B461198A353E00D9A687 /* CCPrimitiveCommand.h in Headers */, - 5034CA31191D591100CE6051 /* ccShader_PositionTexture_uColor.vert in Headers */, 4DED48821DFFA4AF0070C5C4 /* b2WeldJoint.h in Headers */, 4DED48661DFFA4AF0070C5C4 /* b2Joint.h in Headers */, - 50ABBE7B1925AB6F00A911A9 /* CCEventMouse.h in Headers */, - BAFF7D681D5C1CF80051B92F /* Bone.h in Headers */, - 503DD8F91926B0DB00CD74DD /* CCIMEDispatcher.h in Headers */, - 15AE1BB419AADFEF00C27E9E /* HttpResponse.h in Headers */, - 50ABBE291925AB6F00A911A9 /* CCAutoreleasePool.h in Headers */, 1A28FF651F20AFAB007A1D9D /* SRPinningSecurityPolicy.h in Headers */, - 299CF1FD19A434BC00C378C1 /* ccRandom.h in Headers */, - 50ABBE471925AB6F00A911A9 /* CCEvent.h in Headers */, - B257B4501989D5E800D9A687 /* CCPrimitive.h in Headers */, + 46FDDBC9202ADDCE00931238 /* ccFPSImages.h in Headers */, + 46FDDA85202ACC6A00931238 /* View.h in Headers */, 4DED484E1DFFA4AF0070C5C4 /* b2EdgeAndPolygonContact.h in Headers */, - 50ABBE6B1925AB6F00A911A9 /* CCEventListenerFocus.h in Headers */, - FA6F1BA71D80F858007DD223 /* DataParser.h in Headers */, - 50ABBDA51925AB4100A911A9 /* CCQuadCommand.h in Headers */, - BAFF7D5C1D5C1CF80051B92F /* Attachment.h in Headers */, BA68D7811D62F4A500B7A3F9 /* utils.h in Headers */, 1A28FF951F20AFAB007A1D9D /* SocketRocket.h in Headers */, - 50643BD919BFAF4400EF68ED /* CCApplication.h in Headers */, BA68D78B1D62F4A500B7A3F9 /* cdt.h in Headers */, - BAFF7D641D5C1CF80051B92F /* AttachmentVertices.h in Headers */, 50ABBD3A1925AB0000A911A9 /* CCAffineTransform.h in Headers */, - 15AE1BB319AADFEF00C27E9E /* HttpRequest.h in Headers */, - 50ABBE571925AB6F00A911A9 /* CCEventFocus.h in Headers */, - 50ABBE251925AB6F00A911A9 /* base64.h in Headers */, - FA6F1B7B1D80F858007DD223 /* DragonBones.h in Headers */, - A05DCF9E1B90584E00EE040B /* CCDownloader-curl.h in Headers */, - BAFF7DCE1D5C1CF80051B92F /* spine.h in Headers */, - 50693C601B6BF2AE005C5820 /* CCDownloader.h in Headers */, - 50ABBEC91925AB6F00A911A9 /* firePngData.h in Headers */, - FAC8F25D1D339EB70061CEDD /* CCTMXLayer.h in Headers */, - 4DC06BD11E8A68D400CA08B1 /* CCPhysicsAABBQueryCallback.h in Headers */, - 503DD8F51926B0DB00CD74DD /* CCIMEDelegate.h in Headers */, 50ABBD5A1925AB0000A911A9 /* Vec2.h in Headers */, 1A37E9C7200DDFC70078AF72 /* CCReachability.h in Headers */, - FA6F1BAF1D80F858007DD223 /* TextureData.h in Headers */, - FAC8F66C1E1DF15D002B17E8 /* SkeletonBinary.h in Headers */, - B24AA987195A675C007B4522 /* CCFastTMXLayer.h in Headers */, - 50ABBEBD1925AB6F00A911A9 /* ccUtils.h in Headers */, + 46FDDB81202ADDCE00931238 /* ccTypes.h in Headers */, + 46FDDADD202ACC6A00931238 /* VertexBuffer.h in Headers */, 4DED486E1DFFA4AF0070C5C4 /* b2MouseJoint.h in Headers */, - A0534A651B872FFD006B03E5 /* CCDownloader-apple.h in Headers */, - 844EB1201F78D4CB00EFE4CD /* CCThreadPool.h in Headers */, - BA679B361CEC373000F875FA /* CCEventAssetsManagerEx.h in Headers */, - 50ABC0231926664800A911A9 /* CCGLViewImpl-desktop.h in Headers */, - A63CF0081CD9CF3500A6971D /* CCUIPasswordTextField.h in Headers */, - 1AD473AD1EAD9A5300202582 /* Uri.h in Headers */, 1A28FF8D1F20AFAB007A1D9D /* NSRunLoop+SRWebSocket.h in Headers */, + 46FDDBE5202ADDCE00931238 /* CCIMEDelegate.h in Headers */, 4DED48521DFFA4AF0070C5C4 /* b2PolygonAndCircleContact.h in Headers */, 4DED48861DFFA4AF0070C5C4 /* b2WheelJoint.h in Headers */, 4DED485A1DFFA4AF0070C5C4 /* b2DistanceJoint.h in Headers */, - BAFF7D481D5C1CF80051B92F /* Animation.h in Headers */, + 46FDDACD202ACC6A00931238 /* GraphicsHandle.h in Headers */, 4DED47D21DFFA4AF0070C5C4 /* Box2D.h in Headers */, ED3057921BEC77770083C3ED /* edtaa3func.h in Headers */, + 46FDDC4D202AEAC500931238 /* WebGLTexelConversions.h in Headers */, + 46FDDBCB202ADDCE00931238 /* ZipUtils.h in Headers */, 50ABBFFD1926664800A911A9 /* CCFileUtils-apple.h in Headers */, - 5034CA41191D591100CE6051 /* ccShader_Position_uColor.frag in Headers */, - 50ABBE7F1925AB6F00A911A9 /* CCEventTouch.h in Headers */, - 50ABBE5B1925AB6F00A911A9 /* CCEventKeyboard.h in Headers */, + 46FDDA8F202ACC6A00931238 /* BaseRenderer.h in Headers */, + 46FDDAD7202ACC6A00931238 /* GFXUtils.h in Headers */, 50ABC00F1926664800A911A9 /* CCFileUtils.h in Headers */, - 50ABBE3B1925AB6F00A911A9 /* CCData.h in Headers */, - 50ABBD9D1925AB4100A911A9 /* ccGLStateCache.h in Headers */, - 50ABBEB91925AB6F00A911A9 /* ccUTF8.h in Headers */, - 292DB13F19B4574100A80320 /* UIEditBox.h in Headers */, - 50ABBE671925AB6F00A911A9 /* CCEventListenerCustom.h in Headers */, - 50ABBE2F1925AB6F00A911A9 /* ccConfig.h in Headers */, 1A28FF4D1F20AFAB007A1D9D /* SRDelegateController.h in Headers */, - 1AAF5851180E40B9000584C8 /* LocalStorage.h in Headers */, - A0E749F91BA8FD7F001A8332 /* UIEditBoxImpl-common.h in Headers */, - FA6F1B9F1D80F858007DD223 /* FrameData.h in Headers */, - 1A9DCA29180E6955007A3AD4 /* CCGLBufferedNode.h in Headers */, 50ABC0031926664800A911A9 /* CCLock-apple.h in Headers */, - 50ABBE2D1925AB6F00A911A9 /* ccCArray.h in Headers */, + 46FDDB9F202ADDCE00931238 /* CCVector.h in Headers */, 50ABBD5E1925AB0000A911A9 /* Vec3.h in Headers */, + 46FDDC49202AEAC500931238 /* WebGLFormats.h in Headers */, + 46FDDBD1202ADDCE00931238 /* ccUTF8.h in Headers */, ED3057A21BEC77D50083C3ED /* xxhash.h in Headers */, - BAFF7D581D5C1CF80051B92F /* AtlasAttachmentLoader.h in Headers */, - 291901431B05895600F8B4BA /* CCNinePatchImageParser.h in Headers */, - B24AA98B195A675C007B4522 /* CCFastTMXTiledMap.h in Headers */, - 50ABBE371925AB6F00A911A9 /* CCConsole.h in Headers */, 50ABC00B1926664800A911A9 /* CCDevice.h in Headers */, + 46FDDB89202ADDCE00931238 /* CCRef.h in Headers */, + 46FDDC3D202AEAC500931238 /* CheckedInt.h in Headers */, 4DED47E41DFFA4AF0070C5C4 /* b2Distance.h in Headers */, - FA6F1B491D80F858007DD223 /* BaseTimelineState.h in Headers */, - 50ABC0131926664800A911A9 /* CCGLView.h in Headers */, - 50ABBDB31925AB4100A911A9 /* ccShaders.h in Headers */, - 50ABBDAB1925AB4100A911A9 /* CCRenderCommandPool.h in Headers */, - 5034CA45191D591100CE6051 /* ccShader_Label_outline.frag in Headers */, - 50ABBEB11925AB6F00A911A9 /* CCUserDefault.h in Headers */, + 46FDDBE9202ADDCE00931238 /* CCAutoreleasePool.h in Headers */, + 46FDDB4F202ADDCE00931238 /* CCValue.h in Headers */, + 46FDDBB5202ADDCE00931238 /* uthash.h in Headers */, 1A28FF7D1F20AFAB007A1D9D /* SRMutex.h in Headers */, - 50ABBEC71925AB6F00A911A9 /* etc1.h in Headers */, - 50ABBEA91925AB6F00A911A9 /* CCTouch.h in Headers */, - 50ABBE971925AB6F00A911A9 /* CCProtocols.h in Headers */, 50ABC0691926664800A911A9 /* CCStdC-mac.h in Headers */, - BAFF7DC01D5C1CF80051B92F /* Skin.h in Headers */, 1A28FF711F20AFAB007A1D9D /* SRHash.h in Headers */, - FA6F1B891D80F858007DD223 /* Matrix.h in Headers */, - 50ABBE771925AB6F00A911A9 /* CCEventListenerTouch.h in Headers */, - 5034CA33191D591100CE6051 /* ccShader_PositionTexture_uColor.frag in Headers */, 50ABC0171926664800A911A9 /* CCImage.h in Headers */, - 50ABBDA91925AB4100A911A9 /* CCRenderCommand.h in Headers */, - 50ABBD951925AB4100A911A9 /* CCGLProgramState.h in Headers */, - 50ABC0091926664800A911A9 /* CCCommon.h in Headers */, - 50ABBE531925AB6F00A911A9 /* CCEventDispatcher.h in Headers */, ED30577F1BEC76C90083C3ED /* ioapi_mem.h in Headers */, - 464AD6E7197EBB1400E502D8 /* pvr.h in Headers */, - BAFF7D801D5C1CF80051B92F /* extension.h in Headers */, + 46FDDB79202ADDCE00931238 /* CCGameController.h in Headers */, 4DED48281DFFA4AF0070C5C4 /* b2Island.h in Headers */, ); runOnlyForDeploymentPostprocessing = 0; @@ -4459,412 +2162,197 @@ buildActionMask = 2147483647; files = ( BA68D78C1D62F4A500B7A3F9 /* cdt.h in Headers */, - FAC8F66D1E1DF15D002B17E8 /* SkeletonBinary.h in Headers */, 503DD8F01926736A00CD74DD /* CCStdC-ios.h in Headers */, - 2980F0281BA9A5550059E678 /* CCUITextInput.h in Headers */, - 2980F0291BA9A5550059E678 /* UITextField+CCUITextInput.h in Headers */, - 50ABBDA21925AB4100A911A9 /* CCGroupCommand.h in Headers */, - FA6F1B6E1D80F858007DD223 /* CCFactory.h in Headers */, - 50643BDA19BFAF4400EF68ED /* CCApplication.h in Headers */, 503DD8EF1926736A00CD74DD /* CCPlatformDefine-ios.h in Headers */, 1A28FF921F20AFAB007A1D9D /* NSURLRequest+SRWebSocket.h in Headers */, - 292DB14019B4574100A80320 /* UIEditBox.h in Headers */, 50ABBD3B1925AB0000A911A9 /* CCAffineTransform.h in Headers */, - 5034CA38191D591100CE6051 /* ccShader_PositionColorLengthTexture.vert in Headers */, - 50ABBE7C1925AB6F00A911A9 /* CCEventMouse.h in Headers */, - 4DC06BD21E8A68D400CA08B1 /* CCPhysicsAABBQueryCallback.h in Headers */, - 50ABBE9C1925AB6F00A911A9 /* CCRef.h in Headers */, + 46FDDB5C202ADDCE00931238 /* CCData.h in Headers */, 1A28FF961F20AFAB007A1D9D /* SocketRocket.h in Headers */, - 50ABBD961925AB4100A911A9 /* CCGLProgramState.h in Headers */, - 50ABBDB41925AB4100A911A9 /* ccShaders.h in Headers */, - A0E749FA1BA8FD7F001A8332 /* UIEditBoxImpl-common.h in Headers */, - 50ABBE861925AB6F00A911A9 /* ccFPSImages.h in Headers */, BA68D7841D62F4A500B7A3F9 /* poly2tri.h in Headers */, - 50ABBE2E1925AB6F00A911A9 /* ccCArray.h in Headers */, - 15AE1B9119AADA9A00C27E9E /* UIWidget.h in Headers */, - FA6F1B721D80F858007DD223 /* CCSlot.h in Headers */, + 46FDDC36202AEAC500931238 /* IntegerTypeTraits.h in Headers */, + 46FDDAA8202ACC6A00931238 /* ForwardRenderer.h in Headers */, 50ABC0041926664800A911A9 /* CCLock-apple.h in Headers */, 1A28FF8E1F20AFAB007A1D9D /* NSRunLoop+SRWebSocket.h in Headers */, - 5034CA40191D591100CE6051 /* ccShader_Position_uColor.vert in Headers */, - BAFF7DCF1D5C1CF80051B92F /* spine.h in Headers */, - 4D2E690E1CC543B40032DD5C /* Triangulate.h in Headers */, - 50ABBEC21925AB6F00A911A9 /* CCValue.h in Headers */, - 2980F0241BA9A5550059E678 /* CCUIMultilineTextField.h in Headers */, - 50ABBECA1925AB6F00A911A9 /* firePngData.h in Headers */, + 46FDDBA0202ADDCE00931238 /* CCVector.h in Headers */, + 46FDDB54202ADDCE00931238 /* utlist.h in Headers */, + 46FDDA84202ACC6A00931238 /* Technique.h in Headers */, BA68D7801D62F4A500B7A3F9 /* shapes.h in Headers */, - B257B4511989D5E800D9A687 /* CCPrimitive.h in Headers */, + 46FDDC3E202AEAC500931238 /* CheckedInt.h in Headers */, + 46FDDBB8202ADDCE00931238 /* ccUtils.h in Headers */, 50643BE319BFCF1800EF68ED /* CCPlatformConfig.h in Headers */, - FA6F1B7A1D80F858007DD223 /* BaseObject.h in Headers */, + 46FDDA92202ACC6A00931238 /* Pass.h in Headers */, + 46FDDC48202AEAC500931238 /* StaticAnalysisFunctions.h in Headers */, + 46FDDB4E202ADDCE00931238 /* pvr.h in Headers */, 4DED48331DFFA4AF0070C5C4 /* b2WorldCallbacks.h in Headers */, BA68D7881D62F4A500B7A3F9 /* advancing_front.h in Headers */, - BAFF7D691D5C1CF80051B92F /* Bone.h in Headers */, 4DED47E11DFFA4AF0070C5C4 /* b2Collision.h in Headers */, - 1A570064180BC5A10088DEC7 /* CCAction.h in Headers */, - BAFF7D991D5C1CF80051B92F /* PathConstraint.h in Headers */, + 46FDDBB6202ADDCE00931238 /* uthash.h in Headers */, 4DED480D1DFFA4AF0070C5C4 /* b2Math.h in Headers */, + 46FDDB5E202ADDCE00931238 /* ccMacros.h in Headers */, 294D7D9B1D0E93A2002CE7B7 /* CCDevice-apple.h in Headers */, - BAFF7D591D5C1CF80051B92F /* AtlasAttachmentLoader.h in Headers */, + 46FDDAA6202ACC6A00931238 /* Scene.h in Headers */, + 46FDDC4A202AEAC500931238 /* WebGLFormats.h in Headers */, 4DED486F1DFFA4AF0070C5C4 /* b2MouseJoint.h in Headers */, - 503DD8EC1926736A00CD74DD /* CCGLViewImpl-ios.h in Headers */, - 4DC06BEA1E8A68D400CA08B1 /* CCPhysicsWorldManifoldWrapper.h in Headers */, 1A28FF821F20AFAB007A1D9D /* SRRandom.h in Headers */, - BAFF7D7D1D5C1CF80051B92F /* EventData.h in Headers */, - FA6F1B9C1D80F858007DD223 /* DragonBonesData.h in Headers */, - FA6F1B861D80F858007DD223 /* BaseFactory.h in Headers */, - 50ABBEBA1925AB6F00A911A9 /* ccUTF8.h in Headers */, 50643BD619BFAEDA00EF68ED /* CCPlatformDefine.h in Headers */, - 1A570068180BC5A10088DEC7 /* CCActionCamera.h in Headers */, 4DED48871DFFA4AF0070C5C4 /* b2WheelJoint.h in Headers */, - BAFF7D491D5C1CF80051B92F /* Animation.h in Headers */, - FA6F1B7E1D80F858007DD223 /* DragonBonesHeaders.h in Headers */, - 1A57006C180BC5A10088DEC7 /* CCActionCatmullRom.h in Headers */, - BAFF7DC11D5C1CF80051B92F /* Skin.h in Headers */, - FA6F1B8A1D80F858007DD223 /* Matrix.h in Headers */, - BAFF7D851D5C1CF80051B92F /* IkConstraint.h in Headers */, - 5034CA3A191D591100CE6051 /* ccShader_PositionColorLengthTexture.frag in Headers */, - DABC9FAC19E7DFA900FA252C /* CCClippingRectangleNode.h in Headers */, 4DED47F91DFFA4AF0070C5C4 /* b2EdgeShape.h in Headers */, - 50ABBEC41925AB6F00A911A9 /* CCVector.h in Headers */, - 50ABBE501925AB6F00A911A9 /* CCEventCustom.h in Headers */, - A0534A661B872FFD006B03E5 /* CCDownloader-apple.h in Headers */, - 1A570070180BC5A10088DEC7 /* CCActionEase.h in Headers */, - 1A570074180BC5A10088DEC7 /* CCActionGrid.h in Headers */, - BAFF7D811D5C1CF80051B92F /* extension.h in Headers */, - 5034CA46191D591100CE6051 /* ccShader_Label_outline.frag in Headers */, - 1A570078180BC5A10088DEC7 /* CCActionGrid3D.h in Headers */, - FA6F1B4A1D80F858007DD223 /* BaseTimelineState.h in Headers */, + 46FDDA6E202ACC6A00931238 /* INode.h in Headers */, 50ABBD631925AB0000A911A9 /* Vec4.h in Headers */, - 50CB247E19D9C5A100687767 /* AudioPlayer.h in Headers */, - BAFF7D9D1D5C1CF80051B92F /* PathConstraintData.h in Headers */, - 1A57007C180BC5A10088DEC7 /* CCActionInstant.h in Headers */, - 4DFA4C1A1CBCE34100E3B736 /* CCScale9Sprite.h in Headers */, - 50ABBE781925AB6F00A911A9 /* CCEventListenerTouch.h in Headers */, - 15AE1BC019AADFF000C27E9E /* WebSocket.h in Headers */, 4DED48831DFFA4AF0070C5C4 /* b2WeldJoint.h in Headers */, - 1A570080180BC5A10088DEC7 /* CCActionInterval.h in Headers */, - BAFF7DD31D5C1CF80051B92F /* TransformConstraint.h in Headers */, - 1A570084180BC5A10088DEC7 /* CCActionManager.h in Headers */, - 50ABC0141926664800A911A9 /* CCGLView.h in Headers */, 4DED48191DFFA4AF0070C5C4 /* b2Timer.h in Headers */, - BAFF7D911D5C1CF80051B92F /* MeshAttachment.h in Headers */, 4DED487B1DFFA4AF0070C5C4 /* b2RevoluteJoint.h in Headers */, + 46FDDC44202AEAC500931238 /* Pair.h in Headers */, + 46FDDB7A202ADDCE00931238 /* CCGameController.h in Headers */, BA68D7941D62F4A500B7A3F9 /* sweep_context.h in Headers */, - 1A570088180BC5A10088DEC7 /* CCActionPageTurn3D.h in Headers */, - 15AE1B9319AADA9A00C27E9E /* UIHelper.h in Headers */, - 50ABBD9E1925AB4100A911A9 /* ccGLStateCache.h in Headers */, - FA6F1B481D80F858007DD223 /* AnimationState.h in Headers */, - FA6F1BB01D80F858007DD223 /* TextureData.h in Headers */, - 15AE1B9619AADA9A00C27E9E /* CocosGUI.h in Headers */, - BAFF7D791D5C1CF80051B92F /* Event.h in Headers */, - 1A57008C180BC5A10088DEC7 /* CCActionProgressTimer.h in Headers */, - 1A570090180BC5A10088DEC7 /* CCActionTiledGrid.h in Headers */, - 1A570094180BC5A10088DEC7 /* CCActionTween.h in Headers */, - 1A57009B180BC5C10088DEC7 /* CCAtlasNode.h in Headers */, - 1A5700A1180BC5D20088DEC7 /* CCNode.h in Headers */, + 46FDDA82202ACC6A00931238 /* RendererUtils.h in Headers */, 503DD8E41926736A00CD74DD /* CCDirectorCaller-ios.h in Headers */, - BAFF7D551D5C1CF80051B92F /* Atlas.h in Headers */, - FA6F1B681D80F858007DD223 /* CCArmatureDisplay.h in Headers */, - FA6F1B621D80F858007DD223 /* Slot.h in Headers */, 1A9F0F9A1F301DE200A499E1 /* b2ObjectDestroyNotifier.h in Headers */, - 4D6CF43A1E83AAD5003327D4 /* CCCameraNode.h in Headers */, - 50ABBD8A1925AB4100A911A9 /* CCCustomCommand.h in Headers */, - 299754F7193EC95400A54AC3 /* ObjectFactory.h in Headers */, - 50ABBE881925AB6F00A911A9 /* ccMacros.h in Headers */, 50ABC0101926664800A911A9 /* CCFileUtils.h in Headers */, - 5034CA30191D591100CE6051 /* ccShader_PositionTexture.vert in Headers */, - 1A570111180BC8EE0088DEC7 /* CCDrawingPrimitives.h in Headers */, - 50ABBE381925AB6F00A911A9 /* CCConsole.h in Headers */, - 50ABBE8A1925AB6F00A911A9 /* CCMap.h in Headers */, + 46FDDA9C202ACC6A00931238 /* Effect.h in Headers */, 503DD8E61926736A00CD74DD /* CCEAGLView-ios.h in Headers */, - 50ABBE4C1925AB6F00A911A9 /* CCEventAcceleration.h in Headers */, + 46FDDAC8202ACC6A00931238 /* GFX.h in Headers */, + 46FDDC3A202AEAC500931238 /* Attributes.h in Headers */, + 46FDDA98202ACC6A00931238 /* Model.h in Headers */, 4DED482F1DFFA4AF0070C5C4 /* b2World.h in Headers */, 50ABBD571925AB0000A911A9 /* TransformUtils.h in Headers */, - 1A570115180BC8EE0088DEC7 /* CCDrawNode.h in Headers */, - BAFF7DBD1D5C1CF80051B92F /* SkeletonRenderer.h in Headers */, - 1A57011E180BC90D0088DEC7 /* CCGrabber.h in Headers */, - FA6F1B761D80F858007DD223 /* CCTextureData.h in Headers */, - 1A570122180BC90D0088DEC7 /* CCGrid.h in Headers */, - 5034CA2E191D591100CE6051 /* ccShader_PositionTextureA8Color.frag in Headers */, - FA6F1B5C1D80F858007DD223 /* Bone.h in Headers */, - 29394CF519B01DBA00D2DE1A /* UIWebViewImpl-ios.h in Headers */, + 46FDDBE6202ADDCE00931238 /* CCIMEDelegate.h in Headers */, 50ABBD5B1925AB0000A911A9 /* Vec2.h in Headers */, 50ABBD411925AB0000A911A9 /* CCMath.h in Headers */, 4DED47ED1DFFA4AF0070C5C4 /* b2TimeOfImpact.h in Headers */, - 1A5701A0180BCB590088DEC7 /* CCFont.h in Headers */, - 292DB14819B4574100A80320 /* UIEditBoxImpl-ios.h in Headers */, - BAFF7DA11D5C1CF80051B92F /* RegionAttachment.h in Headers */, - 3E2BDADE19C030ED0055CDCD /* AudioEngine.h in Headers */, - 50ABBD9A1925AB4100A911A9 /* CCGLProgramStateCache.h in Headers */, - 15AE1BBB19AADFF000C27E9E /* HttpRequest.h in Headers */, - B230ED7419B417AE00364AA8 /* CCTrianglesCommand.h in Headers */, + 46FDDAB0202ACC6A00931238 /* Texture2D.h in Headers */, 4DED48471DFFA4AF0070C5C4 /* b2ContactSolver.h in Headers */, 50ABBD3F1925AB0000A911A9 /* CCGeometry.h in Headers */, - 1AD473AF1EAD9A5900202582 /* Uri.h in Headers */, + 46FDDC2C202AEAC500931238 /* UniquePtr.h in Headers */, 1A28FF6A1F20AFAB007A1D9D /* SRConstants.h in Headers */, 50ABBFFE1926664800A911A9 /* CCFileUtils-apple.h in Headers */, - 1A5701A4180BCB590088DEC7 /* CCFontAtlas.h in Headers */, - 1A5701A8180BCB590088DEC7 /* CCFontAtlasCache.h in Headers */, - FA6F1B581D80F858007DD223 /* Armature.h in Headers */, - 1A5701B4180BCB590088DEC7 /* CCFontFNT.h in Headers */, - 1A5701B8180BCB5A0088DEC7 /* CCFontFreeType.h in Headers */, - 1A5701BC180BCB5A0088DEC7 /* CCLabel.h in Headers */, - 1A5701C0180BCB5A0088DEC7 /* CCLabelAtlas.h in Headers */, - 50ABBE681925AB6F00A911A9 /* CCEventListenerCustom.h in Headers */, + 46FDDBEA202ADDCE00931238 /* CCAutoreleasePool.h in Headers */, 4DED48251DFFA4AF0070C5C4 /* b2Fixture.h in Headers */, - 15AE1BBA19AADFF000C27E9E /* HttpClient.h in Headers */, - 15AE1B9419AADA9A00C27E9E /* GUIDefine.h in Headers */, - 50693C611B6BF2AE005C5820 /* CCDownloader.h in Headers */, - 5034CA42191D591100CE6051 /* ccShader_Position_uColor.frag in Headers */, - 52B47A2E1A5349A3004E4C60 /* HttpAsynConnection-apple.h in Headers */, - 15AE1BBC19AADFF000C27E9E /* HttpResponse.h in Headers */, 1A28FF521F20AFAB007A1D9D /* SRIOConsumer.h in Headers */, - 50ABBDA61925AB4100A911A9 /* CCQuadCommand.h in Headers */, 1A28FF981F20AFAB007A1D9D /* SRSecurityPolicy.h in Headers */, - 50ABBE9E1925AB6F00A911A9 /* CCRefPtr.h in Headers */, - 1A5701CA180BCB5A0088DEC7 /* CCLabelTextFormatter.h in Headers */, 50643BDC19BFAF4400EF68ED /* CCStdC.h in Headers */, 1A37E9C5200DD0680078AF72 /* CCReachability.h in Headers */, 1A28FF761F20AFAB007A1D9D /* SRHTTPConnectMessage.h in Headers */, - BAFF7D6D1D5C1CF80051B92F /* BoneData.h in Headers */, + 46FDDBBC202ADDCE00931238 /* CCRefPtr.h in Headers */, 4DED48211DFFA4AF0070C5C4 /* b2ContactManager.h in Headers */, - 5034CA22191D591100CE6051 /* ccShader_PositionTextureColorAlphaTest.frag in Headers */, 50643BE519BFCF1800EF68ED /* CCPlatformMacros.h in Headers */, - FA6F1B641D80F858007DD223 /* TransformObject.h in Headers */, 4DED47E91DFFA4AF0070C5C4 /* b2DynamicTree.h in Headers */, - BAFF7D651D5C1CF80051B92F /* AttachmentVertices.h in Headers */, - 1A5701E1180BCB8C0088DEC7 /* CCLayer.h in Headers */, + 46FDDBCA202ADDCE00931238 /* ccFPSImages.h in Headers */, + 46FDDADE202ACC6A00931238 /* VertexBuffer.h in Headers */, 1A28FF621F20AFAB007A1D9D /* SRRunLoopThread.h in Headers */, - 1A5701E5180BCB8C0088DEC7 /* CCScene.h in Headers */, - 1A5701E9180BCB8C0088DEC7 /* CCTransition.h in Headers */, - FA6F1B981D80F858007DD223 /* ArmatureData.h in Headers */, - FAC8F6691E1DF15D002B17E8 /* kvec.h in Headers */, - 50ABBED41925AB6F00A911A9 /* uthash.h in Headers */, - 1A5701ED180BCB8C0088DEC7 /* CCTransitionPageTurn.h in Headers */, - FA6F1B821D80F858007DD223 /* EventObject.h in Headers */, - 1A5701F1180BCB8C0088DEC7 /* CCTransitionProgress.h in Headers */, - 1A5701FA180BCBAD0088DEC7 /* CCMenu.h in Headers */, - FA6F1BA01D80F858007DD223 /* FrameData.h in Headers */, - 4DC06BD61E8A68D400CA08B1 /* CCPhysicsContactListener.h in Headers */, - 1A5701FE180BCBAD0088DEC7 /* CCMenuItem.h in Headers */, 4DED48031DFFA4AF0070C5C4 /* b2BlockAllocator.h in Headers */, + 46FDDA86202ACC6A00931238 /* View.h in Headers */, + 46FDDAD8202ACC6A00931238 /* GFXUtils.h in Headers */, + 46FDDB82202ADDCE00931238 /* ccTypes.h in Headers */, + 46FDDC00202ADDCE00931238 /* firePngData.h in Headers */, 50ABC00C1926664800A911A9 /* CCDevice.h in Headers */, - 1A570205180BCBD40088DEC7 /* CCClippingNode.h in Headers */, + 46FDDC0C202ADDCE00931238 /* CCIMEDispatcher.h in Headers */, 4DED483B1DFFA4AF0070C5C4 /* b2ChainAndPolygonContact.h in Headers */, 4DED48071DFFA4AF0070C5C4 /* b2Draw.h in Headers */, 4DED484F1DFFA4AF0070C5C4 /* b2EdgeAndPolygonContact.h in Headers */, - BAFF7D891D5C1CF80051B92F /* IkConstraintData.h in Headers */, + 46FDDC34202AEAC500931238 /* Types.h in Headers */, 4DED486B1DFFA4AF0070C5C4 /* b2MotorJoint.h in Headers */, - 5034CA34191D591100CE6051 /* ccShader_PositionTexture_uColor.frag in Headers */, - BAFF7D751D5C1CF80051B92F /* Cocos2dAttachmentLoader.h in Headers */, + 46FDDA74202ACC6A00931238 /* ProgramLib.h in Headers */, + 46FDDAD0202ACC6A00931238 /* RenderBuffer.h in Headers */, 1A28FF7A1F20AFAB007A1D9D /* SRLog.h in Headers */, - BAFF7DB11D5C1CF80051B92F /* SkeletonBounds.h in Headers */, - 50ABBEA21925AB6F00A911A9 /* CCScheduler.h in Headers */, - 4D2816691E8CBB7200F26B06 /* CCPhysicsContactImpulse.h in Headers */, - 4DC06BE21E8A68D400CA08B1 /* CCPhysicsRayCastCallback.h in Headers */, + 46FDDACC202ACC6A00931238 /* VertexFormat.h in Headers */, + 46FDDACE202ACC6A00931238 /* GraphicsHandle.h in Headers */, + 46FDDA80202ACC6A00931238 /* Renderer.h in Headers */, 4DED48431DFFA4AF0070C5C4 /* b2Contact.h in Headers */, - 1A57020B180BCBDF0088DEC7 /* CCMotionStreak.h in Headers */, - 1A75DC171DFE3C7700A271DF /* AudioDecoder.h in Headers */, - 1A570213180BCBF40088DEC7 /* CCProgressTimer.h in Headers */, 4DED47E51DFFA4AF0070C5C4 /* b2Distance.h in Headers */, - FA6F1B7C1D80F858007DD223 /* DragonBones.h in Headers */, - BA679B331CEC373000F875FA /* AssetsManagerEx.h in Headers */, - 1A570217180BCBF40088DEC7 /* CCRenderTexture.h in Headers */, + 46FDDAA2202ACC6A00931238 /* InputAssembler.h in Headers */, 4DED47D31DFFA4AF0070C5C4 /* Box2D.h in Headers */, - 1A570224180BCC1A0088DEC7 /* CCParticleBatchNode.h in Headers */, - 503DD8F61926B0DB00CD74DD /* CCIMEDelegate.h in Headers */, - 1A570228180BCC1A0088DEC7 /* CCParticleExamples.h in Headers */, - FAC8F2631D339EC80061CEDD /* CCTMXTiledMap.h in Headers */, - 1A57022C180BCC1A0088DEC7 /* CCParticleSystem.h in Headers */, - 1A570230180BCC1A0088DEC7 /* CCParticleSystemQuad.h in Headers */, - 29394CF119B01DBA00D2DE1A /* UIWebView.h in Headers */, - 2980F0261BA9A5550059E678 /* CCUISingleLineTextField.h in Headers */, - 4DC06BDE1E8A68D400CA08B1 /* CCPhysicsDebugDraw.h in Headers */, + 46FDDBCC202ADDCE00931238 /* ZipUtils.h in Headers */, + 46FDDB50202ADDCE00931238 /* CCValue.h in Headers */, + 46FDDC46202AEAC500931238 /* Move.h in Headers */, + 46FDDADA202ACC6A00931238 /* Program.h in Headers */, + 46FDDAC4202ACC6A00931238 /* FrameBuffer.h in Headers */, + 46FDDB9C202ADDCE00931238 /* CCProfiling.h in Headers */, + 46FDDAD2202ACC6A00931238 /* Texture.h in Headers */, 1A28FF721F20AFAB007A1D9D /* SRHash.h in Headers */, - B24AA988195A675C007B4522 /* CCFastTMXLayer.h in Headers */, - 5034CA2C191D591100CE6051 /* ccShader_PositionTextureA8Color.vert in Headers */, - 50ABBE981925AB6F00A911A9 /* CCProtocols.h in Headers */, - 50CB247A19D9C5A100687767 /* AudioEngine-inl.h in Headers */, 4DED48631DFFA4AF0070C5C4 /* b2GearJoint.h in Headers */, - 52B47A321A5349A3004E4C60 /* HttpCookie.h in Headers */, + 46FDDC2E202AEAC500931238 /* Compiler.h in Headers */, 50ABBD431925AB0000A911A9 /* CCMathBase.h in Headers */, + 46FDDBDE202ADDCE00931238 /* TGAlib.h in Headers */, 4DED47FF1DFFA4AF0070C5C4 /* b2Shape.h in Headers */, - BAFF7D611D5C1CF80051B92F /* AttachmentLoader.h in Headers */, BA68D7821D62F4A500B7A3F9 /* utils.h in Headers */, - FA6F1B8E1D80F858007DD223 /* Rectangle.h in Headers */, - 15EFA214198A2BB5000C57D3 /* CCProtectedNode.h in Headers */, 4DED485B1DFFA4AF0070C5C4 /* b2DistanceJoint.h in Headers */, - 50ABBE441925AB6F00A911A9 /* CCDirector.h in Headers */, - BAFF7DC91D5C1CF80051B92F /* SlotData.h in Headers */, - BAFF7DB91D5C1CF80051B92F /* SkeletonJson.h in Headers */, - BAFF7D711D5C1CF80051B92F /* BoundingBoxAttachment.h in Headers */, - FA6F1B5E1D80F858007DD223 /* IArmatureDisplay.h in Headers */, - 5034CA4A191D591100CE6051 /* ccShader_Label_df.frag in Headers */, 1A28FF9C1F20AFAB007A1D9D /* SRWebSocket.h in Headers */, - 4D2E690A1CC543B40032DD5C /* CCGraphicsNode.h in Headers */, BA68D7901D62F4A500B7A3F9 /* sweep.h in Headers */, BAEA45561E279D5C00FA219F /* tinydir.h in Headers */, - 2980F0221BA9A5550059E678 /* CCUIEditBoxIOS.h in Headers */, - FA6F1B941D80F858007DD223 /* AnimationData.h in Headers */, 4DED47FD1DFFA4AF0070C5C4 /* b2PolygonShape.h in Headers */, - 1A570281180BCC900088DEC7 /* CCSprite.h in Headers */, - 1A570285180BCC900088DEC7 /* CCSpriteBatchNode.h in Headers */, - 1A570289180BCC900088DEC7 /* CCSpriteFrame.h in Headers */, - BAFF7DD71D5C1CF80051B92F /* TransformConstraintData.h in Headers */, - 1A75DC191DFE3C7700A271DF /* AudioMacros.h in Headers */, - BAFF7DB51D5C1CF80051B92F /* SkeletonData.h in Headers */, - 50ABBE701925AB6F00A911A9 /* CCEventListenerKeyboard.h in Headers */, + 46FDDADC202ACC6A00931238 /* State.h in Headers */, + 46FDDB9E202ADDCE00931238 /* ObjectFactory.h in Headers */, + 46FDDC42202AEAC500931238 /* Atomics.h in Headers */, + 46FDDB8A202ADDCE00931238 /* CCRef.h in Headers */, 4DED47D71DFFA4AF0070C5C4 /* b2BroadPhase.h in Headers */, - 1A57028D180BCC900088DEC7 /* CCSpriteFrameCache.h in Headers */, - 1A570295180BCCAB0088DEC7 /* CCAnimation.h in Headers */, - 50ABBDB81925AB4100A911A9 /* CCTexture2D.h in Headers */, 4DED485F1DFFA4AF0070C5C4 /* b2FrictionJoint.h in Headers */, - 50ABBE341925AB6F00A911A9 /* CCConfiguration.h in Headers */, - 1A570299180BCCAB0088DEC7 /* CCAnimationCache.h in Headers */, - 50ABBEAA1925AB6F00A911A9 /* CCTouch.h in Headers */, + 46FDDB6C202ADDCE00931238 /* base64.h in Headers */, 4DED48571DFFA4AF0070C5C4 /* b2PolygonContact.h in Headers */, 4DED47F51DFFA4AF0070C5C4 /* b2CircleShape.h in Headers */, - 2980F02B1BA9A5550059E678 /* UITextView+CCUITextInput.h in Headers */, - 50ABBE741925AB6F00A911A9 /* CCEventListenerMouse.h in Headers */, - FA6F1B541D80F858007DD223 /* WorldClock.h in Headers */, - 1A5702CB180BCE370088DEC7 /* CCTextFieldTTF.h in Headers */, - FA6F1B6A1D80F858007DD223 /* CCDragonBonesHeaders.h in Headers */, + 46FDDA78202ACC6A00931238 /* Light.h in Headers */, 4DED48671DFFA4AF0070C5C4 /* b2Joint.h in Headers */, - BAFF7DA91D5C1CF80051B92F /* SkeletonAnimation.h in Headers */, - 1A5702ED180BCE750088DEC7 /* CCTileMapAtlas.h in Headers */, - 15FB20771AE7BF8600C31518 /* CCAutoPolygon.h in Headers */, - 5034CA44191D591100CE6051 /* ccShader_Label.vert in Headers */, - 1A5702F5180BCE750088DEC7 /* CCTMXObjectGroup.h in Headers */, - 1A5702FD180BCE750088DEC7 /* CCTMXXMLParser.h in Headers */, - FA6F1B901D80F858007DD223 /* Transform.h in Headers */, - 15AE1B8D19AADA9A00C27E9E /* UIScale9Sprite.h in Headers */, - BAFF7D5D1D5C1CF80051B92F /* Attachment.h in Headers */, - BA679B3B1CEC373000F875FA /* CCEventListenerAssetsManagerEx.h in Headers */, + 46FDDAAE202ACC6A00931238 /* Macro.h in Headers */, 1A28FF5E1F20AFAB007A1D9D /* SRProxyConnect.h in Headers */, 1A28FF4E1F20AFAB007A1D9D /* SRDelegateController.h in Headers */, + 46FDDB6E202ADDCE00931238 /* etc1.h in Headers */, 4DED481D1DFFA4AF0070C5C4 /* b2Body.h in Headers */, - 292DB14219B4574100A80320 /* UIEditBoxImpl.h in Headers */, - FAC8F2611D339EC20061CEDD /* CCTMXLayer.h in Headers */, - 1A570303180BCE890088DEC7 /* CCParallaxNode.h in Headers */, - 50ABBE2A1925AB6F00A911A9 /* CCAutoreleasePool.h in Headers */, 4DED48731DFFA4AF0070C5C4 /* b2PrismaticJoint.h in Headers */, - 1A57030F180BCF190088DEC7 /* CCComponent.h in Headers */, 1A28FF8A1F20AFAB007A1D9D /* SRURLUtilities.h in Headers */, - FA6F1B501D80F858007DD223 /* TimelineState.h in Headers */, - BA679B371CEC373000F875FA /* CCEventAssetsManagerEx.h in Headers */, - FA6F1B881D80F858007DD223 /* ColorTransform.h in Headers */, 4DED48091DFFA4AF0070C5C4 /* b2GrowableStack.h in Headers */, 4DED487F1DFFA4AF0070C5C4 /* b2RopeJoint.h in Headers */, - 1A570313180BCF190088DEC7 /* CCComponentContainer.h in Headers */, - 15AE1BC419AADFFB00C27E9E /* ExtensionMacros.h in Headers */, - 1AFFCD781F7A59B200628F2C /* CCThreadPool.h in Headers */, - 4DC06BF01E8B604B00CA08B1 /* CCPhysicsManifoldWrapper.h in Headers */, 50ABBD4B1925AB0000A911A9 /* Mat4.h in Headers */, - 15AE1BBE19AADFF000C27E9E /* SocketIO.h in Headers */, - 50ABBED61925AB6F00A911A9 /* utlist.h in Headers */, - 5034CA48191D591100CE6051 /* ccShader_Label_normal.frag in Headers */, - FA6F1BA81D80F858007DD223 /* DataParser.h in Headers */, + 46FDDC28202AEAC500931238 /* WebGLTypes.h in Headers */, 50ABBD531925AB0000A911A9 /* Quaternion.h in Headers */, 503DD8E81926736A00CD74DD /* CCES2Renderer-ios.h in Headers */, - 50ABBE6C1925AB6F00A911A9 /* CCEventListenerFocus.h in Headers */, - 5034CA3E191D591100CE6051 /* ccShader_PositionColor.frag in Headers */, + 46FDDBE8202ADDCE00931238 /* CCNS.h in Headers */, 4DED484B1DFFA4AF0070C5C4 /* b2EdgeAndCircleContact.h in Headers */, - 50ABBE301925AB6F00A911A9 /* ccConfig.h in Headers */, - 50ABBDAC1925AB4100A911A9 /* CCRenderCommandPool.h in Headers */, - 5034CA3C191D591100CE6051 /* ccShader_PositionColor.vert in Headers */, 50ABC0181926664800A911A9 /* CCImage.h in Headers */, - BAFF7D8D1D5C1CF80051B92F /* Json.h in Headers */, - 50ABBE8E1925AB6F00A911A9 /* CCNS.h in Headers */, - 50ABBEA61925AB6F00A911A9 /* CCScriptSupport.h in Headers */, - 5034CA4C191D591100CE6051 /* ccShader_Label_df_glow.frag in Headers */, 503DD8EB1926736A00CD74DD /* CCGL-ios.h in Headers */, - 50ABBE3C1925AB6F00A911A9 /* CCData.h in Headers */, - 503DD8FA1926B0DB00CD74DD /* CCIMEDispatcher.h in Headers */, - 50ABBEC81925AB6F00A911A9 /* etc1.h in Headers */, - 50ABBDB01925AB4100A911A9 /* CCRenderer.h in Headers */, - 50ABBD861925AB4100A911A9 /* CCBatchCommand.h in Headers */, + 46FDDA7C202ACC6A00931238 /* Camera.h in Headers */, 4DED48151DFFA4AF0070C5C4 /* b2StackAllocator.h in Headers */, - 50ABBE481925AB6F00A911A9 /* CCEvent.h in Headers */, + 46FDDC4C202AEAC500931238 /* GLConsts.h in Headers */, 5027253B190BF1B900AAF4ED /* cocos2d.h in Headers */, - 291901441B05895600F8B4BA /* CCNinePatchImageParser.h in Headers */, BA68D79B1D62F4B700B7A3F9 /* clipper.hpp in Headers */, - 50ABBE641925AB6F00A911A9 /* CCEventListenerAcceleration.h in Headers */, - 50ABBD921925AB4100A911A9 /* CCGLProgramCache.h in Headers */, - FA6F1BAC1D80F858007DD223 /* JSONDataParser.h in Headers */, - 50ABBE961925AB6F00A911A9 /* CCProfiling.h in Headers */, - 503DD8E01926736A00CD74DD /* CCApplication-ios.h in Headers */, - BAFF7DC51D5C1CF80051B92F /* Slot.h in Headers */, - 50ABBD8E1925AB4100A911A9 /* CCGLProgram.h in Headers */, - 50ABC0081926664800A911A9 /* CCApplicationProtocol.h in Headers */, - 1ABA68B11888D700007D1BB4 /* CCFontCharMap.h in Headers */, 4DED48111DFFA4AF0070C5C4 /* b2Settings.h in Headers */, - FA6F1B441D80F858007DD223 /* Animation.h in Headers */, + 46FDDAAC202ACC6A00931238 /* Types.h in Headers */, + 46FDDC32202AEAC500931238 /* TypeTraits.h in Headers */, + 46FDDC40202AEAC500931238 /* Likely.h in Headers */, 50ABBD4F1925AB0000A911A9 /* MathUtil.h in Headers */, 1A28FF561F20AFAB007A1D9D /* SRIOConsumerPool.h in Headers */, - 50ABBEBE1925AB6F00A911A9 /* ccUtils.h in Headers */, 1A28FF7E1F20AFAB007A1D9D /* SRMutex.h in Headers */, - FA6F1B8C1D80F858007DD223 /* Point.h in Headers */, - 50ABBE801925AB6F00A911A9 /* CCEventTouch.h in Headers */, - 299CF1FE19A434BC00C378C1 /* ccRandom.h in Headers */, - BAFF7DAD1D5C1CF80051B92F /* SkeletonBatch.h in Headers */, - 50ABBDBC1925AB4100A911A9 /* CCTextureAtlas.h in Headers */, - 50ABBE541925AB6F00A911A9 /* CCEventDispatcher.h in Headers */, - BAFF7DDB1D5C1CF80051B92F /* VertexAttachment.h in Headers */, - 1A12775A18DFCC4F0005F345 /* CCTweenFunction.h in Headers */, + 46FDDA76202ACC6A00931238 /* Config.h in Headers */, 50643BD519BFAECF00EF68ED /* CCGL.h in Headers */, - B276EF601988D1D500CD400F /* CCVertexIndexData.h in Headers */, + 46FDDB84202ADDCE00931238 /* ccRandom.h in Headers */, + 46FDDC4E202AEAC500931238 /* WebGLTexelConversions.h in Headers */, + 46FDDC30202AEAC500931238 /* Assertions.h in Headers */, + 46FDDBD2202ADDCE00931238 /* ccUTF8.h in Headers */, + 46FDDC2A202AEAC500931238 /* Casting.h in Headers */, 50ABBD5F1925AB0000A911A9 /* Vec3.h in Headers */, - BAFF7D4D1D5C1CF80051B92F /* AnimationState.h in Headers */, - 50ABBE821925AB6F00A911A9 /* CCEventType.h in Headers */, - BAFF7D511D5C1CF80051B92F /* AnimationStateData.h in Headers */, - 1AAF5852180E40B9000584C8 /* LocalStorage.h in Headers */, - 4DC06BE61E8A68D400CA08B1 /* CCPhysicsUtils.h in Headers */, - 50CB247619D9C5A100687767 /* AudioCache.h in Headers */, + 46FDDC02202ADDCE00931238 /* ccCArray.h in Headers */, + 46FDDAE0202ACC6A00931238 /* RenderTarget.h in Headers */, 50ABBD471925AB0000A911A9 /* CCVertex.h in Headers */, - 1A9DCA2A180E6955007A3AD4 /* CCGLBufferedNode.h in Headers */, - 464AD6E8197EBB1400E502D8 /* pvr.h in Headers */, - 5034CA36191D591100CE6051 /* ccShader_PositionTexture.frag in Headers */, - B24AA98C195A675C007B4522 /* CCFastTMXTiledMap.h in Headers */, - BAFF7D951D5C1CF80051B92F /* PathAttachment.h in Headers */, - 50ABBEAE1925AB6F00A911A9 /* ccTypes.h in Headers */, + 46FDDA90202ACC6A00931238 /* BaseRenderer.h in Headers */, + 46FDDABE202ACC6A00931238 /* DeviceGraphics.h in Headers */, 4DED48371DFFA4AF0070C5C4 /* b2ChainAndCircleContact.h in Headers */, - BA679B3F1CEC373000F875FA /* Manifest.h in Headers */, - 50ABBE261925AB6F00A911A9 /* base64.h in Headers */, - 50ABBEDA1925AB6F00A911A9 /* ZipUtils.h in Headers */, + 46FDDAB8202ACC6A00931238 /* IndexBuffer.h in Headers */, 1A28FF5C1F20AFAB007A1D9D /* NSURLRequest+SRWebSocketPrivate.h in Headers */, - 50ABBDC01925AB4100A911A9 /* CCTextureCache.h in Headers */, - B276EF641988D1D500CD400F /* CCVertexIndexBuffer.h in Headers */, - ED9C6A9718599AD8000A5232 /* CCNodeGrid.h in Headers */, - FA6F1BA41D80F858007DD223 /* TimelineData.h in Headers */, - 50ABC0201926664800A911A9 /* CCThread.h in Headers */, - BAFF7DA51D5C1CF80051B92F /* Skeleton.h in Headers */, 1A28FF6E1F20AFAB007A1D9D /* SRError.h in Headers */, - 15AE184B19AAD30500C27E9E /* Export.h in Headers */, - 50ABBED21925AB6F00A911A9 /* TGAlib.h in Headers */, 4DED47F11DFFA4AF0070C5C4 /* b2ChainShape.h in Headers */, 4DED48771DFFA4AF0070C5C4 /* b2PulleyJoint.h in Headers */, 4DED483F1DFFA4AF0070C5C4 /* b2CircleContact.h in Headers */, 4DED48531DFFA4AF0070C5C4 /* b2PolygonAndCircleContact.h in Headers */, 503DD8EA1926736A00CD74DD /* CCESRenderer-ios.h in Headers */, + 46FDDBC4202ADDCE00931238 /* ccConfig.h in Headers */, 4DED488B1DFFA4AF0070C5C4 /* b2Rope.h in Headers */, - 50ABBE581925AB6F00A911A9 /* CCEventFocus.h in Headers */, 4DED482B1DFFA4AF0070C5C4 /* b2TimeStep.h in Headers */, 1A28FF661F20AFAB007A1D9D /* SRPinningSecurityPolicy.h in Headers */, - 15AE1B9719AADAA100C27E9E /* UIVideoPlayer.h in Headers */, - 50ABC00A1926664800A911A9 /* CCCommon.h in Headers */, - 50ABBE5C1925AB6F00A911A9 /* CCEventKeyboard.h in Headers */, 50ABC01C1926664800A911A9 /* CCSAXParser.h in Headers */, + 46FDDBD0202ADDCE00931238 /* CCMap.h in Headers */, 503DD8F11926736A00CD74DD /* OpenGL_Internal-ios.h in Headers */, - 50ABBDAA1925AB4100A911A9 /* CCRenderCommand.h in Headers */, - BAFF7DCD1D5C1CF80051B92F /* spine-cocos2dx.h in Headers */, - B63990CF1A490AFE00B07923 /* CCAsyncTaskPool.h in Headers */, - A614E2E11C8E761D0065A737 /* CCLabelTTF.h in Headers */, 1A28FF5A1F20AFAB007A1D9D /* NSRunLoop+SRWebSocketPrivate.h in Headers */, - 15AE1BC319AADFFB00C27E9E /* cocos-ext.h in Headers */, - 50ABBE601925AB6F00A911A9 /* CCEventListener.h in Headers */, 1A28FF861F20AFAB007A1D9D /* SRSIMDHelpers.h in Headers */, - FA6F1B4C1D80F858007DD223 /* IAnimateble.h in Headers */, - 50ABBEB21925AB6F00A911A9 /* CCUserDefault.h in Headers */, - A0534A6B1B87306E006B03E5 /* CCIDownloaderImpl.h in Headers */, + 46FDDC3C202AEAC500931238 /* MacroArgs.h in Headers */, 4DED48291DFFA4AF0070C5C4 /* b2Island.h in Headers */, ); runOnlyForDeploymentPostprocessing = 0; @@ -4938,350 +2426,156 @@ isa = PBXSourcesBuildPhase; buildActionMask = 2147483647; files = ( + 46FDDBB9202ADDCE00931238 /* CCNS.cpp in Sources */, + 46FDDA7D202ACC6A00931238 /* Light.cpp in Sources */, + 46FDDC37202AEAC500931238 /* Assertions.cpp in Sources */, 1A28FF7F1F20AFAB007A1D9D /* SRMutex.m in Sources */, 4DED48381DFFA4AF0070C5C4 /* b2ChainAndPolygonContact.cpp in Sources */, - 4D2E69071CC543B40032DD5C /* CCGraphicsNode.cpp in Sources */, 4DED48221DFFA4AF0070C5C4 /* b2Fixture.cpp in Sources */, - 50ABBE2B1925AB6F00A911A9 /* ccCArray.cpp in Sources */, + 46FDDB65202ADDCE00931238 /* ccRandom.cpp in Sources */, + 46FDDAB9202ACC6A00931238 /* FrameBuffer.cpp in Sources */, 50ABBD581925AB0000A911A9 /* Vec2.cpp in Sources */, - 50ABBE311925AB6F00A911A9 /* CCConfiguration.cpp in Sources */, - 4D2E690B1CC543B40032DD5C /* Triangulate.cpp in Sources */, + 46FDDBA9202ADDCE00931238 /* CCProfiling.cpp in Sources */, 4DED47F21DFFA4AF0070C5C4 /* b2CircleShape.cpp in Sources */, 4DED481E1DFFA4AF0070C5C4 /* b2ContactManager.cpp in Sources */, 5027253C190BF1B900AAF4ED /* cocos2d.cpp in Sources */, - 50ABC0611926664800A911A9 /* CCCommon-mac.mm in Sources */, - 50ABBDB11925AB4100A911A9 /* ccShaders.cpp in Sources */, 4DED483C1DFFA4AF0070C5C4 /* b2CircleContact.cpp in Sources */, - 4DC06BED1E8B604B00CA08B1 /* CCPhysicsManifoldWrapper.cpp in Sources */, - A63CF00D1CD9CF3500A6971D /* CCUITextFieldFormatter.m in Sources */, 4DED47EA1DFFA4AF0070C5C4 /* b2TimeOfImpact.cpp in Sources */, - FA6F1B511D80F858007DD223 /* WorldClock.cpp in Sources */, - 50ABBE991925AB6F00A911A9 /* CCRef.cpp in Sources */, - FA6F1B731D80F858007DD223 /* CCTextureData.cpp in Sources */, - ED9C6A9418599AD8000A5232 /* CCNodeGrid.cpp in Sources */, - BAFF7DAE1D5C1CF80051B92F /* SkeletonBounds.c in Sources */, + 46FDDAA3202ACC6A00931238 /* InputAssembler.cpp in Sources */, 4DED48581DFFA4AF0070C5C4 /* b2DistanceJoint.cpp in Sources */, - 50ABBDA71925AB4100A911A9 /* CCRenderCommand.cpp in Sources */, + 46FDDC25202AEAC500931238 /* WebGLTexelConversions.cpp in Sources */, 50ABBD501925AB0000A911A9 /* Quaternion.cpp in Sources */, - 4DFA4C171CBCE34100E3B736 /* CCScale9Sprite.cpp in Sources */, - 50ABBEBB1925AB6F00A911A9 /* ccUtils.cpp in Sources */, ED30579A1BEC77B70083C3ED /* ConvertUTF.c in Sources */, - A63CF0051CD9CF3500A6971D /* CCUIEditBoxMac.mm in Sources */, - 15EFA211198A2BB5000C57D3 /* CCProtectedNode.cpp in Sources */, - 50ABBEB71925AB6F00A911A9 /* ccUTF8.cpp in Sources */, - FA6F1B411D80F858007DD223 /* Animation.cpp in Sources */, - 4D6CF4371E83AAD5003327D4 /* CCCameraNode.cpp in Sources */, - 50ABBE271925AB6F00A911A9 /* CCAutoreleasePool.cpp in Sources */, - BAFF7D6E1D5C1CF80051B92F /* BoundingBoxAttachment.c in Sources */, - 4DC06BDB1E8A68D400CA08B1 /* CCPhysicsDebugDraw.cpp in Sources */, - 50ABBE8B1925AB6F00A911A9 /* CCNS.cpp in Sources */, - FA6F1B551D80F858007DD223 /* Armature.cpp in Sources */, + 46FDDA79202ACC6A00931238 /* Camera.cpp in Sources */, + 46FDDAC1202ACC6A00931238 /* Texture.cpp in Sources */, 1A28FF6B1F20AFAB007A1D9D /* SRConstants.m in Sources */, - 1A570061180BC5A10088DEC7 /* CCAction.cpp in Sources */, 294D7D9C1D0E93A2002CE7B7 /* CCDevice-apple.mm in Sources */, - BAFF7D7A1D5C1CF80051B92F /* EventData.c in Sources */, + 46FDDA71202ACC6A00931238 /* Scene.cpp in Sources */, 4DED48301DFFA4AF0070C5C4 /* b2WorldCallbacks.cpp in Sources */, - 50ABBEC51925AB6F00A911A9 /* etc1.cpp in Sources */, - FA6F1B591D80F858007DD223 /* Bone.cpp in Sources */, - 1A570065180BC5A10088DEC7 /* CCActionCamera.cpp in Sources */, - 50ABBEAB1925AB6F00A911A9 /* ccTypes.cpp in Sources */, - 1A570069180BC5A10088DEC7 /* CCActionCatmullRom.cpp in Sources */, - B257B44E1989D5E800D9A687 /* CCPrimitive.cpp in Sources */, - 299CF1FB19A434BC00C378C1 /* ccRandom.cpp in Sources */, - 1A57006D180BC5A10088DEC7 /* CCActionEase.cpp in Sources */, 4DED48741DFFA4AF0070C5C4 /* b2PulleyJoint.cpp in Sources */, - 1A570071180BC5A10088DEC7 /* CCActionGrid.cpp in Sources */, - 50CB247F19D9C5A100687767 /* AudioPlayer.mm in Sources */, 4DED481A1DFFA4AF0070C5C4 /* b2Body.cpp in Sources */, 50ABBFFF1926664800A911A9 /* CCFileUtils-apple.mm in Sources */, - 1A570075180BC5A10088DEC7 /* CCActionGrid3D.cpp in Sources */, - 1A570079180BC5A10088DEC7 /* CCActionInstant.cpp in Sources */, - 50ABBE591925AB6F00A911A9 /* CCEventKeyboard.cpp in Sources */, - BA679B381CEC373000F875FA /* CCEventListenerAssetsManagerEx.cpp in Sources */, - 1A57007D180BC5A10088DEC7 /* CCActionInterval.cpp in Sources */, 4DED48701DFFA4AF0070C5C4 /* b2PrismaticJoint.cpp in Sources */, - 1A570081180BC5A10088DEC7 /* CCActionManager.cpp in Sources */, - 1A570085180BC5A10088DEC7 /* CCActionPageTurn3D.cpp in Sources */, - FAC8F66A1E1DF15D002B17E8 /* SkeletonBinary.c in Sources */, - 844EB11F1F78D4CB00EFE4CD /* CCThreadPool.cpp in Sources */, - 1A570089180BC5A10088DEC7 /* CCActionProgressTimer.cpp in Sources */, - 1A57008D180BC5A10088DEC7 /* CCActionTiledGrid.cpp in Sources */, - 1A570091180BC5A10088DEC7 /* CCActionTween.cpp in Sources */, - FA6F1B4D1D80F858007DD223 /* TimelineState.cpp in Sources */, - FAC8F25C1D339EB70061CEDD /* CCTMXLayer.cpp in Sources */, - 50ABBEBF1925AB6F00A911A9 /* CCValue.cpp in Sources */, 4DED48681DFFA4AF0070C5C4 /* b2MotorJoint.cpp in Sources */, BA68D7911D62F4A500B7A3F9 /* sweep_context.cc in Sources */, - FA6F1B831D80F858007DD223 /* BaseFactory.cpp in Sources */, - FAC8F25E1D339EB70061CEDD /* CCTMXTiledMap.cpp in Sources */, - 1A570098180BC5C10088DEC7 /* CCAtlasNode.cpp in Sources */, - 1A57009E180BC5D20088DEC7 /* CCNode.cpp in Sources */, - B257B460198A353E00D9A687 /* CCPrimitiveCommand.cpp in Sources */, - 291901451B05895600F8B4BA /* CCNinePatchImageParser.cpp in Sources */, - BAFF7D521D5C1CF80051B92F /* Atlas.c in Sources */, - 50ED2BDB19BE76D500A0AB90 /* UIVideoPlayer-ios.mm in Sources */, 4DED480A1DFFA4AF0070C5C4 /* b2Math.cpp in Sources */, 4DED47EE1DFFA4AF0070C5C4 /* b2ChainShape.cpp in Sources */, - 50ABBE651925AB6F00A911A9 /* CCEventListenerCustom.cpp in Sources */, - 50ABBE391925AB6F00A911A9 /* CCData.cpp in Sources */, 4DC57D211F7A58B5005B6546 /* xxtea.cpp in Sources */, - 4DC06BE71E8A68D400CA08B1 /* CCPhysicsWorldManifoldWrapper.cpp in Sources */, - 1A57010E180BC8EE0088DEC7 /* CCDrawingPrimitives.cpp in Sources */, - 50ABBED71925AB6F00A911A9 /* ZipUtils.cpp in Sources */, - BAFF7DC21D5C1CF80051B92F /* Slot.c in Sources */, - 1A570112180BC8EE0088DEC7 /* CCDrawNode.cpp in Sources */, 4DED482C1DFFA4AF0070C5C4 /* b2World.cpp in Sources */, - 1A57011B180BC90D0088DEC7 /* CCGrabber.cpp in Sources */, - 1A57011F180BC90D0088DEC7 /* CCGrid.cpp in Sources */, - BAFF7D861D5C1CF80051B92F /* IkConstraintData.c in Sources */, 4DED47D81DFFA4AF0070C5C4 /* b2CollideCircle.cpp in Sources */, - BAFF7D461D5C1CF80051B92F /* Animation.c in Sources */, + 46FDDB71202ADDCE00931238 /* base64.cpp in Sources */, + 46FDDA8D202ACC6A00931238 /* Config.cpp in Sources */, BA68D7851D62F4A500B7A3F9 /* advancing_front.cc in Sources */, 1A28FF991F20AFAB007A1D9D /* SRSecurityPolicy.m in Sources */, - 15AE1B6D19AADA9900C27E9E /* UIHelper.cpp in Sources */, - 29394CF219B01DBA00D2DE1A /* UIWebView.mm in Sources */, - A0534A671B872FFD006B03E5 /* CCDownloader-apple.mm in Sources */, - BAFF7D621D5C1CF80051B92F /* AttachmentVertices.cpp in Sources */, - 1A57019D180BCB590088DEC7 /* CCFont.cpp in Sources */, - 50CB247B19D9C5A100687767 /* AudioEngine-inl.mm in Sources */, - 1A5701A1180BCB590088DEC7 /* CCFontAtlas.cpp in Sources */, - 1A5701A5180BCB590088DEC7 /* CCFontAtlasCache.cpp in Sources */, - BAFF7DD01D5C1CF80051B92F /* TransformConstraint.c in Sources */, - 1A5701B1180BCB590088DEC7 /* CCFontFNT.cpp in Sources */, - BAFF7D6A1D5C1CF80051B92F /* BoneData.c in Sources */, 4DED48881DFFA4AF0070C5C4 /* b2Rope.cpp in Sources */, - 1A5701B5180BCB590088DEC7 /* CCFontFreeType.cpp in Sources */, - 4DC06BDF1E8A68D400CA08B1 /* CCPhysicsRayCastCallback.cpp in Sources */, - 1A5701B9180BCB5A0088DEC7 /* CCLabel.cpp in Sources */, - 1A5701BD180BCB5A0088DEC7 /* CCLabelAtlas.cpp in Sources */, - 1AD473AC1EAD9A5200202582 /* Uri.cpp in Sources */, + 46FDDAE1202ACC6A00931238 /* GFXUtils.cpp in Sources */, 4DED48541DFFA4AF0070C5C4 /* b2PolygonContact.cpp in Sources */, BA68D78D1D62F4A500B7A3F9 /* sweep.cc in Sources */, - 292DB13D19B4574100A80320 /* UIEditBox.cpp in Sources */, - 50ABBE551925AB6F00A911A9 /* CCEventFocus.cpp in Sources */, - 50ABBE491925AB6F00A911A9 /* CCEventAcceleration.cpp in Sources */, + 46FDDAB5202ACC6A00931238 /* Program.cpp in Sources */, + 46FDDBF9202ADDCE00931238 /* etc1.cpp in Sources */, 50ABBD4C1925AB0000A911A9 /* MathUtil.cpp in Sources */, - 50ABBD831925AB4100A911A9 /* CCBatchCommand.cpp in Sources */, - 1A5701C7180BCB5A0088DEC7 /* CCLabelTextFormatter.cpp in Sources */, + 46FDDA99202ACC6A00931238 /* Model.cpp in Sources */, + 46FDDC4F202AEAC500931238 /* WebGLFormats.cpp in Sources */, + 46FDDA89202ACC6A00931238 /* Effect.cpp in Sources */, 4DED48161DFFA4AF0070C5C4 /* b2Timer.cpp in Sources */, - 50ABBE711925AB6F00A911A9 /* CCEventListenerMouse.cpp in Sources */, - BA679B341CEC373000F875FA /* CCEventAssetsManagerEx.cpp in Sources */, - BAFF7DB61D5C1CF80051B92F /* SkeletonJson.c in Sources */, 4DED47E61DFFA4AF0070C5C4 /* b2DynamicTree.cpp in Sources */, - 1A5701DE180BCB8C0088DEC7 /* CCLayer.cpp in Sources */, ED30577E1BEC76C90083C3ED /* ioapi_mem.cpp in Sources */, - 1A5701E2180BCB8C0088DEC7 /* CCScene.cpp in Sources */, 4DED484C1DFFA4AF0070C5C4 /* b2EdgeAndPolygonContact.cpp in Sources */, - FA6F1B9D1D80F858007DD223 /* FrameData.cpp in Sources */, - 1A12775C18DFCC590005F345 /* CCTweenFunction.cpp in Sources */, 4DED48481DFFA4AF0070C5C4 /* b2EdgeAndCircleContact.cpp in Sources */, + 46FDDABF202ACC6A00931238 /* State.cpp in Sources */, 1A28FF5F1F20AFAB007A1D9D /* SRProxyConnect.m in Sources */, - FA6F1B451D80F858007DD223 /* AnimationState.cpp in Sources */, - 1A5701E6180BCB8C0088DEC7 /* CCTransition.cpp in Sources */, - B24AA985195A675C007B4522 /* CCFastTMXLayer.cpp in Sources */, - B63990CC1A490AFE00B07923 /* CCAsyncTaskPool.cpp in Sources */, - 1A5701EA180BCB8C0088DEC7 /* CCTransitionPageTurn.cpp in Sources */, - 50ABBDAD1925AB4100A911A9 /* CCRenderer.cpp in Sources */, - BAFF7DB21D5C1CF80051B92F /* SkeletonData.c in Sources */, - 4DC06BD31E8A68D400CA08B1 /* CCPhysicsContactListener.cpp in Sources */, - 1A5701EE180BCB8C0088DEC7 /* CCTransitionProgress.cpp in Sources */, - 1A5701F7180BCBAD0088DEC7 /* CCMenu.cpp in Sources */, + 46FDDB8B202ADDCE00931238 /* CCAutoreleasePool.cpp in Sources */, + 46FDDA87202ACC6A00931238 /* View.cpp in Sources */, ED3057821BEC76C90083C3ED /* unzip.cpp in Sources */, - 1A5701FB180BCBAD0088DEC7 /* CCMenuItem.cpp in Sources */, - 1A570202180BCBD40088DEC7 /* CCClippingNode.cpp in Sources */, - A63CF0091CD9CF3500A6971D /* CCUIPasswordTextField.m in Sources */, - 1A570208180BCBDF0088DEC7 /* CCMotionStreak.cpp in Sources */, - 1A570210180BCBF40088DEC7 /* CCProgressTimer.cpp in Sources */, - 292DB14D19B4574100A80320 /* UIEditBoxImpl-mac.mm in Sources */, 1A28FF8F1F20AFAB007A1D9D /* NSRunLoop+SRWebSocket.m in Sources */, - BAFF7D921D5C1CF80051B92F /* PathAttachment.c in Sources */, - FA6F1BA11D80F858007DD223 /* TimelineData.cpp in Sources */, - BAFF7DC61D5C1CF80051B92F /* SlotData.c in Sources */, - BAFF7DA61D5C1CF80051B92F /* SkeletonAnimation.cpp in Sources */, - 50ABBDB51925AB4100A911A9 /* CCTexture2D.cpp in Sources */, ED3057801BEC76C90083C3ED /* ioapi.cpp in Sources */, - 1A570214180BCBF40088DEC7 /* CCRenderTexture.cpp in Sources */, - A0E749F71BA8FD7F001A8332 /* UIEditBoxImpl-common.cpp in Sources */, - BAFF7D661D5C1CF80051B92F /* Bone.c in Sources */, - B276EF651988D1D500CD400F /* CCVertexIndexBuffer.cpp in Sources */, - 50ABBE411925AB6F00A911A9 /* CCDirector.cpp in Sources */, - 4DC06BE31E8A68D400CA08B1 /* CCPhysicsUtils.cpp in Sources */, - 1A570221180BCC1A0088DEC7 /* CCParticleBatchNode.cpp in Sources */, - 1A570225180BCC1A0088DEC7 /* CCParticleExamples.cpp in Sources */, - 1A570229180BCC1A0088DEC7 /* CCParticleSystem.cpp in Sources */, + 46FDDA9F202ACC6A00931238 /* ProgramLib.cpp in Sources */, + 46FDDABB202ACC6A00931238 /* VertexFormat.cpp in Sources */, 4DED48801DFFA4AF0070C5C4 /* b2WeldJoint.cpp in Sources */, 1A28FF671F20AFAB007A1D9D /* SRPinningSecurityPolicy.m in Sources */, - 1A57022D180BCC1A0088DEC7 /* CCParticleSystemQuad.cpp in Sources */, - 1A57027E180BCC900088DEC7 /* CCSprite.cpp in Sources */, - 1A570282180BCC900088DEC7 /* CCSpriteBatchNode.cpp in Sources */, - BAFF7D7E1D5C1CF80051B92F /* extension.c in Sources */, - 1A570286180BCC900088DEC7 /* CCSpriteFrame.cpp in Sources */, - B24AA989195A675C007B4522 /* CCFastTMXTiledMap.cpp in Sources */, 50ABC0191926664800A911A9 /* CCSAXParser.cpp in Sources */, 4DED480E1DFFA4AF0070C5C4 /* b2Settings.cpp in Sources */, - BAFF7DAA1D5C1CF80051B92F /* SkeletonBatch.cpp in Sources */, 1A28FF571F20AFAB007A1D9D /* SRIOConsumerPool.m in Sources */, - BAFF7DA21D5C1CF80051B92F /* Skeleton.c in Sources */, - 1A57028A180BCC900088DEC7 /* CCSpriteFrameCache.cpp in Sources */, - 1A570292180BCCAB0088DEC7 /* CCAnimation.cpp in Sources */, + 46FDDB7B202ADDCE00931238 /* CCRef.cpp in Sources */, + 46FDDB8D202ADDCE00931238 /* ccTypes.cpp in Sources */, 4DED47DE1DFFA4AF0070C5C4 /* b2Collision.cpp in Sources */, - 1A570296180BCCAB0088DEC7 /* CCAnimationCache.cpp in Sources */, - BAFF7DD81D5C1CF80051B92F /* VertexAttachment.c in Sources */, - 50ABBE351925AB6F00A911A9 /* CCConsole.cpp in Sources */, - 50693C5E1B6BF2AE005C5820 /* CCDownloader.cpp in Sources */, - 50ABBEAF1925AB6F00A911A9 /* CCUserDefault.cpp in Sources */, - BAFF7D4A1D5C1CF80051B92F /* AnimationState.c in Sources */, - 50ABBE791925AB6F00A911A9 /* CCEventMouse.cpp in Sources */, - A05DCF9D1B90584E00EE040B /* CCDownloader-curl.cpp in Sources */, + 46FDDAA9202ACC6A00931238 /* Types.cpp in Sources */, 4DED48001DFFA4AF0070C5C4 /* b2BlockAllocator.cpp in Sources */, - 50ABC0111926664800A911A9 /* CCGLView.cpp in Sources */, BA68D7981D62F4B600B7A3F9 /* clipper.cpp in Sources */, - 1A5702C8180BCE370088DEC7 /* CCTextFieldTTF.cpp in Sources */, - FA6F1BAD1D80F858007DD223 /* TextureData.cpp in Sources */, - 50ABBE7D1925AB6F00A911A9 /* CCEventTouch.cpp in Sources */, 1A28FF4F1F20AFAB007A1D9D /* SRDelegateController.m in Sources */, - 1A5702EA180BCE750088DEC7 /* CCTileMapAtlas.cpp in Sources */, - 50ABBD971925AB4100A911A9 /* CCGLProgramStateCache.cpp in Sources */, - 50ABBE691925AB6F00A911A9 /* CCEventListenerFocus.cpp in Sources */, 4DED485C1DFFA4AF0070C5C4 /* b2FrictionJoint.cpp in Sources */, - FA6F1B951D80F858007DD223 /* ArmatureData.cpp in Sources */, - BAFF7D761D5C1CF80051B92F /* Event.c in Sources */, 4DED47DC1DFFA4AF0070C5C4 /* b2CollidePolygon.cpp in Sources */, - 4D2816661E8CBB7200F26B06 /* CCPhysicsContactImpulse.cpp in Sources */, - BAFF7DCA1D5C1CF80051B92F /* spine-cocos2dx.cpp in Sources */, 4DED48041DFFA4AF0070C5C4 /* b2Draw.cpp in Sources */, - B230ED7119B417AE00364AA8 /* CCTrianglesCommand.cpp in Sources */, - 1A5702F2180BCE750088DEC7 /* CCTMXObjectGroup.cpp in Sources */, - 1A5FB7CA1DF10E3500C918C1 /* AudioDecoder.mm in Sources */, - 826294351AAF004C00CB7CF7 /* HttpCookie.cpp in Sources */, - BAFF7DD41D5C1CF80051B92F /* TransformConstraintData.c in Sources */, 4DED487C1DFFA4AF0070C5C4 /* b2RopeJoint.cpp in Sources */, - 1A5702FA180BCE750088DEC7 /* CCTMXXMLParser.cpp in Sources */, + 46FDDBFB202ADDCE00931238 /* ccCArray.cpp in Sources */, 1A28FF631F20AFAB007A1D9D /* SRRunLoopThread.m in Sources */, 50ABBD5C1925AB0000A911A9 /* Vec3.cpp in Sources */, + 46FDDBB3202ADDCE00931238 /* CCIMEDispatcher.cpp in Sources */, ED3057911BEC77770083C3ED /* edtaa3func.cpp in Sources */, - BAFF7D821D5C1CF80051B92F /* IkConstraint.c in Sources */, - FA6F1B5F1D80F858007DD223 /* Slot.cpp in Sources */, - 1A570300180BCE890088DEC7 /* CCParallaxNode.cpp in Sources */, + 46FDDB93202ADDCE00931238 /* TGAlib.cpp in Sources */, 1A28FF831F20AFAB007A1D9D /* SRRandom.m in Sources */, - FA6F1B651D80F858007DD223 /* CCArmatureDisplay.cpp in Sources */, - 1A57030C180BCF190088DEC7 /* CCComponent.cpp in Sources */, - 15FB20741AE7BF8600C31518 /* CCAutoPolygon.cpp in Sources */, - 1A570310180BCF190088DEC7 /* CCComponentContainer.cpp in Sources */, + 46FDDAC5202ACC6A00931238 /* RenderTarget.cpp in Sources */, 50ABBD3C1925AB0000A911A9 /* CCGeometry.cpp in Sources */, 1A28FF771F20AFAB007A1D9D /* SRHTTPConnectMessage.m in Sources */, - A63CF00B1CD9CF3500A6971D /* CCUISingleLineTextField.m in Sources */, - FA6F1BA51D80F858007DD223 /* DataParser.cpp in Sources */, + 46FDDB99202ADDCE00931238 /* ccUTF8.cpp in Sources */, + 46FDDAE3202ACC6A00931238 /* GFX.cpp in Sources */, 50ABC0011926664800A911A9 /* CCLock-apple.cpp in Sources */, - 50ABBD931925AB4100A911A9 /* CCGLProgramState.cpp in Sources */, ED30579C1BEC77B70083C3ED /* ConvertUTFWrapper.cpp in Sources */, - BA679B301CEC373000F875FA /* AssetsManagerEx.cpp in Sources */, - BAFF7D5E1D5C1CF80051B92F /* AttachmentLoader.c in Sources */, 4DED48261DFFA4AF0070C5C4 /* b2Island.cpp in Sources */, - 50ABBEB31925AB6F00A911A9 /* CCUserDefault-apple.mm in Sources */, - BAFF7DBA1D5C1CF80051B92F /* SkeletonRenderer.cpp in Sources */, + 46FDDAB1202ACC6A00931238 /* DeviceGraphics.cpp in Sources */, 1A28FF7B1F20AFAB007A1D9D /* SRLog.m in Sources */, - 29394CF619B01DBA00D2DE1A /* UIWebViewImpl-ios.mm in Sources */, - 50ABBE831925AB6F00A911A9 /* ccFPSImages.c in Sources */, - 15AE1B7019AADA9900C27E9E /* CocosGUI.cpp in Sources */, - 50CB247719D9C5A100687767 /* AudioCache.mm in Sources */, 4DED48401DFFA4AF0070C5C4 /* b2Contact.cpp in Sources */, - 50ABBEA71925AB6F00A911A9 /* CCTouch.cpp in Sources */, - BAFF7D9A1D5C1CF80051B92F /* PathConstraintData.c in Sources */, - FA6F1BA91D80F858007DD223 /* JSONDataParser.cpp in Sources */, + 46FDDAC9202ACC6A00931238 /* RenderBuffer.cpp in Sources */, 4DED48441DFFA4AF0070C5C4 /* b2ContactSolver.cpp in Sources */, BA68D7891D62F4A500B7A3F9 /* cdt.cc in Sources */, 1A28FF6F1F20AFAB007A1D9D /* SRError.m in Sources */, 1A28FF531F20AFAB007A1D9D /* SRIOConsumer.m in Sources */, + 46FDDB4B202ADDCE00931238 /* ccFPSImages.c in Sources */, 4DED48501DFFA4AF0070C5C4 /* b2PolygonAndCircleContact.cpp in Sources */, - 50ABBD8B1925AB4100A911A9 /* CCGLProgram.cpp in Sources */, 1A9F0F971F301DE200A499E1 /* b2ObjectDestroyNotifier.cpp in Sources */, 1A37E9C8200DDFC90078AF72 /* CCReachability.cpp in Sources */, - 464AD6E5197EBB1400E502D8 /* pvr.cpp in Sources */, - 50ABBDA31925AB4100A911A9 /* CCQuadCommand.cpp in Sources */, - 50ABC01D1926664800A911A9 /* CCThread.cpp in Sources */, + 46FDDA8B202ACC6A00931238 /* ForwardRenderer.cpp in Sources */, 50ABBD481925AB0000A911A9 /* Mat4.cpp in Sources */, - 826294341AAF003E00CB7CF7 /* HttpClient-apple.mm in Sources */, - 50ABBD8F1925AB4100A911A9 /* CCGLProgramCache.cpp in Sources */, 50ABBD441925AB0000A911A9 /* CCVertex.cpp in Sources */, - BA8122AB1D77C4150010BEE9 /* CCLabelTTF.cpp in Sources */, - FA6F1B991D80F858007DD223 /* DragonBonesData.cpp in Sources */, - B276EF611988D1D500CD400F /* CCVertexIndexData.cpp in Sources */, - 503DD8F71926B0DB00CD74DD /* CCIMEDispatcher.cpp in Sources */, - 1A8D25511F39C4E3002CC0A8 /* WebSocket-apple.mm in Sources */, - 50ABBE751925AB6F00A911A9 /* CCEventListenerTouch.cpp in Sources */, - 50ABBE511925AB6F00A911A9 /* CCEventDispatcher.cpp in Sources */, 4DED47F61DFFA4AF0070C5C4 /* b2EdgeShape.cpp in Sources */, - 50ABC0051926664800A911A9 /* CCThread-apple.mm in Sources */, 50ABC0631926664800A911A9 /* CCDevice-mac.mm in Sources */, 4DED48781DFFA4AF0070C5C4 /* b2RevoluteJoint.cpp in Sources */, - 15AE1B6719AADA9900C27E9E /* UIScale9Sprite.cpp in Sources */, - 1AAF584F180E40B9000584C8 /* LocalStorage.cpp in Sources */, - 50ABBEA31925AB6F00A911A9 /* CCScriptSupport.cpp in Sources */, - 826294331AAF001C00CB7CF7 /* HttpAsynConnection-apple.m in Sources */, - 50ABBE6D1925AB6F00A911A9 /* CCEventListenerKeyboard.cpp in Sources */, - 1A9DCA27180E6955007A3AD4 /* CCGLBufferedNode.cpp in Sources */, 50ABBD541925AB0000A911A9 /* TransformUtils.cpp in Sources */, - DABC9FA919E7DFA900FA252C /* CCClippingRectangleNode.cpp in Sources */, - 3E2F27A619CFBFE100E7C490 /* AudioEngine.cpp in Sources */, - BAFF7DBE1D5C1CF80051B92F /* Skin.c in Sources */, - 4DC06BCF1E8A68D400CA08B1 /* CCPhysicsAABBQueryCallback.cpp in Sources */, - 50ABBD9B1925AB4100A911A9 /* ccGLStateCache.cpp in Sources */, - 50ABBDB91925AB4100A911A9 /* CCTextureAtlas.cpp in Sources */, - FA6F1B911D80F858007DD223 /* AnimationData.cpp in Sources */, + 46FDDAD5202ACC6A00931238 /* GraphicsHandle.cpp in Sources */, BA68D77D1D62F4A500B7A3F9 /* shapes.cc in Sources */, - 50ABBECF1925AB6F00A911A9 /* TGAlib.cpp in Sources */, - FA6F1B6F1D80F858007DD223 /* CCSlot.cpp in Sources */, - 50ABBE451925AB6F00A911A9 /* CCEvent.cpp in Sources */, - 50ABBE611925AB6F00A911A9 /* CCEventListenerAcceleration.cpp in Sources */, - BAFF7D8E1D5C1CF80051B92F /* MeshAttachment.c in Sources */, - 50ABBD9F1925AB4100A911A9 /* CCGroupCommand.cpp in Sources */, - 50ABBD871925AB4100A911A9 /* CCCustomCommand.cpp in Sources */, - FA6F1B6B1D80F858007DD223 /* CCFactory.cpp in Sources */, - BAFF7D8A1D5C1CF80051B92F /* Json.c in Sources */, + 46FDDA9D202ACC6A00931238 /* BaseRenderer.cpp in Sources */, 4DED48641DFFA4AF0070C5C4 /* b2Joint.cpp in Sources */, - 50ABBDBD1925AB4100A911A9 /* CCTextureCache.cpp in Sources */, - FA6F1B7F1D80F858007DD223 /* EventObject.cpp in Sources */, - 299754F4193EC95400A54AC3 /* ObjectFactory.cpp in Sources */, 4DED48121DFFA4AF0070C5C4 /* b2StackAllocator.cpp in Sources */, - BAFF7D961D5C1CF80051B92F /* PathConstraint.c in Sources */, - 50ABC0211926664800A911A9 /* CCGLViewImpl-desktop.cpp in Sources */, 4DED47FA1DFFA4AF0070C5C4 /* b2PolygonShape.cpp in Sources */, - BAFF7D4E1D5C1CF80051B92F /* AnimationStateData.c in Sources */, 4DED48841DFFA4AF0070C5C4 /* b2WheelJoint.cpp in Sources */, - BAFF7D721D5C1CF80051B92F /* Cocos2dAttachmentLoader.cpp in Sources */, + 46FDDAE5202ACC6B00931238 /* IndexBuffer.cpp in Sources */, 50ABC00D1926664800A911A9 /* CCFileUtils.cpp in Sources */, - 50ABBE4D1925AB6F00A911A9 /* CCEventCustom.cpp in Sources */, 4DED486C1DFFA4AF0070C5C4 /* b2MouseJoint.cpp in Sources */, - BAFF7D5A1D5C1CF80051B92F /* Attachment.c in Sources */, - A63CF0071CD9CF3500A6971D /* CCUIMultilineTextField.m in Sources */, + 46FDDBA3202ADDCE00931238 /* pvr.cpp in Sources */, + 46FDDBE3202ADDCE00931238 /* CCData.cpp in Sources */, 1A28FF731F20AFAB007A1D9D /* SRHash.m in Sources */, - 50ABBE9F1925AB6F00A911A9 /* CCScheduler.cpp in Sources */, + 46FDDAB3202ACC6A00931238 /* VertexBuffer.cpp in Sources */, 4DED48601DFFA4AF0070C5C4 /* b2GearJoint.cpp in Sources */, 50ABC0151926664800A911A9 /* CCImage.cpp in Sources */, - 50ABBE231925AB6F00A911A9 /* base64.cpp in Sources */, - A6F0D7A11C2796020029CC44 /* CCStencilStateManager.cpp in Sources */, - 15AE1BB519AADFEF00C27E9E /* SocketIO.cpp in Sources */, 4DED48341DFFA4AF0070C5C4 /* b2ChainAndCircleContact.cpp in Sources */, - 50ABBE5D1925AB6F00A911A9 /* CCEventListener.cpp in Sources */, 4DED47E21DFFA4AF0070C5C4 /* b2Distance.cpp in Sources */, - FA6F1B771D80F858007DD223 /* BaseObject.cpp in Sources */, - BA679B3C1CEC373000F875FA /* Manifest.cpp in Sources */, - BAFF7D9E1D5C1CF80051B92F /* RegionAttachment.c in Sources */, + 46FDDAD3202ACC6A00931238 /* Texture2D.cpp in Sources */, + 46FDDB6F202ADDCE00931238 /* ZipUtils.cpp in Sources */, 1A28FF871F20AFAB007A1D9D /* SRSIMDHelpers.m in Sources */, 50ABBD601925AB0000A911A9 /* Vec4.cpp in Sources */, 4DED47D41DFFA4AF0070C5C4 /* b2BroadPhase.cpp in Sources */, - 50ABC05F1926664800A911A9 /* CCApplication-mac.mm in Sources */, + 46FDDA93202ACC6A00931238 /* Technique.cpp in Sources */, + 46FDDBFD202ADDCE00931238 /* CCValue.cpp in Sources */, ED3057A11BEC77D50083C3ED /* xxhash.c in Sources */, 50ABBD381925AB0000A911A9 /* CCAffineTransform.cpp in Sources */, - BAFF7D561D5C1CF80051B92F /* AtlasAttachmentLoader.c in Sources */, + 46FDDA6F202ACC6A00931238 /* Pass.cpp in Sources */, 1A28FF8B1F20AFAB007A1D9D /* SRURLUtilities.m in Sources */, ED3057881BEC773E0083C3ED /* tinyxml2.cpp in Sources */, 4DED47DA1DFFA4AF0070C5C4 /* b2CollideEdge.cpp in Sources */, - 15AE1B6B19AADA9900C27E9E /* UIWidget.cpp in Sources */, - 50ABBE931925AB6F00A911A9 /* CCProfiling.cpp in Sources */, + 46FDDA95202ACC6A00931238 /* RendererUtils.cpp in Sources */, 1A28FF9D1F20AFAB007A1D9D /* SRWebSocket.m in Sources */, - 1ABA68AE1888D700007D1BB4 /* CCFontCharMap.cpp in Sources */, + 46FDDBA1202ADDCE00931238 /* ObjectFactory.cpp in Sources */, + 46FDDB8F202ADDCE00931238 /* ccUtils.cpp in Sources */, 1A28FF931F20AFAB007A1D9D /* NSURLRequest+SRWebSocket.m in Sources */, ); runOnlyForDeploymentPostprocessing = 0; @@ -5291,353 +2585,160 @@ buildActionMask = 2147483647; files = ( ED30578D1BEC77550083C3ED /* unzip.cpp in Sources */, - BAFF7D7F1D5C1CF80051B92F /* extension.c in Sources */, - 15AE1B9819AADAA100C27E9E /* UIVideoPlayer-ios.mm in Sources */, - FA6F1B521D80F858007DD223 /* WorldClock.cpp in Sources */, + 46FDDA9E202ACC6A00931238 /* BaseRenderer.cpp in Sources */, + 46FDDAC6202ACC6A00931238 /* RenderTarget.cpp in Sources */, 1A28FF601F20AFAB007A1D9D /* SRProxyConnect.m in Sources */, - 2986667F18B1B246000E39CA /* CCTweenFunction.cpp in Sources */, - FA6F1B701D80F858007DD223 /* CCSlot.cpp in Sources */, - 50ABBDA01925AB4100A911A9 /* CCGroupCommand.cpp in Sources */, 1A28FF901F20AFAB007A1D9D /* NSRunLoop+SRWebSocket.m in Sources */, 50ABC0161926664800A911A9 /* CCImage.cpp in Sources */, - B230ED7219B417AE00364AA8 /* CCTrianglesCommand.cpp in Sources */, + 46FDDC50202AEAC500931238 /* WebGLFormats.cpp in Sources */, + 46FDDBA4202ADDCE00931238 /* pvr.cpp in Sources */, 4DED47DD1DFFA4AF0070C5C4 /* b2CollidePolygon.cpp in Sources */, - 15AE1B9019AADA9A00C27E9E /* UIWidget.cpp in Sources */, - ED9C6A9518599AD8000A5232 /* CCNodeGrid.cpp in Sources */, - B276EF621988D1D500CD400F /* CCVertexIndexData.cpp in Sources */, + 46FDDAB6202ACC6A00931238 /* Program.cpp in Sources */, 4DED47DB1DFFA4AF0070C5C4 /* b2CollideEdge.cpp in Sources */, - 50ABBE561925AB6F00A911A9 /* CCEventFocus.cpp in Sources */, - 503DD8E11926736A00CD74DD /* CCApplication-ios.mm in Sources */, - FA6F1B781D80F858007DD223 /* BaseObject.cpp in Sources */, + 46FDDAC2202ACC6A00931238 /* Texture.cpp in Sources */, 50ABC01A1926664800A911A9 /* CCSAXParser.cpp in Sources */, - B2165EEA19921124000BE3E6 /* CCPrimitiveCommand.cpp in Sources */, 4DED48351DFFA4AF0070C5C4 /* b2ChainAndCircleContact.cpp in Sources */, 4DED486D1DFFA4AF0070C5C4 /* b2MouseJoint.cpp in Sources */, - BAFF7D671D5C1CF80051B92F /* Bone.c in Sources */, - 1A8D25521F39C4E4002CC0A8 /* WebSocket-apple.mm in Sources */, - 1A75DC181DFE3C7700A271DF /* AudioDecoder.mm in Sources */, - BAFF7D9B1D5C1CF80051B92F /* PathConstraintData.c in Sources */, - FA6F1B961D80F858007DD223 /* ArmatureData.cpp in Sources */, 503DD8EE1926736A00CD74DD /* CCImage-ios.mm in Sources */, - 50ABBD941925AB4100A911A9 /* CCGLProgramState.cpp in Sources */, ED30578B1BEC774D0083C3ED /* ioapi_mem.cpp in Sources */, - FA6F1B421D80F858007DD223 /* Animation.cpp in Sources */, - B257B44F1989D5E800D9A687 /* CCPrimitive.cpp in Sources */, - 4DFA4C181CBCE34100E3B736 /* CCScale9Sprite.cpp in Sources */, 1A28FF9A1F20AFAB007A1D9D /* SRSecurityPolicy.m in Sources */, - 50ABBE281925AB6F00A911A9 /* CCAutoreleasePool.cpp in Sources */, - BAFF7D531D5C1CF80051B92F /* Atlas.c in Sources */, - 1A570062180BC5A10088DEC7 /* CCAction.cpp in Sources */, - 1A570066180BC5A10088DEC7 /* CCActionCamera.cpp in Sources */, 4DED47E31DFFA4AF0070C5C4 /* b2Distance.cpp in Sources */, - 4DC06BE81E8A68D400CA08B1 /* CCPhysicsWorldManifoldWrapper.cpp in Sources */, 1A28FF581F20AFAB007A1D9D /* SRIOConsumerPool.m in Sources */, - B276EF661988D1D500CD400F /* CCVertexIndexBuffer.cpp in Sources */, ED30579E1BEC77BD0083C3ED /* ConvertUTFWrapper.cpp in Sources */, 1A28FF801F20AFAB007A1D9D /* SRMutex.m in Sources */, - 1A57006A180BC5A10088DEC7 /* CCActionCatmullRom.cpp in Sources */, - BAFF7DA31D5C1CF80051B92F /* Skeleton.c in Sources */, - BAFF7D4F1D5C1CF80051B92F /* AnimationStateData.c in Sources */, - BA679B391CEC373000F875FA /* CCEventListenerAssetsManagerEx.cpp in Sources */, - BAFF7D7B1D5C1CF80051B92F /* EventData.c in Sources */, - 1A57006E180BC5A10088DEC7 /* CCActionEase.cpp in Sources */, - 50ABBD8C1925AB4100A911A9 /* CCGLProgram.cpp in Sources */, - 1A570072180BC5A10088DEC7 /* CCActionGrid.cpp in Sources */, 4DED47E71DFFA4AF0070C5C4 /* b2DynamicTree.cpp in Sources */, ED3057C21BEC78A80083C3ED /* xxhash.c in Sources */, - 52B47A301A5349A3004E4C60 /* HttpClient-apple.mm in Sources */, - FAC8F2601D339EBF0061CEDD /* CCTMXLayer.cpp in Sources */, ED30578C1BEC77510083C3ED /* ioapi.cpp in Sources */, 4DED48411DFFA4AF0070C5C4 /* b2Contact.cpp in Sources */, - FA6F1B841D80F858007DD223 /* BaseFactory.cpp in Sources */, - DABC9FAA19E7DFA900FA252C /* CCClippingRectangleNode.cpp in Sources */, 4DED48791DFFA4AF0070C5C4 /* b2RevoluteJoint.cpp in Sources */, 4DED47D91DFFA4AF0070C5C4 /* b2CollideCircle.cpp in Sources */, - 50ABBE621925AB6F00A911A9 /* CCEventListenerAcceleration.cpp in Sources */, - 292DB13E19B4574100A80320 /* UIEditBox.cpp in Sources */, - 50ABBE7E1925AB6F00A911A9 /* CCEventTouch.cpp in Sources */, - FA6F1B601D80F858007DD223 /* Slot.cpp in Sources */, + 46FDDAE4202ACC6B00931238 /* GFX.cpp in Sources */, 4DED48491DFFA4AF0070C5C4 /* b2EdgeAndCircleContact.cpp in Sources */, - BAFF7D6F1D5C1CF80051B92F /* BoundingBoxAttachment.c in Sources */, - 4D2E690C1CC543B40032DD5C /* Triangulate.cpp in Sources */, 4DED48651DFFA4AF0070C5C4 /* b2Joint.cpp in Sources */, - 50ABBE6E1925AB6F00A911A9 /* CCEventListenerKeyboard.cpp in Sources */, ED30578A1BEC77460083C3ED /* tinyxml2.cpp in Sources */, 4DED48311DFFA4AF0070C5C4 /* b2WorldCallbacks.cpp in Sources */, - 50CB247C19D9C5A100687767 /* AudioEngine-inl.mm in Sources */, - 50ABBE461925AB6F00A911A9 /* CCEvent.cpp in Sources */, - 50ABBEA01925AB6F00A911A9 /* CCScheduler.cpp in Sources */, - 50ABBE4E1925AB6F00A911A9 /* CCEventCustom.cpp in Sources */, - 4DC06BEE1E8B604B00CA08B1 /* CCPhysicsManifoldWrapper.cpp in Sources */, - 50ABBE761925AB6F00A911A9 /* CCEventListenerTouch.cpp in Sources */, - 50ABBE5A1925AB6F00A911A9 /* CCEventKeyboard.cpp in Sources */, - 1A570076180BC5A10088DEC7 /* CCActionGrid3D.cpp in Sources */, - FA6F1BA61D80F858007DD223 /* DataParser.cpp in Sources */, + 46FDDBFC202ADDCE00931238 /* ccCArray.cpp in Sources */, + 46FDDB7C202ADDCE00931238 /* CCRef.cpp in Sources */, + 46FDDAB2202ACC6A00931238 /* DeviceGraphics.cpp in Sources */, + 46FDDBFA202ADDCE00931238 /* etc1.cpp in Sources */, + 46FDDA88202ACC6A00931238 /* View.cpp in Sources */, 50ABBD551925AB0000A911A9 /* TransformUtils.cpp in Sources */, 4DED480B1DFFA4AF0070C5C4 /* b2Math.cpp in Sources */, - 1A57007A180BC5A10088DEC7 /* CCActionInstant.cpp in Sources */, - 4DC06BD41E8A68D400CA08B1 /* CCPhysicsContactListener.cpp in Sources */, - FA6F1B4E1D80F858007DD223 /* TimelineState.cpp in Sources */, - 50ABBEC01925AB6F00A911A9 /* CCValue.cpp in Sources */, 50ABBD591925AB0000A911A9 /* Vec2.cpp in Sources */, 4DED487D1DFFA4AF0070C5C4 /* b2RopeJoint.cpp in Sources */, 1A28FF681F20AFAB007A1D9D /* SRPinningSecurityPolicy.m in Sources */, - BA679B3D1CEC373000F875FA /* Manifest.cpp in Sources */, 1A28FF9E1F20AFAB007A1D9D /* SRWebSocket.m in Sources */, + 46FDDA9A202ACC6A00931238 /* Model.cpp in Sources */, 1A37E9C6200DD0680078AF72 /* CCReachability.cpp in Sources */, - 50ABBE421925AB6F00A911A9 /* CCDirector.cpp in Sources */, - BAFF7D831D5C1CF80051B92F /* IkConstraint.c in Sources */, - BA679B311CEC373000F875FA /* AssetsManagerEx.cpp in Sources */, - 1A57007E180BC5A10088DEC7 /* CCActionInterval.cpp in Sources */, - 4DC06BD01E8A68D400CA08B1 /* CCPhysicsAABBQueryCallback.cpp in Sources */, - 1A570082180BC5A10088DEC7 /* CCActionManager.cpp in Sources */, - 4D6CF4381E83AAD5003327D4 /* CCCameraNode.cpp in Sources */, - A0534A681B872FFD006B03E5 /* CCDownloader-apple.mm in Sources */, - FA6F1BA21D80F858007DD223 /* TimelineData.cpp in Sources */, - 1A570086180BC5A10088DEC7 /* CCActionPageTurn3D.cpp in Sources */, - 1A57008A180BC5A10088DEC7 /* CCActionProgressTimer.cpp in Sources */, - FA6F1BAA1D80F858007DD223 /* JSONDataParser.cpp in Sources */, - 50ABBED81925AB6F00A911A9 /* ZipUtils.cpp in Sources */, - 15AE1B9219AADA9A00C27E9E /* UIHelper.cpp in Sources */, - A6F0D7A31C2796060029CC44 /* CCStencilStateManager.cpp in Sources */, + 46FDDBA2202ADDCE00931238 /* ObjectFactory.cpp in Sources */, BA68D7991D62F4B600B7A3F9 /* clipper.cpp in Sources */, - 1A57008E180BC5A10088DEC7 /* CCActionTiledGrid.cpp in Sources */, - FA6F1B9A1D80F858007DD223 /* DragonBonesData.cpp in Sources */, + 46FDDB8C202ADDCE00931238 /* CCAutoreleasePool.cpp in Sources */, + 46FDDABA202ACC6A00931238 /* FrameBuffer.cpp in Sources */, 4DED48511DFFA4AF0070C5C4 /* b2PolygonAndCircleContact.cpp in Sources */, - 1A570092180BC5A10088DEC7 /* CCActionTween.cpp in Sources */, - 1A570099180BC5C10088DEC7 /* CCAtlasNode.cpp in Sources */, + 46FDDAE6202ACC6B00931238 /* IndexBuffer.cpp in Sources */, 4DED48691DFFA4AF0070C5C4 /* b2MotorJoint.cpp in Sources */, + 46FDDB8E202ADDCE00931238 /* ccTypes.cpp in Sources */, 50ABBD4D1925AB0000A911A9 /* MathUtil.cpp in Sources */, - 1A57009F180BC5D20088DEC7 /* CCNode.cpp in Sources */, BA68D78A1D62F4A500B7A3F9 /* cdt.cc in Sources */, - 1A57010F180BC8EE0088DEC7 /* CCDrawingPrimitives.cpp in Sources */, - 1AD473AE1EAD9A5600202582 /* Uri.cpp in Sources */, - 1A570113180BC8EE0088DEC7 /* CCDrawNode.cpp in Sources */, - 1A57011C180BC90D0088DEC7 /* CCGrabber.cpp in Sources */, - 1A570120180BC90D0088DEC7 /* CCGrid.cpp in Sources */, - 1A57019E180BCB590088DEC7 /* CCFont.cpp in Sources */, - 503DD8E21926736A00CD74DD /* CCCommon-ios.mm in Sources */, + 46FDDB90202ADDCE00931238 /* ccUtils.cpp in Sources */, 4DED48711DFFA4AF0070C5C4 /* b2PrismaticJoint.cpp in Sources */, 4DED48851DFFA4AF0070C5C4 /* b2WheelJoint.cpp in Sources */, - 292DB14A19B4574100A80320 /* UIEditBoxImpl-ios.mm in Sources */, - 1A5701A2180BCB590088DEC7 /* CCFontAtlas.cpp in Sources */, 50ABC00E1926664800A911A9 /* CCFileUtils.cpp in Sources */, - 299CF1FC19A434BC00C378C1 /* ccRandom.cpp in Sources */, - FA6F1B6C1D80F858007DD223 /* CCFactory.cpp in Sources */, - BAFF7DBB1D5C1CF80051B92F /* SkeletonRenderer.cpp in Sources */, - 50ABBE241925AB6F00A911A9 /* base64.cpp in Sources */, - 1A5701A6180BCB590088DEC7 /* CCFontAtlasCache.cpp in Sources */, - 1A5701B2180BCB590088DEC7 /* CCFontFNT.cpp in Sources */, - 1A5701B6180BCB590088DEC7 /* CCFontFreeType.cpp in Sources */, - BAFF7DD51D5C1CF80051B92F /* TransformConstraintData.c in Sources */, BA68D78E1D62F4A500B7A3F9 /* sweep.cc in Sources */, - 50ABBEAC1925AB6F00A911A9 /* ccTypes.cpp in Sources */, - BAFF7D5F1D5C1CF80051B92F /* AttachmentLoader.c in Sources */, - BA679B351CEC373000F875FA /* CCEventAssetsManagerEx.cpp in Sources */, - 1A5701BA180BCB5A0088DEC7 /* CCLabel.cpp in Sources */, - BAFF7D971D5C1CF80051B92F /* PathConstraint.c in Sources */, - BAFF7D771D5C1CF80051B92F /* Event.c in Sources */, - 4D2E69081CC543B40032DD5C /* CCGraphicsNode.cpp in Sources */, - 4DC06BE01E8A68D400CA08B1 /* CCPhysicsRayCastCallback.cpp in Sources */, - 1A5701BE180BCB5A0088DEC7 /* CCLabelAtlas.cpp in Sources */, + 46FDDA94202ACC6A00931238 /* Technique.cpp in Sources */, + 46FDDA72202ACC6A00931238 /* Scene.cpp in Sources */, 4DED47F31DFFA4AF0070C5C4 /* b2CircleShape.cpp in Sources */, - 15FB20751AE7BF8600C31518 /* CCAutoPolygon.cpp in Sources */, - A0E749F81BA8FD7F001A8332 /* UIEditBoxImpl-common.cpp in Sources */, 4DED48611DFFA4AF0070C5C4 /* b2GearJoint.cpp in Sources */, - FAC8F2621D339EC50061CEDD /* CCTMXTiledMap.cpp in Sources */, - 1A5701C8180BCB5A0088DEC7 /* CCLabelTextFormatter.cpp in Sources */, - 291901461B05895600F8B4BA /* CCNinePatchImageParser.cpp in Sources */, - BAFF7D571D5C1CF80051B92F /* AtlasAttachmentLoader.c in Sources */, - 299754F5193EC95400A54AC3 /* ObjectFactory.cpp in Sources */, - 1A5701DF180BCB8C0088DEC7 /* CCLayer.cpp in Sources */, + 46FDDBB4202ADDCE00931238 /* CCIMEDispatcher.cpp in Sources */, 4DED48271DFFA4AF0070C5C4 /* b2Island.cpp in Sources */, 4DED48131DFFA4AF0070C5C4 /* b2StackAllocator.cpp in Sources */, - 50ABBDBE1925AB4100A911A9 /* CCTextureCache.cpp in Sources */, + 46FDDAD6202ACC6A00931238 /* GraphicsHandle.cpp in Sources */, 4DED48891DFFA4AF0070C5C4 /* b2Rope.cpp in Sources */, - 1A5701E3180BCB8C0088DEC7 /* CCScene.cpp in Sources */, 50ABBD611925AB0000A911A9 /* Vec4.cpp in Sources */, - 50ABBD9C1925AB4100A911A9 /* ccGLStateCache.cpp in Sources */, - 1A5701E7180BCB8C0088DEC7 /* CCTransition.cpp in Sources */, - 29394CF319B01DBA00D2DE1A /* UIWebView.mm in Sources */, - 50ABC01E1926664800A911A9 /* CCThread.cpp in Sources */, - 4D2816671E8CBB7200F26B06 /* CCPhysicsContactImpulse.cpp in Sources */, - 2980F0271BA9A5550059E678 /* CCUISingleLineTextField.mm in Sources */, - 1A5701EB180BCB8C0088DEC7 /* CCTransitionPageTurn.cpp in Sources */, - 1A5701EF180BCB8C0088DEC7 /* CCTransitionProgress.cpp in Sources */, - BAFF7DC71D5C1CF80051B92F /* SlotData.c in Sources */, - BAFF7DCB1D5C1CF80051B92F /* spine-cocos2dx.cpp in Sources */, - 1A5701F8180BCBAD0088DEC7 /* CCMenu.cpp in Sources */, + 46FDDB9A202ADDCE00931238 /* ccUTF8.cpp in Sources */, + 46FDDA70202ACC6A00931238 /* Pass.cpp in Sources */, + 46FDDBBA202ADDCE00931238 /* CCNS.cpp in Sources */, 1A28FF741F20AFAB007A1D9D /* SRHash.m in Sources */, + 46FDDB70202ADDCE00931238 /* ZipUtils.cpp in Sources */, 50ABBD511925AB0000A911A9 /* Quaternion.cpp in Sources */, - 1A5701FC180BCBAD0088DEC7 /* CCMenuItem.cpp in Sources */, - FA6F1B5A1D80F858007DD223 /* Bone.cpp in Sources */, 4DED485D1DFFA4AF0070C5C4 /* b2FrictionJoint.cpp in Sources */, - FA6F1B461D80F858007DD223 /* AnimationState.cpp in Sources */, 50ABBD491925AB0000A911A9 /* Mat4.cpp in Sources */, - FA6F1B661D80F858007DD223 /* CCArmatureDisplay.cpp in Sources */, - 1A570203180BCBD40088DEC7 /* CCClippingNode.cpp in Sources */, + 46FDDACA202ACC6A00931238 /* RenderBuffer.cpp in Sources */, 4DED484D1DFFA4AF0070C5C4 /* b2EdgeAndPolygonContact.cpp in Sources */, - 1A570209180BCBDF0088DEC7 /* CCMotionStreak.cpp in Sources */, - BAFF7D5B1D5C1CF80051B92F /* Attachment.c in Sources */, - BAFF7D871D5C1CF80051B92F /* IkConstraintData.c in Sources */, - 1A570211180BCBF40088DEC7 /* CCProgressTimer.cpp in Sources */, - 503DD8ED1926736A00CD74DD /* CCGLViewImpl-ios.mm in Sources */, - 1A570215180BCBF40088DEC7 /* CCRenderTexture.cpp in Sources */, - FA6F1B921D80F858007DD223 /* AnimationData.cpp in Sources */, - 1A570222180BCC1A0088DEC7 /* CCParticleBatchNode.cpp in Sources */, + 46FDDC26202AEAC500931238 /* WebGLTexelConversions.cpp in Sources */, + 46FDDB4C202ADDCE00931238 /* ccFPSImages.c in Sources */, + 46FDDAD4202ACC6A00931238 /* Texture2D.cpp in Sources */, 4DED48751DFFA4AF0070C5C4 /* b2PulleyJoint.cpp in Sources */, - BAFF7DA71D5C1CF80051B92F /* SkeletonAnimation.cpp in Sources */, - 1A570226180BCC1A0088DEC7 /* CCParticleExamples.cpp in Sources */, + 46FDDA8C202ACC6A00931238 /* ForwardRenderer.cpp in Sources */, ED30579D1BEC77B90083C3ED /* ConvertUTF.c in Sources */, - BA8122AC1D77C4160010BEE9 /* CCLabelTTF.cpp in Sources */, - 1A57022A180BCC1A0088DEC7 /* CCParticleSystem.cpp in Sources */, - 15AE1BBD19AADFF000C27E9E /* SocketIO.cpp in Sources */, - BAFF7DAB1D5C1CF80051B92F /* SkeletonBatch.cpp in Sources */, 4DED483D1DFFA4AF0070C5C4 /* b2CircleContact.cpp in Sources */, - B24AA98A195A675C007B4522 /* CCFastTMXTiledMap.cpp in Sources */, - BAFF7D4B1D5C1CF80051B92F /* AnimationState.c in Sources */, - 29394CF719B01DBA00D2DE1A /* UIWebViewImpl-ios.mm in Sources */, - B24AA986195A675C007B4522 /* CCFastTMXLayer.cpp in Sources */, - 1A57022E180BCC1A0088DEC7 /* CCParticleSystemQuad.cpp in Sources */, - 50ABBD901925AB4100A911A9 /* CCGLProgramCache.cpp in Sources */, - 4DC06BE41E8A68D400CA08B1 /* CCPhysicsUtils.cpp in Sources */, + 46FDDAA4202ACC6A00931238 /* InputAssembler.cpp in Sources */, 1A28FF941F20AFAB007A1D9D /* NSURLRequest+SRWebSocket.m in Sources */, 4DED481B1DFFA4AF0070C5C4 /* b2Body.cpp in Sources */, - BAFF7D631D5C1CF80051B92F /* AttachmentVertices.cpp in Sources */, ED3057931BEC77790083C3ED /* edtaa3func.cpp in Sources */, - 4DC06BDC1E8A68D400CA08B1 /* CCPhysicsDebugDraw.cpp in Sources */, - BAFF7D9F1D5C1CF80051B92F /* RegionAttachment.c in Sources */, + 46FDDBFE202ADDCE00931238 /* CCValue.cpp in Sources */, 1A28FF7C1F20AFAB007A1D9D /* SRLog.m in Sources */, - 1A57027F180BCC900088DEC7 /* CCSprite.cpp in Sources */, 1A28FF641F20AFAB007A1D9D /* SRRunLoopThread.m in Sources */, 1A28FF6C1F20AFAB007A1D9D /* SRConstants.m in Sources */, - 1A570283180BCC900088DEC7 /* CCSpriteBatchNode.cpp in Sources */, + 46FDDAE2202ACC6A00931238 /* GFXUtils.cpp in Sources */, 1A9F0F981F301DE200A499E1 /* b2ObjectDestroyNotifier.cpp in Sources */, - 1A570287180BCC900088DEC7 /* CCSpriteFrame.cpp in Sources */, - FA6F1B741D80F858007DD223 /* CCTextureData.cpp in Sources */, - 2980F02A1BA9A5550059E678 /* UITextField+CCUITextInput.mm in Sources */, 4DED48551DFFA4AF0070C5C4 /* b2PolygonContact.cpp in Sources */, - BAFF7D8F1D5C1CF80051B92F /* MeshAttachment.c in Sources */, - 1A57028B180BCC900088DEC7 /* CCSpriteFrameCache.cpp in Sources */, - BAFF7D731D5C1CF80051B92F /* Cocos2dAttachmentLoader.cpp in Sources */, - 1A570293180BCCAB0088DEC7 /* CCAnimation.cpp in Sources */, + 46FDDA7A202ACC6A00931238 /* Camera.cpp in Sources */, 4DED48591DFFA4AF0070C5C4 /* b2DistanceJoint.cpp in Sources */, - 15AE1B8C19AADA9A00C27E9E /* UIScale9Sprite.cpp in Sources */, 4DED47FB1DFFA4AF0070C5C4 /* b2PolygonShape.cpp in Sources */, - BAFF7D471D5C1CF80051B92F /* Animation.c in Sources */, - 1A570297180BCCAB0088DEC7 /* CCAnimationCache.cpp in Sources */, 4DED482D1DFFA4AF0070C5C4 /* b2World.cpp in Sources */, - 50ABBE321925AB6F00A911A9 /* CCConfiguration.cpp in Sources */, - 1A5702C9180BCE370088DEC7 /* CCTextFieldTTF.cpp in Sources */, - 1A5702EB180BCE750088DEC7 /* CCTileMapAtlas.cpp in Sources */, - BAFF7DC31D5C1CF80051B92F /* Slot.c in Sources */, - 1A5702F3180BCE750088DEC7 /* CCTMXObjectGroup.cpp in Sources */, + 46FDDAA0202ACC6A00931238 /* ProgramLib.cpp in Sources */, 50ABBD3D1925AB0000A911A9 /* CCGeometry.cpp in Sources */, 4DED47EB1DFFA4AF0070C5C4 /* b2TimeOfImpact.cpp in Sources */, - 50ABBEC61925AB6F00A911A9 /* etc1.cpp in Sources */, - 50ABBE8C1925AB6F00A911A9 /* CCNS.cpp in Sources */, - 50ABBDAE1925AB4100A911A9 /* CCRenderer.cpp in Sources */, - 50ABBDBA1925AB4100A911A9 /* CCTextureAtlas.cpp in Sources */, - 1A5702FB180BCE750088DEC7 /* CCTMXXMLParser.cpp in Sources */, 1A28FF8C1F20AFAB007A1D9D /* SRURLUtilities.m in Sources */, - 1A570301180BCE890088DEC7 /* CCParallaxNode.cpp in Sources */, - 1A57030D180BCF190088DEC7 /* CCComponent.cpp in Sources */, - 1AFFCD771F7A59B200628F2C /* CCThreadPool.cpp in Sources */, - 464AD6E6197EBB1400E502D8 /* pvr.cpp in Sources */, 1A28FF541F20AFAB007A1D9D /* SRIOConsumer.m in Sources */, - 1A570311180BCF190088DEC7 /* CCComponentContainer.cpp in Sources */, - 50ABBE2C1925AB6F00A911A9 /* ccCArray.cpp in Sources */, - 50ABC0061926664800A911A9 /* CCThread-apple.mm in Sources */, - 50ABBDB61925AB4100A911A9 /* CCTexture2D.cpp in Sources */, - BAFF7D931D5C1CF80051B92F /* PathAttachment.c in Sources */, - 50ABBD881925AB4100A911A9 /* CCCustomCommand.cpp in Sources */, - BAFF7DAF1D5C1CF80051B92F /* SkeletonBounds.c in Sources */, - 2980F02C1BA9A5550059E678 /* UITextView+CCUITextInput.mm in Sources */, - 50ABBE941925AB6F00A911A9 /* CCProfiling.cpp in Sources */, - 50ABBE5E1925AB6F00A911A9 /* CCEventListener.cpp in Sources */, - BAFF7D6B1D5C1CF80051B92F /* BoneData.c in Sources */, - 50ABBEA81925AB6F00A911A9 /* CCTouch.cpp in Sources */, + 46FDDAAA202ACC6A00931238 /* Types.cpp in Sources */, 503DD8E91926736A00CD74DD /* CCES2Renderer-ios.m in Sources */, 5027253D190BF1B900AAF4ED /* cocos2d.cpp in Sources */, 1A28FF781F20AFAB007A1D9D /* SRHTTPConnectMessage.m in Sources */, - 50ABBE6A1925AB6F00A911A9 /* CCEventListenerFocus.cpp in Sources */, - 50ABBE661925AB6F00A911A9 /* CCEventListenerCustom.cpp in Sources */, - 503DD8F81926B0DB00CD74DD /* CCIMEDispatcher.cpp in Sources */, 1A28FF881F20AFAB007A1D9D /* SRSIMDHelpers.m in Sources */, - 50ABBDB21925AB4100A911A9 /* ccShaders.cpp in Sources */, 50ABBD451925AB0000A911A9 /* CCVertex.cpp in Sources */, - 50ABBEB01925AB6F00A911A9 /* CCUserDefault.cpp in Sources */, 294D7D9D1D0E93A2002CE7B7 /* CCDevice-apple.mm in Sources */, - 50ABBE521925AB6F00A911A9 /* CCEventDispatcher.cpp in Sources */, - 52B47A2F1A5349A3004E4C60 /* HttpAsynConnection-apple.m in Sources */, 4DED48391DFFA4AF0070C5C4 /* b2ChainAndPolygonContact.cpp in Sources */, 50ABBD391925AB0000A911A9 /* CCAffineTransform.cpp in Sources */, - 50ABBD841925AB4100A911A9 /* CCBatchCommand.cpp in Sources */, 4DED480F1DFFA4AF0070C5C4 /* b2Settings.cpp in Sources */, - 50ABBDA81925AB4100A911A9 /* CCRenderCommand.cpp in Sources */, - 50ABBEA41925AB6F00A911A9 /* CCScriptSupport.cpp in Sources */, + 46FDDC38202AEAC500931238 /* Assertions.cpp in Sources */, 503DD8E71926736A00CD74DD /* CCEAGLView-ios.mm in Sources */, - 3E2BDAEC19C0436F0055CDCD /* AudioEngine.cpp in Sources */, - 52B47A311A5349A3004E4C60 /* HttpCookie.cpp in Sources */, - 50ABBDA41925AB4100A911A9 /* CCQuadCommand.cpp in Sources */, 4DED48811DFFA4AF0070C5C4 /* b2WeldJoint.cpp in Sources */, + 46FDDBAA202ADDCE00931238 /* CCProfiling.cpp in Sources */, + 46FDDA8A202ACC6A00931238 /* Effect.cpp in Sources */, 4DED47F71DFFA4AF0070C5C4 /* b2EdgeShape.cpp in Sources */, - FA6F1B9E1D80F858007DD223 /* FrameData.cpp in Sources */, - BAFF7DB71D5C1CF80051B92F /* SkeletonJson.c in Sources */, - 1AAF5850180E40B9000584C8 /* LocalStorage.cpp in Sources */, - FA6F1B801D80F858007DD223 /* EventObject.cpp in Sources */, - BAFF7D8B1D5C1CF80051B92F /* Json.c in Sources */, + 46FDDB72202ADDCE00931238 /* base64.cpp in Sources */, + 46FDDA7E202ACC6A00931238 /* Light.cpp in Sources */, BA68D7861D62F4A500B7A3F9 /* advancing_front.cc in Sources */, - FA6F1B561D80F858007DD223 /* Armature.cpp in Sources */, - 1A9DCA28180E6955007A3AD4 /* CCGLBufferedNode.cpp in Sources */, - A6E018661CB7A7E000EC1419 /* CCDownloader.cpp in Sources */, - BAFF7DD11D5C1CF80051B92F /* TransformConstraint.c in Sources */, - 50CB248019D9C5A100687767 /* AudioPlayer.mm in Sources */, + 46FDDBE4202ADDCE00931238 /* CCData.cpp in Sources */, + 46FDDAB4202ACC6A00931238 /* VertexBuffer.cpp in Sources */, 4DED47DF1DFFA4AF0070C5C4 /* b2Collision.cpp in Sources */, - 50ABBE9A1925AB6F00A911A9 /* CCRef.cpp in Sources */, 4DED48011DFFA4AF0070C5C4 /* b2BlockAllocator.cpp in Sources */, - 2980F0251BA9A5550059E678 /* CCUIMultilineTextField.mm in Sources */, - 15AE1B9519AADA9A00C27E9E /* CocosGUI.cpp in Sources */, + 46FDDB94202ADDCE00931238 /* TGAlib.cpp in Sources */, 4DED48171DFFA4AF0070C5C4 /* b2Timer.cpp in Sources */, - B63990CD1A490AFE00B07923 /* CCAsyncTaskPool.cpp in Sources */, - 50ABBE361925AB6F00A911A9 /* CCConsole.cpp in Sources */, 4DED47D51DFFA4AF0070C5C4 /* b2BroadPhase.cpp in Sources */, 503DD8E51926736A00CD74DD /* CCDirectorCaller-ios.mm in Sources */, + 46FDDB66202ADDCE00931238 /* ccRandom.cpp in Sources */, 1A28FF841F20AFAB007A1D9D /* SRRandom.m in Sources */, BA68D77E1D62F4A500B7A3F9 /* shapes.cc in Sources */, - BAFF7DD91D5C1CF80051B92F /* VertexAttachment.c in Sources */, - 50CB247819D9C5A100687767 /* AudioCache.mm in Sources */, + 46FDDA96202ACC6A00931238 /* RendererUtils.cpp in Sources */, + 46FDDABC202ACC6A00931238 /* VertexFormat.cpp in Sources */, 50ABBD5D1925AB0000A911A9 /* Vec3.cpp in Sources */, - 50ABC0121926664800A911A9 /* CCGLView.cpp in Sources */, 50ABC0021926664800A911A9 /* CCLock-apple.cpp in Sources */, - FA6F1BAE1D80F858007DD223 /* TextureData.cpp in Sources */, - 50ABBEBC1925AB6F00A911A9 /* ccUtils.cpp in Sources */, - 50ABBE721925AB6F00A911A9 /* CCEventListenerMouse.cpp in Sources */, 4DED48451DFFA4AF0070C5C4 /* b2ContactSolver.cpp in Sources */, - FAC8F66B1E1DF15D002B17E8 /* SkeletonBinary.c in Sources */, BA68D7921D62F4A500B7A3F9 /* sweep_context.cc in Sources */, 50ABC0001926664800A911A9 /* CCFileUtils-apple.mm in Sources */, - 50ABBEB81925AB6F00A911A9 /* ccUTF8.cpp in Sources */, - 50ABBE841925AB6F00A911A9 /* ccFPSImages.c in Sources */, 4DED481F1DFFA4AF0070C5C4 /* b2ContactManager.cpp in Sources */, 4DC57D331F7B840E005B6546 /* xxtea.cpp in Sources */, 4DED48231DFFA4AF0070C5C4 /* b2Fixture.cpp in Sources */, - 50ABBE4A1925AB6F00A911A9 /* CCEventAcceleration.cpp in Sources */, - 2980F0231BA9A5550059E678 /* CCUIEditBoxIOS.mm in Sources */, - 50ABBED01925AB6F00A911A9 /* TGAlib.cpp in Sources */, + 46FDDA8E202ACC6A00931238 /* Config.cpp in Sources */, 503DD8E31926736A00CD74DD /* CCDevice-ios.mm in Sources */, 1A28FF701F20AFAB007A1D9D /* SRError.m in Sources */, 1A28FF501F20AFAB007A1D9D /* SRDelegateController.m in Sources */, - 50ABBEB41925AB6F00A911A9 /* CCUserDefault-apple.mm in Sources */, - 50ABBE3A1925AB6F00A911A9 /* CCData.cpp in Sources */, - 1ABA68AF1888D700007D1BB4 /* CCFontCharMap.cpp in Sources */, - 50ABBE7A1925AB6F00A911A9 /* CCEventMouse.cpp in Sources */, - BAFF7DB31D5C1CF80051B92F /* SkeletonData.c in Sources */, + 46FDDAC0202ACC6A00931238 /* State.cpp in Sources */, 4DED48051DFFA4AF0070C5C4 /* b2Draw.cpp in Sources */, - BAFF7DBF1D5C1CF80051B92F /* Skin.c in Sources */, - 15EFA212198A2BB5000C57D3 /* CCProtectedNode.cpp in Sources */, 4DED47EF1DFFA4AF0070C5C4 /* b2ChainShape.cpp in Sources */, - 50ABBD981925AB4100A911A9 /* CCGLProgramStateCache.cpp in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -5690,7 +2791,7 @@ PRODUCT_NAME = "$(TARGET_NAME)"; SDKROOT = macosx; SKIP_INSTALL = YES; - USER_HEADER_SEARCH_PATHS = "$(SRCROOT)/.. $(SRCROOT)/../cocos $(SRCROOT)/../cocos/editor-support $(SRCROOT)/../external/chipmunk/include/chipmunk $(SRCROOT)/../external $(SRCROOT)/../extensions"; + USER_HEADER_SEARCH_PATHS = "$(SRCROOT)/.. $(SRCROOT)/../cocos $(SRCROOT)/../cocos/renderer $(SRCROOT)/../external $(SRCROOT)/../extensions $(SRCROOT)/../external/sources/firefox/"; }; name = Debug; }; @@ -5735,7 +2836,7 @@ PRODUCT_NAME = "$(TARGET_NAME)"; SDKROOT = macosx; SKIP_INSTALL = YES; - USER_HEADER_SEARCH_PATHS = "$(SRCROOT)/.. $(SRCROOT)/../cocos $(SRCROOT)/../cocos/editor-support $(SRCROOT)/../external/chipmunk/include/chipmunk $(SRCROOT)/../external $(SRCROOT)/../extensions"; + USER_HEADER_SEARCH_PATHS = "$(SRCROOT)/.. $(SRCROOT)/../cocos $(SRCROOT)/../cocos/renderer $(SRCROOT)/../external $(SRCROOT)/../extensions $(SRCROOT)/../external/sources/firefox/"; VALIDATE_PRODUCT = YES; }; name = Release; diff --git a/native/cocos/2d/CCAction.cpp b/native/cocos/2d/CCAction.cpp deleted file mode 100644 index 26e489c628..0000000000 --- a/native/cocos/2d/CCAction.cpp +++ /dev/null @@ -1,356 +0,0 @@ -/**************************************************************************** -Copyright (c) 2008-2010 Ricardo Quesada -Copyright (c) 2010-2012 cocos2d-x.org -Copyright (c) 2011 Zynga Inc. -Copyright (c) 2013-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ - -#include "2d/CCAction.h" -#include "2d/CCActionInterval.h" -#include "2d/CCNode.h" -#include "base/CCDirector.h" -#include "base/ccUTF8.h" - -NS_CC_BEGIN -// -// Action Base Class -// - -Action::Action() -:_originalTarget(nullptr) -,_target(nullptr) -,_tag(Action::INVALID_TAG) -,_flags(0) -{ -#if CC_ENABLE_SCRIPT_BINDING - ScriptEngineProtocol* engine = ScriptEngineManager::getInstance()->getScriptEngine(); - _scriptType = engine != nullptr ? engine->getScriptType() : kScriptTypeNone; -#endif -} - -void Action::sendUpdateEventToScript(float dt, Action *actionObject) -{ -#if CC_ENABLE_SCRIPT_BINDING - if (_scriptType == kScriptTypeJavascript) - { - ScriptEngineManager::sendActionEventToJS(actionObject, kActionUpdate, (void *)&dt); - } -#endif -} - -Action::~Action() -{ - CCLOGINFO("deallocing Action: %p - tag: %i", this, _tag); -} - -std::string Action::description() const -{ - return StringUtils::format("initWithAction(action, speed)) - { - ret->autorelease(); - return ret; - } - CC_SAFE_DELETE(ret); - return nullptr; -} - -bool Speed::initWithAction(ActionInterval *action, float speed) -{ - CCASSERT(action != nullptr, "action must not be NULL"); - if (action == nullptr) - { - log("Speed::initWithAction error: action is nullptr!"); - return false; - } - - action->retain(); - _innerAction = action; -#if CC_ENABLE_GC_FOR_NATIVE_OBJECTS - auto sEngine = ScriptEngineManager::getInstance()->getScriptEngine(); - if (sEngine) - { - sEngine->retainScriptObject(this, _innerAction); - } -#endif // CC_ENABLE_GC_FOR_NATIVE_OBJECTS - _speed = speed; - return true; -} - -Speed *Speed::clone() const -{ - // no copy constructor - if (_innerAction) - return Speed::create(_innerAction->clone(), _speed); - - return nullptr; -} - -void Speed::startWithTarget(Node* target) -{ - if (target && _innerAction) - { - Action::startWithTarget(target); - _innerAction->startWithTarget(target); - } - else - log("Speed::startWithTarget error: target(%p) or _innerAction(%p) is nullptr!", target, _innerAction); -} - -void Speed::stop() -{ - if (_innerAction) - _innerAction->stop(); - - Action::stop(); -} - -void Speed::step(float dt) -{ - _innerAction->step(dt * _speed); -} - -bool Speed::isDone() const -{ - return _innerAction->isDone(); -} - -Speed *Speed::reverse() const -{ - if (_innerAction) - return Speed::create(_innerAction->reverse(), _speed); - - return nullptr; -} - -void Speed::setInnerAction(ActionInterval *action) -{ - if (_innerAction != action) - { -#if CC_ENABLE_GC_FOR_NATIVE_OBJECTS - auto sEngine = ScriptEngineManager::getInstance()->getScriptEngine(); - if (sEngine) - { - sEngine->releaseScriptObject(this, _innerAction); - sEngine->retainScriptObject(this, action); - } -#endif // CC_ENABLE_GC_FOR_NATIVE_OBJECTS - CC_SAFE_RELEASE(_innerAction); - _innerAction = action; - CC_SAFE_RETAIN(_innerAction); - } -} - -// -// Follow -// -Follow::~Follow() -{ - CC_SAFE_RELEASE(_followedNode); -} - -Follow* Follow::create(Node *followedNode, const Rect& rect/* = Rect::ZERO*/) -{ - return createWithOffset(followedNode, 0.0, 0.0,rect); -} - -Follow* Follow::createWithOffset(Node* followedNode,float xOffset,float yOffset,const Rect& rect/*= Rect::ZERO*/){ - Follow *follow = new (std::nothrow) Follow(); - - bool valid; - valid = follow->initWithTargetAndOffset(followedNode, xOffset, yOffset,rect); - - if (follow && valid) - { - follow->autorelease(); - return follow; - } - - delete follow; - return nullptr; -} - -Follow* Follow::clone() const -{ - // no copy constructor - return Follow::createWithOffset(_followedNode, _offsetX,_offsetY,_worldRect); -} - -Follow* Follow::reverse() const -{ - return clone(); -} - -bool Follow::initWithTargetAndOffset(Node *followedNode, float xOffset,float yOffset,const Rect& rect) -{ - CCASSERT(followedNode != nullptr, "FollowedNode can't be NULL"); - if(followedNode == nullptr) - { - log("Follow::initWithTarget error: followedNode is nullptr!"); - return false; - } - - followedNode->retain(); - _followedNode = followedNode; -#if CC_ENABLE_GC_FOR_NATIVE_OBJECTS - auto sEngine = ScriptEngineManager::getInstance()->getScriptEngine(); - if (sEngine) - { - sEngine->retainScriptObject(this, _followedNode); - } -#endif // CC_ENABLE_GC_FOR_NATIVE_OBJECTS - _worldRect = rect; - _boundarySet = !rect.equals(Rect::ZERO); - _boundaryFullyCovered = false; - - Size winSize = Director::getInstance()->getWinSize(); - _fullScreenSize.set(winSize.width, winSize.height); - _halfScreenSize = _fullScreenSize * 0.5f; - _offsetX=xOffset; - _offsetY=yOffset; - _halfScreenSize.x += _offsetX; - _halfScreenSize.y += _offsetY; - - if (_boundarySet) - { - _leftBoundary = -((rect.origin.x+rect.size.width) - _fullScreenSize.x); - _rightBoundary = -rect.origin.x ; - _topBoundary = -rect.origin.y; - _bottomBoundary = -((rect.origin.y+rect.size.height) - _fullScreenSize.y); - - if(_rightBoundary < _leftBoundary) - { - // screen width is larger than world's boundary width - //set both in the middle of the world - _rightBoundary = _leftBoundary = (_leftBoundary + _rightBoundary) / 2; - } - if(_topBoundary < _bottomBoundary) - { - // screen width is larger than world's boundary width - //set both in the middle of the world - _topBoundary = _bottomBoundary = (_topBoundary + _bottomBoundary) / 2; - } - - if( (_topBoundary == _bottomBoundary) && (_leftBoundary == _rightBoundary) ) - { - _boundaryFullyCovered = true; - } - } - - return true; -} - -bool Follow::initWithTarget(Node *followedNode, const Rect& rect /*= Rect::ZERO*/){ - - return initWithTargetAndOffset(followedNode, 0.0, 0.0,rect); - -} -void Follow::step(float dt) -{ - CC_UNUSED_PARAM(dt); - - Vec2 targetWorldPos = _target->convertToWorldSpaceAR(Vec2::ZERO); - Vec2 followedWorldPos = _followedNode->convertToWorldSpaceAR(Vec2::ZERO); - // compute the offset between followed and target node - Vec2 delta = targetWorldPos - followedWorldPos; - Vec2 tempPos = _target->getParent()->convertToNodeSpaceAR(delta + _halfScreenSize); - - if(_boundarySet) - { - // whole map fits inside a single screen, no need to modify the position - unless map boundaries are increased - if(_boundaryFullyCovered) - { - return; - } - - _target->setPosition(clampf(tempPos.x, _leftBoundary, _rightBoundary), - clampf(tempPos.y, _bottomBoundary, _topBoundary)); - } - else - { - _target->setPosition(tempPos); - } - - sendUpdateEventToScript(dt, this); -} - -bool Follow::isDone() const -{ - return ( !_followedNode->isRunning() ); -} - -void Follow::stop() -{ - _target = nullptr; - Action::stop(); -} - -NS_CC_END - diff --git a/native/cocos/2d/CCAction.h b/native/cocos/2d/CCAction.h deleted file mode 100644 index ac29b4825d..0000000000 --- a/native/cocos/2d/CCAction.h +++ /dev/null @@ -1,458 +0,0 @@ -/**************************************************************************** -Copyright (c) 2008-2010 Ricardo Quesada -Copyright (c) 2010-2012 cocos2d-x.org -Copyright (c) 2011 Zynga Inc. -Copyright (c) 2013-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ - -#ifndef __ACTIONS_CCACTION_H__ -#define __ACTIONS_CCACTION_H__ - -#include "base/CCRef.h" -#include "math/CCGeometry.h" -#include "base/CCScriptSupport.h" - -NS_CC_BEGIN - -class Node; - -enum { - kActionUpdate -}; - -/** - * @addtogroup actions - * @{ - */ - -/** - * @brief Base class for Action objects. - */ -class CC_DLL Action : public Ref, public Clonable -{ -public: - /** Default tag used for all the actions. */ - static const int INVALID_TAG = -1; - /** - * @js NA - * @lua NA - */ - virtual std::string description() const; - - /** Returns a clone of action. - * - * @return A clone action. - */ - virtual Action* clone() const - { - CC_ASSERT(0); - return nullptr; - } - - /** Returns a new action that performs the exact reverse of the action. - * - * @return A new action that performs the exact reverse of the action. - * @js NA - */ - virtual Action* reverse() const - { - CC_ASSERT(0); - return nullptr; - } - - /** Return true if the action has finished. - * - * @return Is true if the action has finished. - */ - virtual bool isDone() const; - - /** Called before the action start. It will also set the target. - * - * @param target A certain target. - */ - virtual void startWithTarget(Node *target); - - /** - * Called after the action has finished. It will set the 'target' to nil. - * IMPORTANT: You should never call "Action::stop()" manually. Instead, use: "target->stopAction(action);". - */ - virtual void stop(); - - /** Called every frame with it's delta time, dt in seconds. DON'T override unless you know what you are doing. - * - * @param dt In seconds. - */ - virtual void step(float dt); - - /** - * Called once per frame. time a value between 0 and 1. - - * For example: - * - 0 Means that the action just started. - * - 0.5 Means that the action is in the middle. - * - 1 Means that the action is over. - * - * @param time A value between 0 and 1. - */ - virtual void update(float time); - /** Return certain target. - * - * @return A certain target. - */ - inline Node* getTarget() const { return _target; } - /** The action will modify the target properties. - * - * @param target A certain target. - */ - inline void setTarget(Node *target) { _target = target; } - /** Return a original Target. - * - * @return A original Target. - */ - inline Node* getOriginalTarget() const { return _originalTarget; } - /** - * Set the original target, since target can be nil. - * Is the target that were used to run the action. Unless you are doing something complex, like ActionManager, you should NOT call this method. - * The target is 'assigned', it is not 'retained'. - * @since v0.8.2 - * - * @param originalTarget Is 'assigned', it is not 'retained'. - */ - inline void setOriginalTarget(Node *originalTarget) { _originalTarget = originalTarget; } - /** Returns a tag that is used to identify the action easily. - * - * @return A tag. - */ - inline int getTag() const { return _tag; } - /** Changes the tag that is used to identify the action easily. - * - * @param tag Used to identify the action easily. - */ - inline void setTag(int tag) { _tag = tag; } - /** Returns a flag field that is used to group the actions easily. - * - * @return A tag. - */ - inline unsigned int getFlags() const { return _flags; } - /** Changes the flag field that is used to group the actions easily. - * - * @param flags Used to group the actions easily. - */ - inline void setFlags(unsigned int flags) { _flags = flags; } - -CC_CONSTRUCTOR_ACCESS: - Action(); - virtual ~Action(); - -protected: - Node *_originalTarget; - /** - * The "target". - * The target will be set with the 'startWithTarget' method. - * When the 'stop' method is called, target will be set to nil. - * The target is 'assigned', it is not 'retained'. - */ - Node *_target; - /** The action tag. An identifier of the action. */ - int _tag; - /** The action flag field. To categorize action into certain groups.*/ - unsigned int _flags; - -#if CC_ENABLE_SCRIPT_BINDING - ccScriptType _scriptType; ///< type of script binding, lua or javascript -#endif -private: - CC_DISALLOW_COPY_AND_ASSIGN(Action); -protected: - void sendUpdateEventToScript(float dt, Action *actionObject); -}; - -/** @class FiniteTimeAction - * @brief - * Base class actions that do have a finite time duration. - * Possible actions: - * - An action with a duration of 0 seconds. - * - An action with a duration of 35.5 seconds. - * Infinite time actions are valid. - */ -class CC_DLL FiniteTimeAction : public Action -{ -public: - /** Get duration in seconds of the action. - * - * @return The duration in seconds of the action. - */ - inline float getDuration() const { return _duration; } - /** Set duration in seconds of the action. - * - * @param duration In seconds of the action. - */ - inline void setDuration(float duration) { _duration = duration; } - - // - // Overrides - // - virtual FiniteTimeAction* reverse() const override - { - CC_ASSERT(0); - return nullptr; - } - virtual FiniteTimeAction* clone() const override - { - CC_ASSERT(0); - return nullptr; - } - -CC_CONSTRUCTOR_ACCESS: - FiniteTimeAction() - : _duration(0) - {} - virtual ~FiniteTimeAction(){} - -protected: - //! Duration in seconds. - float _duration; -private: - CC_DISALLOW_COPY_AND_ASSIGN(FiniteTimeAction); -}; - -class ActionInterval; -class RepeatForever; - -/** @class Speed - * @brief Changes the speed of an action, making it take longer (speed>1) - * or shorter (speed<1) time. - * Useful to simulate 'slow motion' or 'fast forward' effect. - * @warning This action can't be Sequenceable because it is not an IntervalAction. - */ -class CC_DLL Speed : public Action -{ -public: - /** Create the action and set the speed. - * - * @param action An action. - * @param speed The action speed. - */ - static Speed* create(ActionInterval* action, float speed); - /** Return the speed. - * - * @return The action speed. - */ - inline float getSpeed(void) const { return _speed; } - /** Alter the speed of the inner function in runtime. - * - * @param speed Alter the speed of the inner function in runtime. - */ - inline void setSpeed(float speed) { _speed = speed; } - - /** Replace the interior action. - * - * @param action The new action, it will replace the running action. - */ - void setInnerAction(ActionInterval *action); - /** Return the interior action. - * - * @return The interior action. - */ - inline ActionInterval* getInnerAction() const { return _innerAction; } - - // - // Override - // - virtual Speed* clone() const override; - virtual Speed* reverse() const override; - virtual void startWithTarget(Node* target) override; - virtual void stop() override; - /** - * @param dt in seconds. - */ - virtual void step(float dt) override; - /** Return true if the action has finished. - * - * @return Is true if the action has finished. - */ - virtual bool isDone() const override; - -CC_CONSTRUCTOR_ACCESS: - Speed(); - virtual ~Speed(void); - /** Initializes the action. */ - bool initWithAction(ActionInterval *action, float speed); - -protected: - float _speed; - ActionInterval *_innerAction; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(Speed); -}; - -/** @class Follow - * @brief Follow is an action that "follows" a node. - * Eg: - * @code - * layer->runAction(Follow::create(hero)); - * @endcode - * Instead of using Camera as a "follower", use this action instead. - * @since v0.99.2 - */ -class CC_DLL Follow : public Action -{ -public: - /** - * Creates the action with a set boundary or with no boundary. - * - * @param followedNode The node to be followed. - * @param rect The boundary. If \p rect is equal to Rect::ZERO, it'll work - * with no boundary. - */ - static Follow* create(Node *followedNode, const Rect& rect = Rect::ZERO); - - /** - * Creates the action with a set boundary or with no boundary with offsets. - * - * @param followedNode The node to be followed. - * @param rect The boundary. If \p rect is equal to Rect::ZERO, it'll work - * with no boundary. - * @param xOffset The horizontal offset from the center of the screen from which the - * node is to be followed.It can be positive,negative or zero.If - * set to zero the node will be horizontally centered followed. - * @param yOffset The vertical offset from the center of the screen from which the - * node is to be followed.It can be positive,negative or zero. - * If set to zero the node will be vertically centered followed. - * If both xOffset and yOffset are set to zero,then the node will be horizontally and vertically centered followed. - */ - - static Follow* createWithOffset(Node* followedNode,float xOffset,float yOffset,const Rect& rect = Rect::ZERO); - - /** Return boundarySet. - * - * @return Return boundarySet. - */ - inline bool isBoundarySet() const { return _boundarySet; } - /** Alter behavior - turn on/off boundary. - * - * @param value Turn on/off boundary. - */ - inline void setBoundarySet(bool value) { _boundarySet = value; } - - // - // Override - // - virtual Follow* clone() const override; - virtual Follow* reverse() const override; - /** - * @param dt in seconds. - * @js NA - */ - virtual void step(float dt) override; - virtual bool isDone() const override; - virtual void stop() override; - -CC_CONSTRUCTOR_ACCESS: - /** - * @js ctor - */ - Follow() - : _followedNode(nullptr) - , _boundarySet(false) - , _boundaryFullyCovered(false) - , _leftBoundary(0.0) - , _rightBoundary(0.0) - , _topBoundary(0.0) - , _bottomBoundary(0.0) - , _offsetX(0.0) - , _offsetY(0.0) - , _worldRect(Rect::ZERO) - {} - /** - * @js NA - * @lua NA - */ - virtual ~Follow(); - - /** - * Initializes the action with a set boundary or with no boundary. - * - * @param followedNode The node to be followed. - * @param rect The boundary. If \p rect is equal to Rect::ZERO, it'll work - * with no boundary. - */ - bool initWithTarget(Node *followedNode, const Rect& rect = Rect::ZERO); - - - /** - * Initializes the action with a set boundary or with no boundary with offsets. - * - * @param followedNode The node to be followed. - * @param rect The boundary. If \p rect is equal to Rect::ZERO, it'll work - * with no boundary. - * @param xOffset The horizontal offset from the center of the screen from which the - * node is to be followed.It can be positive,negative or zero.If - * set to zero the node will be horizontally centered followed. - * @param yOffset The vertical offset from the center of the screen from which the - * node is to be followed.It can be positive,negative or zero. - * If set to zero the node will be vertically centered followed. - * If both xOffset and yOffset are set to zero,then the node will be horizontally and vertically centered followed. - - */ - bool initWithTargetAndOffset(Node *followedNode,float xOffset,float yOffset,const Rect& rect = Rect::ZERO); - -protected: - /** Node to follow. */ - Node *_followedNode; - - /** Whether camera should be limited to certain area. */ - bool _boundarySet; - - /** If screen size is bigger than the boundary - update not needed. */ - bool _boundaryFullyCovered; - - /** Fast access to the screen dimensions. */ - Vec2 _halfScreenSize; - Vec2 _fullScreenSize; - - /** World boundaries. */ - float _leftBoundary; - float _rightBoundary; - float _topBoundary; - float _bottomBoundary; - - /** Horizontal (x) and vertical (y) offset values. */ - float _offsetX; - float _offsetY; - - Rect _worldRect; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(Follow); -}; - -// end of actions group -/// @} - -NS_CC_END - -#endif // __ACTIONS_CCACTION_H__ - diff --git a/native/cocos/2d/CCActionCamera.cpp b/native/cocos/2d/CCActionCamera.cpp deleted file mode 100644 index 0abb5d77b3..0000000000 --- a/native/cocos/2d/CCActionCamera.cpp +++ /dev/null @@ -1,248 +0,0 @@ -/**************************************************************************** -Copyright (c) 2008-2010 Ricardo Quesada -Copyright (c) 2010-2012 cocos2d-x.org -Copyright (c) 2011 Zynga Inc. -Copyright (c) 2013-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ - -#include "2d/CCActionCamera.h" -#include "2d/CCNode.h" -#include "platform/CCStdC.h" - -NS_CC_BEGIN -// -// CameraAction -// -ActionCamera::ActionCamera() -: _center(0, 0, 0) -, _eye(0, 0, FLT_EPSILON) -, _up(0, 1, 0) -{ -} -void ActionCamera::startWithTarget(Node *target) -{ - ActionInterval::startWithTarget(target); -} - -ActionCamera* ActionCamera::clone() const -{ - auto action = new (std::nothrow) ActionCamera(); - if (action) - { - action->autorelease(); - return action; - } - - delete action; - return nullptr; -} - -ActionCamera * ActionCamera::reverse() const -{ - // FIXME: This conversion isn't safe. - return (ActionCamera*)ReverseTime::create(const_cast(this)); -} - -void ActionCamera::restore() -{ - _center.setZero(); - _eye.set(0.0f, 0.0f, FLT_EPSILON); - _up.set(0.0f, 1.0f, 0.0f); -} - -void ActionCamera::setEye(const Vec3& eye) -{ - _eye = eye; - updateTransform(); -} - -void ActionCamera::setEye(float x, float y, float z) -{ - _eye.set(x, y, z); - updateTransform(); -} - -void ActionCamera::setCenter(const Vec3& center) -{ - _center = center; - updateTransform(); -} - -void ActionCamera::setUp(const Vec3& up) -{ - _up = up; - updateTransform(); -} - -void ActionCamera::updateTransform() -{ - Mat4 lookupMatrix; - Mat4::createLookAt(_eye.x, _eye.y, _eye.z, _center.x, _center.y, _center.z, _up.x, _up.y, _up.z, &lookupMatrix); - - Vec2 anchorPoint = _target->getAnchorPointInPoints(); - - bool needsTranslation = !anchorPoint.isZero(); - - Mat4 mv = Mat4::IDENTITY; - - if(needsTranslation) - { - Mat4 t; - Mat4::createTranslation(anchorPoint.x, anchorPoint.y, 0, &t); - mv = mv * t; - } - - mv = mv * lookupMatrix; - - if(needsTranslation) - { - Mat4 t; - Mat4::createTranslation(-anchorPoint.x, -anchorPoint.y, 0, &t); - mv = mv * t; - } - - // FIXME: Using the AdditionalTransform is a complete hack. - // This should be done by multiplying the lookup-Matrix with the Node's MV matrix - // And then setting the result as the new MV matrix - // But that operation needs to be done after all the 'updates'. - // So the Director should emit an 'director_after_update' event. - // And this object should listen to it - _target->setAdditionalTransform(&mv); -} - -// -// OrbitCamera -// - -OrbitCamera::OrbitCamera() -: _radius(0.0) -, _deltaRadius(0.0) -, _angleZ(0.0) -, _deltaAngleZ(0.0) -, _angleX(0.0) -, _deltaAngleX(0.0) -, _radZ(0.0) -, _radDeltaZ(0.0) -, _radX(0.0) -, _radDeltaX(0.0) -{ -} -OrbitCamera::~OrbitCamera() -{ -} - -OrbitCamera * OrbitCamera::create(float t, float radius, float deltaRadius, float angleZ, float deltaAngleZ, float angleX, float deltaAngleX) -{ - OrbitCamera * obitCamera = new (std::nothrow) OrbitCamera(); - if(obitCamera && obitCamera->initWithDuration(t, radius, deltaRadius, angleZ, deltaAngleZ, angleX, deltaAngleX)) - { - obitCamera->autorelease(); - return obitCamera; - } - - delete obitCamera; - return nullptr; -} - -OrbitCamera* OrbitCamera::clone() const -{ - // no copy constructor - return OrbitCamera::create(_duration, _radius, _deltaRadius, _angleZ, _deltaAngleZ, _angleX, _deltaAngleX); -} - -bool OrbitCamera::initWithDuration(float t, float radius, float deltaRadius, float angleZ, float deltaAngleZ, float angleX, float deltaAngleX) -{ - if ( ActionInterval::initWithDuration(t) ) - { - _radius = radius; - _deltaRadius = deltaRadius; - _angleZ = angleZ; - _deltaAngleZ = deltaAngleZ; - _angleX = angleX; - _deltaAngleX = deltaAngleX; - - _radDeltaZ = (float)CC_DEGREES_TO_RADIANS(deltaAngleZ); - _radDeltaX = (float)CC_DEGREES_TO_RADIANS(deltaAngleX); - return true; - } - return false; -} - -void OrbitCamera::startWithTarget(Node *target) -{ - ActionCamera::startWithTarget(target); - - float r, zenith, azimuth; - this->sphericalRadius(&r, &zenith, &azimuth); - if( std::isnan(_radius) ) - _radius = r; - if( std::isnan(_angleZ) ) - _angleZ = (float)CC_RADIANS_TO_DEGREES(zenith); - if( std::isnan(_angleX) ) - _angleX = (float)CC_RADIANS_TO_DEGREES(azimuth); - - _radZ = (float)CC_DEGREES_TO_RADIANS(_angleZ); - _radX = (float)CC_DEGREES_TO_RADIANS(_angleX); -} - -void OrbitCamera::update(float dt) -{ - float r = (_radius + _deltaRadius * dt) * FLT_EPSILON; - float za = _radZ + _radDeltaZ * dt; - float xa = _radX + _radDeltaX * dt; - - float i = sinf(za) * cosf(xa) * r + _center.x; - float j = sinf(za) * sinf(xa) * r + _center.y; - float k = cosf(za) * r + _center.z; - - setEye(i,j,k); -} - -void OrbitCamera::sphericalRadius(float *newRadius, float *zenith, float *azimuth) -{ - float r; // radius - float s; - - float x = _eye.x - _center.x; - float y = _eye.y - _center.y; - float z = _eye.z - _center.z; - - r = sqrtf( powf(x,2) + powf(y,2) + powf(z,2)); - s = sqrtf( powf(x,2) + powf(y,2)); - if( s == 0.0f ) - s = FLT_EPSILON; - if(r==0.0f) - r = FLT_EPSILON; - - *zenith = acosf( z/r); - if( x < 0 ) - *azimuth= (float)M_PI - asinf(y/s); - else - *azimuth = asinf(y/s); - - *newRadius = r / FLT_EPSILON; -} - -NS_CC_END - diff --git a/native/cocos/2d/CCActionCamera.h b/native/cocos/2d/CCActionCamera.h deleted file mode 100644 index 1783ade77b..0000000000 --- a/native/cocos/2d/CCActionCamera.h +++ /dev/null @@ -1,184 +0,0 @@ -/**************************************************************************** -Copyright (c) 2008-2010 Ricardo Quesada -Copyright (c) 2010-2012 cocos2d-x.org -Copyright (c) 2011 Zynga Inc. -Copyright (c) 2013-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ - -#ifndef __CCCAMERA_ACTION_H__ -#define __CCCAMERA_ACTION_H__ - -#include "2d/CCActionInterval.h" -#include "math/CCMath.h" - -NS_CC_BEGIN - -class Camera; - -/** - * @addtogroup actions - * @{ - */ - -/** - *@brief Base class for Camera actions. - *@ingroup Actions - */ -class CC_DLL ActionCamera : public ActionInterval // -{ -public: - /** - * @js ctor - * @lua new - */ - ActionCamera(); - /** - * @js NA - * @lua NA - */ - virtual ~ActionCamera(){}; - - // Overrides - virtual void startWithTarget(Node *target) override; - virtual ActionCamera * reverse() const override; - virtual ActionCamera *clone() const override; - - /* Sets the Eye value of the Camera. - * - * @param eye The Eye value of the Camera. - * @js NA - */ - void setEye(const Vec3 &eye); - void setEye(float x, float y, float z); - /* Returns the Eye value of the Camera. - * - * @return The Eye value of the Camera. - * @js NA - */ - const Vec3& getEye() const { return _eye; } - /* Sets the Center value of the Camera. - * - * @param center The Center value of the Camera. - * @js NA - */ - void setCenter(const Vec3 ¢er); - /* Returns the Center value of the Camera. - * - * @return The Center value of the Camera. - * @js NA - */ - const Vec3& getCenter() const { return _center; } - /* Sets the Up value of the Camera. - * - * @param up The Up value of the Camera. - * @js NA - */ - void setUp(const Vec3 &up); - /* Returns the Up value of the Camera. - * - * @return The Up value of the Camera. - * @js NA - */ - const Vec3& getUp() const { return _up; } - -protected: - - void restore(); - void updateTransform(); - - Vec3 _center; - Vec3 _eye; - Vec3 _up; -}; - -/** @class OrbitCamera - * - * @brief OrbitCamera action. - * Orbits the camera around the center of the screen using spherical coordinates. - * @ingroup Actions - */ -class CC_DLL OrbitCamera : public ActionCamera // -{ -public: - /** Creates a OrbitCamera action with radius, delta-radius, z, deltaZ, x, deltaX. - * - * @param t Duration in seconds. - * @param radius The start radius. - * @param deltaRadius The delta radius. - * @param angleZ The start angle in Z. - * @param deltaAngleZ The delta angle in Z. - * @param angleX The start angle in X. - * @param deltaAngleX The delta angle in X. - * @return An OrbitCamera. - */ - static OrbitCamera* create(float t, float radius, float deltaRadius, float angleZ, float deltaAngleZ, float angleX, float deltaAngleX); - - /** Positions the camera according to spherical coordinates. - * - * @param r The spherical radius. - * @param zenith The spherical zenith. - * @param azimuth The spherical azimuth. - */ - void sphericalRadius(float *r, float *zenith, float *azimuth); - - // Overrides - OrbitCamera *clone() const override; - virtual void startWithTarget(Node *target) override; - virtual void update(float time) override; - -CC_CONSTRUCTOR_ACCESS: - /** - * @js ctor - */ - OrbitCamera(); - /** - * @js NA - * @lua NA - */ - virtual ~OrbitCamera(); - - /** Initializes a OrbitCamera action with radius, delta-radius, z, deltaZ, x, deltaX. */ - bool initWithDuration(float t, float radius, float deltaRadius, float angleZ, float deltaAngleZ, float angleX, float deltaAngleX); - -protected: - float _radius; - float _deltaRadius; - float _angleZ; - float _deltaAngleZ; - float _angleX; - float _deltaAngleX; - - float _radZ; - float _radDeltaZ; - float _radX; - float _radDeltaX; -}; - -// end of actions group -/// @} - -NS_CC_END - -#endif //__CCCAMERA_ACTION_H__ - diff --git a/native/cocos/2d/CCActionCatmullRom.cpp b/native/cocos/2d/CCActionCatmullRom.cpp deleted file mode 100644 index f80eb6cbe7..0000000000 --- a/native/cocos/2d/CCActionCatmullRom.cpp +++ /dev/null @@ -1,558 +0,0 @@ -/* - * Copyright (c) 2008 Radu Gruian - * Copyright (c) 2011 Vit Valentin - * Copyright (c) 2012 cocos2d-x.org - * Copyright (c) 2013-2016 Chukong Technologies Inc. - * Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - * - * Permission is hereby granted, free of charge, to any person obtaining a copy - * of this software and associated documentation files (the "Software"), to deal - * in the Software without restriction, including without limitation the rights - * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell - * copies of the Software, and to permit persons to whom the Software is - * furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice shall be included in - * all copies or substantial portions of the Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN - * THE SOFTWARE. - * - * - * Original code by Radu Gruian: http://www.codeproject.com/Articles/30838/Overhauser-Catmull-Rom-Splines-for-Camera-Animatio.So - * - * Adapted to cocos2d-x by Vit Valentin - * - * Adapted from cocos2d-x to cocos2d-iphone by Ricardo Quesada - */ -#include "base/ccMacros.h" -#include "2d/CCActionCatmullRom.h" -#include "2d/CCNode.h" - -using namespace std; - -NS_CC_BEGIN; - -/* - * Implementation of PointArray - */ - -PointArray* PointArray::create(ssize_t capacity) -{ - PointArray* pointArray = new (std::nothrow) PointArray(); - if (pointArray && pointArray->initWithCapacity(capacity)) - { - pointArray->autorelease(); - return pointArray; - } - - delete pointArray; - return nullptr; -} - -bool PointArray::initWithCapacity(ssize_t capacity) -{ - _controlPoints = new (std::nothrow) vector(); - if (capacity > 0) { - _controlPoints->reserve(capacity); - } - - return true; -} - -PointArray* PointArray::clone() const -{ - vector *newArray = new (std::nothrow) vector(); - vector::iterator iter; - for (iter = _controlPoints->begin(); iter != _controlPoints->end(); ++iter) - { - newArray->push_back(new Vec2((*iter)->x, (*iter)->y)); - } - - PointArray *points = new (std::nothrow) PointArray(); - points->initWithCapacity(10); - points->setControlPoints(newArray); - - points->autorelease(); - return points; -} - -PointArray::~PointArray() -{ - CCLOGINFO("deallocing PointArray: %p", this); - - vector::iterator iter; - for (iter = _controlPoints->begin(); iter != _controlPoints->end(); ++iter) - { - delete *iter; - } - delete _controlPoints; -} - -PointArray::PointArray() :_controlPoints(nullptr){} - -const std::vector* PointArray::getControlPoints() const -{ - return _controlPoints; -} - -void PointArray::setControlPoints(vector *controlPoints) -{ - CCASSERT(controlPoints != nullptr, "control points should not be nullptr"); - - // delete old points - vector::iterator iter; - for (iter = _controlPoints->begin(); iter != _controlPoints->end(); ++iter) - { - delete *iter; - } - delete _controlPoints; - - _controlPoints = controlPoints; -} - -void PointArray::addControlPoint(const Vec2& controlPoint) -{ - _controlPoints->push_back(new Vec2(controlPoint.x, controlPoint.y)); -} - -void PointArray::insertControlPoint(const Vec2& controlPoint, ssize_t index) -{ - Vec2 *temp = new (std::nothrow) Vec2(controlPoint.x, controlPoint.y); - _controlPoints->insert(_controlPoints->begin() + index, temp); -} - -Vec2 PointArray::getControlPointAtIndex(ssize_t index) -{ - index = MIN(static_cast(_controlPoints->size())-1, MAX(index, 0)); - return *(_controlPoints->at(index)); -} - -void PointArray::replaceControlPoint(const Vec2& controlPoint, ssize_t index) -{ - Vec2 *temp = _controlPoints->at(index); - temp->x = controlPoint.x; - temp->y = controlPoint.y; -} - -void PointArray::removeControlPointAtIndex(ssize_t index) -{ - vector::iterator iter = _controlPoints->begin() + index; - Vec2* removedPoint = *iter; - _controlPoints->erase(iter); - delete removedPoint; -} - -ssize_t PointArray::count() const -{ - return _controlPoints->size(); -} - -PointArray* PointArray::reverse() const -{ - vector *newArray = new (std::nothrow) vector(); - vector::reverse_iterator iter; - Vec2 *point = nullptr; - for (iter = _controlPoints->rbegin(); iter != _controlPoints->rend(); ++iter) - { - point = *iter; - newArray->push_back(new Vec2(point->x, point->y)); - } - PointArray *config = PointArray::create(0); - config->setControlPoints(newArray); - - return config; -} - -void PointArray::reverseInline() -{ - size_t l = _controlPoints->size(); - Vec2 *p1 = nullptr; - Vec2 *p2 = nullptr; - float x, y; - for (size_t i = 0; i < l/2; ++i) - { - p1 = _controlPoints->at(i); - p2 = _controlPoints->at(l-i-1); - - x = p1->x; - y = p1->y; - - p1->x = p2->x; - p1->y = p2->y; - - p2->x = x; - p2->y = y; - } -} - -// CatmullRom Spline formula: -Vec2 ccCardinalSplineAt(Vec2 &p0, Vec2 &p1, Vec2 &p2, Vec2 &p3, float tension, float t) -{ - float t2 = t * t; - float t3 = t2 * t; - - /* - * Formula: s(-ttt + 2tt - t)P1 + s(-ttt + tt)P2 + (2ttt - 3tt + 1)P2 + s(ttt - 2tt + t)P3 + (-2ttt + 3tt)P3 + s(ttt - tt)P4 - */ - float s = (1 - tension) / 2; - - float b1 = s * ((-t3 + (2 * t2)) - t); // s(-t3 + 2 t2 - t)P1 - float b2 = s * (-t3 + t2) + (2 * t3 - 3 * t2 + 1); // s(-t3 + t2)P2 + (2 t3 - 3 t2 + 1)P2 - float b3 = s * (t3 - 2 * t2 + t) + (-2 * t3 + 3 * t2); // s(t3 - 2 t2 + t)P3 + (-2 t3 + 3 t2)P3 - float b4 = s * (t3 - t2); // s(t3 - t2)P4 - - float x = (p0.x*b1 + p1.x*b2 + p2.x*b3 + p3.x*b4); - float y = (p0.y*b1 + p1.y*b2 + p2.y*b3 + p3.y*b4); - - return Vec2(x,y); -} - -/* Implementation of CardinalSplineTo - */ - -CardinalSplineTo* CardinalSplineTo::create(float duration, cocos2d::PointArray *points, float tension) -{ - CardinalSplineTo *ret = new (std::nothrow) CardinalSplineTo(); - if (ret) - { - if (ret->initWithDuration(duration, points, tension)) - { - ret->autorelease(); - } - else - { - CC_SAFE_RELEASE_NULL(ret); - } - } - - return ret; -} - -bool CardinalSplineTo::initWithDuration(float duration, cocos2d::PointArray *points, float tension) -{ - CCASSERT(points->count() > 0, "Invalid configuration. It must at least have one control point"); - - if (ActionInterval::initWithDuration(duration)) - { - this->setPoints(points); - this->_tension = tension; - - return true; - } - - return false; -} - -CardinalSplineTo::~CardinalSplineTo() -{ - CC_SAFE_RELEASE_NULL(_points); -} - -CardinalSplineTo::CardinalSplineTo() -: _points(nullptr) -, _deltaT(0.f) -, _tension(0.f) -{ -} - -void CardinalSplineTo::startWithTarget(cocos2d::Node *target) -{ - ActionInterval::startWithTarget(target); - -// _deltaT = (float) 1 / _points->count(); - - // Issue #1441 - _deltaT = (float) 1 / (_points->count() - 1); - - _previousPosition = target->getPosition(); - _accumulatedDiff.setZero(); -} - -CardinalSplineTo* CardinalSplineTo::clone() const -{ - // no copy constructor - auto a = new (std::nothrow) CardinalSplineTo(); - a->initWithDuration(this->_duration, this->_points->clone(), this->_tension); - a->autorelease(); - return a; -} - -void CardinalSplineTo::update(float time) -{ - ssize_t p; - float lt; - - // eg. - // p..p..p..p..p..p..p - // 1..2..3..4..5..6..7 - // want p to be 1, 2, 3, 4, 5, 6 - if (time == 1) - { - p = _points->count() - 1; - lt = 1; - } - else - { - p = time / _deltaT; - lt = (time - _deltaT * (float)p) / _deltaT; - } - - // Interpolate - Vec2 pp0 = _points->getControlPointAtIndex(p-1); - Vec2 pp1 = _points->getControlPointAtIndex(p+0); - Vec2 pp2 = _points->getControlPointAtIndex(p+1); - Vec2 pp3 = _points->getControlPointAtIndex(p+2); - - Vec2 newPos = ccCardinalSplineAt(pp0, pp1, pp2, pp3, _tension, lt); - -#if CC_ENABLE_STACKABLE_ACTIONS - // Support for stacked actions - Node *node = _target; - Vec2 diff = node->getPosition() - _previousPosition; - if( diff.x !=0 || diff.y != 0 ) - { - _accumulatedDiff = _accumulatedDiff + diff; - newPos = newPos + _accumulatedDiff; - } -#endif - - this->updatePosition(newPos); -} - -void CardinalSplineTo::updatePosition(const cocos2d::Vec2& newPos) -{ - _target->setPosition(newPos); - _previousPosition = newPos; -} - -CardinalSplineTo* CardinalSplineTo::reverse() const -{ - PointArray *pReverse = _points->reverse(); - - return CardinalSplineTo::create(_duration, pReverse, _tension); -} - -/* CardinalSplineBy - */ - -CardinalSplineBy* CardinalSplineBy::create(float duration, cocos2d::PointArray *points, float tension) -{ - CardinalSplineBy *ret = new (std::nothrow) CardinalSplineBy(); - if (ret) - { - if (ret->initWithDuration(duration, points, tension)) - { - ret->autorelease(); - } - else - { - CC_SAFE_RELEASE_NULL(ret); - } - } - - return ret; -} - -CardinalSplineBy::CardinalSplineBy() : _startPosition(0,0) -{ -} - -void CardinalSplineBy::updatePosition(const cocos2d::Vec2& newPos) -{ - Vec2 p = newPos + _startPosition; - _target->setPosition(p); - _previousPosition = p; -} - -CardinalSplineBy* CardinalSplineBy::reverse() const -{ - PointArray *copyConfig = _points->clone(); - - // - // convert "absolutes" to "diffs" - // - Vec2 p = copyConfig->getControlPointAtIndex(0); - for (ssize_t i = 1; i < copyConfig->count(); ++i) - { - Vec2 current = copyConfig->getControlPointAtIndex(i); - Vec2 diff = current - p; - copyConfig->replaceControlPoint(diff, i); - - p = current; - } - - // convert to "diffs" to "reverse absolute" - PointArray *pReverse = copyConfig->reverse(); - - // 1st element (which should be 0,0) should be here too - - p = pReverse->getControlPointAtIndex(pReverse->count()-1); - pReverse->removeControlPointAtIndex(pReverse->count()-1); - - p = -p; - pReverse->insertControlPoint(p, 0); - - for (ssize_t i = 1; i < pReverse->count(); ++i) - { - Vec2 current = pReverse->getControlPointAtIndex(i); - current = -current; - Vec2 abs = current + p; - pReverse->replaceControlPoint(abs, i); - - p = abs; - } - - return CardinalSplineBy::create(_duration, pReverse, _tension); -} - -void CardinalSplineBy::startWithTarget(cocos2d::Node *target) -{ - CardinalSplineTo::startWithTarget(target); - _startPosition = target->getPosition(); -} - -CardinalSplineBy* CardinalSplineBy::clone() const -{ - // no copy constructor - auto a = new (std::nothrow) CardinalSplineBy(); - a->initWithDuration(this->_duration, this->_points->clone(), this->_tension); - a->autorelease(); - return a; -} - -/* CatmullRomTo - */ - -CatmullRomTo* CatmullRomTo::create(float dt, cocos2d::PointArray *points) -{ - CatmullRomTo *ret = new (std::nothrow) CatmullRomTo(); - if (ret) - { - if (ret->initWithDuration(dt, points)) - { - ret->autorelease(); - } - else - { - CC_SAFE_RELEASE_NULL(ret); - } - } - - return ret; -} - -bool CatmullRomTo::initWithDuration(float dt, cocos2d::PointArray *points) -{ - if (CardinalSplineTo::initWithDuration(dt, points, 0.5f)) - { - return true; - } - - return false; -} - -CatmullRomTo* CatmullRomTo::clone() const -{ - // no copy constructor - auto a = new (std::nothrow) CatmullRomTo(); - a->initWithDuration(this->_duration, this->_points->clone()); - a->autorelease(); - return a; -} - -CatmullRomTo* CatmullRomTo::reverse() const -{ - PointArray *reverse = _points->reverse(); - return CatmullRomTo::create(_duration, reverse); -} - - -/* CatmullRomBy - */ - -CatmullRomBy* CatmullRomBy::create(float dt, cocos2d::PointArray *points) -{ - CatmullRomBy *ret = new (std::nothrow) CatmullRomBy(); - if (ret) - { - if (ret->initWithDuration(dt, points)) - { - ret->autorelease(); - } - else - { - CC_SAFE_RELEASE_NULL(ret); - } - } - - return ret; -} - -bool CatmullRomBy::initWithDuration(float dt, cocos2d::PointArray *points) -{ - if (CardinalSplineTo::initWithDuration(dt, points, 0.5f)) - { - return true; - } - - return false; -} - -CatmullRomBy* CatmullRomBy::clone() const -{ - // no copy constructor - auto a = new (std::nothrow) CatmullRomBy(); - a->initWithDuration(this->_duration, this->_points->clone()); - a->autorelease(); - return a; -} - -CatmullRomBy* CatmullRomBy::reverse() const -{ - PointArray *copyConfig = _points->clone(); - - // - // convert "absolutes" to "diffs" - // - Vec2 p = copyConfig->getControlPointAtIndex(0); - for (ssize_t i = 1; i < copyConfig->count(); ++i) - { - Vec2 current = copyConfig->getControlPointAtIndex(i); - Vec2 diff = current - p; - copyConfig->replaceControlPoint(diff, i); - - p = current; - } - - // convert to "diffs" to "reverse absolute" - PointArray *reverse = copyConfig->reverse(); - - // 1st element (which should be 0,0) should be here too - - p = reverse->getControlPointAtIndex(reverse->count()-1); - reverse->removeControlPointAtIndex(reverse->count()-1); - - p = -p; - reverse->insertControlPoint(p, 0); - - for (ssize_t i = 1; i < reverse->count(); ++i) - { - Vec2 current = reverse->getControlPointAtIndex(i); - current = -current; - Vec2 abs = current + p; - reverse->replaceControlPoint(abs, i); - - p = abs; - } - - return CatmullRomBy::create(_duration, reverse); -} - -NS_CC_END; - diff --git a/native/cocos/2d/CCActionCatmullRom.h b/native/cocos/2d/CCActionCatmullRom.h deleted file mode 100644 index 4bc46cf524..0000000000 --- a/native/cocos/2d/CCActionCatmullRom.h +++ /dev/null @@ -1,349 +0,0 @@ -/* - * Copyright (c) 2008 Radu Gruian - * Copyright (c) 2011 Vit Valentin - * Copyright (c) 2012 cocos2d-x.org - * Copyright (c) 2013-2016 Chukong Technologies Inc. - * Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - * - * - * Permission is hereby granted, free of charge, to any person obtaining a copy - * of this software and associated documentation files (the "Software"), to deal - * in the Software without restriction, including without limitation the rights - * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell - * copies of the Software, and to permit persons to whom the Software is - * furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice shall be included in - * all copies or substantial portions of the Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN - * THE SOFTWARE. - * - * - * Original code by Radu Gruian: http://www.codeproject.com/Articles/30838/Overhauser-Catmull-Rom-Splines-for-Camera-Animatio.So - * - * Adapted to cocos2d-x by Vit Valentin - * - * Adapted from cocos2d-x to cocos2d-iphone by Ricardo Quesada - */ - - -#ifndef __CCACTION_CATMULLROM_H__ -#define __CCACTION_CATMULLROM_H__ - -#include - -#include "2d/CCActionInterval.h" -#include "math/CCGeometry.h" - -NS_CC_BEGIN; - -class Node; - -/** - * @addtogroup actions - * @{ - */ - -/** An Array that contain control points. - * Used by CardinalSplineTo and (By) and CatmullRomTo (and By) actions. - * @ingroup Actions - * @js NA - */ -class CC_DLL PointArray : public Ref, public Clonable -{ -public: - - /** Creates and initializes a Points array with capacity. - * @js NA - * @param capacity The size of the array. - */ - static PointArray* create(ssize_t capacity); - - /** - * @js NA - * @lua NA - */ - virtual ~PointArray(); - /** - * @js NA - * @lua NA - */ - PointArray(); - - /** Initializes a Catmull Rom config with a capacity hint. - * - * @js NA - * @param capacity The size of the array. - * @return True. - */ - bool initWithCapacity(ssize_t capacity); - - /** Appends a control point. - * - * @js NA - * @param controlPoint A control point. - */ - void addControlPoint(const Vec2& controlPoint); - - /** Inserts a controlPoint at index. - * - * @js NA - * @param controlPoint A control point. - * @param index Insert the point to array in index. - */ - void insertControlPoint(const Vec2& controlPoint, ssize_t index); - - /** Replaces an existing controlPoint at index. - * - * @js NA - * @param controlPoint A control point. - * @param index Replace the point to array in index. - */ - void replaceControlPoint(const Vec2& controlPoint, ssize_t index); - - /** Get the value of a controlPoint at a given index. - * - * @js NA - * @param index Get the point in index. - * @return A Vec2. - */ - Vec2 getControlPointAtIndex(ssize_t index); - - /** Deletes a control point at a given index - * - * @js NA - * @param index Remove the point in index. - */ - void removeControlPointAtIndex(ssize_t index); - - /** Returns the number of objects of the control point array. - * - * @js NA - * @return The number of objects of the control point array. - */ - ssize_t count() const; - - /** Returns a new copy of the array reversed. User is responsible for releasing this copy. - * - * @js NA - * @return A new copy of the array reversed. - */ - PointArray* reverse() const; - - /** Reverse the current control point array inline, without generating a new one. - * @js NA - */ - void reverseInline(); - /** - * @js NA - * @lua NA - */ - virtual PointArray* clone() const; - /** - * @js NA - */ - const std::vector* getControlPoints() const; - /** - * @js NA - */ - void setControlPoints(std::vector *controlPoints); -private: - /** Array that contains the control points. */ - std::vector *_controlPoints; -}; - -/** @class CardinalSplineTo - * Cardinal Spline path. - * http://en.wikipedia.org/wiki/Cubic_Hermite_spline#Cardinal_spline - * @ingroup Actions - */ -class CC_DLL CardinalSplineTo : public ActionInterval -{ -public: - - /** Creates an action with a Cardinal Spline array of points and tension. - * @param duration In seconds. - * @param points An PointArray. - * @param tension Goodness of fit. - * @code - * When this function bound to js or lua,the input params are changed. - * In js: var create(var t,var table) - * In lua: local create(local t, local table) - * @endcode - */ - static CardinalSplineTo* create(float duration, PointArray* points, float tension); - /** - * @js NA - * @lua NA - */ - virtual ~CardinalSplineTo(); - /** - * @js ctor - * @lua NA - */ - CardinalSplineTo(); - - /** - * Initializes the action with a duration and an array of points. - * - * @param duration In seconds. - * @param points An PointArray. - * @param tension Goodness of fit. - */ - bool initWithDuration(float duration, PointArray* points, float tension); - /** It will update the target position and change the _previousPosition to newPos - * - * @param newPos The new position. - */ - virtual void updatePosition(const Vec2& newPos); - /** Return a PointArray. - * - * @return A PointArray. - */ - inline PointArray* getPoints() { return _points; } - /** - * @js NA - * @lua NA - */ - inline void setPoints(PointArray* points) - { - CC_SAFE_RETAIN(points); - CC_SAFE_RELEASE(_points); - _points = points; - } - - // Overrides - virtual CardinalSplineTo *clone() const override; - virtual CardinalSplineTo* reverse() const override; - virtual void startWithTarget(Node *target) override; - - /** - * @param time In seconds. - */ - virtual void update(float time) override; - -protected: - /** Array of control points */ - PointArray *_points; - float _deltaT; - float _tension; - Vec2 _previousPosition; - Vec2 _accumulatedDiff; -}; - -/** @class CardinalSplineBy - * Cardinal Spline path. - * http://en.wikipedia.org/wiki/Cubic_Hermite_spline#Cardinal_spline - * @ingroup Actions - */ -class CC_DLL CardinalSplineBy : public CardinalSplineTo -{ -public: - - /** Creates an action with a Cardinal Spline array of points and tension. - * @code - * When this function bound to js or lua,the input params are changed. - * In js: var create(var t,var table). - * In lua: local create(local t, local table). - * @param duration In seconds. - * @param point An PointArray. - * @param tension Goodness of fit. - * @endcode - */ - static CardinalSplineBy* create(float duration, PointArray* points, float tension); - - CardinalSplineBy(); - - // Overrides - virtual void startWithTarget(Node *target) override; - virtual void updatePosition(const Vec2& newPos) override; - virtual CardinalSplineBy *clone() const override; - virtual CardinalSplineBy* reverse() const override; - -protected: - Vec2 _startPosition; -}; - -/** @class CatmullRomTo - * An action that moves the target with a CatmullRom curve to a destination point. - * A Catmull Rom is a Cardinal Spline with a tension of 0.5. - * http://en.wikipedia.org/wiki/Cubic_Hermite_spline#Catmull.E2.80.93Rom_spline - * @ingroup Actions - */ -class CC_DLL CatmullRomTo : public CardinalSplineTo -{ -public: - - /** Creates an action with a Cardinal Spline array of points and tension. - * @param dt In seconds. - * @param points An PointArray. - * @code - * When this function bound to js or lua,the input params are changed. - * In js: var create(var dt,var table). - * In lua: local create(local dt, local table). - * @endcode - */ - static CatmullRomTo* create(float dt, PointArray* points); - - /** - * Initializes the action with a duration and an array of points. - * - * @param dt In seconds. - * @param points An PointArray. - */ - bool initWithDuration(float dt, PointArray* points); - - // Override - virtual CatmullRomTo *clone() const override; - virtual CatmullRomTo *reverse() const override; -}; - -/** @class CatmullRomBy - * An action that moves the target with a CatmullRom curve by a certain distance. - * A Catmull Rom is a Cardinal Spline with a tension of 0.5. - * http://en.wikipedia.org/wiki/Cubic_Hermite_spline#Catmull.E2.80.93Rom_spline - * @ingroup Actions - */ -class CC_DLL CatmullRomBy : public CardinalSplineBy -{ -public: - /** Creates an action with a Cardinal Spline array of points and tension. - * @param dt In seconds. - * @param points An PointArray. - * @code - * When this function bound to js or lua,the input params are changed. - * In js: var create(var dt,var table). - * In lua: local create(local dt, local table). - * @endcode - */ - static CatmullRomBy* create(float dt, PointArray* points); - - /** Initializes the action with a duration and an array of points. - * - * @param dt In seconds. - * @param points An PointArray. - */ - bool initWithDuration(float dt, PointArray* points); - - // Override - virtual CatmullRomBy *clone() const override; - virtual CatmullRomBy *reverse() const override; - -}; - -/** Returns the Cardinal Spline position for a given set of control points, tension and time */ -extern CC_DLL Vec2 ccCardinalSplineAt(Vec2 &p0, Vec2 &p1, Vec2 &p2, Vec2 &p3, float tension, float t); - -// end of actions group -/// @} - -NS_CC_END; - -#endif // __CCACTION_CATMULLROM_H__ - diff --git a/native/cocos/2d/CCActionEase.cpp b/native/cocos/2d/CCActionEase.cpp deleted file mode 100644 index 19c62e67e7..0000000000 --- a/native/cocos/2d/CCActionEase.cpp +++ /dev/null @@ -1,1394 +0,0 @@ -/**************************************************************************** -Copyright (c) 2008-2009 Jason Booth -Copyright (c) 2010-2012 cocos2d-x.org -Copyright (c) 2013-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - - http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ - -/* - * Elastic, Back and Bounce actions based on code from: - * http://github.com/NikhilK/silverlightfx/ - * - * by http://github.com/NikhilK - */ - -#include "2d/CCActionEase.h" -#include "2d/CCTweenFunction.h" - -NS_CC_BEGIN - -#ifndef M_PI_X_2 -#define M_PI_X_2 (float)M_PI * 2.0f -#endif - -// -// EaseAction -// - -bool ActionEase::initWithAction(ActionInterval *action) -{ - CCASSERT(action != nullptr, "action couldn't be nullptr!"); - if (action == nullptr) - { - return false; - } - - if (ActionInterval::initWithDuration(action->getDuration())) - { - _inner = action; - action->retain(); - - return true; - } - - return false; -} - -ActionEase::~ActionEase(void) -{ - CC_SAFE_RELEASE(_inner); -} - -void ActionEase::startWithTarget(Node *target) -{ - if (target && _inner) - { - ActionInterval::startWithTarget(target); - _inner->startWithTarget(_target); - } - else - { - log("ActionEase::startWithTarget error: target or _inner is nullptr!"); - } -} - -void ActionEase::stop(void) -{ - if (_inner) - _inner->stop(); - - ActionInterval::stop(); -} - -void ActionEase::update(float time) -{ - _inner->update(time); -} - -ActionInterval* ActionEase::getInnerAction() -{ - return _inner; -} - -// -// EaseRateAction -// - -EaseRateAction* EaseRateAction::create(ActionInterval* action, float rate) -{ - EaseRateAction *easeRateAction = new (std::nothrow) EaseRateAction(); - if (easeRateAction && easeRateAction->initWithAction(action, rate)) - { - easeRateAction->autorelease(); - return easeRateAction; - } - - delete easeRateAction; - return nullptr; -} - -bool EaseRateAction::initWithAction(ActionInterval *action, float rate) -{ - if (ActionEase::initWithAction(action)) - { - _rate = rate; - return true; - } - - return false; -} - -EaseRateAction::~EaseRateAction() -{ -} - -// -// EeseIn -// - -EaseIn* EaseIn::create(ActionInterval *action, float rate) -{ - EaseIn *easeIn = new (std::nothrow) EaseIn(); - if (easeIn && easeIn->initWithAction(action, rate)) - { - easeIn->autorelease(); - return easeIn; - } - - delete easeIn; - return nullptr; -} - -EaseIn* EaseIn::clone() const -{ - // no copy constructor - if (_inner) - return EaseIn::create(_inner->clone(), _rate); - - return nullptr; -} - -void EaseIn::update(float time) -{ - _inner->update(tweenfunc::easeIn(time, _rate)); -} - -EaseIn* EaseIn::reverse() const -{ - return EaseIn::create(_inner->reverse(), 1 / _rate); -} - -// -// EaseOut -// -EaseOut* EaseOut::create(ActionInterval *action, float rate) -{ - EaseOut *easeOut = new (std::nothrow) EaseOut(); - if (easeOut && easeOut->initWithAction(action, rate)) - { - easeOut->autorelease(); - return easeOut; - } - - delete easeOut; - return nullptr; -} - -EaseOut* EaseOut::clone() const -{ - // no copy constructor - if (_inner) - return EaseOut::create(_inner->clone(), _rate); - - return nullptr; -} - -void EaseOut::update(float time) -{ - _inner->update(tweenfunc::easeOut(time, _rate)); -} - -EaseOut* EaseOut::reverse() const -{ - return EaseOut::create(_inner->reverse(), 1 / _rate); -} - -// -// EaseInOut -// -EaseInOut* EaseInOut::create(ActionInterval *action, float rate) -{ - EaseInOut *easeInOut = new (std::nothrow) EaseInOut(); - if (easeInOut && easeInOut->initWithAction(action, rate)) - { - easeInOut->autorelease(); - return easeInOut; - } - - delete easeInOut; - return nullptr; -} - -EaseInOut* EaseInOut::clone() const -{ - // no copy constructor - if (_inner) - return EaseInOut::create(_inner->clone(), _rate); - - return nullptr; -} - -void EaseInOut::update(float time) -{ - _inner->update(tweenfunc::easeInOut(time, _rate)); -} - -// InOut and OutIn are symmetrical -EaseInOut* EaseInOut::reverse() const -{ - return EaseInOut::create(_inner->reverse(), _rate); -} - -// -// EaseExponentialIn -// -EaseExponentialIn* EaseExponentialIn::create(ActionInterval* action) -{ - EaseExponentialIn *ret = new (std::nothrow) EaseExponentialIn(); - if (ret && ret->initWithAction(action)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -EaseExponentialIn* EaseExponentialIn::clone() const -{ - // no copy constructor - if (_inner) - return EaseExponentialIn::create(_inner->clone()); - - return nullptr; -} - -void EaseExponentialIn::update(float time) -{ - _inner->update(tweenfunc::expoEaseIn(time)); -} - -ActionEase * EaseExponentialIn::reverse() const -{ - return EaseExponentialOut::create(_inner->reverse()); -} - -// -// EaseExponentialOut -// -EaseExponentialOut* EaseExponentialOut::create(ActionInterval* action) -{ - EaseExponentialOut *ret = new (std::nothrow) EaseExponentialOut(); - if (ret && ret->initWithAction(action)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -EaseExponentialOut* EaseExponentialOut::clone() const -{ - // no copy constructor - if (_inner) - return EaseExponentialOut::create(_inner->clone()); - - return nullptr; -} - -void EaseExponentialOut::update(float time) -{ - _inner->update(tweenfunc::expoEaseOut(time)); -} - -ActionEase* EaseExponentialOut::reverse() const -{ - return EaseExponentialIn::create(_inner->reverse()); -} - -// -// EaseExponentialInOut -// - -EaseExponentialInOut* EaseExponentialInOut::create(ActionInterval *action) -{ - EaseExponentialInOut *ret = new (std::nothrow) EaseExponentialInOut(); - if (ret && ret->initWithAction(action)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -EaseExponentialInOut* EaseExponentialInOut::clone() const -{ - // no copy constructor - if (_inner) - return EaseExponentialInOut::create(_inner->clone()); - - return nullptr; -} - -void EaseExponentialInOut::update(float time) -{ - _inner->update(tweenfunc::expoEaseInOut(time)); -} - -EaseExponentialInOut* EaseExponentialInOut::reverse() const -{ - return EaseExponentialInOut::create(_inner->reverse()); -} - -// -// EaseSineIn -// - -EaseSineIn* EaseSineIn::create(ActionInterval* action) -{ - EaseSineIn *ret = new (std::nothrow) EaseSineIn(); - if (ret && ret->initWithAction(action)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -EaseSineIn* EaseSineIn::clone() const -{ - // no copy constructor - if (_inner) - return EaseSineIn::create(_inner->clone()); - - return nullptr; -} - -void EaseSineIn::update(float time) -{ - _inner->update(tweenfunc::sineEaseIn(time)); -} - -ActionEase* EaseSineIn::reverse() const -{ - return EaseSineOut::create(_inner->reverse()); -} - -// -// EaseSineOut -// - -EaseSineOut* EaseSineOut::create(ActionInterval* action) -{ - EaseSineOut *ret = new (std::nothrow) EaseSineOut(); - if (ret && ret->initWithAction(action)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -EaseSineOut* EaseSineOut::clone() const -{ - // no copy constructor - if (_inner) - return EaseSineOut::create(_inner->clone()); - - return nullptr; -} - -void EaseSineOut::update(float time) -{ - _inner->update(tweenfunc::sineEaseOut(time)); -} - -ActionEase* EaseSineOut::reverse(void) const -{ - return EaseSineIn::create(_inner->reverse()); -} - -// -// EaseSineInOut -// - -EaseSineInOut* EaseSineInOut::create(ActionInterval* action) -{ - EaseSineInOut *ret = new (std::nothrow) EaseSineInOut(); - if (ret && ret->initWithAction(action)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -EaseSineInOut* EaseSineInOut::clone() const -{ - // no copy constructor - if (_inner) - return EaseSineInOut::create(_inner->clone()); - - return nullptr; -} - -void EaseSineInOut::update(float time) -{ - _inner->update(tweenfunc::sineEaseInOut(time)); -} - -EaseSineInOut* EaseSineInOut::reverse() const -{ - return EaseSineInOut::create(_inner->reverse()); -} - -// -// EaseElastic -// - -bool EaseElastic::initWithAction(ActionInterval *action, float period/* = 0.3f*/) -{ - if (ActionEase::initWithAction(action)) - { - _period = period; - return true; - } - - return false; -} - -// -// EaseElasticIn -// - -EaseElasticIn* EaseElasticIn::create(ActionInterval *action) -{ - return EaseElasticIn::create(action, 0.3f); -} - -EaseElasticIn* EaseElasticIn::create(ActionInterval *action, float period/* = 0.3f*/) -{ - EaseElasticIn *ret = new (std::nothrow) EaseElasticIn(); - if (ret && ret->initWithAction(action, period)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -EaseElasticIn* EaseElasticIn::clone() const -{ - // no copy constructor - if (_inner) - return EaseElasticIn::create(_inner->clone(), _period); - - return nullptr; -} - -void EaseElasticIn::update(float time) -{ - _inner->update(tweenfunc::elasticEaseIn(time, _period)); -} - -EaseElastic* EaseElasticIn::reverse() const -{ - return EaseElasticOut::create(_inner->reverse(), _period); -} - -// -// EaseElasticOut -// - -EaseElasticOut* EaseElasticOut::create(ActionInterval *action) -{ - return EaseElasticOut::create(action, 0.3f); -} - -EaseElasticOut* EaseElasticOut::create(ActionInterval *action, float period/* = 0.3f*/) -{ - EaseElasticOut *ret = new (std::nothrow) EaseElasticOut(); - if (ret && ret->initWithAction(action, period)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -EaseElasticOut* EaseElasticOut::clone() const -{ - // no copy constructor - if (_inner) - return EaseElasticOut::create(_inner->clone(), _period); - - return nullptr; -} - -void EaseElasticOut::update(float time) -{ - _inner->update(tweenfunc::elasticEaseOut(time, _period)); -} - -EaseElastic* EaseElasticOut::reverse() const -{ - return EaseElasticIn::create(_inner->reverse(), _period); -} - -// -// EaseElasticInOut -// - -EaseElasticInOut* EaseElasticInOut::create(ActionInterval *action) -{ - return EaseElasticInOut::create(action, 0.3f); -} - -EaseElasticInOut* EaseElasticInOut::create(ActionInterval *action, float period/* = 0.3f*/) -{ - EaseElasticInOut *ret = new (std::nothrow) EaseElasticInOut(); - if (ret && ret->initWithAction(action, period)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -EaseElasticInOut* EaseElasticInOut::clone() const -{ - // no copy constructor - if (_inner) - return EaseElasticInOut::create(_inner->clone(), _period); - - return nullptr; -} - -void EaseElasticInOut::update(float time) -{ - _inner->update(tweenfunc::elasticEaseInOut(time, _period)); -} - -EaseElasticInOut* EaseElasticInOut::reverse() const -{ - return EaseElasticInOut::create(_inner->reverse(), _period); -} - -// -// EaseBounce -// - -// -// EaseBounceIn -// - -EaseBounceIn* EaseBounceIn::create(ActionInterval* action) -{ - EaseBounceIn *ret = new (std::nothrow) EaseBounceIn(); - if (ret && ret->initWithAction(action)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -EaseBounceIn* EaseBounceIn::clone() const -{ - // no copy constructor - if (_inner) - return EaseBounceIn::create(_inner->clone()); - - return nullptr; -} - -void EaseBounceIn::update(float time) -{ - _inner->update(tweenfunc::bounceEaseIn(time)); -} - -EaseBounce* EaseBounceIn::reverse() const -{ - return EaseBounceOut::create(_inner->reverse()); -} - -// -// EaseBounceOut -// - -EaseBounceOut* EaseBounceOut::create(ActionInterval* action) -{ - EaseBounceOut *ret = new (std::nothrow) EaseBounceOut(); - if (ret && ret->initWithAction(action)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -EaseBounceOut* EaseBounceOut::clone() const -{ - // no copy constructor - if (_inner) - return EaseBounceOut::create(_inner->clone()); - - return nullptr; -} - -void EaseBounceOut::update(float time) -{ - _inner->update(tweenfunc::bounceEaseOut(time)); -} - -EaseBounce* EaseBounceOut::reverse() const -{ - return EaseBounceIn::create(_inner->reverse()); -} - -// -// EaseBounceInOut -// - -EaseBounceInOut* EaseBounceInOut::create(ActionInterval* action) -{ - EaseBounceInOut *ret = new (std::nothrow) EaseBounceInOut(); - if (ret && ret->initWithAction(action)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -EaseBounceInOut* EaseBounceInOut::clone() const -{ - // no copy constructor - if (_inner) - return EaseBounceInOut::create(_inner->clone()); - - return nullptr; -} - -void EaseBounceInOut::update(float time) -{ - _inner->update(tweenfunc::bounceEaseInOut(time)); -} - -EaseBounceInOut* EaseBounceInOut::reverse() const -{ - return EaseBounceInOut::create(_inner->reverse()); -} - -// -// EaseBackIn -// - -EaseBackIn* EaseBackIn::create(ActionInterval *action) -{ - EaseBackIn *ret = new (std::nothrow) EaseBackIn(); - if (ret && ret->initWithAction(action)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -EaseBackIn* EaseBackIn::clone() const -{ - if (_inner) - return EaseBackIn::create(_inner->clone()); - - return nullptr; -} - -void EaseBackIn::update(float time) -{ - _inner->update(tweenfunc::backEaseIn(time)); -} - -ActionEase* EaseBackIn::reverse() const -{ - return EaseBackOut::create(_inner->reverse()); -} - -// -// EaseBackOut -// - -EaseBackOut* EaseBackOut::create(ActionInterval* action) -{ - EaseBackOut *ret = new (std::nothrow) EaseBackOut(); - if (ret && ret->initWithAction(action)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -EaseBackOut* EaseBackOut::clone() const -{ - if (_inner) - return EaseBackOut::create(_inner->clone()); - - return nullptr; -} - -void EaseBackOut::update(float time) -{ - _inner->update(tweenfunc::backEaseOut(time)); -} - -ActionEase* EaseBackOut::reverse() const -{ - return EaseBackIn::create(_inner->reverse()); -} - -// -// EaseBackInOut -// - -EaseBackInOut* EaseBackInOut::create(ActionInterval* action) -{ - EaseBackInOut *ret = new (std::nothrow) EaseBackInOut(); - if (ret && ret->initWithAction(action)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -EaseBackInOut* EaseBackInOut::clone() const -{ - if (_inner) - return EaseBackInOut::create(_inner->clone()); - - return nullptr; -} - -void EaseBackInOut::update(float time) -{ - _inner->update(tweenfunc::backEaseInOut(time)); -} - -EaseBackInOut* EaseBackInOut::reverse() const -{ - return EaseBackInOut::create(_inner->reverse()); -} - -EaseBezierAction* EaseBezierAction::create(cocos2d::ActionInterval* action) -{ - EaseBezierAction *ret = new (std::nothrow) EaseBezierAction(); - if (ret && ret->initWithAction(action)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -void EaseBezierAction::setBezierParamer( float p0, float p1, float p2, float p3) -{ - _p0 = p0; - _p1 = p1; - _p2 = p2; - _p3 = p3; -} - -EaseBezierAction* EaseBezierAction::clone() const -{ - // no copy constructor - if (_inner) - { - auto ret = EaseBezierAction::create(_inner->clone()); - if (ret) - { - ret->setBezierParamer(_p0,_p1,_p2,_p3); - } - return ret; - } - - return nullptr; -} - -void EaseBezierAction::update(float time) -{ - _inner->update(tweenfunc::bezieratFunction(_p0,_p1,_p2,_p3,time)); -} - -EaseBezierAction* EaseBezierAction::reverse() const -{ - EaseBezierAction* reverseAction = EaseBezierAction::create(_inner->reverse()); - reverseAction->setBezierParamer(_p3,_p2,_p1,_p0); - return reverseAction; -} - -// -// EaseQuadraticActionIn -// - -EaseQuadraticActionIn* EaseQuadraticActionIn::create(ActionInterval* action) -{ - EaseQuadraticActionIn *ret = new (std::nothrow) EaseQuadraticActionIn(); - if (ret && ret->initWithAction(action)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -EaseQuadraticActionIn* EaseQuadraticActionIn::clone() const -{ - // no copy constructor - if (_inner) - return EaseQuadraticActionIn::create(_inner->clone()); - - return nullptr; -} - -void EaseQuadraticActionIn::update(float time) -{ - _inner->update(tweenfunc::quadraticIn(time)); -} - -EaseQuadraticActionIn* EaseQuadraticActionIn::reverse() const -{ - return EaseQuadraticActionIn::create(_inner->reverse()); -} - -// -// EaseQuadraticActionOut -// - -EaseQuadraticActionOut* EaseQuadraticActionOut::create(ActionInterval* action) -{ - EaseQuadraticActionOut *ret = new (std::nothrow) EaseQuadraticActionOut(); - if (ret && ret->initWithAction(action)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -EaseQuadraticActionOut* EaseQuadraticActionOut::clone() const -{ - // no copy constructor - if (_inner) - return EaseQuadraticActionOut::create(_inner->clone()); - - return nullptr; -} - -void EaseQuadraticActionOut::update(float time) -{ - _inner->update(tweenfunc::quadraticOut(time)); -} - -EaseQuadraticActionOut* EaseQuadraticActionOut::reverse() const -{ - return EaseQuadraticActionOut::create(_inner->reverse()); -} - -// -// EaseQuadraticActionInOut -// - -EaseQuadraticActionInOut* EaseQuadraticActionInOut::create(ActionInterval* action) -{ - EaseQuadraticActionInOut *ret = new (std::nothrow) EaseQuadraticActionInOut(); - if (ret && ret->initWithAction(action)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -EaseQuadraticActionInOut* EaseQuadraticActionInOut::clone() const -{ - // no copy constructor - if (_inner) - return EaseQuadraticActionInOut::create(_inner->clone()); - - return nullptr; -} - -void EaseQuadraticActionInOut::update(float time) -{ - _inner->update(tweenfunc::quadraticInOut(time)); -} - -EaseQuadraticActionInOut* EaseQuadraticActionInOut::reverse() const -{ - return EaseQuadraticActionInOut::create(_inner->reverse()); -} - -// -// EaseQuarticActionIn -// -EaseQuarticActionIn* EaseQuarticActionIn::create(ActionInterval* action) -{ - EaseQuarticActionIn *ret = new (std::nothrow) EaseQuarticActionIn(); - if (ret && ret->initWithAction(action)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -EaseQuarticActionIn* EaseQuarticActionIn::clone() const -{ - // no copy constructor - if (_inner) - return EaseQuarticActionIn::create(_inner->clone()); - - return nullptr; -} - -void EaseQuarticActionIn::update(float time) -{ - _inner->update(tweenfunc::quartEaseIn(time)); -} - -EaseQuarticActionIn* EaseQuarticActionIn::reverse() const -{ - return EaseQuarticActionIn::create(_inner->reverse()); -} - -// -// EaseQuarticActionOut -// -EaseQuarticActionOut* EaseQuarticActionOut::create(ActionInterval* action) -{ - EaseQuarticActionOut *ret = new (std::nothrow) EaseQuarticActionOut(); - if (ret && ret->initWithAction(action)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -EaseQuarticActionOut* EaseQuarticActionOut::clone() const -{ - // no copy constructor - if (_inner) - return EaseQuarticActionOut::create(_inner->clone()); - - return nullptr; -} - -void EaseQuarticActionOut::update(float time) -{ - _inner->update(tweenfunc::quartEaseOut(time)); -} - -EaseQuarticActionOut* EaseQuarticActionOut::reverse() const -{ - return EaseQuarticActionOut::create(_inner->reverse()); -} - -// -// EaseQuarticActionInOut -// -EaseQuarticActionInOut* EaseQuarticActionInOut::create(ActionInterval* action) -{ - EaseQuarticActionInOut *ret = new (std::nothrow) EaseQuarticActionInOut(); - if (ret && ret->initWithAction(action)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -EaseQuarticActionInOut* EaseQuarticActionInOut::clone() const -{ - // no copy constructor - if (_inner) - return EaseQuarticActionInOut::create(_inner->clone()); - - return nullptr; -} - -void EaseQuarticActionInOut::update(float time) -{ - _inner->update(tweenfunc::quartEaseInOut(time)); -} - -EaseQuarticActionInOut* EaseQuarticActionInOut::reverse() const -{ - return EaseQuarticActionInOut::create(_inner->reverse()); -} - -// -// EaseQuinticActionIn -// -EaseQuinticActionIn* EaseQuinticActionIn::create(ActionInterval* action) -{ - EaseQuinticActionIn *ret = new (std::nothrow) EaseQuinticActionIn(); - if (ret && ret->initWithAction(action)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -EaseQuinticActionIn* EaseQuinticActionIn::clone() const -{ - // no copy constructor - if (_inner) - return EaseQuinticActionIn::create(_inner->clone()); - - return nullptr; -} - -void EaseQuinticActionIn::update(float time) -{ - _inner->update(tweenfunc::quintEaseIn(time)); -} - -EaseQuinticActionIn* EaseQuinticActionIn::reverse() const -{ - return EaseQuinticActionIn::create(_inner->reverse()); -} - -// -// EaseQuinticActionOut -// -EaseQuinticActionOut* EaseQuinticActionOut::create(ActionInterval* action) -{ - EaseQuinticActionOut *ret = new (std::nothrow) EaseQuinticActionOut(); - if (ret && ret->initWithAction(action)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -EaseQuinticActionOut* EaseQuinticActionOut::clone() const -{ - // no copy constructor - if (_inner) - return EaseQuinticActionOut::create(_inner->clone()); - - return nullptr; -} - -void EaseQuinticActionOut::update(float time) -{ - _inner->update(tweenfunc::quintEaseOut(time)); -} - -EaseQuinticActionOut* EaseQuinticActionOut::reverse() const -{ - return EaseQuinticActionOut::create(_inner->reverse()); -} - -// -// EaseQuinticActionInOut -// -EaseQuinticActionInOut* EaseQuinticActionInOut::create(ActionInterval* action) -{ - EaseQuinticActionInOut *ret = new (std::nothrow) EaseQuinticActionInOut(); - if (ret && ret->initWithAction(action)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -EaseQuinticActionInOut* EaseQuinticActionInOut::clone() const -{ - // no copy constructor - if (_inner) - return EaseQuinticActionInOut::create(_inner->clone()); - - return nullptr; -} - -void EaseQuinticActionInOut::update(float time) -{ - _inner->update(tweenfunc::quintEaseInOut(time)); -} - -EaseQuinticActionInOut* EaseQuinticActionInOut::reverse() const -{ - return EaseQuinticActionInOut::create(_inner->reverse()); -} - -// -// EaseCircleActionIn -// -EaseCircleActionIn* EaseCircleActionIn::create(ActionInterval* action) -{ - EaseCircleActionIn *ret = new (std::nothrow) EaseCircleActionIn(); - if (ret && ret->initWithAction(action)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -EaseCircleActionIn* EaseCircleActionIn::clone() const -{ - // no copy constructor - if (_inner) - return EaseCircleActionIn::create(_inner->clone()); - - return nullptr; -} - -void EaseCircleActionIn::update(float time) -{ - _inner->update(tweenfunc::circEaseIn(time)); -} - -EaseCircleActionIn* EaseCircleActionIn::reverse() const -{ - return EaseCircleActionIn::create(_inner->reverse()); -} - -// -// EaseCircleActionOut -// -EaseCircleActionOut* EaseCircleActionOut::create(ActionInterval* action) -{ - EaseCircleActionOut *ret = new (std::nothrow) EaseCircleActionOut(); - if (ret && ret->initWithAction(action)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -EaseCircleActionOut* EaseCircleActionOut::clone() const -{ - // no copy constructor - if (_inner) - return EaseCircleActionOut::create(_inner->clone()); - - return nullptr; -} - -void EaseCircleActionOut::update(float time) -{ - _inner->update(tweenfunc::circEaseOut(time)); -} - -EaseCircleActionOut* EaseCircleActionOut::reverse() const -{ - return EaseCircleActionOut::create(_inner->reverse()); -} - -// -// EaseCircleActionInOut -// -EaseCircleActionInOut* EaseCircleActionInOut::create(ActionInterval* action) -{ - EaseCircleActionInOut *ret = new (std::nothrow) EaseCircleActionInOut(); - if (ret && ret->initWithAction(action)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -EaseCircleActionInOut* EaseCircleActionInOut::clone() const -{ - // no copy constructor - if (_inner) - return EaseCircleActionInOut::create(_inner->clone()); - - return nullptr; -} - -void EaseCircleActionInOut::update(float time) -{ - _inner->update(tweenfunc::circEaseInOut(time)); -} - -EaseCircleActionInOut* EaseCircleActionInOut::reverse() const -{ - return EaseCircleActionInOut::create(_inner->reverse()); -} - -// -// EaseCubicActionIn -// - -EaseCubicActionIn* EaseCubicActionIn::create(ActionInterval* action) -{ - EaseCubicActionIn *ret = new (std::nothrow) EaseCubicActionIn(); - if (ret && ret->initWithAction(action)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -EaseCubicActionIn* EaseCubicActionIn::clone() const -{ - // no copy constructor - if (_inner) - return EaseCubicActionIn::create(_inner->clone()); - - return nullptr; -} - -void EaseCubicActionIn::update(float time) -{ - _inner->update(tweenfunc::cubicEaseIn(time)); -} - -EaseCubicActionIn* EaseCubicActionIn::reverse() const -{ - return EaseCubicActionIn::create(_inner->reverse()); -} - -// -// EaseCubicActionOut -// - -EaseCubicActionOut* EaseCubicActionOut::create(ActionInterval* action) -{ - EaseCubicActionOut *ret = new (std::nothrow) EaseCubicActionOut(); - if (ret && ret->initWithAction(action)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -EaseCubicActionOut* EaseCubicActionOut::clone() const -{ - // no copy constructor - if (_inner) - return EaseCubicActionOut::create(_inner->clone()); - - return nullptr; -} - -void EaseCubicActionOut::update(float time) -{ - _inner->update(tweenfunc::cubicEaseOut(time)); -} - -EaseCubicActionOut* EaseCubicActionOut::reverse() const -{ - return EaseCubicActionOut::create(_inner->reverse()); -} - -// -// EaseCubicActionInOut -// - -EaseCubicActionInOut* EaseCubicActionInOut::create(ActionInterval* action) -{ - EaseCubicActionInOut *ret = new (std::nothrow) EaseCubicActionInOut(); - if (ret && ret->initWithAction(action)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -EaseCubicActionInOut* EaseCubicActionInOut::clone() const -{ - // no copy constructor - if (_inner) - return EaseCubicActionInOut::create(_inner->clone()); - - return nullptr; -} - -void EaseCubicActionInOut::update(float time) -{ - _inner->update(tweenfunc::cubicEaseInOut(time)); -} - -EaseCubicActionInOut* EaseCubicActionInOut::reverse() const -{ - if (_inner) - return EaseCubicActionInOut::create(_inner->reverse()); - - return nullptr; -} - -NS_CC_END diff --git a/native/cocos/2d/CCActionEase.h b/native/cocos/2d/CCActionEase.h deleted file mode 100644 index dfc93b8c7e..0000000000 --- a/native/cocos/2d/CCActionEase.h +++ /dev/null @@ -1,1281 +0,0 @@ -/**************************************************************************** -Copyright (c) 2008-2009 Jason Booth -Copyright (c) 2010-2012 cocos2d-x.org -Copyright (c) 2013-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ - -#ifndef __ACTION_CCEASE_ACTION_H__ -#define __ACTION_CCEASE_ACTION_H__ - -#include "2d/CCActionInterval.h" - -NS_CC_BEGIN - -/** - * @addtogroup actions - * @{ - */ - -/** - @class ActionEase - @brief Base class for Easing actions. - @details Ease actions are created from other interval actions. - The ease action will change the timeline of the inner action. - @ingroup Actions - */ -class CC_DLL ActionEase : public ActionInterval -{ -public: - - /** - @brief Get the pointer of the inner action. - @return The pointer of the inner action. - */ - virtual ActionInterval* getInnerAction(); - - // - // Overrides - // - virtual ActionEase* clone() const override - { - CC_ASSERT(0); - return nullptr; - } - - virtual ActionEase* reverse() const override - { - CC_ASSERT(0); - return nullptr; - } - - virtual void startWithTarget(Node *target) override; - virtual void stop() override; - virtual void update(float time) override; - -CC_CONSTRUCTOR_ACCESS: - ActionEase() - : _inner(nullptr) - {} - - virtual ~ActionEase(); - /** - @brief Initializes the action. - @return Return true when the initialization success, otherwise return false. - */ - bool initWithAction(ActionInterval *action); - -protected: - /** The inner action */ - ActionInterval *_inner; -private: - CC_DISALLOW_COPY_AND_ASSIGN(ActionEase); -}; - -/** - @class EaseRateAction - @brief Base class for Easing actions with rate parameters. - @details Ease the inner action with specified rate. - @ingroup Actions - */ -class CC_DLL EaseRateAction : public ActionEase -{ -public: - /** - @brief Creates the action with the inner action and the rate parameter. - @param action A given ActionInterval - @param rate A given rate - @return An autoreleased EaseRateAction object. - **/ - static EaseRateAction* create(ActionInterval* action, float rate); - - /** - @brief Set the rate value for the ease rate action. - @param rate The value will be set. - */ - inline void setRate(float rate) { _rate = rate; } - /** - @brief Get the rate value of the ease rate action. - @return Return the rate value of the ease rate action. - */ - inline float getRate() const { return _rate; } - - // - // Overrides - // - virtual EaseRateAction* clone() const override - { - CC_ASSERT(0); - return nullptr; - } - virtual EaseRateAction* reverse() const override - { - CC_ASSERT(0); - return nullptr; - } - -CC_CONSTRUCTOR_ACCESS: - EaseRateAction() {} - virtual ~EaseRateAction(); - /** - @brief Initializes the action with the inner action and the rate parameter. - @param pAction The pointer of the inner action. - @param fRate The value of the rate parameter. - @return Return true when the initialization success, otherwise return false. - */ - bool initWithAction(ActionInterval *pAction, float fRate); - -protected: - float _rate; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(EaseRateAction); -}; - -/** - @class EaseIn - @brief EaseIn action with a rate. - @details The timeline of inner action will be changed by: - \f${ time }^{ rate }\f$. - @ingroup Actions - */ -class CC_DLL EaseIn : public EaseRateAction -{ -public: - /** - @brief Create the action with the inner action and the rate parameter. - @param action The pointer of the inner action. - @param rate The value of the rate parameter. - @return A pointer of EaseIn action. If creation failed, return nil. - */ - static EaseIn* create(ActionInterval* action, float rate); - - // Overrides - virtual void update(float time) override; - virtual EaseIn* clone() const override; - virtual EaseIn* reverse() const override; - -CC_CONSTRUCTOR_ACCESS: - EaseIn() {} - virtual ~EaseIn() {} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(EaseIn); -}; - -/** - @class EaseOut - @brief EaseOut action with a rate. - @details The timeline of inner action will be changed by: - \f${ time }^ { (1/rate) }\f$. - @ingroup Actions - */ -class CC_DLL EaseOut : public EaseRateAction -{ -public: - /** - @brief Create the action with the inner action and the rate parameter. - @param action The pointer of the inner action. - @param rate The value of the rate parameter. - @return A pointer of EaseOut action. If creation failed, return nil. - */ - static EaseOut* create(ActionInterval* action, float rate); - - // Overrides - virtual void update(float time) override; - virtual EaseOut* clone() const override; - virtual EaseOut* reverse() const override; - -CC_CONSTRUCTOR_ACCESS: - EaseOut() {} - virtual ~EaseOut() {} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(EaseOut); -}; - -/** - @class EaseInOut - @brief EaseInOut action with a rate - @details If time * 2 < 1, the timeline of inner action will be changed by: - \f$0.5*{ time }^{ rate }\f$. - Else, the timeline of inner action will be changed by: - \f$1.0-0.5*{ 2-time }^{ rate }\f$. - @ingroup Actions - */ -class CC_DLL EaseInOut : public EaseRateAction -{ -public: - /** - @brief Create the action with the inner action and the rate parameter. - @param action The pointer of the inner action. - @param rate The value of the rate parameter. - @return A pointer of EaseInOut action. If creation failed, return nil. - */ - static EaseInOut* create(ActionInterval* action, float rate); - - // Overrides - virtual void update(float time) override; - virtual EaseInOut* clone() const override; - virtual EaseInOut* reverse() const override; - -CC_CONSTRUCTOR_ACCESS: - EaseInOut() {} - virtual ~EaseInOut() {} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(EaseInOut); -}; - -/** - @class EaseExponentialIn - @brief Ease Exponential In action. - @details The timeline of inner action will be changed by: - \f${ 2 }^{ 10*(time-1) }-1*0.001\f$. - @ingroup Actions - */ -class CC_DLL EaseExponentialIn : public ActionEase -{ -public: - /** - @brief Create the action with the inner action. - @param action The pointer of the inner action. - @return A pointer of EaseExponentialIn action. If creation failed, return nil. - */ - static EaseExponentialIn* create(ActionInterval* action); - - // Overrides - virtual void update(float time) override; - virtual EaseExponentialIn* clone() const override; - virtual ActionEase* reverse() const override; - -CC_CONSTRUCTOR_ACCESS: - EaseExponentialIn() {} - virtual ~EaseExponentialIn() {} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(EaseExponentialIn); -}; - -/** - @class EaseExponentialOut - @brief Ease Exponential Out - @details The timeline of inner action will be changed by: - \f$1-{ 2 }^{ -10*(time-1) }\f$. - @ingroup Actions - */ -class CC_DLL EaseExponentialOut : public ActionEase -{ -public: - /** - @brief Create the action with the inner action. - @param action The pointer of the inner action. - @return A pointer of EaseExponentialOut action. If creation failed, return nil. - */ - static EaseExponentialOut* create(ActionInterval* action); - - // Overrides - virtual void update(float time) override; - virtual EaseExponentialOut* clone() const override; - virtual ActionEase* reverse() const override; - -CC_CONSTRUCTOR_ACCESS: - EaseExponentialOut() {} - virtual ~EaseExponentialOut() {} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(EaseExponentialOut); -}; - -/** - @class EaseExponentialInOut - @brief Ease Exponential InOut - @details If time * 2 < 1, the timeline of inner action will be changed by: - \f$0.5*{ 2 }^{ 10*(time-1) }\f$. - else, the timeline of inner action will be changed by: - \f$0.5*(2-{ 2 }^{ -10*(time-1) })\f$. - @ingroup Actions - */ -class CC_DLL EaseExponentialInOut : public ActionEase -{ -public: - /** - @brief Create the action with the inner action. - @param action The pointer of the inner action. - @return A pointer of EaseExponentialInOut action. If creation failed, return nil. - */ - static EaseExponentialInOut* create(ActionInterval* action); - - // Overrides - virtual void update(float time) override; - virtual EaseExponentialInOut* clone() const override; - virtual EaseExponentialInOut* reverse() const override; - -CC_CONSTRUCTOR_ACCESS: - EaseExponentialInOut() {} - virtual ~EaseExponentialInOut() {} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(EaseExponentialInOut); -}; - -/** - @class EaseSineIn - @brief Ease Sine In - @details The timeline of inner action will be changed by: - \f$1-cos(time*\frac { \pi }{ 2 } )\f$. - @ingroup Actions - */ -class CC_DLL EaseSineIn : public ActionEase -{ -public: - /** - @brief Create the action with the inner action. - @param action The pointer of the inner action. - @return A pointer of EaseSineIn action. If creation failed, return nil. - */ - static EaseSineIn* create(ActionInterval* action); - - // Overrides - virtual void update(float time) override; - virtual EaseSineIn* clone() const override; - virtual ActionEase* reverse() const override; - -CC_CONSTRUCTOR_ACCESS: - EaseSineIn() {} - virtual ~EaseSineIn() {} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(EaseSineIn); -}; - -/** - @class EaseSineOut - @brief Ease Sine Out - @details The timeline of inner action will be changed by: - \f$sin(time*\frac { \pi }{ 2 } )\f$. - @ingroup Actions - */ -class CC_DLL EaseSineOut : public ActionEase -{ -public: - /** - @brief Create the action with the inner action. - @param action The pointer of the inner action. - @return A pointer of EaseSineOut action. If creation failed, return nil. - */ - static EaseSineOut* create(ActionInterval* action); - - // Overrides - virtual void update(float time) override; - virtual EaseSineOut* clone() const override; - virtual ActionEase* reverse() const override; - -CC_CONSTRUCTOR_ACCESS: - EaseSineOut() {} - virtual ~EaseSineOut() {} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(EaseSineOut); -}; - -/** - @class EaseSineInOut - @brief Ease Sine InOut - @details The timeline of inner action will be changed by: - \f$-0.5*(cos(\pi *time)-1)\f$. - @ingroup Actions - */ -class CC_DLL EaseSineInOut : public ActionEase -{ -public: - /** - @brief Create the action with the inner action. - @param action The pointer of the inner action. - @return A pointer of EaseSineInOut action. If creation failed, return nil. - */ - static EaseSineInOut* create(ActionInterval* action); - - // Overrides - virtual void update(float time) override; - virtual EaseSineInOut* clone() const override; - virtual EaseSineInOut* reverse() const override; - -CC_CONSTRUCTOR_ACCESS: - EaseSineInOut() {} - virtual ~EaseSineInOut() {} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(EaseSineInOut); -}; - -/** - @class EaseElastic - @brief Ease Elastic abstract class - @since v0.8.2 - @ingroup Actions - */ -class CC_DLL EaseElastic : public ActionEase -{ -public: - - /** - @brief Get period of the wave in radians. Default value is 0.3. - @return Return the period of the wave in radians. - */ - inline float getPeriod() const { return _period; } - /** - @brief Set period of the wave in radians. - @param fPeriod The value will be set. - */ - inline void setPeriod(float fPeriod) { _period = fPeriod; } - - // - // Overrides - // - virtual EaseElastic* clone() const override - { - CC_ASSERT(0); - return nullptr; - } - - virtual EaseElastic* reverse() const override - { - CC_ASSERT(0); - return nullptr; - } - -CC_CONSTRUCTOR_ACCESS: - EaseElastic() {} - virtual ~EaseElastic() {} - /** - @brief Initializes the action with the inner action and the period in radians. - @param action The pointer of the inner action. - @param period Period of the wave in radians. Default is 0.3. - @return Return true when the initialization success, otherwise return false. - */ - bool initWithAction(ActionInterval *action, float period = 0.3f); - -protected: - float _period; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(EaseElastic); - -}; - -/** - @class EaseElasticIn - @brief Ease Elastic In action. - @details If time == 0 or time == 1, the timeline of inner action will not be changed. - Else, the timeline of inner action will be changed by: - \f$-{ 2 }^{ 10*(time-1) }*sin((time-1-\frac { period }{ 4 } )*\pi *2/period)\f$. - - @warning This action doesn't use a bijective function. - Actions like Sequence might have an unexpected result when used with this action. - @since v0.8.2 - @ingroup Actions - */ -class CC_DLL EaseElasticIn : public EaseElastic -{ -public: - /** - @brief Create the EaseElasticIn action with the inner action and the period in radians. - @param action The pointer of the inner action. - @param period Period of the wave in radians. - @return A pointer of EaseElasticIn action. If creation failed, return nil. - */ - static EaseElasticIn* create(ActionInterval *action, float period); - - /** - @brief Create the EaseElasticIn action with the inner action and period value is 0.3. - @param action The pointer of the inner action. - @return A pointer of EaseElasticIn action. If creation failed, return nil. - */ - static EaseElasticIn* create(ActionInterval *action); - - // Overrides - virtual void update(float time) override; - virtual EaseElasticIn* clone() const override; - virtual EaseElastic* reverse() const override; - -CC_CONSTRUCTOR_ACCESS: - EaseElasticIn() {} - virtual ~EaseElasticIn() {} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(EaseElasticIn); -}; - -/** - @class EaseElasticOut - @brief Ease Elastic Out action. - @details If time == 0 or time == 1, the timeline of inner action will not be changed. - Else, the timeline of inner action will be changed by: - \f${ 2 }^{ -10*time }*sin((time-\frac { period }{ 4 } )*\pi *2/period)+1\f$. - @warning This action doesn't use a bijective function. - Actions like Sequence might have an unexpected result when used with this action. - @since v0.8.2 - @ingroup Actions - */ -class CC_DLL EaseElasticOut : public EaseElastic -{ -public: - /** - @brief Create the EaseElasticOut action with the inner action and the period in radians. - @param action The pointer of the inner action. - @param period Period of the wave in radians. - @return A pointer of EaseElasticOut action. If creation failed, return nil. - */ - static EaseElasticOut* create(ActionInterval *action, float period); - - /** - @brief Create the EaseElasticOut action with the inner action and period value is 0.3. - @param action The pointer of the inner action. - @return A pointer of EaseElasticOut action. If creation failed, return nil. - */ - static EaseElasticOut* create(ActionInterval *action); - - // Overrides - virtual void update(float time) override; - virtual EaseElasticOut* clone() const override; - virtual EaseElastic* reverse() const override; - -CC_CONSTRUCTOR_ACCESS: - EaseElasticOut() {} - virtual ~EaseElasticOut() {} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(EaseElasticOut); -}; - -/** - @class EaseElasticInOut - @brief Ease Elastic InOut action. - @warning This action doesn't use a bijective function. - Actions like Sequence might have an unexpected result when used with this action. - @since v0.8.2 - @ingroup Actions - */ -class CC_DLL EaseElasticInOut : public EaseElastic -{ -public: - /** - @brief Create the EaseElasticInOut action with the inner action and the period in radians. - @param action The pointer of the inner action. - @param period Period of the wave in radians. - @return A pointer of EaseElasticInOut action. If creation failed, return nil. - */ - static EaseElasticInOut* create(ActionInterval *action, float period); - - /** - @brief Create the EaseElasticInOut action with the inner action and period value is 0.3. - @param action The pointer of the inner action. - @return A pointer of EaseElasticInOut action. If creation failed, return nil. - */ - static EaseElasticInOut* create(ActionInterval *action); - - // Overrides - virtual void update(float time) override; - virtual EaseElasticInOut* clone() const override; - virtual EaseElasticInOut* reverse() const override; - -CC_CONSTRUCTOR_ACCESS: - EaseElasticInOut() {} - virtual ~EaseElasticInOut() {} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(EaseElasticInOut); -}; - -/** - @class EaseBounce - @brief EaseBounce abstract class. - @since v0.8.2 - @ingroup Actions -*/ -class CC_DLL EaseBounce : public ActionEase -{ -public: - - // Overrides - virtual EaseBounce* clone() const override - { - CC_ASSERT(0); - return nullptr; - } - - virtual EaseBounce* reverse() const override - { - CC_ASSERT(0); - return nullptr; - } - -CC_CONSTRUCTOR_ACCESS: - EaseBounce() {} - virtual ~EaseBounce() {} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(EaseBounce); -}; - -/** - @class EaseBounceIn - @brief EaseBounceIn action. - @warning This action doesn't use a bijective function. - Actions like Sequence might have an unexpected result when used with this action. - @since v0.8.2 - @ingroup Actions -*/ -class CC_DLL EaseBounceIn : public EaseBounce -{ -public: - /** - @brief Create the action with the inner action. - @param action The pointer of the inner action. - @return A pointer of EaseBounceIn action. If creation failed, return nil. - */ - static EaseBounceIn* create(ActionInterval* action); - - // Overrides - virtual void update(float time) override; - virtual EaseBounceIn* clone() const override; - virtual EaseBounce* reverse() const override; - -CC_CONSTRUCTOR_ACCESS: - EaseBounceIn() {} - virtual ~EaseBounceIn() {} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(EaseBounceIn); -}; - -/** - @class EaseBounceOut - @brief EaseBounceOut action. - @warning This action doesn't use a bijective function. - Actions like Sequence might have an unexpected result when used with this action. - @since v0.8.2 - @ingroup Actions - */ -class CC_DLL EaseBounceOut : public EaseBounce -{ -public: - /** - @brief Create the action with the inner action. - @param action The pointer of the inner action. - @return A pointer of EaseBounceOut action. If creation failed, return nil. - */ - static EaseBounceOut* create(ActionInterval* action); - - // Overrides - virtual void update(float time) override; - virtual EaseBounceOut* clone() const override; - virtual EaseBounce* reverse() const override; - -CC_CONSTRUCTOR_ACCESS: - EaseBounceOut() {} - virtual ~EaseBounceOut() {} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(EaseBounceOut); -}; - -/** - @class EaseBounceInOut - @brief EaseBounceInOut action. - @warning This action doesn't use a bijective function. - Actions like Sequence might have an unexpected result when used with this action. - @since v0.8.2 - @ingroup Actions - */ -class CC_DLL EaseBounceInOut : public EaseBounce -{ -public: - /** - @brief Create the action with the inner action. - @param action The pointer of the inner action. - @return A pointer of EaseBounceInOut action. If creation failed, return nil. - */ - static EaseBounceInOut* create(ActionInterval* action); - - // Overrides - virtual void update(float time) override; - virtual EaseBounceInOut* clone() const override; - virtual EaseBounceInOut* reverse() const override; - -CC_CONSTRUCTOR_ACCESS: - EaseBounceInOut() {} - virtual ~EaseBounceInOut() {} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(EaseBounceInOut); -}; - -/** - @class EaseBackIn - @brief EaseBackIn action. - @warning This action doesn't use a bijective function. - Actions like Sequence might have an unexpected result when used with this action. - @since v0.8.2 - @ingroup Actions - */ -class CC_DLL EaseBackIn : public ActionEase -{ -public: - /** - @brief Create the action with the inner action. - @param action The pointer of the inner action. - @return A pointer of EaseBackIn action. If creation failed, return nil. - */ - static EaseBackIn* create(ActionInterval* action); - - // Overrides - virtual void update(float time) override; - virtual EaseBackIn* clone() const override; - virtual ActionEase* reverse() const override; - -CC_CONSTRUCTOR_ACCESS: - EaseBackIn() {} - virtual ~EaseBackIn() {} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(EaseBackIn); -}; - -/** - @class EaseBackOut - @brief EaseBackOut action. - @warning This action doesn't use a bijective function. - Actions like Sequence might have an unexpected result when used with this action. - @since v0.8.2 - @ingroup Actions - */ -class CC_DLL EaseBackOut : public ActionEase -{ -public: - /** - @brief Create the action with the inner action. - @param action The pointer of the inner action. - @return A pointer of EaseBackOut action. If creation failed, return nil. - */ - static EaseBackOut* create(ActionInterval* action); - - // Overrides - virtual void update(float time) override; - virtual EaseBackOut* clone() const override; - virtual ActionEase* reverse() const override; - -CC_CONSTRUCTOR_ACCESS: - EaseBackOut() {} - virtual ~EaseBackOut() {} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(EaseBackOut); -}; - -/** - @class EaseBackInOut - @brief EaseBackInOut action. - @warning This action doesn't use a bijective function. - Actions like Sequence might have an unexpected result when used with this action. - @since v0.8.2 - @ingroup Actions - */ -class CC_DLL EaseBackInOut : public ActionEase -{ -public: - /** - @brief Create the action with the inner action. - @param action The pointer of the inner action. - @return A pointer of EaseBackInOut action. If creation failed, return nil. - */ - static EaseBackInOut* create(ActionInterval* action); - - // Overrides - virtual void update(float time) override; - virtual EaseBackInOut* clone() const override; - virtual EaseBackInOut* reverse() const override; - -CC_CONSTRUCTOR_ACCESS: - EaseBackInOut() {} - virtual ~EaseBackInOut() {} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(EaseBackInOut); -}; - - -/** -@class EaseBezierAction -@brief Ease Bezier -@ingroup Actions -*/ -class CC_DLL EaseBezierAction : public ActionEase -{ -public: - /** - @brief Create the action with the inner action. - @param action The pointer of the inner action. - @return A pointer of EaseBezierAction action. If creation failed, return nil. - */ - static EaseBezierAction* create(ActionInterval* action); - - virtual void update(float time) override; - virtual EaseBezierAction* clone() const override; - virtual EaseBezierAction* reverse() const override; - - /** - @brief Set the bezier parameters. - */ - virtual void setBezierParamer( float p0, float p1, float p2, float p3); - -CC_CONSTRUCTOR_ACCESS: - EaseBezierAction() {} - virtual ~EaseBezierAction() {} - -protected: - float _p0; - float _p1; - float _p2; - float _p3; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(EaseBezierAction); -}; - -/** -@class EaseQuadraticActionIn -@brief Ease Quadratic In -@ingroup Actions -*/ -class CC_DLL EaseQuadraticActionIn : public ActionEase -{ -public: - /** - @brief Create the action with the inner action. - @param action The pointer of the inner action. - @return A pointer of EaseQuadraticActionIn action. If creation failed, return nil. - */ - static EaseQuadraticActionIn* create(ActionInterval* action); - - virtual void update(float time) override; - virtual EaseQuadraticActionIn* clone() const override; - virtual EaseQuadraticActionIn* reverse() const override; - -CC_CONSTRUCTOR_ACCESS: - EaseQuadraticActionIn() {} - virtual ~EaseQuadraticActionIn() {} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(EaseQuadraticActionIn); - -}; - -/** -@class EaseQuadraticActionOut -@brief Ease Quadratic Out -@ingroup Actions -*/ -class CC_DLL EaseQuadraticActionOut : public ActionEase -{ -public: - /** - @brief Create the action with the inner action. - @param action The pointer of the inner action. - @return A pointer of EaseQuadraticActionOut action. If creation failed, return nil. - */ - static EaseQuadraticActionOut* create(ActionInterval* action); - - virtual void update(float time) override; - virtual EaseQuadraticActionOut* clone() const override; - virtual EaseQuadraticActionOut* reverse() const override; - -CC_CONSTRUCTOR_ACCESS: - EaseQuadraticActionOut() {} - virtual ~EaseQuadraticActionOut() {} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(EaseQuadraticActionOut); - -}; - -/** -@class EaseQuadraticActionInOut -@brief Ease Quadratic InOut -@ingroup Actions -*/ -class CC_DLL EaseQuadraticActionInOut : public ActionEase -{ -public: - /** - @brief Create the action with the inner action. - @param action The pointer of the inner action. - @return A pointer of EaseQuadraticActionInOut action. If creation failed, return nil. - */ - static EaseQuadraticActionInOut* create(ActionInterval* action); - - virtual void update(float time) override; - virtual EaseQuadraticActionInOut* clone() const override; - virtual EaseQuadraticActionInOut* reverse() const override; - -CC_CONSTRUCTOR_ACCESS: - EaseQuadraticActionInOut() {} - virtual ~EaseQuadraticActionInOut() {} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(EaseQuadraticActionInOut); -}; - -/** -@class EaseQuarticActionIn -@brief Ease Quartic In -@ingroup Actions -*/ -class CC_DLL EaseQuarticActionIn : public ActionEase -{ -public: - /** - @brief Create the action with the inner action. - @param action The pointer of the inner action. - @return A pointer of EaseQuarticActionIn action. If creation failed, return nil. - */ - static EaseQuarticActionIn* create(ActionInterval* action); - - virtual void update(float time) override; - virtual EaseQuarticActionIn* clone() const override; - virtual EaseQuarticActionIn* reverse() const override; - -CC_CONSTRUCTOR_ACCESS: - EaseQuarticActionIn() {} - virtual ~EaseQuarticActionIn() {} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(EaseQuarticActionIn); -}; - -/** -@class EaseQuarticActionOut -@brief Ease Quartic Out -@ingroup Actions -*/ -class CC_DLL EaseQuarticActionOut : public ActionEase -{ -public: - /** - @brief Create the action with the inner action. - @param action The pointer of the inner action. - @return A pointer of EaseQuarticActionOut action. If creation failed, return nil. - */ - static EaseQuarticActionOut* create(ActionInterval* action); - - virtual void update(float time) override; - virtual EaseQuarticActionOut* clone() const override; - virtual EaseQuarticActionOut* reverse() const override; - -CC_CONSTRUCTOR_ACCESS: - EaseQuarticActionOut() {} - virtual ~EaseQuarticActionOut() {} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(EaseQuarticActionOut); -}; - -/** -@class EaseQuarticActionInOut -@brief Ease Quartic InOut -@ingroup Actions -*/ -class CC_DLL EaseQuarticActionInOut : public ActionEase -{ -public: - /** - @brief Create the action with the inner action. - @param action The pointer of the inner action. - @return A pointer of EaseQuarticActionInOut action. If creation failed, return nil. - */ - static EaseQuarticActionInOut* create(ActionInterval* action); - - virtual void update(float time) override; - virtual EaseQuarticActionInOut* clone() const override; - virtual EaseQuarticActionInOut* reverse() const override; - -CC_CONSTRUCTOR_ACCESS: - EaseQuarticActionInOut() {} - virtual ~EaseQuarticActionInOut() {} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(EaseQuarticActionInOut); -}; - - -/** -@class EaseQuinticActionIn -@brief Ease Quintic In -@ingroup Actions -*/ -class CC_DLL EaseQuinticActionIn : public ActionEase -{ -public: - /** - @brief Create the action with the inner action. - @param action The pointer of the inner action. - @return A pointer of EaseQuinticActionIn action. If creation failed, return nil. - */ - static EaseQuinticActionIn* create(ActionInterval* action); - - virtual void update(float time) override; - virtual EaseQuinticActionIn* clone() const override; - virtual EaseQuinticActionIn* reverse() const override; - -CC_CONSTRUCTOR_ACCESS: - EaseQuinticActionIn() {} - virtual ~EaseQuinticActionIn() {} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(EaseQuinticActionIn); -}; - -/** -@class EaseQuinticActionOut -@brief Ease Quintic Out -@ingroup Actions -*/ -class CC_DLL EaseQuinticActionOut : public ActionEase -{ -public: - /** - @brief Create the action with the inner action. - @param action The pointer of the inner action. - @return A pointer of EaseQuinticActionOut action. If creation failed, return nil. - */ - static EaseQuinticActionOut* create(ActionInterval* action); - - virtual void update(float time) override; - virtual EaseQuinticActionOut* clone() const override; - virtual EaseQuinticActionOut* reverse() const override; - -CC_CONSTRUCTOR_ACCESS: - EaseQuinticActionOut() {} - virtual ~EaseQuinticActionOut() {} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(EaseQuinticActionOut); -}; - -/** -@class EaseQuinticActionInOut -@brief Ease Quintic InOut -@ingroup Actions -*/ -class CC_DLL EaseQuinticActionInOut : public ActionEase -{ -public: - /** - @brief Create the action with the inner action. - @param action The pointer of the inner action. - @return A pointer of EaseQuinticActionInOut action. If creation failed, return nil. - */ - static EaseQuinticActionInOut* create(ActionInterval* action); - - virtual void update(float time) override; - virtual EaseQuinticActionInOut* clone() const override; - virtual EaseQuinticActionInOut* reverse() const override; - -CC_CONSTRUCTOR_ACCESS: - EaseQuinticActionInOut() {} - virtual ~EaseQuinticActionInOut() {} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(EaseQuinticActionInOut); -}; - -/** -@class EaseCircleActionIn -@brief Ease Circle In -@ingroup Actions -*/ -class CC_DLL EaseCircleActionIn : public ActionEase -{ -public: - /** - @brief Create the action with the inner action. - @param action The pointer of the inner action. - @return A pointer of EaseCircleActionIn action. If creation failed, return nil. - */ - static EaseCircleActionIn* create(ActionInterval* action); - - virtual void update(float time) override; - virtual EaseCircleActionIn* clone() const override; - virtual EaseCircleActionIn* reverse() const override; - -CC_CONSTRUCTOR_ACCESS: - EaseCircleActionIn() {} - virtual ~EaseCircleActionIn() {} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(EaseCircleActionIn); -}; - -/** -@class EaseCircleActionOut -@brief Ease Circle Out -@ingroup Actions -*/ -class CC_DLL EaseCircleActionOut : public ActionEase -{ -public: - /** - @brief Create the action with the inner action. - @param action The pointer of the inner action. - @return A pointer of EaseCircleActionOut action. If creation failed, return nil. - */ - static EaseCircleActionOut* create(ActionInterval* action); - - virtual void update(float time) override; - virtual EaseCircleActionOut* clone() const override; - virtual EaseCircleActionOut* reverse() const override; - -CC_CONSTRUCTOR_ACCESS: - EaseCircleActionOut() {} - virtual ~EaseCircleActionOut() {} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(EaseCircleActionOut); -}; - -/** -@class EaseCircleActionInOut -@brief Ease Circle InOut -@ingroup Actions -*/ -class CC_DLL EaseCircleActionInOut:public ActionEase -{ -public: - /** - @brief Create the action with the inner action. - @param action The pointer of the inner action. - @return A pointer of EaseCircleActionInOut action. If creation failed, return nil. - */ - static EaseCircleActionInOut* create(ActionInterval* action); - - virtual void update(float time) override; - virtual EaseCircleActionInOut* clone() const override; - virtual EaseCircleActionInOut* reverse() const override; - -CC_CONSTRUCTOR_ACCESS: - EaseCircleActionInOut() {} - virtual ~EaseCircleActionInOut() {} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(EaseCircleActionInOut); -}; - -/** -@class EaseCubicActionIn -@brief Ease Cubic In -@ingroup Actions -*/ -class CC_DLL EaseCubicActionIn:public ActionEase -{ -public: - /** - @brief Create the action with the inner action. - @param action The pointer of the inner action. - @return A pointer of EaseCubicActionIn action. If creation failed, return nil. - */ - static EaseCubicActionIn* create(ActionInterval* action); - - virtual void update(float time) override; - virtual EaseCubicActionIn* clone() const override; - virtual EaseCubicActionIn* reverse() const override; - -CC_CONSTRUCTOR_ACCESS: - EaseCubicActionIn() {} - virtual ~EaseCubicActionIn() {} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(EaseCubicActionIn); -}; - -/** -@class EaseCubicActionOut -@brief Ease Cubic Out -@ingroup Actions -*/ -class CC_DLL EaseCubicActionOut : public ActionEase -{ -public: - /** - @brief Create the action with the inner action. - @param action The pointer of the inner action. - @return A pointer of EaseCubicActionOut action. If creation failed, return nil. - */ - static EaseCubicActionOut* create(ActionInterval* action); - - virtual void update(float time) override; - virtual EaseCubicActionOut* clone() const override; - virtual EaseCubicActionOut* reverse() const override; - -CC_CONSTRUCTOR_ACCESS: - EaseCubicActionOut() {} - virtual ~EaseCubicActionOut() {} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(EaseCubicActionOut); -}; - -/** -@class EaseCubicActionInOut -@brief Ease Cubic InOut -@ingroup Actions -*/ -class CC_DLL EaseCubicActionInOut : public ActionEase -{ -public: - /** - @brief Create the action with the inner action. - @param action The pointer of the inner action. - @return A pointer of EaseCubicActionInOut action. If creation failed, return nil. - */ - static EaseCubicActionInOut* create(ActionInterval* action); - - virtual void update(float time) override; - virtual EaseCubicActionInOut* clone() const override; - virtual EaseCubicActionInOut* reverse() const override; - -CC_CONSTRUCTOR_ACCESS: - EaseCubicActionInOut() {} - virtual ~EaseCubicActionInOut() {} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(EaseCubicActionInOut); -}; - -// end of actions group -/// @} - -NS_CC_END - -#endif // __ACTION_CCEASE_ACTION_H__ - diff --git a/native/cocos/2d/CCActionGrid.cpp b/native/cocos/2d/CCActionGrid.cpp deleted file mode 100644 index e16b9019b9..0000000000 --- a/native/cocos/2d/CCActionGrid.cpp +++ /dev/null @@ -1,445 +0,0 @@ -/**************************************************************************** -Copyright (c) 2009 On-Core -Copyright (c) 2010-2012 cocos2d-x.org -Copyright (c) 2013-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ - -#include "2d/CCActionGrid.h" - -#include "2d/CCGrid.h" -#include "2d/CCNodeGrid.h" -#include "base/CCDirector.h" - -NS_CC_BEGIN -// implementation of GridAction - -bool GridAction::initWithDuration(float duration, const Size& gridSize) -{ - if (ActionInterval::initWithDuration(duration)) - { - _gridSize = gridSize; - - return true; - } - - return false; -} - -void GridAction::startWithTarget(Node *target) -{ - ActionInterval::startWithTarget(target); - cacheTargetAsGridNode(); - - GridBase *newgrid = this->getGrid(); - - GridBase *targetGrid = _gridNodeTarget->getGrid(); - - if (targetGrid && targetGrid->getReuseGrid() > 0) - { - if (targetGrid->isActive() && targetGrid->getGridSize().width == _gridSize.width - && targetGrid->getGridSize().height == _gridSize.height) - { - targetGrid->reuse(); - } - else - { - CCASSERT(0, "Invalid grid parameters!"); - } - } - else - { - if (targetGrid && targetGrid->isActive()) - { - targetGrid->setActive(false); - } - - _gridNodeTarget->setGrid(newgrid); - _gridNodeTarget->getGrid()->setActive(true); - } -} - -void GridAction::cacheTargetAsGridNode() -{ - _gridNodeTarget = dynamic_cast (_target); - CCASSERT(_gridNodeTarget, "GridActions can only used on NodeGrid"); -} - -GridAction* GridAction::reverse() const -{ - // FIXME: This conversion isn't safe. - return (GridAction*)ReverseTime::create( this->clone() ); -} - -GridBase* GridAction::getGrid() -{ - // Abstract class needs implementation - CCASSERT(0, "Subclass should implement this method!"); - - return nullptr; -} - -// implementation of Grid3DAction - -GridBase* Grid3DAction::getGrid() -{ - return Grid3D::create(_gridSize, _gridNodeTarget->getGridRect()); -} - -Vec3 Grid3DAction::getVertex(const Vec2& position) const -{ - Grid3D *g = (Grid3D*)_gridNodeTarget->getGrid(); - return g->getVertex(position); -} - -Vec3 Grid3DAction::getOriginalVertex(const Vec2& position) const -{ - Grid3D *g = (Grid3D*)_gridNodeTarget->getGrid(); - return g->getOriginalVertex(position); -} - -void Grid3DAction::setVertex(const Vec2& position, const Vec3& vertex) -{ - Grid3D *g = (Grid3D*)_gridNodeTarget->getGrid(); - g->setVertex(position, vertex); -} - -Rect Grid3DAction::getGridRect() const -{ - Grid3D *g = (Grid3D*)_gridNodeTarget->getGrid(); - return g->getGridRect(); -} - -// implementation of TiledGrid3DAction - -GridBase* TiledGrid3DAction::getGrid(void) -{ - return TiledGrid3D::create(_gridSize, _gridNodeTarget->getGridRect()); -} - -Quad3 TiledGrid3DAction::getTile(const Vec2& pos) const -{ - TiledGrid3D *g = (TiledGrid3D*)_gridNodeTarget->getGrid(); - return g->getTile(pos); -} - -Quad3 TiledGrid3DAction::getOriginalTile(const Vec2& pos) const -{ - TiledGrid3D *g = (TiledGrid3D*)_gridNodeTarget->getGrid(); - return g->getOriginalTile(pos); -} - -void TiledGrid3DAction::setTile(const Vec2& pos, const Quad3& coords) -{ - TiledGrid3D *g = (TiledGrid3D*)_gridNodeTarget->getGrid(); - return g->setTile(pos, coords); -} - -// implementation AccelDeccelAmplitude - -AccelDeccelAmplitude* AccelDeccelAmplitude::create(Action *action, float duration) -{ - AccelDeccelAmplitude *ret = new (std::nothrow) AccelDeccelAmplitude(); - if (ret && ret->initWithAction(action, duration)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -bool AccelDeccelAmplitude::initWithAction(Action *action, float duration) -{ - if (ActionInterval::initWithDuration(duration)) - { - _rate = 1.0f; - _other = (ActionInterval*)(action); - action->retain(); - - return true; - } - - return false; -} - -AccelDeccelAmplitude* AccelDeccelAmplitude::clone() const -{ - // no copy constructor - if (_other) - return AccelDeccelAmplitude::create(_other->clone(), _rate); - - return nullptr; -} - -AccelDeccelAmplitude::~AccelDeccelAmplitude() -{ - CC_SAFE_RELEASE(_other); -} - -void AccelDeccelAmplitude::startWithTarget(Node *target) -{ - ActionInterval::startWithTarget(target); - _other->startWithTarget(target); -} - -void AccelDeccelAmplitude::update(float time) -{ - float f = time * 2; - - if (f > 1) - { - f -= 1; - f = 1 - f; - } - - ((AccelDeccelAmplitude*)(_other))->setAmplitudeRate(powf(f, _rate)); -} - -AccelDeccelAmplitude* AccelDeccelAmplitude::reverse() const -{ - if (_other) - return AccelDeccelAmplitude::create(_other->reverse(), _duration); - - return nullptr; -} - -// implementation of AccelAmplitude - -AccelAmplitude* AccelAmplitude::create(Action *action, float duration) -{ - AccelAmplitude *ret = new (std::nothrow) AccelAmplitude(); - if (ret && ret->initWithAction(action, duration)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -bool AccelAmplitude::initWithAction(Action *action, float duration) -{ - if (ActionInterval::initWithDuration(duration)) - { - _rate = 1.0f; - _other = (ActionInterval*)(action); - action->retain(); - - return true; - } - - return false; -} - -AccelAmplitude* AccelAmplitude::clone() const -{ - // no copy constructor - if (_other) - return AccelAmplitude::create(_other->clone(), _duration); - - return nullptr; -} - -AccelAmplitude::~AccelAmplitude() -{ - CC_SAFE_DELETE(_other); -} - -void AccelAmplitude::startWithTarget(Node *target) -{ - ActionInterval::startWithTarget(target); - _other->startWithTarget(target); -} - -void AccelAmplitude::update(float time) -{ - ((AccelAmplitude*)(_other))->setAmplitudeRate(powf(time, _rate)); - _other->update(time); -} - -AccelAmplitude* AccelAmplitude::reverse() const -{ - if (_other) - return AccelAmplitude::create(_other->reverse(), _duration); - - return nullptr; -} - -// DeccelAmplitude - -DeccelAmplitude* DeccelAmplitude::create(Action *action, float duration) -{ - DeccelAmplitude *ret = new (std::nothrow) DeccelAmplitude(); - if (ret && ret->initWithAction(action, duration)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -bool DeccelAmplitude::initWithAction(Action *action, float duration) -{ - if (ActionInterval::initWithDuration(duration)) - { - _rate = 1.0f; - _other = (ActionInterval*)(action); - action->retain(); - - return true; - } - - return false; -} - -DeccelAmplitude::~DeccelAmplitude() -{ - CC_SAFE_RELEASE(_other); -} - -void DeccelAmplitude::startWithTarget(Node *target) -{ - ActionInterval::startWithTarget(target); - _other->startWithTarget(target); -} - -void DeccelAmplitude::update(float time) -{ - ((DeccelAmplitude*)(_other))->setAmplitudeRate(powf((1 - time), _rate)); - _other->update(time); -} - -DeccelAmplitude* DeccelAmplitude::clone() const -{ - // no copy constructor - if (_other) - return DeccelAmplitude::create(_other->clone(), _duration); - - return nullptr; -} - -DeccelAmplitude* DeccelAmplitude::reverse() const -{ - return DeccelAmplitude::create(_other->reverse(), _duration); -} - -// implementation of StopGrid - -void StopGrid::startWithTarget(Node *target) -{ - ActionInstant::startWithTarget(target); - cacheTargetAsGridNode(); - GridBase *grid = _gridNodeTarget->getGrid(); - if (grid && grid->isActive()) - { - grid->setActive(false); - } -} - -void StopGrid::cacheTargetAsGridNode() -{ - _gridNodeTarget = dynamic_cast (_target); - CCASSERT(_gridNodeTarget, "GridActions can only used on NodeGrid"); -} - -StopGrid* StopGrid::create() -{ - StopGrid* action = new (std::nothrow) StopGrid(); - if (action) - { - action->autorelease(); - return action; - } - - delete action; - return nullptr; -} - -StopGrid* StopGrid::clone() const -{ - return StopGrid::create(); -} - -StopGrid* StopGrid::reverse() const -{ - // no reverse, just clone it - return this->clone(); -} - -// implementation of ReuseGrid - -ReuseGrid* ReuseGrid::create(int times) -{ - ReuseGrid *action = new (std::nothrow) ReuseGrid(); - if (action && action->initWithTimes(times)) - { - action->autorelease(); - return action; - } - - delete action; - return nullptr; -} - -bool ReuseGrid::initWithTimes(int times) -{ - _times = times; - - return true; -} - -void ReuseGrid::startWithTarget(Node *target) -{ - ActionInstant::startWithTarget(target); - cacheTargetAsGridNode(); - - if (_gridNodeTarget->getGrid() && _gridNodeTarget->getGrid()->isActive()) - { - _gridNodeTarget->getGrid()->setReuseGrid(_gridNodeTarget->getGrid()->getReuseGrid() + _times); - } -} - -void ReuseGrid::cacheTargetAsGridNode() -{ - _gridNodeTarget = dynamic_cast (_target); - CCASSERT(_gridNodeTarget, "GridActions can only used on NodeGrid"); -} - -ReuseGrid* ReuseGrid::clone() const -{ - return ReuseGrid::create(_times); -} - -ReuseGrid* ReuseGrid::reverse() const -{ - // no reverse, just clone it - return this->clone(); -} - -NS_CC_END - diff --git a/native/cocos/2d/CCActionGrid.h b/native/cocos/2d/CCActionGrid.h deleted file mode 100644 index 043f4c3d32..0000000000 --- a/native/cocos/2d/CCActionGrid.h +++ /dev/null @@ -1,423 +0,0 @@ -/**************************************************************************** -Copyright (c) 2009 On-Core -Copyright (c) 2010-2012 cocos2d-x.org -Copyright (c) 2013-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ -#ifndef __ACTION_CCGRID_ACTION_H__ -#define __ACTION_CCGRID_ACTION_H__ - -#include "2d/CCActionInterval.h" -#include "2d/CCActionInstant.h" - -NS_CC_BEGIN - -class GridBase; -class NodeGrid; - -/** - * @addtogroup actions - * @{ - */ - -/** -@class GridAction -@brief Base class for Grid actions. -@details Grid actions are the actions take effect on GridBase. -*/ -class CC_DLL GridAction : public ActionInterval -{ -public: - - /** - @brief Get the pointer of GridBase. - @return The pointer of GridBase. - */ - virtual GridBase* getGrid(); - - // overrides - virtual GridAction * clone() const override - { - CC_ASSERT(0); - return nullptr; - } - virtual GridAction* reverse() const override; - virtual void startWithTarget(Node *target) override; - -CC_CONSTRUCTOR_ACCESS: - GridAction() {} - virtual ~GridAction() {} - /** - * @brief Initializes the action with size and duration. - * @param duration The duration of the GridAction. It's a value in seconds. - * @param gridSize The size of the GridAction should be. - * @return Return true when the initialization success, otherwise return false. - */ - bool initWithDuration(float duration, const Size& gridSize); - -protected: - Size _gridSize; - - NodeGrid* _gridNodeTarget; - - void cacheTargetAsGridNode(); - -private: - CC_DISALLOW_COPY_AND_ASSIGN(GridAction); -}; - -/** - @brief Base class for Grid3D actions. - @details Grid3D actions can modify a non-tiled grid. - */ -class CC_DLL Grid3DAction : public GridAction -{ -public: - - - virtual GridBase* getGrid() override; - /** - * @brief Get the vertex that belongs to certain position in the grid. - * @param position The position of the grid. - * @return Return a pointer of vertex. - * @js vertex - * @lua NA - */ - Vec3 getVertex(const Vec2& position) const; - - /** - * @brief Get the non-transformed vertex that belongs to certain position in the grid. - * @param position The position of the grid. - * @return Return a pointer of vertex. - * @js originalVertex - * @lua NA - */ - Vec3 getOriginalVertex(const Vec2& position) const; - - /** - * @brief Set a new vertex to a certain position of the grid. - * @param position The position of the grid. - * @param vertex The vertex will be used on the certain position of grid. - * @js setVertex - * @lua NA - */ - void setVertex(const Vec2& position, const Vec3& vertex); - - // Overrides - virtual Grid3DAction * clone() const override - { - CC_ASSERT(0); - return nullptr; - } - - /** - * @brief Get the effect grid rect. - * @return Return the effect grid rect. - */ - Rect getGridRect() const; -}; - -/** -@brief Base class for TiledGrid3D actions. -*/ -class CC_DLL TiledGrid3DAction : public GridAction -{ -public: - /** - * @brief Create the action with size and duration. - * @param duration The duration of the action. It's a value in seconds. - * @param gridSize Specify the grid size of the action. - * @return A pointer of TiledGrid3DAction. If creation failed, return nil. - * @lua NA - */ - static TiledGrid3DAction* create(float duration, const Size& gridSize); - - /** - * @brief Get the tile that belongs to a certain position of the grid. - * @param position The position of the tile want to get. - * @return A quadrilateral of the tile. - * @js tile - * @lua NA - */ - Quad3 getTile(const Vec2& position) const; - - /** - * @brief Get the non-transformed tile that belongs to a certain position of the grid. - * @param position The position of the tile want to get. - * @return A quadrilateral of the tile. - * @js originalTile - * @lua NA - */ - Quad3 getOriginalTile(const Vec2& position) const; - - /** - * @brief Set a new tile to a certain position of the grid. - * @param position The position of the tile. - * @param coords The quadrilateral of the new tile. - * @lua NA - */ - void setTile(const Vec2& position, const Quad3& coords); - - /** returns the grid */ - virtual GridBase* getGrid() override; - - // Override - virtual TiledGrid3DAction * clone() const override - { - CC_ASSERT(0); - return nullptr; - } -}; - -/** -@brief AccelDeccelAmplitude action. -@js NA -*/ -class CC_DLL AccelDeccelAmplitude : public ActionInterval -{ -public: - /** - @brief Create the action with an inner action that has the amplitude property, and a duration time. - @param action A pointer of the inner action. - @param duration Specify the duration of the AccelDeccelAmplitude action. - @return Return a pointer of AccelDeccelAmplitude action. When the creation failed, return nil. - */ - static AccelDeccelAmplitude* create(Action *action, float duration); - - /** - @brief Get the value of amplitude rate. - @return the value of amplitude rate. - */ - inline float getRate(void) const { return _rate; } - /** - @brief Set the value of amplitude rate. - @param rate Specify the value of amplitude rate. - */ - inline void setRate(float rate) { _rate = rate; } - - // Overrides - virtual void startWithTarget(Node *target) override; - virtual void update(float time) override; - virtual AccelDeccelAmplitude* clone() const override; - virtual AccelDeccelAmplitude* reverse() const override; - -CC_CONSTRUCTOR_ACCESS: - AccelDeccelAmplitude() {} - virtual ~AccelDeccelAmplitude(); - - /** - @brief Initializes the action with an inner action that has the amplitude property, and a duration time. - @param action A pointer of the inner action. - @param duration Specify the duration of the AccelDeccelAmplitude action. - @return If the initialization success, return true; otherwise, return false. - */ - bool initWithAction(Action *action, float duration); - -protected: - float _rate; - ActionInterval *_other; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(AccelDeccelAmplitude); -}; - -/** -@brief AccelAmplitude action. -@js NA -*/ -class CC_DLL AccelAmplitude : public ActionInterval -{ -public: - /** - @brief Create the action with an inner action that has the amplitude property, and a duration time. - @param action A pointer of the inner action. - @param duration Specify the duration of the AccelAmplitude action. - @return Return a pointer of AccelAmplitude action. When the creation failed, return nil. - */ - static AccelAmplitude* create(Action *action, float duration); - - /** - @brief Get the value of amplitude rate. - @return The value of amplitude rate. - */ - inline float getRate() const { return _rate; } - /** - @brief Set the value of amplitude rate. - @param rate Specify the value of amplitude rate. - */ - inline void setRate(float rate) { _rate = rate; } - - // Overrides - virtual void startWithTarget(Node *target) override; - virtual void update(float time) override; - virtual AccelAmplitude* clone() const override; - virtual AccelAmplitude* reverse() const override; - -CC_CONSTRUCTOR_ACCESS: - AccelAmplitude() {} - virtual ~AccelAmplitude(); - - bool initWithAction(Action *action, float duration); - -protected: - float _rate; - ActionInterval *_other; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(AccelAmplitude); -}; - -/** -@brief DeccelAmplitude action. -@js NA -*/ -class CC_DLL DeccelAmplitude : public ActionInterval -{ -public: - /** - @brief Creates the action with an inner action that has the amplitude property, and a duration time. - @param action A pointer of the inner action. - @param duration Specify the duration of the DeccelAmplitude action. - @return Return a pointer of DeccelAmplitude. When the creation failed, return nil. - */ - static DeccelAmplitude* create(Action *action, float duration); - - /** - @brief Get the value of amplitude rate. - @return The value of amplitude rate. - */ - inline float getRate() const { return _rate; } - /** - @brief Set the value of amplitude rate. - @param rate Specify the value. - */ - inline void setRate(float rate) { _rate = rate; } - - // overrides - virtual void startWithTarget(Node *target) override; - virtual void update(float time) override; - virtual DeccelAmplitude* clone() const override; - virtual DeccelAmplitude* reverse() const override; - -CC_CONSTRUCTOR_ACCESS: - DeccelAmplitude() {} - virtual ~DeccelAmplitude(); - - /** - @brief Initializes the action with an inner action that has the amplitude property, and a duration time. - @param action The pointer of inner action. - @param duration The duration of the DeccelAmplitude action. - @return If the initialization success, return true; otherwise, return false. - */ - bool initWithAction(Action *action, float duration); - -protected: - float _rate; - ActionInterval *_other; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(DeccelAmplitude); -}; - -/** - @brief StopGrid action. - @warning Don't call this action if another grid action is active. - Call if you want to remove the grid effect. Example: - @code - Sequence::create(Lens3D::create(...), StopGrid::create(), nullptr); - @endcode - */ -class CC_DLL StopGrid : public ActionInstant -{ -public: - /** - @brief Create a StopGrid Action. - @return Return a pointer of StopGrid. When the creation failed, return nil. - */ - static StopGrid* create(); - - // Overrides - virtual void startWithTarget(Node *target) override; - virtual StopGrid* clone() const override; - virtual StopGrid* reverse() const override; - -CC_CONSTRUCTOR_ACCESS: - StopGrid() {} - virtual ~StopGrid() {} - -protected: - NodeGrid* _gridNodeTarget; - - void cacheTargetAsGridNode(); - -private: - CC_DISALLOW_COPY_AND_ASSIGN(StopGrid); -}; - -/** -@brief ReuseGrid action. -*/ -class CC_DLL ReuseGrid : public ActionInstant -{ -public: - /** - @brief Create an action with the number of times that the current grid will be reused. - @param times Specify times the grid will be reused. - @return Return a pointer of ReuseGrid. When the creation failed, return nil. - */ - static ReuseGrid* create(int times); - - // Override - virtual void startWithTarget(Node *target) override; - virtual ReuseGrid* clone() const override; - virtual ReuseGrid* reverse() const override; - -CC_CONSTRUCTOR_ACCESS: - ReuseGrid() {} - virtual ~ReuseGrid() {} - - /** - @brief Initializes an action with the number of times that the current grid will be reused. - @param times Specify times the grid will be reused. - @return If the initialization success, return true; otherwise, return false. - */ - bool initWithTimes(int times); - -protected: - NodeGrid* _gridNodeTarget; - - void cacheTargetAsGridNode(); - - int _times; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(ReuseGrid); -}; - -// end of actions group -/// @} - -NS_CC_END - -#endif // __ACTION_CCGRID_ACTION_H__ - diff --git a/native/cocos/2d/CCActionGrid3D.cpp b/native/cocos/2d/CCActionGrid3D.cpp deleted file mode 100644 index bdd18e1dd3..0000000000 --- a/native/cocos/2d/CCActionGrid3D.cpp +++ /dev/null @@ -1,734 +0,0 @@ -/**************************************************************************** -Copyright (c) 2009 On-Core -Copyright (c) 2010-2012 cocos2d-x.org -Copyright (c) 2013-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ -#include "2d/CCActionGrid3D.h" -#include "base/CCDirector.h" - -NS_CC_BEGIN -// implementation of Waves3D - -Waves3D* Waves3D::create(float duration, const Size& gridSize, unsigned int waves, float amplitude) -{ - Waves3D *action = new (std::nothrow) Waves3D(); - - if (action && action->initWithDuration(duration, gridSize, waves, amplitude)) - { - action->autorelease(); - return action; - } - - delete action; - return nullptr; -} - -bool Waves3D::initWithDuration(float duration, const Size& gridSize, unsigned int waves, float amplitude) -{ - if (Grid3DAction::initWithDuration(duration, gridSize)) - { - _waves = waves; - _amplitude = amplitude; - _amplitudeRate = 1.0f; - - return true; - } - - return false; -} - -Waves3D* Waves3D::clone() const -{ - // no copy constructor - return Waves3D::create(_duration, _gridSize, _waves, _amplitude); -} - -void Waves3D::update(float time) -{ - int i, j; - for (i = 0; i < _gridSize.width + 1; ++i) - { - for (j = 0; j < _gridSize.height + 1; ++j) - { - Vec3 v = getOriginalVertex(Vec2(i ,j)); - v.z += (sinf((float)M_PI * time * _waves * 2 + (v.y+v.x) * 0.01f) * _amplitude * _amplitudeRate); - //CCLOG("v.z offset is %f\n", (sinf((float)M_PI * time * _waves * 2 + (v.y+v.x) * .01f) * _amplitude * _amplitudeRate)); - setVertex(Vec2(i, j), v); - } - } -} - -// implementation of FlipX3D - -FlipX3D* FlipX3D::create(float duration) -{ - FlipX3D *action = new (std::nothrow) FlipX3D(); - - if (action && action->initWithDuration(duration)) - { - action->autorelease(); - return action; - } - - delete action; - return nullptr; -} - -bool FlipX3D::initWithDuration(float duration) -{ - return Grid3DAction::initWithDuration(duration, Size(1, 1)); -} - -bool FlipX3D::initWithSize(const Size& gridSize, float duration) -{ - if (gridSize.width != 1 || gridSize.height != 1) - { - // Grid size must be (1,1) - CCASSERT(0, "Grid size must be (1,1)"); - - return false; - } - - return Grid3DAction::initWithDuration(duration, gridSize); -} - -FlipX3D* FlipX3D::clone() const -{ - auto a = new (std::nothrow) FlipX3D(); - a->initWithSize(_gridSize, _duration); - a->autorelease(); - return a; -} - -void FlipX3D::update(float time) -{ - float angle = (float)M_PI * time; // 180 degrees - float mz = sinf(angle); - angle = angle / 2.0f; // x calculates degrees from 0 to 90 - float mx = cosf(angle); - - Vec3 v0, v1, v, diff; - - v0 = getOriginalVertex(Vec2::ONE); - v1 = getOriginalVertex(Vec2::ZERO); - - float x0 = v0.x; - float x1 = v1.x; - float x; - Vec2 a, b, c, d; - - if ( x0 > x1 ) - { - // Normal Grid - a.setZero(); - b.set(0.0f, 1.0f); - c.set(1.0f, 0.0f); - d.set(1.0f, 1.0f); - x = x0; - } - else - { - // Reversed Grid - c.setZero(); - d.set(0.0f, 1.0f); - a.set(1.0f, 0.0f); - b.set(1.0f, 1.0f); - x = x1; - } - - diff.x = ( x - x * mx ); - diff.z = fabsf( floorf( (x * mz) / 4.0f ) ); - - // bottom-left - v = getOriginalVertex(a); - v.x = diff.x; - v.z += diff.z; - setVertex(a, v); - - // upper-left - v = getOriginalVertex(b); - v.x = diff.x; - v.z += diff.z; - setVertex(b, v); - - // bottom-right - v = getOriginalVertex(c); - v.x -= diff.x; - v.z -= diff.z; - setVertex(c, v); - - // upper-right - v = getOriginalVertex(d); - v.x -= diff.x; - v.z -= diff.z; - setVertex(d, v); -} - -// implementation of FlipY3D - -FlipY3D* FlipY3D::clone() const -{ - // no copy constructor - auto a = new (std::nothrow) FlipY3D(); - a->initWithSize(_gridSize, _duration); - a->autorelease(); - return a; -} - -FlipY3D* FlipY3D::create(float duration) -{ - FlipY3D *action = new (std::nothrow) FlipY3D(); - - if (action) - { - if (action->initWithDuration(duration)) - { - action->autorelease(); - } - else - { - CC_SAFE_RELEASE_NULL(action); - } - } - - return action; -} - -void FlipY3D::update(float time) -{ - float angle = (float)M_PI * time; // 180 degrees - float mz = sinf( angle ); - angle = angle / 2.0f; // x calculates degrees from 0 to 90 - float my = cosf(angle); - - Vec3 v0, v1, v, diff; - - v0 = getOriginalVertex(Vec2::ONE); - v1 = getOriginalVertex(Vec2::ZERO); - - float y0 = v0.y; - float y1 = v1.y; - float y; - Vec2 a, b, c, d; - - if (y0 > y1) - { - // Normal Grid - a.setZero(); - b.set(0.0f, 1.0f); - c.set(1.0f, 0.0f); - d.set(1.0f, 1.0f); - y = y0; - } - else - { - // Reversed Grid - b.setZero(); - a.set(0.0f, 1.0f); - d.set(1.0f, 0.0f); - c.set(1.0f, 1.0f); - y = y1; - } - - diff.y = y - y * my; - diff.z = fabsf(floorf((y * mz) / 4.0f)); - - // bottom-left - v = getOriginalVertex(a); - v.y = diff.y; - v.z += diff.z; - setVertex(a, v); - - // upper-left - v = getOriginalVertex(b); - v.y -= diff.y; - v.z -= diff.z; - setVertex(b, v); - - // bottom-right - v = getOriginalVertex(c); - v.y = diff.y; - v.z += diff.z; - setVertex(c, v); - - // upper-right - v = getOriginalVertex(d); - v.y -= diff.y; - v.z -= diff.z; - setVertex(d, v); -} - - -// implementation of Lens3D - -Lens3D* Lens3D::create(float duration, const Size& gridSize, const Vec2& position, float radius) -{ - Lens3D *action = new (std::nothrow) Lens3D(); - - if (action) - { - if (action->initWithDuration(duration, gridSize, position, radius)) - { - action->autorelease(); - } - else - { - CC_SAFE_RELEASE_NULL(action); - } - } - - return action; -} - -bool Lens3D::initWithDuration(float duration, const Size& gridSize, const Vec2& position, float radius) -{ - if (Grid3DAction::initWithDuration(duration, gridSize)) - { - _position.set(-1.0f, -1.0f); - setPosition(position); - _radius = radius; - _lensEffect = 0.7f; - _concave = false; - _dirty = true; - - return true; - } - - return false; -} - -Lens3D* Lens3D::clone() const -{ - // no copy constructor - auto a = new (std::nothrow) Lens3D(); - a->initWithDuration(_duration, _gridSize, _position, _radius); - a->autorelease(); - return a; -} - -void Lens3D::setPosition(const Vec2& pos) -{ - if( !pos.equals(_position)) - { - _position = pos; - _dirty = true; - } -} - -void Lens3D::update(float time) -{ - CC_UNUSED_PARAM(time); - if (_dirty) - { - int i, j; - - for (i = 0; i < _gridSize.width + 1; ++i) - { - for (j = 0; j < _gridSize.height + 1; ++j) - { - Vec3 v = getOriginalVertex(Vec2(i, j)); - Vec2 vect = _position - Vec2(v.x, v.y); - float r = vect.getLength(); - - if (r < _radius) - { - r = _radius - r; - float pre_log = r / _radius; - if ( pre_log == 0 ) - { - pre_log = 0.001f; - } - - float l = logf(pre_log) * _lensEffect; - float new_r = expf( l ) * _radius; - - if (vect.getLength() > 0) - { - vect.normalize(); - Vec2 new_vect = vect * new_r; - v.z += (_concave ? -1.0f : 1.0f) * new_vect.getLength() * _lensEffect; - } - } - - setVertex(Vec2(i, j), v); - } - } - - _dirty = false; - } -} - -// implementation of Ripple3D - -Ripple3D* Ripple3D::create(float duration, const Size& gridSize, const Vec2& position, float radius, unsigned int waves, float amplitude) -{ - Ripple3D *action = new (std::nothrow) Ripple3D(); - - if (action) - { - if (action->initWithDuration(duration, gridSize, position, radius, waves, amplitude)) - { - action->autorelease(); - } - else - { - CC_SAFE_RELEASE_NULL(action); - } - } - - return action; -} - -bool Ripple3D::initWithDuration(float duration, const Size& gridSize, const Vec2& position, float radius, unsigned int waves, float amplitude) -{ - if (Grid3DAction::initWithDuration(duration, gridSize)) - { - setPosition(position); - _radius = radius; - _waves = waves; - _amplitude = amplitude; - _amplitudeRate = 1.0f; - - return true; - } - - return false; -} - -void Ripple3D::setPosition(const Vec2& position) -{ - _position = position; -} - - -Ripple3D* Ripple3D::clone() const -{ - // no copy constructor - auto a = new (std::nothrow) Ripple3D(); - a->initWithDuration(_duration, _gridSize, _position, _radius, _waves, _amplitude); - a->autorelease(); - return a; -} - -void Ripple3D::update(float time) -{ - int i, j; - - for (i = 0; i < (_gridSize.width+1); ++i) - { - for (j = 0; j < (_gridSize.height+1); ++j) - { - Vec3 v = getOriginalVertex(Vec2(i, j)); - Vec2 vect = _position - Vec2(v.x,v.y); - float r = vect.getLength(); - - if (r < _radius) - { - r = _radius - r; - float rate = powf(r / _radius, 2); - v.z += (sinf( time*(float)M_PI * _waves * 2 + r * 0.1f) * _amplitude * _amplitudeRate * rate); - } - - setVertex(Vec2(i, j), v); - } - } -} - -// implementation of Shaky3D - -Shaky3D* Shaky3D::create(float duration, const Size& gridSize, int range, bool shakeZ) -{ - Shaky3D *action = new (std::nothrow) Shaky3D(); - - if (action) - { - if (action->initWithDuration(duration, gridSize, range, shakeZ)) - { - action->autorelease(); - } - else - { - CC_SAFE_RELEASE_NULL(action); - } - } - - return action; -} - -bool Shaky3D::initWithDuration(float duration, const Size& gridSize, int range, bool shakeZ) -{ - if (Grid3DAction::initWithDuration(duration, gridSize)) - { - _randrange = range; - _shakeZ = shakeZ; - - return true; - } - - return false; -} - -Shaky3D* Shaky3D::clone() const -{ - // no copy constructor - auto a = new (std::nothrow) Shaky3D(); - a->initWithDuration(_duration, _gridSize, _randrange, _shakeZ); - a->autorelease(); - return a; -} - -void Shaky3D::update(float time) -{ - CC_UNUSED_PARAM(time); - int i, j; - - for (i = 0; i < (_gridSize.width+1); ++i) - { - for (j = 0; j < (_gridSize.height+1); ++j) - { - Vec3 v = getOriginalVertex(Vec2(i ,j)); - v.x += (rand() % (_randrange*2)) - _randrange; - v.y += (rand() % (_randrange*2)) - _randrange; - if (_shakeZ) - { - v.z += (rand() % (_randrange*2)) - _randrange; - } - - setVertex(Vec2(i, j), v); - } - } -} - -// implementation of Liquid - -Liquid* Liquid::create(float duration, const Size& gridSize, unsigned int waves, float amplitude) -{ - Liquid *action = new (std::nothrow) Liquid(); - - if (action) - { - if (action->initWithDuration(duration, gridSize, waves, amplitude)) - { - action->autorelease(); - } - else - { - CC_SAFE_RELEASE_NULL(action); - } - } - - return action; -} - -bool Liquid::initWithDuration(float duration, const Size& gridSize, unsigned int waves, float amplitude) -{ - if (Grid3DAction::initWithDuration(duration, gridSize)) - { - _waves = waves; - _amplitude = amplitude; - _amplitudeRate = 1.0f; - - return true; - } - - return false; -} - -Liquid* Liquid::clone() const -{ - // no copy constructor - auto a = new (std::nothrow) Liquid(); - a->initWithDuration(_duration, _gridSize, _waves, _amplitude); - a->autorelease(); - return a; -} - -void Liquid::update(float time) -{ - int i, j; - - for (i = 1; i < _gridSize.width; ++i) - { - for (j = 1; j < _gridSize.height; ++j) - { - Vec3 v = getOriginalVertex(Vec2(i, j)); - v.x = (v.x + (sinf(time * (float)M_PI * _waves * 2 + v.x * .01f) * _amplitude * _amplitudeRate)); - v.y = (v.y + (sinf(time * (float)M_PI * _waves * 2 + v.y * .01f) * _amplitude * _amplitudeRate)); - setVertex(Vec2(i, j), v); - } - } -} - -// implementation of Waves - -Waves* Waves::create(float duration, const Size& gridSize, unsigned int waves, float amplitude, bool horizontal, bool vertical) -{ - Waves *action = new (std::nothrow) Waves(); - - if (action) - { - if (action->initWithDuration(duration, gridSize, waves, amplitude, horizontal, vertical)) - { - action->autorelease(); - } - else - { - CC_SAFE_RELEASE_NULL(action); - } - } - - return action; -} - -bool Waves::initWithDuration(float duration, const Size& gridSize, unsigned int waves, float amplitude, bool horizontal, bool vertical) -{ - if (Grid3DAction::initWithDuration(duration, gridSize)) - { - _waves = waves; - _amplitude = amplitude; - _amplitudeRate = 1.0f; - _horizontal = horizontal; - _vertical = vertical; - - return true; - } - - return false; -} - -Waves* Waves::clone() const -{ - // no copy constructor - auto a = new (std::nothrow) Waves(); - a->initWithDuration(_duration, _gridSize, _waves, _amplitude, _horizontal, _vertical); - a->autorelease(); - return a; -} - -void Waves::update(float time) -{ - int i, j; - - for (i = 0; i < _gridSize.width + 1; ++i) - { - for (j = 0; j < _gridSize.height + 1; ++j) - { - Vec3 v = getOriginalVertex(Vec2(i, j)); - - if (_vertical) - { - v.x = (v.x + (sinf(time * (float)M_PI * _waves * 2 + v.y * .01f) * _amplitude * _amplitudeRate)); - } - - if (_horizontal) - { - v.y = (v.y + (sinf(time * (float)M_PI * _waves * 2 + v.x * .01f) * _amplitude * _amplitudeRate)); - } - - setVertex(Vec2(i, j), v); - } - } -} - -// implementation of Twirl - -Twirl* Twirl::create(float duration, const Size& gridSize, const Vec2& position, unsigned int twirls, float amplitude) -{ - Twirl *action = new (std::nothrow) Twirl(); - - if (action) - { - if (action->initWithDuration(duration, gridSize, position, twirls, amplitude)) - { - action->autorelease(); - } - else - { - CC_SAFE_RELEASE_NULL(action); - } - } - - return action; -} - -bool Twirl::initWithDuration(float duration, const Size& gridSize, const Vec2& position, unsigned int twirls, float amplitude) -{ - if (Grid3DAction::initWithDuration(duration, gridSize)) - { - setPosition(position); - _twirls = twirls; - _amplitude = amplitude; - _amplitudeRate = 1.0f; - - return true; - } - - return false; -} - -void Twirl::setPosition(const Vec2& position) -{ - _position = position; -} - -Twirl *Twirl::clone() const -{ - // no copy constructor - auto a = new (std::nothrow) Twirl(); - a->initWithDuration(_duration, _gridSize, _position, _twirls, _amplitude); - a->autorelease(); - return a; -} - -void Twirl::update(float time) -{ - int i, j; - Vec2 c = _position; - - for (i = 0; i < (_gridSize.width+1); ++i) - { - for (j = 0; j < (_gridSize.height+1); ++j) - { - Vec3 v = getOriginalVertex(Vec2(i ,j)); - - Vec2 avg(i-(_gridSize.width/2.0f), j-(_gridSize.height/2.0f)); - float r = avg.getLength(); - - float amp = 0.1f * _amplitude * _amplitudeRate; - float a = r * cosf( (float)M_PI/2.0f + time * (float)M_PI * _twirls * 2 ) * amp; - - Vec2 d( - sinf(a) * (v.y-c.y) + cosf(a) * (v.x-c.x), - cosf(a) * (v.y-c.y) - sinf(a) * (v.x-c.x)); - - v.x = c.x + d.x; - v.y = c.y + d.y; - - setVertex(Vec2(i ,j), v); - } - } -} - -NS_CC_END - diff --git a/native/cocos/2d/CCActionGrid3D.h b/native/cocos/2d/CCActionGrid3D.h deleted file mode 100644 index d693614444..0000000000 --- a/native/cocos/2d/CCActionGrid3D.h +++ /dev/null @@ -1,621 +0,0 @@ -/**************************************************************************** -Copyright (c) 2009 On-Core -Copyright (c) 2010-2012 cocos2d-x.org -Copyright (c) 2013-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ -#ifndef __ACTION_CCGRID3D_ACTION_H__ -#define __ACTION_CCGRID3D_ACTION_H__ - -#include "2d/CCActionGrid.h" - -NS_CC_BEGIN - -/** - * @addtogroup actions - * @{ - */ - -/** -@brief Waves3D action. -@details This action is used for take effect on the target node as 3D waves. - You can control the effect by these parameters: - duration, grid size, waves count, amplitude. -*/ -class CC_DLL Waves3D : public Grid3DAction -{ -public: - /** - @brief Create an action with duration, grid size, waves and amplitude. - @param duration Specify the duration of the Waves3D action. It's a value in seconds. - @param gridSize Specify the size of the grid. - @param waves Specify the waves count of the Waves3D action. - @param amplitude Specify the amplitude of the Waves3D action. - @return If the creation success, return a pointer of Waves3D action; otherwise, return nil. - */ - static Waves3D* create(float duration, const Size& gridSize, unsigned int waves, float amplitude); - - /** - @brief Get the amplitude of the effect. - @return Return the amplitude of the effect. - */ - inline float getAmplitude() const { return _amplitude; } - /** - @brief Set the amplitude to the effect. - @param amplitude The value of amplitude will be set. - */ - inline void setAmplitude(float amplitude) { _amplitude = amplitude; } - - /** - @brief Get the amplitude rate of the effect. - @return Return the amplitude rate of the effect. - */ - inline float getAmplitudeRate() const { return _amplitudeRate; } - /** - @brief Set the amplitude rate of the effect. - @param amplitudeRate The value of amplitude rate will be set. - */ - inline void setAmplitudeRate(float amplitudeRate) { _amplitudeRate = amplitudeRate; } - - // Overrides - virtual Waves3D* clone() const override; - virtual void update(float time) override; - -CC_CONSTRUCTOR_ACCESS: - Waves3D() {} - virtual ~Waves3D() {} - - /** - @brief Initializes an action with duration, grid size, waves and amplitude. - @param duration Specify the duration of the Waves3D action. It's a value in seconds. - @param gridSize Specify the size of the grid. - @param waves Specify the waves count of the Waves3D action. - @param amplitude Specify the amplitude of the Waves3D action. - @return If the initialization success, return true; otherwise, return false. - */ - bool initWithDuration(float duration, const Size& gridSize, unsigned int waves, float amplitude); - -protected: - unsigned int _waves; - float _amplitude; - float _amplitudeRate; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(Waves3D); -}; - -/** -@brief FlipX3D action. -@details This action is used for flipping the target node on the x axis. -*/ -class CC_DLL FlipX3D : public Grid3DAction -{ -public: - /** - @brief Create the action with duration. - @param duration Specify the duration of the FilpX3D action. It's a value in seconds. - @return If the creation success, return a pointer of FilpX3D action; otherwise, return nil. - */ - static FlipX3D* create(float duration); - - // Override - virtual FlipX3D* clone() const override; - virtual void update(float time) override; - -CC_CONSTRUCTOR_ACCESS: - FlipX3D() {} - virtual ~FlipX3D() {} - - /** - @brief Initializes an action with duration. - @param duration Specify the duration of the FlipX3D action. It's a value in seconds. - @return If the initialization success, return true; otherwise, return false. - */ - bool initWithDuration(float duration); - - /** - @brief Initializes an action with duration and grid size. - @param gridSize Specify the grid size of the FlipX3D action. - @param duration Specify the duration of the FlipX3D action. It's a value in seconds. - @return If the initialization success, return true; otherwise, return false. - */ - virtual bool initWithSize(const Size& gridSize, float duration); - -private: - CC_DISALLOW_COPY_AND_ASSIGN(FlipX3D); -}; - -/** -@brief FlipY3D action. -@details This action is used for flipping the target node on the y axis. -*/ -class CC_DLL FlipY3D : public FlipX3D -{ -public: - /** - @brief Create the action with duration. - @param duration Specify the duration of the FlipY3D action. It's a value in seconds. - @return If the creation success, return a pointer of FlipY3D action; otherwise, return nil. - */ - static FlipY3D* create(float duration); - - // Overrides - virtual void update(float time) override; - virtual FlipY3D* clone() const override; - -CC_CONSTRUCTOR_ACCESS: - FlipY3D() {} - virtual ~FlipY3D() {} -private: - CC_DISALLOW_COPY_AND_ASSIGN(FlipY3D); -}; - -/** -@brief Lens3D action. -@details This action is used for take effect on the target node as lens. - You can create the action by these parameters: - duration, grid size, center position of lens, radius of lens. - Also you can change the lens effect value & whether effect is concave by the setter methods. -*/ -class CC_DLL Lens3D : public Grid3DAction -{ -public: - /** - @brief Create the action with center position, radius, a grid size and duration. - @param duration Specify the duration of the Lens3D action. It's a value in seconds. - @param gridSize Specify the size of the grid. - @param position Specify the center position of the lens. - @param radius Specify the radius of the lens. - @return If the creation success, return a pointer of Lens3D action; otherwise, return nil. - */ - static Lens3D* create(float duration, const Size& gridSize, const Vec2& position, float radius); - - /** - @brief Get the value of lens effect. Default value is 0.7. - @return The value of lens effect. - */ - inline float getLensEffect() const { return _lensEffect; } - - /** - @brief Set the value of lens effect. - @param lensEffect The value of lens effect will be set. - */ - inline void setLensEffect(float lensEffect) { _lensEffect = lensEffect; } - - /** - @brief Set whether lens is concave. - @param concave Whether lens is concave. - */ - inline void setConcave(bool concave) { _concave = concave; } - - /** - @brief Get the center position of lens effect. - @return The center position of lens effect. - */ - inline const Vec2& getPosition() const { return _position; } - - /** - @brief Set the center position of lens effect. - @param position The center position will be set. - */ - void setPosition(const Vec2& position); - - // Overrides - virtual Lens3D* clone() const override; - virtual void update(float time) override; - -CC_CONSTRUCTOR_ACCESS: - Lens3D() {} - virtual ~Lens3D() {} - - /** - @brief Initializes the action with center position, radius, grid size and duration. - @param duration Specify the duration of the Lens3D action. It's a value in seconds. - @param gridSize Specify the size of the grid. - @param position Specify the center position of the lens effect. - @param radius Specify the radius of the lens effect. - @return If the initialization success, return true; otherwise, return false. - */ - bool initWithDuration(float duration, const Size& gridSize, const Vec2& position, float radius); - -protected: - /* lens center position */ - Vec2 _position; - float _radius; - /** lens effect. Defaults to 0.7 - 0 means no effect, 1 is very strong effect */ - float _lensEffect; - /** lens is concave. (true = concave, false = convex) default is convex i.e. false */ - bool _concave; - - bool _dirty; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(Lens3D); -}; - -/** -@brief Ripple3D action. -@details This action is used for take effect on the target node as ripple. - You can create the action by these parameters: - duration, grid size, center position of ripple, - radius of ripple, waves count, amplitude. -*/ -class CC_DLL Ripple3D : public Grid3DAction -{ -public: - /** - @brief Create the action with center position, radius, number of waves, amplitude, a grid size and duration. - @param duration Specify the duration of the Ripple3D action. It's a value in seconds. - @param gridSize Specify the size of the grid. - @param position Specify the center position of the ripple effect. - @param radius Specify the radius of the ripple effect. - @param waves Specify the waves count of the ripple effect. - @param amplitude Specify the amplitude of the ripple effect. - @return If the creation success, return a pointer of Ripple3D action; otherwise, return nil. - */ - static Ripple3D* create(float duration, const Size& gridSize, const Vec2& position, float radius, unsigned int waves, float amplitude); - - /** - @brief Get the center position of ripple effect. - @return The center position of ripple effect. - */ - inline const Vec2& getPosition() const { return _position; } - /** - @brief Set the center position of ripple effect. - @param position The center position of ripple effect will be set. - */ - void setPosition(const Vec2& position); - - /** - @brief Get the amplitude of ripple effect. - @return The amplitude of ripple effect. - */ - inline float getAmplitude() const { return _amplitude; } - /** - @brief Set the amplitude of ripple effect. - @param fAmplitude The amplitude of ripple effect. - */ - inline void setAmplitude(float fAmplitude) { _amplitude = fAmplitude; } - - /** - @brief Get the amplitude rate of ripple effect. - @return The amplitude rate of ripple effect. - */ - inline float getAmplitudeRate() const { return _amplitudeRate; } - /** - @brief Set the amplitude rate of ripple effect. - @param fAmplitudeRate The amplitude rate of ripple effect. - */ - inline void setAmplitudeRate(float fAmplitudeRate) { _amplitudeRate = fAmplitudeRate; } - - // Override - virtual Ripple3D* clone() const override; - virtual void update(float time) override; - -CC_CONSTRUCTOR_ACCESS: - Ripple3D() {} - virtual ~Ripple3D() {} - - /** - @brief Initializes the action with center position, radius, number of waves, amplitude, a grid size and duration. - @param duration Specify the duration of the Ripple3D action. It's a value in seconds. - @param gridSize Specify the size of the grid. - @param position Specify the center position of the ripple effect. - @param radius Specify the radius of the ripple effect. - @param waves Specify the waves count of the ripple effect. - @param amplitude Specify the amplitude of the ripple effect. - @return If the initialization success, return true; otherwise, return false. - */ - bool initWithDuration(float duration, const Size& gridSize, const Vec2& position, float radius, unsigned int waves, float amplitude); - -protected: - /* center position */ - Vec2 _position; - float _radius; - unsigned int _waves; - float _amplitude; - float _amplitudeRate; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(Ripple3D); -}; - -/** -@brief Shaky3D action. -@details This action is used for take effect on the target node as shaky. - You can create the action by these parameters: - duration, grid size, range, whether shake on the z axis. -*/ -class CC_DLL Shaky3D : public Grid3DAction -{ -public: - /** - @brief Create the action with a range, shake Z vertices, a grid and duration. - @param initWithDuration Specify the duration of the Shaky3D action. It's a value in seconds. - @param gridSize Specify the size of the grid. - @param range Specify the range of the shaky effect. - @param shakeZ Specify whether shake on the z axis. - @return If the creation success, return a pointer of Shaky3D action; otherwise, return nil. - */ - static Shaky3D* create(float initWithDuration, const Size& gridSize, int range, bool shakeZ); - - // Overrides - virtual Shaky3D* clone() const override; - virtual void update(float time) override; - -CC_CONSTRUCTOR_ACCESS: - Shaky3D() {} - virtual ~Shaky3D() {} - - /** - @brief Initializes the action with a range, shake Z vertices, grid size and duration. - @param duration Specify the duration of the Shaky3D action. It's a value in seconds. - @param gridSize Specify the size of the grid. - @param range Specify the range of the shaky effect. - @param shakeZ Specify whether shake on the z axis. - @return If the Initialization success, return true; otherwise, return false. - */ - bool initWithDuration(float duration, const Size& gridSize, int range, bool shakeZ); - -protected: - int _randrange; - bool _shakeZ; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(Shaky3D); -}; - -/** -@brief Liquid action. -@details This action is used for take effect on the target node as liquid. - You can create the action by these parameters: - duration, grid size, waves count, amplitude of the liquid effect. -*/ -class CC_DLL Liquid : public Grid3DAction -{ -public: - /** - @brief Create the action with amplitude, grid size, waves count and duration. - @param duration Specify the duration of the Liquid action. It's a value in seconds. - @param gridSize Specify the size of the grid. - @param waves Specify the waves count of the Liquid action. - @param amplitude Specify the amplitude of the Liquid action. - @return If the creation success, return a pointer of Liquid action; otherwise, return nil. - */ - static Liquid* create(float duration, const Size& gridSize, unsigned int waves, float amplitude); - - /** - @brief Get the amplitude of the effect. - @return Return the amplitude of the effect. - */ - inline float getAmplitude() const { return _amplitude; } - /** - @brief Set the amplitude to the effect. - @param amplitude The value of amplitude will be set. - */ - inline void setAmplitude(float amplitude) { _amplitude = amplitude; } - - /** - @brief Get the amplitude rate of the effect. - @return Return the amplitude rate of the effect. - */ - inline float getAmplitudeRate() const { return _amplitudeRate; } - /** - @brief Set the amplitude rate of the effect. - @param amplitudeRate The value of amplitude rate will be set. - */ - inline void setAmplitudeRate(float amplitudeRate) { _amplitudeRate = amplitudeRate; } - - // Overrides - virtual Liquid* clone() const override; - virtual void update(float time) override; - -CC_CONSTRUCTOR_ACCESS: - Liquid() {} - virtual ~Liquid() {} - - /** - @brief Initializes the action with amplitude, grid size, waves count and duration. - @param duration Specify the duration of the Liquid action. It's a value in seconds. - @param gridSize Specify the size of the grid. - @param waves Specify the waves count of the Liquid action. - @param amplitude Specify the amplitude of the Liquid action. - @return If the initialization success, return true; otherwise, return false. - */ - bool initWithDuration(float duration, const Size& gridSize, unsigned int waves, float amplitude); - -protected: - unsigned int _waves; - float _amplitude; - float _amplitudeRate; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(Liquid); -}; - -/** -@brief Waves action. -@details This action is used for take effect on the target node as waves. - You can control the effect by these parameters: - duration, grid size, waves count, amplitude, - whether waves on horizontal and whether waves on vertical. -*/ -class CC_DLL Waves : public Grid3DAction -{ -public: - /** - @brief Create the action with amplitude, horizontal sin, vertical sin, grid size, waves count and duration. - @param duration Specify the duration of the Waves action. It's a value in seconds. - @param gridSize Specify the size of the grid. - @param waves Specify the waves count of the Waves action. - @param amplitude Specify the amplitude of the Waves action. - @param horizontal Specify whether waves on horizontal. - @param vertical Specify whether waves on vertical. - @return If the creation success, return a pointer of Waves action; otherwise, return nil. - */ - static Waves* create(float duration, const Size& gridSize, unsigned int waves, float amplitude, bool horizontal, bool vertical); - - /** - @brief Get the amplitude of the effect. - @return Return the amplitude of the effect. - */ - inline float getAmplitude() const { return _amplitude; } - /** - @brief Set the amplitude to the effect. - @param amplitude The value of amplitude will be set. - */ - inline void setAmplitude(float amplitude) { _amplitude = amplitude; } - - /** - @brief Get the amplitude rate of the effect. - @return Return the amplitude rate of the effect. - */ - inline float getAmplitudeRate() const { return _amplitudeRate; } - /** - @brief Set the amplitude rate of the effect. - @param amplitudeRate The value of amplitude rate will be set. - */ - inline void setAmplitudeRate(float amplitudeRate) { _amplitudeRate = amplitudeRate; } - - // Overrides - virtual Waves* clone() const override; - virtual void update(float time) override; - -CC_CONSTRUCTOR_ACCESS: - Waves() {} - virtual ~Waves() {} - - /** - @brief Initializes the action with amplitude, horizontal sin, vertical sin, grid size, waves count and duration. - @param duration Specify the duration of the Waves action. It's a value in seconds. - @param gridSize Specify the size of the grid. - @param waves Specify the waves count of the Waves action. - @param amplitude Specify the amplitude of the Waves action. - @param horizontal Specify whether waves on horizontal. - @param vertical Specify whether waves on vertical. - @return If the initialization success, return true; otherwise, return false. - */ - bool initWithDuration(float duration, const Size& gridSize, unsigned int waves, float amplitude, bool horizontal, bool vertical); - -protected: - unsigned int _waves; - float _amplitude; - float _amplitudeRate; - bool _vertical; - bool _horizontal; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(Waves); -}; - -/** -@brief Twirl action. -@details This action is used for take effect on the target node as twirl. - You can control the effect by these parameters: - duration, grid size, center position, twirls count, amplitude. -*/ -class CC_DLL Twirl : public Grid3DAction -{ -public: - /** - @brief Create the action with center position, number of twirls, amplitude, a grid size and duration. - @param duration Specify the duration of the Twirl action. It's a value in seconds. - @param gridSize Specify the size of the grid. - @param position Specify the center position of the twirl action. - @param twirls Specify the twirls count of the Twirl action. - @param amplitude Specify the amplitude of the Twirl action. - @return If the creation success, return a pointer of Twirl action; otherwise, return nil. - */ - static Twirl* create(float duration, const Size& gridSize, const Vec2& position, unsigned int twirls, float amplitude); - - /** - @brief Get the center position of twirl action. - @return The center position of twirl action. - */ - inline const Vec2& getPosition() const { return _position; } - /** - @brief Set the center position of twirl action. - @param position The center position of twirl action will be set. - */ - void setPosition(const Vec2& position); - - /** - @brief Get the amplitude of the effect. - @return Return the amplitude of the effect. - */ - inline float getAmplitude() const { return _amplitude; } - /** - @brief Set the amplitude to the effect. - @param amplitude The value of amplitude will be set. - */ - inline void setAmplitude(float amplitude) { _amplitude = amplitude; } - - /** - @brief Get the amplitude rate of the effect. - @return Return the amplitude rate of the effect. - */ - inline float getAmplitudeRate() const { return _amplitudeRate; } - /** - @brief Set the amplitude rate of the effect. - @param amplitudeRate The value of amplitude rate will be set. - */ - inline void setAmplitudeRate(float amplitudeRate) { _amplitudeRate = amplitudeRate; } - - - // Overrides - virtual Twirl* clone() const override; - virtual void update(float time) override; - -CC_CONSTRUCTOR_ACCESS: - Twirl() {} - virtual ~Twirl() {} - - /** - @brief Initializes the action with center position, number of twirls, amplitude, a grid size and duration. - @param duration Specify the duration of the Twirl action. It's a value in seconds. - @param gridSize Specify the size of the grid. - @param position Specify the center position of the twirl action. - @param twirls Specify the twirls count of the Twirl action. - @param amplitude Specify the amplitude of the Twirl action. - @return If the initialization success, return true; otherwise, return false. - */ - bool initWithDuration(float duration, const Size& gridSize, const Vec2& position, unsigned int twirls, float amplitude); - -protected: - /* twirl center */ - Vec2 _position; - unsigned int _twirls; - float _amplitude; - float _amplitudeRate; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(Twirl); -}; - -// end of actions group -/// @} - -NS_CC_END - -#endif // __ACTION_CCGRID3D_ACTION_H__ - diff --git a/native/cocos/2d/CCActionInstant.cpp b/native/cocos/2d/CCActionInstant.cpp deleted file mode 100644 index c872fe5f8d..0000000000 --- a/native/cocos/2d/CCActionInstant.cpp +++ /dev/null @@ -1,419 +0,0 @@ -/**************************************************************************** - Copyright (c) 2008-2010 Ricardo Quesada - Copyright (c) 2010-2012 cocos2d-x.org - Copyright (c) 2011 Zynga Inc. - Copyright (c) 2013-2016 Chukong Technologies Inc. - Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - - http://www.cocos2d-x.org - - Permission is hereby granted, free of charge, to any person obtaining a copy - of this software and associated documentation files (the "Software"), to deal - in the Software without restriction, including without limitation the rights - to use, copy, modify, merge, publish, distribute, sublicense, and/or sell - copies of the Software, and to permit persons to whom the Software is - furnished to do so, subject to the following conditions: - - The above copyright notice and this permission notice shall be included in - all copies or substantial portions of the Software. - - THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN - THE SOFTWARE. - ****************************************************************************/ - -#include "2d/CCActionInstant.h" -#include "2d/CCNode.h" -#include "2d/CCSprite.h" - -#if defined(__GNUC__) && ((__GNUC__ >= 4) || ((__GNUC__ == 3) && (__GNUC_MINOR__ >= 1))) -#pragma GCC diagnostic ignored "-Wdeprecated-declarations" -#elif _MSC_VER >= 1400 //vs 2005 or higher -#pragma warning (push) -#pragma warning (disable: 4996) -#endif - -NS_CC_BEGIN -// -// InstantAction -// -bool ActionInstant::isDone() const -{ - return true; -} - -void ActionInstant::step(float dt) -{ - CC_UNUSED_PARAM(dt); - float updateDt = 1; -#if CC_ENABLE_SCRIPT_BINDING - if (_scriptType == kScriptTypeJavascript) - { - if (ScriptEngineManager::sendActionEventToJS(this, kActionUpdate, (void *)&updateDt)) - return; - } -#endif - update(updateDt); -} - -void ActionInstant::update(float time) -{ - CC_UNUSED_PARAM(time); - // nothing -} - -// -// Show -// - -Show* Show::create() -{ - Show* ret = new (std::nothrow) Show(); - if (ret) - { - ret->autorelease(); - } - - return ret; -} - -void Show::update(float time) -{ - CC_UNUSED_PARAM(time); - _target->setVisible(true); -} - -ActionInstant* Show::reverse() const -{ - return Hide::create(); -} - -Show* Show::clone() const -{ - // no copy constructor - return Show::create(); -} - -// -// Hide -// -Hide * Hide::create() -{ - Hide *ret = new (std::nothrow) Hide(); - - if (ret) - { - ret->autorelease(); - } - - return ret; -} - -void Hide::update(float time) -{ - CC_UNUSED_PARAM(time); - _target->setVisible(false); -} - -ActionInstant *Hide::reverse() const -{ - return Show::create(); -} - -Hide* Hide::clone() const -{ - // no copy constructor - return Hide::create(); -} - -// -// ToggleVisibility -// -ToggleVisibility* ToggleVisibility::create() -{ - ToggleVisibility *ret = new (std::nothrow) ToggleVisibility(); - - if (ret) - { - ret->autorelease(); - } - - return ret; -} - -void ToggleVisibility::update(float time) -{ - CC_UNUSED_PARAM(time); - _target->setVisible(!_target->isVisible()); -} - -ToggleVisibility* ToggleVisibility::reverse() const -{ - return ToggleVisibility::create(); -} - -ToggleVisibility* ToggleVisibility::clone() const -{ - // no copy constructor - return ToggleVisibility::create(); -} - -// -// Remove Self -// -RemoveSelf* RemoveSelf::create(bool isNeedCleanUp /*= true*/) -{ - RemoveSelf *ret = new (std::nothrow) RemoveSelf(); - - if (ret && ret->init(isNeedCleanUp)) - { - ret->autorelease(); - } - - return ret; -} - -bool RemoveSelf::init(bool isNeedCleanUp) -{ - _isNeedCleanUp = isNeedCleanUp; - return true; -} - -void RemoveSelf::update(float time) -{ - CC_UNUSED_PARAM(time); - _target->removeFromParentAndCleanup(_isNeedCleanUp); -} - -RemoveSelf *RemoveSelf::reverse() const -{ - return RemoveSelf::create(_isNeedCleanUp); -} - -RemoveSelf* RemoveSelf::clone() const -{ - // no copy constructor - return RemoveSelf::create(_isNeedCleanUp); -} - -// -// FlipX -// - -FlipX *FlipX::create(bool x) -{ - FlipX *ret = new (std::nothrow) FlipX(); - - if (ret && ret->initWithFlipX(x)) - { - ret->autorelease(); - return ret; - } - - CC_SAFE_DELETE(ret); - return nullptr; -} - -bool FlipX::initWithFlipX(bool x) -{ - _flipX = x; - return true; -} - -void FlipX::update(float time) -{ - CC_UNUSED_PARAM(time); - static_cast(_target)->setFlippedX(_flipX); -} - -FlipX* FlipX::reverse() const -{ - return FlipX::create(!_flipX); -} - -FlipX * FlipX::clone() const -{ - // no copy constructor - return FlipX::create(_flipX); -} -// -// FlipY -// - -FlipY * FlipY::create(bool y) -{ - FlipY *ret = new (std::nothrow) FlipY(); - - if (ret && ret->initWithFlipY(y)) - { - ret->autorelease(); - return ret; - } - - CC_SAFE_DELETE(ret); - return nullptr; -} - -bool FlipY::initWithFlipY(bool y) -{ - _flipY = y; - return true; -} - -void FlipY::update(float time) -{ - CC_UNUSED_PARAM(time); - static_cast(_target)->setFlippedY(_flipY); -} - -FlipY* FlipY::reverse() const -{ - return FlipY::create(!_flipY); -} - -FlipY * FlipY::clone() const -{ - // no copy constructor - return FlipY::create(_flipY); -} - -// -// Place -// - -Place* Place::create(const Vec2& pos) -{ - Place *ret = new (std::nothrow) Place(); - - if (ret && ret->initWithPosition(pos)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -bool Place::initWithPosition(const Vec2& pos) -{ - _position = pos; - return true; -} - -Place * Place::clone() const -{ - // no copy constructor - return Place::create(_position); -} - -Place * Place::reverse() const -{ - // no reverse, just clone - return this->clone(); -} - -void Place::update(float time) -{ - CC_UNUSED_PARAM(time); - _target->setPosition(_position); -} - -// -// CallFunc -// - -CallFunc * CallFunc::create(const std::function &func) -{ - CallFunc *ret = new (std::nothrow) CallFunc(); - - if (ret && ret->initWithFunction(func) ) - { - ret->autorelease(); - return ret; - } - - CC_SAFE_DELETE(ret); - return nullptr; -} - -bool CallFunc::initWithFunction(const std::function &func) -{ - _function = func; - return true; -} - -CallFunc::~CallFunc() -{ - CC_SAFE_RELEASE(_selectorTarget); -} - -CallFunc* CallFunc::clone() const -{ - // no copy constructor - return CallFunc::create(_function); -} - -CallFunc * CallFunc::reverse() const -{ - // no reverse here, just return a clone - return this->clone(); -} - -void CallFunc::update(float time) -{ - CC_UNUSED_PARAM(time); - this->execute(); -} - -void CallFunc::execute() -{ - if( _function ){ - _function(); - } -} - -// -// CallFuncN -// - -CallFuncN * CallFuncN::create(const std::function &func) -{ - auto ret = new (std::nothrow) CallFuncN(); - - if (ret && ret->initWithFunction(func) ) - { - ret->autorelease(); - return ret; - } - - CC_SAFE_DELETE(ret); - return nullptr; -} - -void CallFuncN::execute() -{ - if (_functionN) - { - _functionN(_target); - } -} - -bool CallFuncN::initWithFunction(const std::function &func) -{ - _functionN = func; - return true; -} - -CallFuncN * CallFuncN::clone() const -{ - // no copy constructor - return CallFuncN::create(_functionN); -} - -NS_CC_END - diff --git a/native/cocos/2d/CCActionInstant.h b/native/cocos/2d/CCActionInstant.h deleted file mode 100644 index 2a06c15686..0000000000 --- a/native/cocos/2d/CCActionInstant.h +++ /dev/null @@ -1,443 +0,0 @@ -/**************************************************************************** - Copyright (c) 2008-2010 Ricardo Quesada - Copyright (c) 2010-2012 cocos2d-x.org - Copyright (c) 2011 Zynga Inc. - Copyright (c) 2013-2016 Chukong Technologies Inc. - Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ - -#ifndef __CCINSTANT_ACTION_H__ -#define __CCINSTANT_ACTION_H__ - -#include -#include "2d/CCAction.h" - -NS_CC_BEGIN - -/** - * @addtogroup actions - * @{ - */ - -/** @class ActionInstant -* @brief Instant actions are immediate actions. They don't have a duration like the IntervalAction actions. -**/ -class CC_DLL ActionInstant : public FiniteTimeAction // -{ -public: - // - // Overrides - // - virtual ActionInstant* clone() const override - { - CC_ASSERT(0); - return nullptr; - } - - virtual ActionInstant * reverse() const override - { - CC_ASSERT(0); - return nullptr; - } - - virtual bool isDone() const override; - /** - * @param dt In seconds. - */ - virtual void step(float dt) override; - /** - * @param time In seconds. - */ - virtual void update(float time) override; -}; - -/** @class Show -* @brief Show the node. -**/ -class CC_DLL Show : public ActionInstant -{ -public: - /** Allocates and initializes the action. - * - * @return An autoreleased Show object. - */ - static Show * create(); - - // - // Overrides - // - /** - * @param time In seconds. - */ - virtual void update(float time) override; - virtual ActionInstant* reverse() const override; - virtual Show* clone() const override; - -CC_CONSTRUCTOR_ACCESS: - Show(){} - virtual ~Show(){} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(Show); -}; - -/** @class Hide -* @brief Hide the node. -*/ -class CC_DLL Hide : public ActionInstant -{ -public: - /** Allocates and initializes the action. - * - * @return An autoreleased Hide object. - */ - static Hide * create(); - - // - // Overrides - // - /** - * @param time In seconds. - */ - virtual void update(float time) override; - virtual ActionInstant* reverse() const override; - virtual Hide* clone() const override; - -CC_CONSTRUCTOR_ACCESS: - Hide(){} - virtual ~Hide(){} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(Hide); -}; - -/** @class ToggleVisibility -* @brief Toggles the visibility of a node. -*/ -class CC_DLL ToggleVisibility : public ActionInstant -{ -public: - /** Allocates and initializes the action. - * - * @return An autoreleased ToggleVisibility object. - */ - static ToggleVisibility * create(); - - // - // Overrides - // - /** - * @param time In seconds. - */ - virtual void update(float time) override; - virtual ToggleVisibility* reverse() const override; - virtual ToggleVisibility* clone() const override; - -CC_CONSTRUCTOR_ACCESS: - ToggleVisibility(){} - virtual ~ToggleVisibility(){} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(ToggleVisibility); -}; - -/** @class RemoveSelf -* @brief Remove the node. -*/ -class CC_DLL RemoveSelf : public ActionInstant -{ -public: - /** Create the action. - * - * @param isNeedCleanUp Is need to clean up, the default value is true. - * @return An autoreleased RemoveSelf object. - */ - static RemoveSelf * create(bool isNeedCleanUp = true); - - // - // Override - // - /** - * @param time In seconds. - */ - virtual void update(float time) override; - virtual RemoveSelf* clone() const override; - virtual RemoveSelf* reverse() const override; - -CC_CONSTRUCTOR_ACCESS: - RemoveSelf() : _isNeedCleanUp(true){} - virtual ~RemoveSelf(){} - - /** init the action */ - bool init(bool isNeedCleanUp); - -protected: - bool _isNeedCleanUp; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(RemoveSelf); -}; - -/** @class FlipX -* @brief Flips the sprite horizontally. -* @since v0.99.0 -*/ -class CC_DLL FlipX : public ActionInstant -{ -public: - /** Create the action. - * - * @param x Flips the sprite horizontally if true. - * @return An autoreleased FlipX object. - */ - static FlipX * create(bool x); - - // - // Overrides - // - /** - * @param time In seconds. - */ - virtual void update(float time) override; - virtual FlipX* reverse() const override; - virtual FlipX* clone() const override; - -CC_CONSTRUCTOR_ACCESS: - FlipX() :_flipX(false) {} - virtual ~FlipX() {} - - /** init the action */ - bool initWithFlipX(bool x); - -protected: - bool _flipX; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(FlipX); -}; - -/** @class FlipY -* @brief Flips the sprite vertically. -* @since v0.99.0 -*/ -class CC_DLL FlipY : public ActionInstant -{ -public: - /** Create the action. - * - * @param y Flips the sprite vertically if true. - * @return An autoreleased FlipY object. - */ - static FlipY * create(bool y); - - // - // Overrides - // - /** - * @param time In seconds. - */ - virtual void update(float time) override; - virtual FlipY* reverse() const override; - virtual FlipY* clone() const override; - -CC_CONSTRUCTOR_ACCESS: - FlipY() :_flipY(false) {} - virtual ~FlipY() {} - - /** init the action */ - bool initWithFlipY(bool y); - -protected: - bool _flipY; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(FlipY); -}; - -/** @class Place -* @brief Places the node in a certain position. -*/ -class CC_DLL Place : public ActionInstant // -{ -public: - - /** Creates a Place action with a position. - * - * @param pos A certain position. - * @return An autoreleased Place object. - */ - static Place * create(const Vec2& pos); - - // - // Overrides - // - /** - * @param time In seconds. - */ - virtual void update(float time) override; - virtual Place* reverse() const override; - virtual Place* clone() const override; - -CC_CONSTRUCTOR_ACCESS: - Place(){} - virtual ~Place(){} - - /** Initializes a Place action with a position */ - bool initWithPosition(const Vec2& pos); - -protected: - Vec2 _position; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(Place); -}; - - -/** @class CallFunc -* @brief Calls a 'callback'. -*/ -class CC_DLL CallFunc : public ActionInstant // -{ -public: - /** Creates the action with the callback of type std::function. - This is the preferred way to create the callback. - * When this function bound in js or lua ,the input param will be changed. - * In js: var create(var func, var this, var [data]) or var create(var func). - * In lua:local create(local funcID). - * - * @param func A callback function need to be executed. - * @return An autoreleased CallFunc object. - */ - static CallFunc * create(const std::function& func); - -public: - /** Executes the callback. - */ - virtual void execute(); - - /** Get the selector target. - * - * @return The selector target. - */ - inline Ref* getTargetCallback() - { - return _selectorTarget; - } - - /** Set the selector target. - * - * @param sel The selector target. - */ - inline void setTargetCallback(Ref* sel) - { - if (sel != _selectorTarget) - { - CC_SAFE_RETAIN(sel); - CC_SAFE_RELEASE(_selectorTarget); - _selectorTarget = sel; - } - } - // - // Overrides - // - /** - * @param time In seconds. - */ - virtual void update(float time) override; - virtual CallFunc* reverse() const override; - virtual CallFunc* clone() const override; - -CC_CONSTRUCTOR_ACCESS: - CallFunc() - : _selectorTarget(nullptr) - , _callFunc(nullptr) - , _function(nullptr) - { - } - virtual ~CallFunc(); - - /** initializes the action with the std::function - * @lua NA - */ - bool initWithFunction(const std::function& func); - -protected: - /** Target that will be called */ - Ref* _selectorTarget; - - union - { - SEL_CallFunc _callFunc; - SEL_CallFuncN _callFuncN; - }; - - /** function that will be called */ - std::function _function; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(CallFunc); -}; - -/** @class CallFuncN -* @brief Calls a 'callback' with the node as the first argument. N means Node. -* @js NA -*/ -class CC_DLL CallFuncN : public CallFunc -{ -public: - /** Creates the action with the callback of type std::function. - This is the preferred way to create the callback. - * - * @param func A callback function need to be executed. - * @return An autoreleased CallFuncN object. - */ - static CallFuncN * create(const std::function& func); - - // - // Overrides - // - virtual CallFuncN* clone() const override; - virtual void execute() override; - -CC_CONSTRUCTOR_ACCESS: - CallFuncN():_functionN(nullptr){} - virtual ~CallFuncN(){} - - /** initializes the action with the std::function */ - bool initWithFunction(const std::function& func); - -protected: - /** function that will be called with the "sender" as the 1st argument */ - std::function _functionN; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(CallFuncN); -}; - -// end of actions group -/// @} - -NS_CC_END - -#endif //__CCINSTANT_ACTION_H__ - diff --git a/native/cocos/2d/CCActionInterval.cpp b/native/cocos/2d/CCActionInterval.cpp deleted file mode 100644 index 7049f80764..0000000000 --- a/native/cocos/2d/CCActionInterval.cpp +++ /dev/null @@ -1,2640 +0,0 @@ -/**************************************************************************** -Copyright (c) 2008-2010 Ricardo Quesada -Copyright (c) 2010-2012 cocos2d-x.org -Copyright (c) 2011 Zynga Inc. -Copyright (c) 2013-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ - -#include "2d/CCActionInterval.h" - -#include - -#include "2d/CCSprite.h" -#include "2d/CCNode.h" -#include "2d/CCSpriteFrame.h" -#include "2d/CCActionInstant.h" -#include "base/CCDirector.h" -#include "base/CCEventCustom.h" -#include "base/CCEventDispatcher.h" -#include "platform/CCStdC.h" -#include "base/CCScriptSupport.h" - -NS_CC_BEGIN - -// Extra action for making a Sequence or Spawn when only adding one action to it. -class ExtraAction : public FiniteTimeAction -{ -public: - static ExtraAction* create(); - virtual ExtraAction* clone() const; - virtual ExtraAction* reverse(void) const; - virtual void update(float time); - virtual void step(float dt); -}; - -ExtraAction* ExtraAction::create() -{ - ExtraAction* ret = new (std::nothrow) ExtraAction(); - if (ret) - { - ret->autorelease(); - } - return ret; -} - -ExtraAction* ExtraAction::clone() const -{ - // no copy constructor - return ExtraAction::create(); -} - -ExtraAction* ExtraAction::reverse() const -{ - return ExtraAction::create(); -} - -void ExtraAction::update(float time) -{ - CC_UNUSED_PARAM(time); -} - -void ExtraAction::step(float dt) -{ - CC_UNUSED_PARAM(dt); -} - -// -// IntervalAction -// -bool ActionInterval::initWithDuration(float d) -{ - _duration = d; - - // prevent division by 0 - // This comparison could be in step:, but it might decrease the performance - // by 3% in heavy based action games. - if (_duration <= FLT_EPSILON) - { - _duration = FLT_EPSILON; - } - - _elapsed = 0; - _firstTick = true; - - return true; -} - -bool ActionInterval::sendUpdateEventToScript(float dt, Action *actionObject) -{ -#if CC_ENABLE_SCRIPT_BINDING - if (_scriptType == kScriptTypeJavascript) - { - ScriptEngineManager::sendActionEventToJS(actionObject, kActionUpdate, (void *)&dt); - } -#endif - return false; -} - -bool ActionInterval::isDone() const -{ - return _elapsed >= _duration; -} - -void ActionInterval::step(float dt) -{ - if (_firstTick) - { - _firstTick = false; - _elapsed = 0; - } - else - { - _elapsed += dt; - } - - - float updateDt = MAX (0, // needed for rewind. elapsed could be negative - MIN(1, _elapsed / _duration) - ); - - this->update(updateDt); - sendUpdateEventToScript(updateDt, this); -} - -void ActionInterval::setAmplitudeRate(float amp) -{ - CC_UNUSED_PARAM(amp); - // Abstract class needs implementation - CCASSERT(0, "Subclass should implement this method!"); -} - -float ActionInterval::getAmplitudeRate() -{ - // Abstract class needs implementation - CCASSERT(0, "Subclass should implement this method!"); - - return 0; -} - -void ActionInterval::startWithTarget(Node *target) -{ - FiniteTimeAction::startWithTarget(target); - _elapsed = 0.0f; - _firstTick = true; -} - -// -// Sequence -// - -Sequence* Sequence::createWithTwoActions(FiniteTimeAction *actionOne, FiniteTimeAction *actionTwo) -{ - Sequence *sequence = new (std::nothrow) Sequence(); - if (sequence && sequence->initWithTwoActions(actionOne, actionTwo)) - { - sequence->autorelease(); - return sequence; - } - - delete sequence; - return nullptr; -} - -#if (CC_TARGET_PLATFORM == CC_PLATFORM_WINRT) -Sequence* Sequence::variadicCreate(FiniteTimeAction *action1, ...) -{ - va_list params; - va_start(params, action1); - - Sequence *ret = Sequence::createWithVariableList(action1, params); - - va_end(params); - - return ret; -} -#else -Sequence* Sequence::create(FiniteTimeAction *action1, ...) -{ - va_list params; - va_start(params, action1); - - Sequence *ret = Sequence::createWithVariableList(action1, params); - - va_end(params); - - return ret; -} -#endif - -Sequence* Sequence::createWithVariableList(FiniteTimeAction *action1, va_list args) -{ - FiniteTimeAction *now; - FiniteTimeAction *prev = action1; - bool bOneAction = true; - - while (action1) - { - now = va_arg(args, FiniteTimeAction*); - if (now) - { - prev = createWithTwoActions(prev, now); - bOneAction = false; - } - else - { - // If only one action is added to Sequence, make up a Sequence by adding a simplest finite time action. - if (bOneAction) - { - prev = createWithTwoActions(prev, ExtraAction::create()); - } - break; - } - } - - return ((Sequence*)prev); -} - -Sequence* Sequence::create(const Vector& arrayOfActions) -{ - Sequence* seq = new (std::nothrow) Sequence; - - if (seq && seq->init(arrayOfActions)) - { - seq->autorelease(); - return seq; - } - - delete seq; - return nullptr; -} - -bool Sequence::init(const Vector& arrayOfActions) -{ - auto count = arrayOfActions.size(); - if (count == 0) - return false; - - if (count == 1) - return initWithTwoActions(arrayOfActions.at(0), ExtraAction::create()); - - // else size > 1 - auto prev = arrayOfActions.at(0); - for (int i = 1; i < count-1; ++i) - { - FiniteTimeAction *action = arrayOfActions.at(i); - prev = createWithTwoActions(prev, action); -#if CC_ENABLE_GC_FOR_NATIVE_OBJECTS - auto sEngine = ScriptEngineManager::getInstance()->getScriptEngine(); - if (sEngine) - { - sEngine->retainScriptObject(this, action); - } -#endif // CC_ENABLE_GC_FOR_NATIVE_OBJECTS - } - - return initWithTwoActions(prev, arrayOfActions.at(count-1)); -} - -bool Sequence::initWithTwoActions(FiniteTimeAction *actionOne, FiniteTimeAction *actionTwo) -{ - CCASSERT(actionOne != nullptr, "actionOne can't be nullptr!"); - CCASSERT(actionTwo != nullptr, "actionTwo can't be nullptr!"); - if (actionOne == nullptr || actionTwo == nullptr) - { - log("Sequence::initWithTwoActions error: action is nullptr!!"); - return false; - } - - float d = actionOne->getDuration() + actionTwo->getDuration(); - ActionInterval::initWithDuration(d); - - _actions[0] = actionOne; - actionOne->retain(); - - _actions[1] = actionTwo; - actionTwo->retain(); - -#if CC_ENABLE_GC_FOR_NATIVE_OBJECTS - auto sEngine = ScriptEngineManager::getInstance()->getScriptEngine(); - if (sEngine) - { - sEngine->retainScriptObject(this, actionOne); - sEngine->retainScriptObject(this, actionTwo); - } -#endif // CC_ENABLE_GC_FOR_NATIVE_OBJECTS - - return true; -} - -Sequence* Sequence::clone() const -{ - // no copy constructor - if (_actions[0] && _actions[1]) - { - return Sequence::create(_actions[0]->clone(), _actions[1]->clone(), nullptr); - } else { - return nullptr; - } -} - -Sequence::Sequence() -: _split(0) -{ - _actions[0] = nullptr; - _actions[1] = nullptr; -} - -Sequence::~Sequence() -{ - CC_SAFE_RELEASE(_actions[0]); - CC_SAFE_RELEASE(_actions[1]); -} - -void Sequence::startWithTarget(Node *target) -{ - if (target == nullptr) - { - log("Sequence::startWithTarget error: target is nullptr!"); - return; - } - if (_actions[0] == nullptr || _actions[1] == nullptr) - { - log("Sequence::startWithTarget error: _actions[0] or _actions[1] is nullptr!"); - return; - } - if (_duration > FLT_EPSILON) - _split = _actions[0]->getDuration() / _duration; - - ActionInterval::startWithTarget(target); - _last = -1; -} - -void Sequence::stop(void) -{ - // Issue #1305 - if( _last != - 1 && _actions[_last]) - { - _actions[_last]->stop(); - } - - ActionInterval::stop(); -} - -void Sequence::update(float t) -{ - int found = 0; - float new_t = 0.0f; - - if( t < _split ) - { - // action[0] - found = 0; - if( _split != 0 ) - new_t = t / _split; - else - new_t = 1; - - } - else - { - // action[1] - found = 1; - if ( _split == 1 ) - new_t = 1; - else - new_t = (t-_split) / (1 - _split ); - } - - if ( found==1 ) - { - if( _last == -1 ) - { - // action[0] was skipped, execute it. - _actions[0]->startWithTarget(_target); - _actions[0]->update(1.0f); - sendUpdateEventToScript(1.0f, _actions[0]); - - _actions[0]->stop(); - } - else if( _last == 0 ) - { - // switching to action 1. stop action 0. - _actions[0]->update(1.0f); - sendUpdateEventToScript(1.0f, _actions[0]); - _actions[0]->stop(); - } - } - else if(found==0 && _last==1 ) - { - // Reverse mode ? - // FIXME: Bug. this case doesn't contemplate when _last==-1, found=0 and in "reverse mode" - // since it will require a hack to know if an action is on reverse mode or not. - // "step" should be overridden, and the "reverseMode" value propagated to inner Sequences. - _actions[1]->update(0); - sendUpdateEventToScript(0, _actions[1]); - _actions[1]->stop(); - } - // Last action found and it is done. - if( found == _last && _actions[found]->isDone() ) - { - return; - } - - // Last action found and it is done - if( found != _last ) - { - _actions[found]->startWithTarget(_target); - } - - _actions[found]->update(new_t); - sendUpdateEventToScript(new_t, _actions[found]); - - _last = found; -} - -Sequence* Sequence::reverse() const -{ - if (_actions[0] && _actions[1]) - return Sequence::createWithTwoActions(_actions[1]->reverse(), _actions[0]->reverse()); - else - return nullptr; -} - -// -// Repeat -// - -Repeat* Repeat::create(FiniteTimeAction *action, unsigned int times) -{ - Repeat* repeat = new (std::nothrow) Repeat(); - if (repeat && repeat->initWithAction(action, times)) - { - repeat->autorelease(); - return repeat; - } - - delete repeat; - return nullptr; -} - -bool Repeat::initWithAction(FiniteTimeAction *action, unsigned int times) -{ - float d = action->getDuration() * times; - - if (action && ActionInterval::initWithDuration(d)) - { - _times = times; - _innerAction = action; - action->retain(); -#if CC_ENABLE_GC_FOR_NATIVE_OBJECTS - auto sEngine = ScriptEngineManager::getInstance()->getScriptEngine(); - if (sEngine) - { - sEngine->retainScriptObject(this, _innerAction); - } -#endif // CC_ENABLE_GC_FOR_NATIVE_OBJECTS - - _actionInstant = dynamic_cast(action) ? true : false; - //an instant action needs to be executed one time less in the update method since it uses startWithTarget to execute the action - // minggo: instant action doesn't execute action in Repeat::startWithTarget(), so comment it. -// if (_actionInstant) -// { -// _times -=1; -// } - _total = 0; - - return true; - } - - return false; -} - -Repeat* Repeat::clone(void) const -{ - // no copy constructor - return Repeat::create(_innerAction->clone(), _times); -} - -Repeat::~Repeat(void) -{ - CC_SAFE_RELEASE(_innerAction); -} - -void Repeat::startWithTarget(Node *target) -{ - _total = 0; - _nextDt = _innerAction->getDuration()/_duration; - ActionInterval::startWithTarget(target); - _innerAction->startWithTarget(target); -} - -void Repeat::stop(void) -{ - _innerAction->stop(); - ActionInterval::stop(); -} - -// issue #80. Instead of hooking step:, hook update: since it can be called by any -// container action like Repeat, Sequence, Ease, etc.. -void Repeat::update(float dt) -{ - if (dt >= _nextDt) - { - while (dt >= _nextDt && _total < _times) - { - _innerAction->update(1.0f); - sendUpdateEventToScript(1.0f, _innerAction); - - _total++; - - _innerAction->stop(); - _innerAction->startWithTarget(_target); - _nextDt = _innerAction->getDuration()/_duration * (_total+1); - } - - // fix for issue #1288, incorrect end value of repeat - if (std::abs(dt - 1.0f) < FLT_EPSILON && _total < _times) - { - _innerAction->update(1.0f); - sendUpdateEventToScript(1.0f, _innerAction); - - _total++; - } - - // don't set an instant action back or update it, it has no use because it has no duration - if (!_actionInstant) - { - if (_total == _times) - { - // minggo: inner action update is invoked above, don't have to invoke it here -// _innerAction->update(1); -// sendUpdateEventToScript(1, _innerAction); - _innerAction->stop(); - } - else - { - // issue #390 prevent jerk, use right update - _innerAction->update(dt - (_nextDt - _innerAction->getDuration()/_duration)); - sendUpdateEventToScript(dt - (_nextDt - _innerAction->getDuration()/_duration), _innerAction); - } - } - } - else - { - _innerAction->update(fmodf(dt * _times,1.0f)); - sendUpdateEventToScript(fmodf(dt * _times,1.0f), _innerAction); - } -} - -bool Repeat::isDone(void) const -{ - return _total == _times; -} - -Repeat* Repeat::reverse() const -{ - return Repeat::create(_innerAction->reverse(), _times); -} - -// -// RepeatForever -// -RepeatForever::~RepeatForever() -{ - CC_SAFE_RELEASE(_innerAction); -} - -RepeatForever *RepeatForever::create(ActionInterval *action) -{ - RepeatForever *ret = new (std::nothrow) RepeatForever(); - if (ret && ret->initWithAction(action)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -bool RepeatForever::initWithAction(ActionInterval *action) -{ - CCASSERT(action != nullptr, "action can't be nullptr!"); - if (action == nullptr) - { - log("RepeatForever::initWithAction error:action is nullptr!"); - return false; - } - - action->retain(); - _innerAction = action; -#if CC_ENABLE_GC_FOR_NATIVE_OBJECTS - auto sEngine = ScriptEngineManager::getInstance()->getScriptEngine(); - if (sEngine) - { - sEngine->retainScriptObject(this, _innerAction); - } -#endif // CC_ENABLE_GC_FOR_NATIVE_OBJECTS - - return true; -} - -RepeatForever *RepeatForever::clone() const -{ - // no copy constructor - return RepeatForever::create(_innerAction->clone()); -} - -void RepeatForever::startWithTarget(Node* target) -{ - ActionInterval::startWithTarget(target); - _innerAction->startWithTarget(target); -} - -void RepeatForever::step(float dt) -{ - _innerAction->step(dt); - if (_innerAction->isDone()) - { - float diff = _innerAction->getElapsed() - _innerAction->getDuration(); - if (diff > _innerAction->getDuration()) - diff = fmodf(diff, _innerAction->getDuration()); - _innerAction->startWithTarget(_target); - // to prevent jerk. issue #390, 1247 - _innerAction->step(0.0f); - _innerAction->step(diff); - } -} - -bool RepeatForever::isDone() const -{ - return false; -} - -RepeatForever *RepeatForever::reverse() const -{ - return RepeatForever::create(_innerAction->reverse()); -} - -// -// Spawn -// - -#if (CC_TARGET_PLATFORM == CC_PLATFORM_WINRT) -Spawn* Spawn::variadicCreate(FiniteTimeAction *action1, ...) -{ - va_list params; - va_start(params, action1); - - Spawn *ret = Spawn::createWithVariableList(action1, params); - - va_end(params); - - return ret; -} -#else -Spawn* Spawn::create(FiniteTimeAction *action1, ...) -{ - va_list params; - va_start(params, action1); - - Spawn *ret = Spawn::createWithVariableList(action1, params); - - va_end(params); - - return ret; -} -#endif - -Spawn* Spawn::createWithVariableList(FiniteTimeAction *action1, va_list args) -{ - FiniteTimeAction *now; - FiniteTimeAction *prev = action1; - bool oneAction = true; - - while (action1) - { - now = va_arg(args, FiniteTimeAction*); - if (now) - { - prev = createWithTwoActions(prev, now); - oneAction = false; - } - else - { - // If only one action is added to Spawn, make up a Spawn by adding a simplest finite time action. - if (oneAction) - { - prev = createWithTwoActions(prev, ExtraAction::create()); - } - break; - } - } - - return ((Spawn*)prev); -} - -Spawn* Spawn::create(const Vector& arrayOfActions) -{ - Spawn* ret = new (std::nothrow) Spawn; - - if (ret && ret->init(arrayOfActions)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -Spawn* Spawn::createWithTwoActions(FiniteTimeAction *action1, FiniteTimeAction *action2) -{ - Spawn *spawn = new (std::nothrow) Spawn(); - if (spawn && spawn->initWithTwoActions(action1, action2)) - { - spawn->autorelease(); - return spawn; - } - - delete spawn; - return nullptr; -} - -bool Spawn::init(const Vector& arrayOfActions) -{ - auto count = arrayOfActions.size(); - - if (count == 0) - return false; - - if (count == 1) - return initWithTwoActions(arrayOfActions.at(0), ExtraAction::create()); - - // else count > 1 - auto prev = arrayOfActions.at(0); - for (int i = 1; i < count-1; ++i) - { - FiniteTimeAction* action = arrayOfActions.at(i); - prev = createWithTwoActions(prev, action); -#if CC_ENABLE_GC_FOR_NATIVE_OBJECTS - auto sEngine = ScriptEngineManager::getInstance()->getScriptEngine(); - if (sEngine) - { - sEngine->retainScriptObject(this, action); - } -#endif // CC_ENABLE_GC_FOR_NATIVE_OBJECTS - } - - return initWithTwoActions(prev, arrayOfActions.at(count-1)); -} - -bool Spawn::initWithTwoActions(FiniteTimeAction *action1, FiniteTimeAction *action2) -{ - CCASSERT(action1 != nullptr, "action1 can't be nullptr!"); - CCASSERT(action2 != nullptr, "action2 can't be nullptr!"); - if (action1 == nullptr || action2 == nullptr) - { - log("Spawn::initWithTwoActions error: action is nullptr!"); - return false; - } - - bool ret = false; - - float d1 = action1->getDuration(); - float d2 = action2->getDuration(); - - if (ActionInterval::initWithDuration(MAX(d1, d2))) - { - _one = action1; - _two = action2; - - if (d1 > d2) - { - _two = Sequence::createWithTwoActions(action2, DelayTime::create(d1 - d2)); - } - else if (d1 < d2) - { - _one = Sequence::createWithTwoActions(action1, DelayTime::create(d2 - d1)); - } - - _one->retain(); - _two->retain(); - -#if CC_ENABLE_GC_FOR_NATIVE_OBJECTS - auto sEngine = ScriptEngineManager::getInstance()->getScriptEngine(); - if (sEngine) - { - sEngine->retainScriptObject(this, _one); - sEngine->retainScriptObject(this, _two); - } -#endif // CC_ENABLE_GC_FOR_NATIVE_OBJECTS - - ret = true; - } - - return ret; -} - -Spawn* Spawn::clone(void) const -{ - // no copy constructor - if (_one && _two) - return Spawn::createWithTwoActions(_one->clone(), _two->clone()); - else - return nullptr; -} - -Spawn::Spawn() -: _one(nullptr) -, _two(nullptr) -{ - -} - -Spawn::~Spawn(void) -{ - CC_SAFE_RELEASE(_one); - CC_SAFE_RELEASE(_two); -} - -void Spawn::startWithTarget(Node *target) -{ - if (target == nullptr) - { - log("Spawn::startWithTarget error: target is nullptr!"); - return; - } - if (_one == nullptr || _two == nullptr) - { - log("Spawn::startWithTarget error: _one or _two is nullptr!"); - return; - } - - ActionInterval::startWithTarget(target); - _one->startWithTarget(target); - _two->startWithTarget(target); -} - -void Spawn::stop(void) -{ - if (_one) - _one->stop(); - - if (_two) - _two->stop(); - - ActionInterval::stop(); -} - -void Spawn::update(float time) -{ - if (_one) - { - _one->update(time); - sendUpdateEventToScript(time, _one); - - } - if (_two) - { - _two->update(time); - sendUpdateEventToScript(time, _two); - } -} - -Spawn* Spawn::reverse() const -{ - if (_one && _two) - return Spawn::createWithTwoActions(_one->reverse(), _two->reverse()); - - return nullptr; -} - -// -// RotateTo -// - -RotateTo* RotateTo::create(float duration, float dstAngle) -{ - RotateTo* rotateTo = new (std::nothrow) RotateTo(); - if (rotateTo && rotateTo->initWithDuration(duration, dstAngle, dstAngle)) - { - rotateTo->autorelease(); - return rotateTo; - } - - delete rotateTo; - return nullptr; -} - -RotateTo* RotateTo::create(float duration, float dstAngleX, float dstAngleY) -{ - RotateTo* rotateTo = new (std::nothrow) RotateTo(); - if (rotateTo && rotateTo->initWithDuration(duration, dstAngleX, dstAngleY)) - { - rotateTo->autorelease(); - return rotateTo; - } - - delete rotateTo; - return nullptr; -} - -RotateTo::RotateTo() -{ -} - -bool RotateTo::initWithDuration(float duration, float dstAngleX, float dstAngleY) -{ - if (ActionInterval::initWithDuration(duration)) - { - _dstAngle.x = dstAngleX; - _dstAngle.y = dstAngleY; - - return true; - } - - return false; -} - -RotateTo* RotateTo::clone() const -{ - // no copy constructor - return RotateTo::create(_duration, _dstAngle.x, _dstAngle.y); -} - -void RotateTo::calculateAngles(float &startAngle, float &diffAngle, float dstAngle) -{ - if (startAngle > 0) - { - startAngle = fmodf(startAngle, 360.0f); - } - else - { - startAngle = fmodf(startAngle, -360.0f); - } - - diffAngle = dstAngle - startAngle; - if (diffAngle > 180) - { - diffAngle -= 360; - } - if (diffAngle < -180) - { - diffAngle += 360; - } -} - -void RotateTo::startWithTarget(Node *target) -{ - ActionInterval::startWithTarget(target); - _startAngle.x = _target->getRotationSkewX(); - _startAngle.y = _target->getRotationSkewY(); - - calculateAngles(_startAngle.x, _diffAngle.x, _dstAngle.x); - calculateAngles(_startAngle.y, _diffAngle.y, _dstAngle.y); - calculateAngles(_startAngle.z, _diffAngle.z, _dstAngle.z); -} - -void RotateTo::update(float time) -{ - if (_target) - { - _target->setRotationSkewX(_startAngle.x + _diffAngle.x * time); - _target->setRotationSkewY(_startAngle.y + _diffAngle.y * time); - } -} - -RotateTo *RotateTo::reverse() const -{ - CCASSERT(false, "RotateTo doesn't support the 'reverse' method"); - return nullptr; -} - -// -// RotateBy -// - -RotateBy* RotateBy::create(float duration, float deltaAngle) -{ - RotateBy *rotateBy = new (std::nothrow) RotateBy(); - if (rotateBy && rotateBy->initWithDuration(duration, deltaAngle)) - { - rotateBy->autorelease(); - return rotateBy; - } - - delete rotateBy; - return nullptr; -} - -RotateBy* RotateBy::create(float duration, float deltaAngleX, float deltaAngleY) -{ - RotateBy *rotateBy = new (std::nothrow) RotateBy(); - if (rotateBy && rotateBy->initWithDuration(duration, deltaAngleX, deltaAngleY)) - { - rotateBy->autorelease(); - return rotateBy; - } - - delete rotateBy; - return nullptr; -} - -RotateBy::RotateBy() -{ -} - -bool RotateBy::initWithDuration(float duration, float deltaAngle) -{ - if (ActionInterval::initWithDuration(duration)) - { - _deltaAngle.x = _deltaAngle.y = deltaAngle; - return true; - } - - return false; -} - -bool RotateBy::initWithDuration(float duration, float deltaAngleX, float deltaAngleY) -{ - if (ActionInterval::initWithDuration(duration)) - { - _deltaAngle.x = deltaAngleX; - _deltaAngle.y = deltaAngleY; - return true; - } - - return false; -} - -RotateBy* RotateBy::clone() const -{ - // no copy constructor - return RotateBy::create(_duration, _deltaAngle.x, _deltaAngle.y); -} - -void RotateBy::startWithTarget(Node *target) -{ - ActionInterval::startWithTarget(target); - _startAngle.x = target->getRotationSkewX(); - _startAngle.y = target->getRotationSkewY(); -} - -void RotateBy::update(float time) -{ - // FIXME: shall I add % 360 - if (_target) - { - _target->setRotationSkewX(_startAngle.x + _deltaAngle.x * time); - _target->setRotationSkewY(_startAngle.y + _deltaAngle.y * time); - } -} - -RotateBy* RotateBy::reverse() const -{ - return RotateBy::create(_duration, -_deltaAngle.x, -_deltaAngle.y); -} - -// -// MoveBy -// -MoveBy* MoveBy::create(float duration, const Vec2& deltaPosition) -{ - MoveBy *ret = new (std::nothrow) MoveBy(); - - if (ret && ret->initWithDuration(duration, deltaPosition)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -bool MoveBy::initWithDuration(float duration, const Vec2& deltaPosition) -{ - bool ret = false; - - if (ActionInterval::initWithDuration(duration)) - { - _positionDelta = deltaPosition; - ret = true; - } - - return ret; -} - -MoveBy* MoveBy::clone() const -{ - // no copy constructor - return MoveBy::create(_duration, _positionDelta); -} - -void MoveBy::startWithTarget(Node *target) -{ - ActionInterval::startWithTarget(target); - _previousPosition = _startPosition = target->getPosition(); -} - -MoveBy* MoveBy::reverse() const -{ - return MoveBy::create(_duration, -_positionDelta); -} - - -void MoveBy::update(float dt) -{ - if (_target) - { -#if CC_ENABLE_STACKABLE_ACTIONS - auto currentPos = _target->getPosition(); - auto diff = currentPos - _previousPosition; - _startPosition = _startPosition + diff; - - _previousPosition.x = _startPosition.x + _positionDelta.x * dt; - _previousPosition.y = _startPosition.y + _positionDelta.y * dt; - - _target->setPosition(_previousPosition); -#else - _target->setPosition(_startPosition + _positionDelta * t); -#endif // CC_ENABLE_STACKABLE_ACTIONS - } -} - -// -// MoveTo -// -MoveTo* MoveTo::create(float duration, const Vec2& position) -{ - MoveTo *ret = new (std::nothrow) MoveTo(); - - if (ret && ret->initWithDuration(duration, position)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -bool MoveTo::initWithDuration(float duration, const Vec2& position) -{ - bool ret = false; - - if (ActionInterval::initWithDuration(duration)) - { - _endPosition = position; - ret = true; - } - - return ret; -} - -MoveTo* MoveTo::clone() const -{ - // no copy constructor - return MoveTo::create(_duration, _endPosition); -} - -void MoveTo::startWithTarget(Node *target) -{ - MoveBy::startWithTarget(target); - _positionDelta = _endPosition - target->getPosition(); -} - -MoveTo* MoveTo::reverse() const -{ - CCASSERT(false, "reverse() not supported in MoveTo"); - return nullptr; -} - - -// -// SkewTo -// -SkewTo* SkewTo::create(float t, float sx, float sy) -{ - SkewTo *skewTo = new (std::nothrow) SkewTo(); - if (skewTo && skewTo->initWithDuration(t, sx, sy)) - { - skewTo->autorelease(); - return skewTo; - } - - delete skewTo; - return nullptr; -} - -bool SkewTo::initWithDuration(float t, float sx, float sy) -{ - bool bRet = false; - - if (ActionInterval::initWithDuration(t)) - { - _endSkewX = sx; - _endSkewY = sy; - - bRet = true; - } - - return bRet; -} - -SkewTo* SkewTo::clone() const -{ - // no copy constructor - return SkewTo::create(_duration, _endSkewX, _endSkewY); -} - -SkewTo* SkewTo::reverse() const -{ - CCASSERT(false, "reverse() not supported in SkewTo"); - return nullptr; -} - -void SkewTo::startWithTarget(Node *target) -{ - ActionInterval::startWithTarget(target); - - _startSkewX = target->getSkewX(); - - if (_startSkewX > 0) - { - _startSkewX = fmodf(_startSkewX, 180.f); - } - else - { - _startSkewX = fmodf(_startSkewX, -180.f); - } - - _deltaX = _endSkewX - _startSkewX; - - if (_deltaX > 180) - { - _deltaX -= 360; - } - if (_deltaX < -180) - { - _deltaX += 360; - } - - _startSkewY = target->getSkewY(); - - if (_startSkewY > 0) - { - _startSkewY = fmodf(_startSkewY, 360.f); - } - else - { - _startSkewY = fmodf(_startSkewY, -360.f); - } - - _deltaY = _endSkewY - _startSkewY; - - if (_deltaY > 180) - { - _deltaY -= 360; - } - if (_deltaY < -180) - { - _deltaY += 360; - } -} - -void SkewTo::update(float t) -{ - _target->setSkewX(_startSkewX + _deltaX * t); - _target->setSkewY(_startSkewY + _deltaY * t); -} - -SkewTo::SkewTo() -: _skewX(0.0) -, _skewY(0.0) -, _startSkewX(0.0) -, _startSkewY(0.0) -, _endSkewX(0.0) -, _endSkewY(0.0) -, _deltaX(0.0) -, _deltaY(0.0) -{ -} - -// -// SkewBy -// -SkewBy* SkewBy::create(float t, float sx, float sy) -{ - SkewBy *skewBy = new (std::nothrow) SkewBy(); - if (skewBy && skewBy->initWithDuration(t, sx, sy)) - { - skewBy->autorelease(); - return skewBy; - } - - delete skewBy; - return nullptr; -} - -SkewBy * SkewBy::clone() const -{ - // no copy constructor - return SkewBy::create(_duration, _skewX, _skewY); -} - -bool SkewBy::initWithDuration(float t, float deltaSkewX, float deltaSkewY) -{ - bool ret = false; - - if (SkewTo::initWithDuration(t, deltaSkewX, deltaSkewY)) - { - _skewX = deltaSkewX; - _skewY = deltaSkewY; - - ret = true; - } - - return ret; -} - -void SkewBy::startWithTarget(Node *target) -{ - SkewTo::startWithTarget(target); - _deltaX = _skewX; - _deltaY = _skewY; - _endSkewX = _startSkewX + _deltaX; - _endSkewY = _startSkewY + _deltaY; -} - -SkewBy* SkewBy::reverse() const -{ - return SkewBy::create(_duration, -_skewX, -_skewY); -} - -// -// JumpBy -// - -JumpBy* JumpBy::create(float duration, const Vec2& position, float height, int jumps) -{ - JumpBy *jumpBy = new (std::nothrow) JumpBy(); - if (jumpBy && jumpBy->initWithDuration(duration, position, height, jumps)) - { - jumpBy->autorelease(); - return jumpBy; - } - - delete jumpBy; - return nullptr; -} - -bool JumpBy::initWithDuration(float duration, const Vec2& position, float height, int jumps) -{ - CCASSERT(jumps>=0, "Number of jumps must be >= 0"); - if (jumps < 0) - { - log("JumpBy::initWithDuration error: Number of jumps must be >= 0"); - return false; - } - - if (ActionInterval::initWithDuration(duration) && jumps>=0) - { - _delta = position; - _height = height; - _jumps = jumps; - - return true; - } - - return false; -} - -JumpBy* JumpBy::clone() const -{ - // no copy constructor - return JumpBy::create(_duration, _delta, _height, _jumps); -} - -void JumpBy::startWithTarget(Node *target) -{ - ActionInterval::startWithTarget(target); - _previousPos = _startPosition = target->getPosition(); -} - -void JumpBy::update(float t) -{ - // parabolic jump (since v0.8.2) - if (_target) - { - float frac = fmodf( t * _jumps, 1.0f ); - float y = _height * 4 * frac * (1 - frac); - y += _delta.y * t; - - float x = _delta.x * t; -#if CC_ENABLE_STACKABLE_ACTIONS - Vec2 currentPos = _target->getPosition(); - - Vec2 diff = currentPos - _previousPos; - _startPosition = diff + _startPosition; - - Vec2 newPos = _startPosition + Vec2(x,y); - _target->setPosition(newPos); - - _previousPos = newPos; -#else - _target->setPosition(_startPosition + Vec2(x,y)); -#endif // !CC_ENABLE_STACKABLE_ACTIONS - } -} - -JumpBy* JumpBy::reverse() const -{ - return JumpBy::create(_duration, Vec2(-_delta.x, -_delta.y), - _height, _jumps); -} - -// -// JumpTo -// - -JumpTo* JumpTo::create(float duration, const Vec2& position, float height, int jumps) -{ - JumpTo *jumpTo = new (std::nothrow) JumpTo(); - if (jumpTo && jumpTo->initWithDuration(duration, position, height, jumps)) - { - jumpTo->autorelease(); - return jumpTo; - } - - delete jumpTo; - return nullptr; -} - -bool JumpTo::initWithDuration(float duration, const Vec2& position, float height, int jumps) -{ - CCASSERT(jumps>=0, "Number of jumps must be >= 0"); - if (jumps < 0) - { - log("JumpTo::initWithDuration error:Number of jumps must be >= 0"); - return false; - } - - if (ActionInterval::initWithDuration(duration) && jumps>=0) - { - _endPosition = position; - _height = height; - _jumps = jumps; - - return true; - } - - return false; -} - -JumpTo* JumpTo::clone() const -{ - // no copy constructor - return JumpTo::create(_duration, _endPosition, _height, _jumps); -} - -JumpTo* JumpTo::reverse() const -{ - CCASSERT(false, "reverse() not supported in JumpTo"); - return nullptr; -} - -void JumpTo::startWithTarget(Node *target) -{ - JumpBy::startWithTarget(target); - _delta.set(_endPosition.x - _startPosition.x, _endPosition.y - _startPosition.y); -} - -// Bezier cubic formula: -// ((1 - t) + t)3 = 1 -// Expands to ... -// (1 - t)3 + 3t(1-t)2 + 3t2(1 - t) + t3 = 1 -static inline float bezierat( float a, float b, float c, float d, float t ) -{ - return (powf(1-t,3) * a + - 3*t*(powf(1-t,2))*b + - 3*powf(t,2)*(1-t)*c + - powf(t,3)*d ); -} - -// -// BezierBy -// - -BezierBy* BezierBy::create(float t, const ccBezierConfig& c) -{ - BezierBy *bezierBy = new (std::nothrow) BezierBy(); - if (bezierBy && bezierBy->initWithDuration(t, c)) - { - bezierBy->autorelease(); - return bezierBy; - } - - delete bezierBy; - return nullptr; -} - -bool BezierBy::initWithDuration(float t, const ccBezierConfig& c) -{ - if (ActionInterval::initWithDuration(t)) - { - _config = c; - return true; - } - - return false; -} - -void BezierBy::startWithTarget(Node *target) -{ - ActionInterval::startWithTarget(target); - _previousPosition = _startPosition = target->getPosition(); -} - -BezierBy* BezierBy::clone() const -{ - // no copy constructor - return BezierBy::create(_duration, _config); -} - -void BezierBy::update(float time) -{ - if (_target) - { - float xa = 0; - float xb = _config.controlPoint_1.x; - float xc = _config.controlPoint_2.x; - float xd = _config.endPosition.x; - - float ya = 0; - float yb = _config.controlPoint_1.y; - float yc = _config.controlPoint_2.y; - float yd = _config.endPosition.y; - - float x = bezierat(xa, xb, xc, xd, time); - float y = bezierat(ya, yb, yc, yd, time); - -#if CC_ENABLE_STACKABLE_ACTIONS - Vec2 currentPos = _target->getPosition(); - Vec2 diff = currentPos - _previousPosition; - _startPosition = _startPosition + diff; - - Vec2 newPos = _startPosition + Vec2(x,y); - _target->setPosition(newPos); - - _previousPosition = newPos; -#else - _target->setPosition( _startPosition + Vec2(x,y)); -#endif // !CC_ENABLE_STACKABLE_ACTIONS - } -} - -BezierBy* BezierBy::reverse() const -{ - ccBezierConfig r; - - r.endPosition = -_config.endPosition; - r.controlPoint_1 = _config.controlPoint_2 + (-_config.endPosition); - r.controlPoint_2 = _config.controlPoint_1 + (-_config.endPosition); - - BezierBy *action = BezierBy::create(_duration, r); - return action; -} - -// -// BezierTo -// - -BezierTo* BezierTo::create(float t, const ccBezierConfig& c) -{ - BezierTo *bezierTo = new (std::nothrow) BezierTo(); - if (bezierTo && bezierTo->initWithDuration(t, c)) - { - bezierTo->autorelease(); - return bezierTo; - } - - delete bezierTo; - return nullptr; -} - -bool BezierTo::initWithDuration(float t, const ccBezierConfig &c) -{ - if (ActionInterval::initWithDuration(t)) - { - _toConfig = c; - return true; - } - - return false; -} - -BezierTo* BezierTo::clone() const -{ - // no copy constructor - return BezierTo::create(_duration, _toConfig); -} - -void BezierTo::startWithTarget(Node *target) -{ - BezierBy::startWithTarget(target); - _config.controlPoint_1 = _toConfig.controlPoint_1 - _startPosition; - _config.controlPoint_2 = _toConfig.controlPoint_2 - _startPosition; - _config.endPosition = _toConfig.endPosition - _startPosition; -} - -BezierTo* BezierTo::reverse() const -{ - CCASSERT(false, "CCBezierTo doesn't support the 'reverse' method"); - return nullptr; -} - - -// -// ScaleTo -// -ScaleTo* ScaleTo::create(float duration, float s) -{ - ScaleTo *scaleTo = new (std::nothrow) ScaleTo(); - if (scaleTo && scaleTo->initWithDuration(duration, s)) - { - scaleTo->autorelease(); - return scaleTo; - } - - delete scaleTo; - return nullptr; -} - -ScaleTo* ScaleTo::create(float duration, float sx, float sy) -{ - ScaleTo *scaleTo = new (std::nothrow) ScaleTo(); - if (scaleTo && scaleTo->initWithDuration(duration, sx, sy)) - { - scaleTo->autorelease(); - return scaleTo; - } - - delete scaleTo; - return nullptr; -} - -ScaleTo* ScaleTo::create(float duration, float sx, float sy, float sz) -{ - ScaleTo *scaleTo = new (std::nothrow) ScaleTo(); - if (scaleTo && scaleTo->initWithDuration(duration, sx, sy, sz)) - { - scaleTo->autorelease(); - return scaleTo; - } - - delete scaleTo; - return nullptr; -} - -bool ScaleTo::initWithDuration(float duration, float s) -{ - if (ActionInterval::initWithDuration(duration)) - { - _endScaleX = s; - _endScaleY = s; - _endScaleZ = s; - - return true; - } - - return false; -} - -bool ScaleTo::initWithDuration(float duration, float sx, float sy) -{ - if (ActionInterval::initWithDuration(duration)) - { - _endScaleX = sx; - _endScaleY = sy; - _endScaleZ = 1.f; - - return true; - } - - return false; -} - -bool ScaleTo::initWithDuration(float duration, float sx, float sy, float sz) -{ - if (ActionInterval::initWithDuration(duration)) - { - _endScaleX = sx; - _endScaleY = sy; - _endScaleZ = sz; - - return true; - } - - return false; -} - -ScaleTo* ScaleTo::clone() const -{ - // no copy constructor - return ScaleTo::create(_duration, _endScaleX, _endScaleY, _endScaleZ); -} - -ScaleTo* ScaleTo::reverse() const -{ - CCASSERT(false, "reverse() not supported in ScaleTo"); - return nullptr; -} - -void ScaleTo::startWithTarget(Node *target) -{ - ActionInterval::startWithTarget(target); - _startScaleX = target->getScaleX(); - _startScaleY = target->getScaleY(); - _startScaleZ = target->getScaleZ(); - _deltaX = _endScaleX - _startScaleX; - _deltaY = _endScaleY - _startScaleY; - _deltaZ = _endScaleZ - _startScaleZ; -} - -void ScaleTo::update(float time) -{ - if (_target) - { - _target->setScaleX(_startScaleX + _deltaX * time); - _target->setScaleY(_startScaleY + _deltaY * time); - _target->setScaleZ(_startScaleZ + _deltaZ * time); - } -} - -// -// ScaleBy -// - -ScaleBy* ScaleBy::create(float duration, float s) -{ - ScaleBy *scaleBy = new (std::nothrow) ScaleBy(); - if (scaleBy && scaleBy->initWithDuration(duration, s)) - { - scaleBy->autorelease(); - return scaleBy; - } - - delete scaleBy; - return nullptr; -} - -ScaleBy* ScaleBy::create(float duration, float sx, float sy) -{ - ScaleBy *scaleBy = new (std::nothrow) ScaleBy(); - if (scaleBy && scaleBy->initWithDuration(duration, sx, sy, 1.f)) - { - scaleBy->autorelease(); - return scaleBy; - } - - delete scaleBy; - return nullptr; -} - -ScaleBy* ScaleBy::create(float duration, float sx, float sy, float sz) -{ - ScaleBy *scaleBy = new (std::nothrow) ScaleBy(); - if (scaleBy && scaleBy->initWithDuration(duration, sx, sy, sz)) - { - scaleBy->autorelease(); - return scaleBy; - } - - delete scaleBy; - return nullptr; -} - -ScaleBy* ScaleBy::clone() const -{ - // no copy constructor - return ScaleBy::create(_duration, _endScaleX, _endScaleY, _endScaleZ); -} - -void ScaleBy::startWithTarget(Node *target) -{ - ScaleTo::startWithTarget(target); - _deltaX = _startScaleX * _endScaleX - _startScaleX; - _deltaY = _startScaleY * _endScaleY - _startScaleY; - _deltaZ = _startScaleZ * _endScaleZ - _startScaleZ; -} - -ScaleBy* ScaleBy::reverse() const -{ - return ScaleBy::create(_duration, 1 / _endScaleX, 1 / _endScaleY, 1/ _endScaleZ); -} - -// -// Blink -// - -Blink* Blink::create(float duration, int blinks) -{ - Blink *blink = new (std::nothrow) Blink(); - if (blink && blink->initWithDuration(duration, blinks)) - { - blink->autorelease(); - return blink; - } - - delete blink; - return nullptr; -} - -bool Blink::initWithDuration(float duration, int blinks) -{ - CCASSERT(blinks>=0, "blinks should be >= 0"); - if (blinks < 0) - { - log("Blink::initWithDuration error:blinks should be >= 0"); - return false; - } - - if (ActionInterval::initWithDuration(duration) && blinks>=0) - { - _times = blinks; - return true; - } - - return false; -} - -void Blink::stop() -{ - if (nullptr != _target) - _target->setVisible(_originalState); - ActionInterval::stop(); -} - -void Blink::startWithTarget(Node *target) -{ - ActionInterval::startWithTarget(target); - _originalState = target->isVisible(); -} - -Blink* Blink::clone(void) const -{ - // no copy constructor - return Blink::create(_duration, _times); -} - -void Blink::update(float time) -{ - if (_target && ! isDone()) - { - float slice = 1.0f / _times; - float m = fmodf(time, slice); - _target->setVisible(m > slice / 2 ? true : false); - } -} - -Blink* Blink::reverse() const -{ - return Blink::create(_duration, _times); -} - -// -// FadeIn -// - -FadeIn* FadeIn::create(float d) -{ - FadeIn* action = new (std::nothrow) FadeIn(); - if (action && action->initWithDuration(d,255.0f)) - { - action->autorelease(); - return action; - } - - delete action; - return nullptr; -} - -FadeIn* FadeIn::clone() const -{ - // no copy constructor - return FadeIn::create(_duration); -} - -void FadeIn::setReverseAction(cocos2d::FadeTo *ac) -{ - _reverseAction = ac; -} - - -FadeTo* FadeIn::reverse() const -{ - auto action = FadeOut::create(_duration); - action->setReverseAction(const_cast(this)); - return action; - -} - -void FadeIn::startWithTarget(cocos2d::Node *target) -{ - ActionInterval::startWithTarget(target); - - if (nullptr != _reverseAction) - this->_toOpacity = this->_reverseAction->_fromOpacity; - else - _toOpacity = 255.0f; - - if (target) - _fromOpacity = target->getOpacity(); -} - -// -// FadeOut -// - -FadeOut* FadeOut::create(float d) -{ - FadeOut* action = new (std::nothrow) FadeOut(); - if (action && action->initWithDuration(d,0.0f)) - { - action->autorelease(); - return action; - } - - delete action; - return nullptr; -} - -FadeOut* FadeOut::clone() const -{ - // no copy constructor - return FadeOut::create(_duration); -} - -void FadeOut::startWithTarget(cocos2d::Node *target) -{ - ActionInterval::startWithTarget(target); - - if (nullptr != _reverseAction) - _toOpacity = _reverseAction->_fromOpacity; - else - _toOpacity = 0.0f; - - if (target) - _fromOpacity = target->getOpacity(); -} - -void FadeOut::setReverseAction(cocos2d::FadeTo *ac) -{ - _reverseAction = ac; -} - - -FadeTo* FadeOut::reverse() const -{ - auto action = FadeIn::create(_duration); - action->setReverseAction(const_cast(this)); - return action; -} - -// -// FadeTo -// - -FadeTo* FadeTo::create(float duration, GLubyte opacity) -{ - FadeTo *fadeTo = new (std::nothrow) FadeTo(); - if (fadeTo && fadeTo->initWithDuration(duration, opacity)) - { - fadeTo->autorelease(); - return fadeTo; - } - - delete fadeTo; - return nullptr; -} - -bool FadeTo::initWithDuration(float duration, GLubyte opacity) -{ - if (ActionInterval::initWithDuration(duration)) - { - _toOpacity = opacity; - return true; - } - - return false; -} - -FadeTo* FadeTo::clone() const -{ - // no copy constructor - return FadeTo::create(_duration, _toOpacity); -} - -FadeTo* FadeTo::reverse() const -{ - CCASSERT(false, "reverse() not supported in FadeTo"); - return nullptr; -} - -void FadeTo::startWithTarget(Node *target) -{ - ActionInterval::startWithTarget(target); - - if (target) - { - _fromOpacity = target->getOpacity(); - } -} - -void FadeTo::update(float time) -{ - if (_target) - { - _target->setOpacity((GLubyte)(_fromOpacity + (_toOpacity - _fromOpacity) * time)); - } -} - -// -// TintTo -// -TintTo* TintTo::create(float duration, GLubyte red, GLubyte green, GLubyte blue) -{ - TintTo *tintTo = new (std::nothrow) TintTo(); - if (tintTo && tintTo->initWithDuration(duration, red, green, blue)) - { - tintTo->autorelease(); - return tintTo; - } - - delete tintTo; - return nullptr; -} - -TintTo* TintTo::create(float duration, const Color3B& color) -{ - return create(duration, color.r, color.g, color.b); -} - -bool TintTo::initWithDuration(float duration, GLubyte red, GLubyte green, GLubyte blue) -{ - if (ActionInterval::initWithDuration(duration)) - { - _to = Color3B(red, green, blue); - return true; - } - - return false; -} - -TintTo* TintTo::clone() const -{ - // no copy constructor - return TintTo::create(_duration, _to.r, _to.g, _to.b); -} - -TintTo* TintTo::reverse() const -{ - CCASSERT(false, "reverse() not supported in TintTo"); - return nullptr; -} - -void TintTo::startWithTarget(Node *target) -{ - ActionInterval::startWithTarget(target); - if (_target) - { - _from = _target->getColor(); - } -} - -void TintTo::update(float time) -{ - if (_target) - { - _target->setColor(Color3B(GLubyte(_from.r + (_to.r - _from.r) * time), - (GLubyte)(_from.g + (_to.g - _from.g) * time), - (GLubyte)(_from.b + (_to.b - _from.b) * time))); - } -} - -// -// TintBy -// - -TintBy* TintBy::create(float duration, GLshort deltaRed, GLshort deltaGreen, GLshort deltaBlue) -{ - TintBy *tintBy = new (std::nothrow) TintBy(); - if (tintBy && tintBy->initWithDuration(duration, deltaRed, deltaGreen, deltaBlue)) - { - tintBy->autorelease(); - return tintBy; - } - - delete tintBy; - return nullptr; -} - -bool TintBy::initWithDuration(float duration, GLshort deltaRed, GLshort deltaGreen, GLshort deltaBlue) -{ - if (ActionInterval::initWithDuration(duration)) - { - _deltaR = deltaRed; - _deltaG = deltaGreen; - _deltaB = deltaBlue; - - return true; - } - - return false; -} - -TintBy* TintBy::clone() const -{ - // no copy constructor - return TintBy::create(_duration, _deltaR, _deltaG, _deltaB); -} - -void TintBy::startWithTarget(Node *target) -{ - ActionInterval::startWithTarget(target); - - if (target) - { - Color3B color = target->getColor(); - _fromR = color.r; - _fromG = color.g; - _fromB = color.b; - } -} - -void TintBy::update(float time) -{ - if (_target) - { - _target->setColor(Color3B((GLubyte)(_fromR + _deltaR * time), - (GLubyte)(_fromG + _deltaG * time), - (GLubyte)(_fromB + _deltaB * time))); - } -} - -TintBy* TintBy::reverse() const -{ - return TintBy::create(_duration, -_deltaR, -_deltaG, -_deltaB); -} - -// -// DelayTime -// -DelayTime* DelayTime::create(float d) -{ - DelayTime* action = new (std::nothrow) DelayTime(); - if (action && action->initWithDuration(d)) - { - action->autorelease(); - return action; - } - - delete action; - return nullptr; -} - -DelayTime* DelayTime::clone() const -{ - // no copy constructor - return DelayTime::create(_duration); -} - -void DelayTime::update(float time) -{ - CC_UNUSED_PARAM(time); - return; -} - -DelayTime* DelayTime::reverse() const -{ - return DelayTime::create(_duration); -} - -// -// ReverseTime -// - -ReverseTime* ReverseTime::create(FiniteTimeAction *action) -{ - // casting to prevent warnings - ReverseTime *reverseTime = new (std::nothrow) ReverseTime(); - if (reverseTime && reverseTime->initWithAction( action->clone() )) - { - reverseTime->autorelease(); - return reverseTime; - } - - delete reverseTime; - return nullptr; -} - -bool ReverseTime::initWithAction(FiniteTimeAction *action) -{ - CCASSERT(action != nullptr, "action can't be nullptr!"); - CCASSERT(action != _other, "action doesn't equal to _other!"); - if (action == nullptr || action == _other) - { - log("ReverseTime::initWithAction error: action is null or action equal to _other"); - return false; - } - - if (ActionInterval::initWithDuration(action->getDuration())) - { - // Don't leak if action is reused - CC_SAFE_RELEASE(_other); - - _other = action; - action->retain(); -#if CC_ENABLE_GC_FOR_NATIVE_OBJECTS - auto sEngine = ScriptEngineManager::getInstance()->getScriptEngine(); - if (sEngine) - { - sEngine->retainScriptObject(this, action); - } -#endif // CC_ENABLE_GC_FOR_NATIVE_OBJECTS - - return true; - } - - return false; -} - -ReverseTime* ReverseTime::clone() const -{ - // no copy constructor - return ReverseTime::create(_other->clone()); -} - -ReverseTime::ReverseTime() : _other(nullptr) -{ - -} - -ReverseTime::~ReverseTime() -{ - CC_SAFE_RELEASE(_other); -} - -void ReverseTime::startWithTarget(Node *target) -{ - ActionInterval::startWithTarget(target); - _other->startWithTarget(target); -} - -void ReverseTime::stop(void) -{ - _other->stop(); - ActionInterval::stop(); -} - -void ReverseTime::update(float time) -{ - if (_other) - { - _other->update(1 - time); - sendUpdateEventToScript(1 - time, _other); - } -} - -ReverseTime* ReverseTime::reverse() const -{ - // FIXME: This looks like a bug - return (ReverseTime*)_other->clone(); -} - -// -// Animate -// -Animate* Animate::create(Animation *animation) -{ - Animate *animate = new (std::nothrow) Animate(); - if (animate && animate->initWithAnimation(animation)) - { - animate->autorelease(); - return animate; - } - - delete animate; - return nullptr; -} - -Animate::Animate() -: _splitTimes(new std::vector) -, _nextFrame(0) -, _origFrame(nullptr) -, _executedLoops(0) -, _animation(nullptr) -, _frameDisplayedEvent(nullptr) -, _currFrameIndex(0) -{ - -} - -Animate::~Animate() -{ - CC_SAFE_RELEASE(_animation); - CC_SAFE_RELEASE(_origFrame); - CC_SAFE_DELETE(_splitTimes); - CC_SAFE_RELEASE(_frameDisplayedEvent); -} - -bool Animate::initWithAnimation(Animation* animation) -{ - CCASSERT( animation!=nullptr, "Animate: argument Animation must be non-nullptr"); - if (animation == nullptr) - { - log("Animate::initWithAnimation: argument Animation must be non-nullptr"); - return false; - } - - float singleDuration = animation->getDuration(); - - if ( ActionInterval::initWithDuration(singleDuration * animation->getLoops() ) ) - { - _nextFrame = 0; - setAnimation(animation); - _origFrame = nullptr; - _executedLoops = 0; - - _splitTimes->reserve(animation->getFrames().size()); - - float accumUnitsOfTime = 0; - float newUnitOfTimeValue = singleDuration / animation->getTotalDelayUnits(); - - auto& frames = animation->getFrames(); - - for (auto& frame : frames) - { - float value = (accumUnitsOfTime * newUnitOfTimeValue) / singleDuration; - accumUnitsOfTime += frame->getDelayUnits(); - _splitTimes->push_back(value); - } - return true; - } - return false; -} - -void Animate::setAnimation(cocos2d::Animation *animation) -{ - if (_animation != animation) - { - CC_SAFE_RETAIN(animation); - CC_SAFE_RELEASE(_animation); - _animation = animation; - } -} - -Animate* Animate::clone() const -{ - // no copy constructor - return Animate::create(_animation->clone()); -} - -void Animate::startWithTarget(Node *target) -{ - ActionInterval::startWithTarget(target); - Sprite *sprite = static_cast(target); - - CC_SAFE_RELEASE(_origFrame); - - if (_animation->getRestoreOriginalFrame()) - { - _origFrame = sprite->getSpriteFrame(); - _origFrame->retain(); - } - _nextFrame = 0; - _executedLoops = 0; -} - -void Animate::stop() -{ - if (_animation->getRestoreOriginalFrame() && _target) - { - auto blend = static_cast(_target)->getBlendFunc(); - static_cast(_target)->setSpriteFrame(_origFrame); - static_cast(_target)->setBlendFunc(blend); - } - - ActionInterval::stop(); -} - -void Animate::update(float t) -{ - // if t==1, ignore. Animation should finish with t==1 - if( t < 1.0f ) - { - t *= _animation->getLoops(); - - // new loop? If so, reset frame counter - unsigned int loopNumber = (unsigned int)t; - if( loopNumber > _executedLoops ) - { - _nextFrame = 0; - _executedLoops++; - } - - // new t for animations - t = fmodf(t, 1.0f); - } - - auto& frames = _animation->getFrames(); - auto numberOfFrames = frames.size(); - SpriteFrame *frameToDisplay = nullptr; - - for( int i=_nextFrame; i < numberOfFrames; i++ ) - { - float splitTime = _splitTimes->at(i); - - if( splitTime <= t ) - { - auto blend = static_cast(_target)->getBlendFunc(); - _currFrameIndex = i; - AnimationFrame* frame = frames.at(_currFrameIndex); - frameToDisplay = frame->getSpriteFrame(); - static_cast(_target)->setSpriteFrame(frameToDisplay); - static_cast(_target)->setBlendFunc(blend); - - const ValueMap& dict = frame->getUserInfo(); - if ( !dict.empty() ) - { - if (_frameDisplayedEvent == nullptr) - _frameDisplayedEvent = new (std::nothrow) EventCustom(AnimationFrameDisplayedNotification); - - _frameDisplayedEventInfo.target = _target; - _frameDisplayedEventInfo.userInfo = &dict; - _frameDisplayedEvent->setUserData(&_frameDisplayedEventInfo); - Director::getInstance()->getEventDispatcher()->dispatchEvent(_frameDisplayedEvent); - } - _nextFrame = i+1; - } - // Issue 1438. Could be more than one frame per tick, due to low frame rate or frame delta < 1/FPS - else { - break; - } - } -} - -Animate* Animate::reverse() const -{ - auto& oldArray = _animation->getFrames(); - Vector newArray(oldArray.size()); - - if (!oldArray.empty()) - { - for (auto iter = oldArray.crbegin(); iter != oldArray.crend(); ++iter) - { - AnimationFrame* animFrame = *iter; - if (!animFrame) - { - break; - } - - newArray.pushBack(animFrame->clone()); - } - } - - Animation *newAnim = Animation::create(newArray, _animation->getDelayPerUnit(), _animation->getLoops()); - newAnim->setRestoreOriginalFrame(_animation->getRestoreOriginalFrame()); - return Animate::create(newAnim); -} - -// TargetedAction - -TargetedAction::TargetedAction() -: _action(nullptr) -, _forcedTarget(nullptr) -{ - -} - -TargetedAction::~TargetedAction() -{ - CC_SAFE_RELEASE(_forcedTarget); - CC_SAFE_RELEASE(_action); -} - -TargetedAction* TargetedAction::create(Node* target, FiniteTimeAction* action) -{ - TargetedAction* p = new (std::nothrow) TargetedAction(); - if (p && p->initWithTarget(target, action)) - { - p->autorelease(); - return p; - } - - delete p; - return nullptr; -} - - -bool TargetedAction::initWithTarget(Node* target, FiniteTimeAction* action) -{ - if(ActionInterval::initWithDuration(action->getDuration())) - { - CC_SAFE_RETAIN(target); - _forcedTarget = target; - CC_SAFE_RETAIN(action); - _action = action; -#if CC_ENABLE_GC_FOR_NATIVE_OBJECTS - auto sEngine = ScriptEngineManager::getInstance()->getScriptEngine(); - if (sEngine) - { - sEngine->retainScriptObject(this, _action); - } -#endif // CC_ENABLE_GC_FOR_NATIVE_OBJECTS - return true; - } - return false; -} - -TargetedAction* TargetedAction::clone() const -{ - // no copy constructor - // win32 : use the _other's copy object. - return TargetedAction::create(_forcedTarget, _action->clone()); -} - -TargetedAction* TargetedAction::reverse() const -{ - // just reverse the internal action - auto a = new (std::nothrow) TargetedAction(); - a->initWithTarget(_forcedTarget, _action->reverse()); - a->autorelease(); - return a; -} - -void TargetedAction::startWithTarget(Node *target) -{ - ActionInterval::startWithTarget(target); - _action->startWithTarget(_forcedTarget); -} - -void TargetedAction::stop() -{ - _action->stop(); -} - -void TargetedAction::update(float time) -{ - _action->update(time); - sendUpdateEventToScript(time, _action); -} - -void TargetedAction::setForcedTarget(Node* forcedTarget) -{ - if( _forcedTarget != forcedTarget ) - { - CC_SAFE_RETAIN(forcedTarget); - CC_SAFE_RELEASE(_forcedTarget); - _forcedTarget = forcedTarget; - } -} - -// ActionFloat - -ActionFloat* ActionFloat::create(float duration, float from, float to, ActionFloatCallback callback) -{ - auto ref = new (std::nothrow) ActionFloat(); - if (ref && ref->initWithDuration(duration, from, to, callback)) - { - ref->autorelease(); - return ref; - } - - delete ref; - return nullptr; -} - -bool ActionFloat::initWithDuration(float duration, float from, float to, ActionFloatCallback callback) -{ - if (ActionInterval::initWithDuration(duration)) - { - _from = from; - _to = to; - _callback = callback; - return true; - } - return false; -} - -ActionFloat* ActionFloat::clone() const -{ - return ActionFloat::create(_duration, _from, _to, _callback); -} - -void ActionFloat::startWithTarget(Node *target) -{ - ActionInterval::startWithTarget(target); - _delta = _to - _from; -} - -void ActionFloat::update(float delta) -{ - float value = _to - _delta * (1 - delta); - - if (_callback) - { - // report back value to caller - _callback(value); - } -} - -ActionFloat* ActionFloat::reverse() const -{ - return ActionFloat::create(_duration, _to, _from, _callback); -} - -NS_CC_END diff --git a/native/cocos/2d/CCActionInterval.h b/native/cocos/2d/CCActionInterval.h deleted file mode 100644 index 0c33b56038..0000000000 --- a/native/cocos/2d/CCActionInterval.h +++ /dev/null @@ -1,1593 +0,0 @@ -/**************************************************************************** -Copyright (c) 2008-2010 Ricardo Quesada -Copyright (c) 2011 Zynga Inc. -Copyright (c) 2010-2012 cocos2d-x.org -Copyright (c) 2013-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ - -#ifndef __ACTION_CCINTERVAL_ACTION_H__ -#define __ACTION_CCINTERVAL_ACTION_H__ - -#include - -#include "2d/CCAction.h" -#include "2d/CCAnimation.h" -#include "base/CCProtocols.h" -#include "base/CCVector.h" - -NS_CC_BEGIN - -class Node; -class SpriteFrame; -class EventCustom; - -/** - * @addtogroup actions - * @{ - */ - -/** @class ActionInterval -@brief An interval action is an action that takes place within a certain period of time. -It has an start time, and a finish time. The finish time is the parameter -duration plus the start time. - -These ActionInterval actions have some interesting properties, like: -- They can run normally (default) -- They can run reversed with the reverse method -- They can run with the time altered with the Accelerate, AccelDeccel and Speed actions. - -For example, you can simulate a Ping Pong effect running the action normally and -then running it again in Reverse mode. - -Example: - -@code -auto action = MoveBy::create(1.0f, Vec2::ONE); -auto pingPongAction = Sequence::create(action, action->reverse(), nullptr); -@endcode -*/ -class CC_DLL ActionInterval : public FiniteTimeAction -{ -public: - /** How many seconds had elapsed since the actions started to run. - * - * @return The seconds had elapsed since the actions started to run. - */ - inline float getElapsed(void) { return _elapsed; } - - /** Sets the amplitude rate, extension in GridAction - * - * @param amp The amplitude rate. - */ - void setAmplitudeRate(float amp); - - /** Gets the amplitude rate, extension in GridAction - * - * @return The amplitude rate. - */ - float getAmplitudeRate(void); - - // - // Overrides - // - virtual bool isDone(void) const override; - /** - * @param dt in seconds - */ - virtual void step(float dt) override; - virtual void startWithTarget(Node *target) override; - virtual ActionInterval* reverse() const override - { - CC_ASSERT(0); - return nullptr; - } - - virtual ActionInterval *clone() const override - { - CC_ASSERT(0); - return nullptr; - } - -CC_CONSTRUCTOR_ACCESS: - /** initializes the action */ - bool initWithDuration(float d); - -protected: - float _elapsed; - bool _firstTick; - -protected: - bool sendUpdateEventToScript(float dt, Action *actionObject); -}; - -/** @class Sequence - * @brief Runs actions sequentially, one after another. - */ -class CC_DLL Sequence : public ActionInterval -{ -public: - /** Helper constructor to create an array of sequenceable actions. - * - * @return An autoreleased Sequence object. - */ -#if (CC_TARGET_PLATFORM == CC_PLATFORM_WINRT) - // VS2013 does not support nullptr in variable args lists and variadic templates are also not supported - typedef FiniteTimeAction* M; - static Sequence* create(M m1, std::nullptr_t listEnd) { return variadicCreate(m1, NULL); } - static Sequence* create(M m1, M m2, std::nullptr_t listEnd) { return variadicCreate(m1, m2, NULL); } - static Sequence* create(M m1, M m2, M m3, std::nullptr_t listEnd) { return variadicCreate(m1, m2, m3, NULL); } - static Sequence* create(M m1, M m2, M m3, M m4, std::nullptr_t listEnd) { return variadicCreate(m1, m2, m3, m4, NULL); } - static Sequence* create(M m1, M m2, M m3, M m4, M m5, std::nullptr_t listEnd) { return variadicCreate(m1, m2, m3, m4, m5, NULL); } - static Sequence* create(M m1, M m2, M m3, M m4, M m5, M m6, std::nullptr_t listEnd) { return variadicCreate(m1, m2, m3, m4, m5, m6, NULL); } - static Sequence* create(M m1, M m2, M m3, M m4, M m5, M m6, M m7, std::nullptr_t listEnd) { return variadicCreate(m1, m2, m3, m4, m5, m6, m7, NULL); } - static Sequence* create(M m1, M m2, M m3, M m4, M m5, M m6, M m7, M m8, std::nullptr_t listEnd) { return variadicCreate(m1, m2, m3, m4, m5, m6, m7, m8, NULL); } - static Sequence* create(M m1, M m2, M m3, M m4, M m5, M m6, M m7, M m8, M m9, std::nullptr_t listEnd) { return variadicCreate(m1, m2, m3, m4, m5, m6, m7, m8, m9, NULL); } - static Sequence* create(M m1, M m2, M m3, M m4, M m5, M m6, M m7, M m8, M m9, M m10, std::nullptr_t listEnd) { return variadicCreate(m1, m2, m3, m4, m5, m6, m7, m8, m9, m10, NULL); } - - // On WP8 for variable argument lists longer than 10 items, use the other create functions or variadicCreate with NULL as the last argument - static Sequence* variadicCreate(FiniteTimeAction* item, ...); -#else - static Sequence* create(FiniteTimeAction *action1, ...) CC_REQUIRES_NULL_TERMINATION; -#endif - - /** Helper constructor to create an array of sequenceable actions given an array. - * @code - * When this function bound to the js or lua,the input params changed - * in js :var create(var object1,var object2, ...) - * in lua :local create(local object1,local object2, ...) - * @endcode - * - * @param arrayOfActions An array of sequenceable actions. - * @return An autoreleased Sequence object. - */ - static Sequence* create(const Vector& arrayOfActions); - /** Helper constructor to create an array of sequence-able actions. - * - * @param action1 The first sequenceable action. - * @param args The va_list variable. - * @return An autoreleased Sequence object. - * @js NA - */ - static Sequence* createWithVariableList(FiniteTimeAction *action1, va_list args); - /** Creates the action. - * @param actionOne The first sequenceable action. - * @param actionTwo The second sequenceable action. - * @return An autoreleased Sequence object. - * @js NA - */ - static Sequence* createWithTwoActions(FiniteTimeAction *actionOne, FiniteTimeAction *actionTwo); - - // - // Overrides - // - virtual Sequence* clone() const override; - virtual Sequence* reverse() const override; - virtual void startWithTarget(Node *target) override; - virtual void stop(void) override; - /** - * @param t In seconds. - */ - virtual void update(float t) override; - -CC_CONSTRUCTOR_ACCESS: - Sequence(); - virtual ~Sequence(); - - /** initializes the action */ - bool initWithTwoActions(FiniteTimeAction *pActionOne, FiniteTimeAction *pActionTwo); - bool init(const Vector& arrayOfActions); - -protected: - FiniteTimeAction *_actions[2]; - float _split; - int _last; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(Sequence); -}; - -/** @class Repeat - * @brief Repeats an action a number of times. - * To repeat an action forever use the RepeatForever action. - */ -class CC_DLL Repeat : public ActionInterval -{ -public: - /** Creates a Repeat action. Times is an unsigned integer between 1 and pow(2,30). - * - * @param action The action needs to repeat. - * @param times The repeat times. - * @return An autoreleased Repeat object. - */ - static Repeat* create(FiniteTimeAction *action, unsigned int times); - - /** Sets the inner action. - * - * @param action The inner action. - */ - inline void setInnerAction(FiniteTimeAction *action) - { - if (_innerAction != action) - { - CC_SAFE_RETAIN(action); - CC_SAFE_RELEASE(_innerAction); - _innerAction = action; - } - } - - /** Gets the inner action. - * - * @return The inner action. - */ - inline FiniteTimeAction* getInnerAction() - { - return _innerAction; - } - - // - // Overrides - // - virtual Repeat* clone() const override; - virtual Repeat* reverse() const override; - virtual void startWithTarget(Node *target) override; - virtual void stop(void) override; - /** - * @param dt In seconds. - */ - virtual void update(float dt) override; - virtual bool isDone(void) const override; - -CC_CONSTRUCTOR_ACCESS: - Repeat() {} - virtual ~Repeat(); - - /** initializes a Repeat action. Times is an unsigned integer between 1 and pow(2,30) */ - bool initWithAction(FiniteTimeAction *pAction, unsigned int times); - -protected: - unsigned int _times; - unsigned int _total; - float _nextDt; - bool _actionInstant; - /** Inner action */ - FiniteTimeAction *_innerAction; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(Repeat); -}; - -/** @class RepeatForever - * @brief Repeats an action for ever. - To repeat the an action for a limited number of times use the Repeat action. - * @warning This action can't be Sequenceable because it is not an IntervalAction. - */ -class CC_DLL RepeatForever : public ActionInterval -{ -public: - /** Creates the action. - * - * @param action The action need to repeat forever. - * @return An autoreleased RepeatForever object. - */ - static RepeatForever* create(ActionInterval *action); - - /** Sets the inner action. - * - * @param action The inner action. - */ - inline void setInnerAction(ActionInterval *action) - { - if (_innerAction != action) - { - CC_SAFE_RELEASE(_innerAction); - _innerAction = action; - CC_SAFE_RETAIN(_innerAction); - } - } - - /** Gets the inner action. - * - * @return The inner action. - */ - inline ActionInterval* getInnerAction() - { - return _innerAction; - } - - // - // Overrides - // - virtual RepeatForever* clone() const override; - virtual RepeatForever* reverse(void) const override; - virtual void startWithTarget(Node* target) override; - /** - * @param dt In seconds. - */ - virtual void step(float dt) override; - virtual bool isDone(void) const override; - -CC_CONSTRUCTOR_ACCESS: - RepeatForever() - : _innerAction(nullptr) - {} - virtual ~RepeatForever(); - - /** initializes the action */ - bool initWithAction(ActionInterval *action); - -protected: - /** Inner action */ - ActionInterval *_innerAction; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(RepeatForever); -}; - -/** @class Spawn - * @brief Spawn a new action immediately - */ -class CC_DLL Spawn : public ActionInterval -{ -public: - /** Helper constructor to create an array of spawned actions. - * @code - * When this function bound to the js or lua, the input params changed. - * in js :var create(var object1,var object2, ...) - * in lua :local create(local object1,local object2, ...) - * @endcode - * - * @return An autoreleased Spawn object. - */ -#if (CC_TARGET_PLATFORM == CC_PLATFORM_WINRT) - // VS2013 does not support nullptr in variable args lists and variadic templates are also not supported. - typedef FiniteTimeAction* M; - static Spawn* create(M m1, std::nullptr_t listEnd) { return variadicCreate(m1, NULL); } - static Spawn* create(M m1, M m2, std::nullptr_t listEnd) { return variadicCreate(m1, m2, NULL); } - static Spawn* create(M m1, M m2, M m3, std::nullptr_t listEnd) { return variadicCreate(m1, m2, m3, NULL); } - static Spawn* create(M m1, M m2, M m3, M m4, std::nullptr_t listEnd) { return variadicCreate(m1, m2, m3, m4, NULL); } - static Spawn* create(M m1, M m2, M m3, M m4, M m5, std::nullptr_t listEnd) { return variadicCreate(m1, m2, m3, m4, m5, NULL); } - static Spawn* create(M m1, M m2, M m3, M m4, M m5, M m6, std::nullptr_t listEnd) { return variadicCreate(m1, m2, m3, m4, m5, m6, NULL); } - static Spawn* create(M m1, M m2, M m3, M m4, M m5, M m6, M m7, std::nullptr_t listEnd) { return variadicCreate(m1, m2, m3, m4, m5, m6, m7, NULL); } - static Spawn* create(M m1, M m2, M m3, M m4, M m5, M m6, M m7, M m8, std::nullptr_t listEnd) { return variadicCreate(m1, m2, m3, m4, m5, m6, m7, m8, NULL); } - static Spawn* create(M m1, M m2, M m3, M m4, M m5, M m6, M m7, M m8, M m9, std::nullptr_t listEnd) { return variadicCreate(m1, m2, m3, m4, m5, m6, m7, m8, m9, NULL); } - static Spawn* create(M m1, M m2, M m3, M m4, M m5, M m6, M m7, M m8, M m9, M m10, std::nullptr_t listEnd) { return variadicCreate(m1, m2, m3, m4, m5, m6, m7, m8, m9, m10, NULL); } - - // On WP8 for variable argument lists longer than 10 items, use the other create functions or createSpawn with NULL as the last argument. - static Spawn* variadicCreate(FiniteTimeAction* item, ...); -#else - static Spawn* create(FiniteTimeAction *action1, ...) CC_REQUIRES_NULL_TERMINATION; -#endif - - /** Helper constructor to create an array of spawned actions. - * - * @param action1 The first sequenceable action. - * @param args The va_list variable. - * @return An autoreleased Spawn object. - * @js NA - */ - static Spawn* createWithVariableList(FiniteTimeAction *action1, va_list args); - - /** Helper constructor to create an array of spawned actions given an array. - * - * @param arrayOfActions An array of spawned actions. - * @return An autoreleased Spawn object. - */ - static Spawn* create(const Vector& arrayOfActions); - - /** Creates the Spawn action. - * - * @param action1 The first spawned action. - * @param action2 The second spawned action. - * @return An autoreleased Spawn object. - * @js NA - */ - static Spawn* createWithTwoActions(FiniteTimeAction *action1, FiniteTimeAction *action2); - - // - // Overrides - // - virtual Spawn* clone() const override; - virtual Spawn* reverse(void) const override; - virtual void startWithTarget(Node *target) override; - virtual void stop(void) override; - /** - * @param time In seconds. - */ - virtual void update(float time) override; - -CC_CONSTRUCTOR_ACCESS: - Spawn(); - virtual ~Spawn(); - - /** initializes the Spawn action with the 2 actions to spawn */ - bool initWithTwoActions(FiniteTimeAction *action1, FiniteTimeAction *action2); - bool init(const Vector& arrayOfActions); - -protected: - FiniteTimeAction *_one; - FiniteTimeAction *_two; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(Spawn); -}; - -/** @class RotateTo - * @brief Rotates a Node object to a certain angle by modifying it's rotation attribute. - The direction will be decided by the shortest angle. -*/ -class CC_DLL RotateTo : public ActionInterval -{ -public: - /** - * Creates the action with separate rotation angles. - * - * @param duration Duration time, in seconds. - * @param dstAngleX In degreesCW. - * @param dstAngleY In degreesCW. - * @return An autoreleased RotateTo object. - */ - static RotateTo* create(float duration, float dstAngleX, float dstAngleY); - - /** - * Creates the action. - * - * @param duration Duration time, in seconds. - * @param dstAngle In degreesCW. - * @return An autoreleased RotateTo object. - */ - static RotateTo* create(float duration, float dstAngle); - - /** - * Creates the action with 3D rotation angles. - * @param duration Duration time, in seconds. - * @param dstAngle3D A Vec3 angle. - * @return An autoreleased RotateTo object. - */ - //static RotateTo* create(float duration, const Vec3& dstAngle3D); - - // - // Overrides - // - virtual RotateTo* clone() const override; - virtual RotateTo* reverse() const override; - virtual void startWithTarget(Node *target) override; - /** - * @param time In seconds. - */ - virtual void update(float time) override; - -CC_CONSTRUCTOR_ACCESS: - RotateTo(); - virtual ~RotateTo() {} - - /** - * initializes the action - * @param duration in seconds - * @param dstAngleX in degreesCW - * @param dstAngleY in degreesCW - */ - bool initWithDuration(float duration, float dstAngleX, float dstAngleY); - /** - * initializes the action - * @param duration in seconds - */ - //bool initWithDuration(float duration, const Vec3& dstAngle3D); - - /** - * calculates the start and diff angles - * @param dstAngle in degreesCW - */ - void calculateAngles(float &startAngle, float &diffAngle, float dstAngle); - -protected: - Vec3 _dstAngle; - Vec3 _startAngle; - Vec3 _diffAngle; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(RotateTo); -}; - -/** @class RotateBy - * @brief Rotates a Node object clockwise a number of degrees by modifying it's rotation attribute. -*/ -class CC_DLL RotateBy : public ActionInterval -{ -public: - /** - * Creates the action. - * - * @param duration Duration time, in seconds. - * @param deltaAngle In degreesCW. - * @return An autoreleased RotateBy object. - */ - static RotateBy* create(float duration, float deltaAngle); - /** - * Creates the action with separate rotation angles. - * - * @param duration Duration time, in seconds. - * @param deltaAngleZ_X In degreesCW. - * @param deltaAngleZ_Y In degreesCW. - * @return An autoreleased RotateBy object. - */ - static RotateBy* create(float duration, float deltaAngleZ_X, float deltaAngleZ_Y); - /** Creates the action with 3D rotation angles. - * - * @param duration Duration time, in seconds. - * @param deltaAngle3D A Vec3 angle. - * @return An autoreleased RotateBy object. - */ - //static RotateBy* create(float duration, const Vec3& deltaAngle3D); - - // - // Override - // - virtual RotateBy* clone() const override; - virtual RotateBy* reverse(void) const override; - virtual void startWithTarget(Node *target) override; - /** - * @param time In seconds. - */ - virtual void update(float time) override; - -CC_CONSTRUCTOR_ACCESS: - RotateBy(); - virtual ~RotateBy() {} - - /** initializes the action */ - bool initWithDuration(float duration, float deltaAngle); - /** - * @param deltaAngleZ_X in degreesCW - * @param deltaAngleZ_Y in degreesCW - */ - bool initWithDuration(float duration, float deltaAngleZ_X, float deltaAngleZ_Y); - //bool initWithDuration(float duration, const Vec3& deltaAngle3D); - -protected: - Vec3 _deltaAngle; - Vec3 _startAngle; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(RotateBy); -}; - -/** @class MoveBy - * @brief Moves a Node object x,y pixels by modifying it's position attribute. - x and y are relative to the position of the object. - Several MoveBy actions can be concurrently called, and the resulting - movement will be the sum of individual movements. - @since v2.1beta2-custom - */ -class CC_DLL MoveBy : public ActionInterval -{ -public: - /** - * Creates the action. - * - * @param duration Duration time, in seconds. - * @param deltaPosition The delta distance in 2d, it's a Vec2 type. - * @return An autoreleased MoveBy object. - */ - static MoveBy* create(float duration, const Vec2& deltaPosition); - /** - * Creates the action. - * - * @param duration Duration time, in seconds. - * @param deltaPosition The delta distance in 3d, it's a Vec3 type. - * @return An autoreleased MoveBy object. - */ - //static MoveBy* create(float duration, const Vec3& deltaPosition); - - // - // Overrides - // - virtual MoveBy* clone() const override; - virtual MoveBy* reverse(void) const override; - virtual void startWithTarget(Node *target) override; - /** - * @param time in seconds - */ - virtual void update(float time) override; - -CC_CONSTRUCTOR_ACCESS: - MoveBy(){} - virtual ~MoveBy() {} - - /** initializes the action */ - bool initWithDuration(float duration, const Vec2& deltaPosition); - //bool initWithDuration(float duration, const Vec3& deltaPosition); - -protected: - Vec2 _positionDelta; - Vec2 _startPosition; - Vec2 _previousPosition; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(MoveBy); -}; - -/** @class MoveTo - * @brief Moves a Node object to the position x,y. x and y are absolute coordinates by modifying it's position attribute. - Several MoveTo actions can be concurrently called, and the resulting - movement will be the sum of individual movements. - @since v2.1beta2-custom - */ -class CC_DLL MoveTo : public MoveBy -{ -public: - /** - * Creates the action. - * @param duration Duration time, in seconds. - * @param position The destination position in 2d. - * @return An autoreleased MoveTo object. - */ - static MoveTo* create(float duration, const Vec2& position); - /** - * Creates the action. - * @param duration Duration time, in seconds. - * @param position The destination position in 3d. - * @return An autoreleased MoveTo object. - */ - //static MoveTo* create(float duration, const Vec3& position); - - // - // Overrides - // - virtual MoveTo* clone() const override; - virtual MoveTo* reverse() const override; - virtual void startWithTarget(Node *target) override; - -CC_CONSTRUCTOR_ACCESS: - MoveTo() {} - virtual ~MoveTo() {} - - /** - * initializes the action - * @param duration in seconds - */ - bool initWithDuration(float duration, const Vec2& position); - /** - * initializes the action - * @param duration in seconds - */ - //bool initWithDuration(float duration, const Vec3& position); - -protected: - Vec2 _endPosition; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(MoveTo); -}; - -/** @class SkewTo - * @brief Skews a Node object to given angles by modifying it's skewX and skewY attributes -@since v1.0 -*/ -class CC_DLL SkewTo : public ActionInterval -{ -public: - /** - * Creates the action. - * @param t Duration time, in seconds. - * @param sx Skew x angle. - * @param sy Skew y angle. - * @return An autoreleased SkewTo object. - */ - static SkewTo* create(float t, float sx, float sy); - - // - // Overrides - // - virtual SkewTo* clone() const override; - virtual SkewTo* reverse(void) const override; - virtual void startWithTarget(Node *target) override; - /** - * @param time In seconds. - */ - virtual void update(float time) override; - -CC_CONSTRUCTOR_ACCESS: - SkewTo(); - virtual ~SkewTo() {} - /** - * @param t In seconds. - */ - bool initWithDuration(float t, float sx, float sy); - -protected: - float _skewX; - float _skewY; - float _startSkewX; - float _startSkewY; - float _endSkewX; - float _endSkewY; - float _deltaX; - float _deltaY; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(SkewTo); -}; - -/** @class SkewBy -* @brief Skews a Node object by skewX and skewY degrees. -@since v1.0 -*/ -class CC_DLL SkewBy : public SkewTo -{ -public: - /** - * Creates the action. - * @param t Duration time, in seconds. - * @param deltaSkewX Skew x delta angle. - * @param deltaSkewY Skew y delta angle. - * @return An autoreleased SkewBy object. - */ - static SkewBy* create(float t, float deltaSkewX, float deltaSkewY); - - // - // Overrides - // - virtual void startWithTarget(Node *target) override; - virtual SkewBy* clone() const override; - virtual SkewBy* reverse(void) const override; - -CC_CONSTRUCTOR_ACCESS: - SkewBy() {} - virtual ~SkewBy() {} - /** - * @param t In seconds. - */ - bool initWithDuration(float t, float sx, float sy); - -private: - CC_DISALLOW_COPY_AND_ASSIGN(SkewBy); -}; - -/** @class JumpBy - * @brief Moves a Node object simulating a parabolic jump movement by modifying it's position attribute. -*/ -class CC_DLL JumpBy : public ActionInterval -{ -public: - /** - * Creates the action. - * @param duration Duration time, in seconds. - * @param position The jumping distance. - * @param height The jumping height. - * @param jumps The jumping times. - * @return An autoreleased JumpBy object. - */ - static JumpBy* create(float duration, const Vec2& position, float height, int jumps); - - // - // Overrides - // - virtual JumpBy* clone() const override; - virtual JumpBy* reverse(void) const override; - virtual void startWithTarget(Node *target) override; - /** - * @param time In seconds. - */ - virtual void update(float time) override; - -CC_CONSTRUCTOR_ACCESS: - JumpBy() {} - virtual ~JumpBy() {} - - /** - * initializes the action - * @param duration in seconds - */ - bool initWithDuration(float duration, const Vec2& position, float height, int jumps); - -protected: - Vec2 _startPosition; - Vec2 _delta; - float _height; - int _jumps; - Vec2 _previousPos; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(JumpBy); -}; - -/** @class JumpTo - * @brief Moves a Node object to a parabolic position simulating a jump movement by modifying it's position attribute. -*/ -class CC_DLL JumpTo : public JumpBy -{ -public: - /** - * Creates the action. - * @param duration Duration time, in seconds. - * @param position The jumping destination position. - * @param height The jumping height. - * @param jumps The jumping times. - * @return An autoreleased JumpTo object. - */ - static JumpTo* create(float duration, const Vec2& position, float height, int jumps); - - // - // Override - // - virtual void startWithTarget(Node *target) override; - virtual JumpTo* clone() const override; - virtual JumpTo* reverse(void) const override; - -CC_CONSTRUCTOR_ACCESS: - JumpTo() {} - virtual ~JumpTo() {} - - /** - * initializes the action - * @param duration In seconds. - */ - bool initWithDuration(float duration, const Vec2& position, float height, int jumps); - -protected: - Vec2 _endPosition; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(JumpTo); -}; - -/** @struct Bezier configuration structure - */ -typedef struct _ccBezierConfig { - //! end position of the bezier - Vec2 endPosition; - //! Bezier control point 1 - Vec2 controlPoint_1; - //! Bezier control point 2 - Vec2 controlPoint_2; -} ccBezierConfig; - -/** @class BezierBy - * @brief An action that moves the target with a cubic Bezier curve by a certain distance. - */ -class CC_DLL BezierBy : public ActionInterval -{ -public: - /** Creates the action with a duration and a bezier configuration. - * @param t Duration time, in seconds. - * @param c Bezier config. - * @return An autoreleased BezierBy object. - * @code - * When this function bound to js or lua,the input params are changed. - * in js: var create(var t,var table) - * in lua: local create(local t, local table) - * @endcode - */ - static BezierBy* create(float t, const ccBezierConfig& c); - - // - // Overrides - // - virtual BezierBy* clone() const override; - virtual BezierBy* reverse(void) const override; - virtual void startWithTarget(Node *target) override; - /** - * @param time In seconds. - */ - virtual void update(float time) override; - -CC_CONSTRUCTOR_ACCESS: - BezierBy() {} - virtual ~BezierBy() {} - - /** - * initializes the action with a duration and a bezier configuration - * @param t in seconds - */ - bool initWithDuration(float t, const ccBezierConfig& c); - -protected: - ccBezierConfig _config; - Vec2 _startPosition; - Vec2 _previousPosition; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(BezierBy); -}; - -/** @class BezierTo - * @brief An action that moves the target with a cubic Bezier curve to a destination point. - @since v0.8.2 - */ -class CC_DLL BezierTo : public BezierBy -{ -public: - /** Creates the action with a duration and a bezier configuration. - * @param t Duration time, in seconds. - * @param c Bezier config. - * @return An autoreleased BezierTo object. - * @code - * when this function bound to js or lua,the input params are changed - * in js: var create(var t,var table) - * in lua: local create(local t, local table) - * @endcode - */ - static BezierTo* create(float t, const ccBezierConfig& c); - - // - // Overrides - // - virtual void startWithTarget(Node *target) override; - virtual BezierTo* clone() const override; - virtual BezierTo* reverse(void) const override; - -CC_CONSTRUCTOR_ACCESS: - BezierTo() {} - virtual ~BezierTo() {} - /** - * @param t In seconds. - */ - bool initWithDuration(float t, const ccBezierConfig &c); - -protected: - ccBezierConfig _toConfig; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(BezierTo); -}; - -/** @class ScaleTo - @brief Scales a Node object to a zoom factor by modifying it's scale attribute. - @warning This action doesn't support "reverse". - */ -class CC_DLL ScaleTo : public ActionInterval -{ -public: - /** - * Creates the action with the same scale factor for X and Y. - * @param duration Duration time, in seconds. - * @param s Scale factor of x and y. - * @return An autoreleased ScaleTo object. - */ - static ScaleTo* create(float duration, float s); - - /** - * Creates the action with and X factor and a Y factor. - * @param duration Duration time, in seconds. - * @param sx Scale factor of x. - * @param sy Scale factor of y. - * @return An autoreleased ScaleTo object. - */ - static ScaleTo* create(float duration, float sx, float sy); - - /** - * Creates the action with X Y Z factor. - * @param duration Duration time, in seconds. - * @param sx Scale factor of x. - * @param sy Scale factor of y. - * @param sz Scale factor of z. - * @return An autoreleased ScaleTo object. - */ - static ScaleTo* create(float duration, float sx, float sy, float sz); - - // - // Overrides - // - virtual ScaleTo* clone() const override; - virtual ScaleTo* reverse(void) const override; - virtual void startWithTarget(Node *target) override; - /** - * @param time In seconds. - */ - virtual void update(float time) override; - -CC_CONSTRUCTOR_ACCESS: - ScaleTo() {} - virtual ~ScaleTo() {} - - /** - * initializes the action with the same scale factor for X and Y - * @param duration in seconds - */ - bool initWithDuration(float duration, float s); - /** - * initializes the action with and X factor and a Y factor - * @param duration in seconds - */ - bool initWithDuration(float duration, float sx, float sy); - /** - * initializes the action with X Y Z factor - * @param duration in seconds - */ - bool initWithDuration(float duration, float sx, float sy, float sz); - -protected: - float _scaleX; - float _scaleY; - float _scaleZ; - float _startScaleX; - float _startScaleY; - float _startScaleZ; - float _endScaleX; - float _endScaleY; - float _endScaleZ; - float _deltaX; - float _deltaY; - float _deltaZ; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(ScaleTo); -}; - -/** @class ScaleBy - * @brief Scales a Node object a zoom factor by modifying it's scale attribute. -*/ -class CC_DLL ScaleBy : public ScaleTo -{ -public: - /** - * Creates the action with the same scale factor for X and Y. - * @param duration Duration time, in seconds. - * @param s Scale factor of x and y. - * @return An autoreleased ScaleBy object. - */ - static ScaleBy* create(float duration, float s); - - /** - * Creates the action with and X factor and a Y factor. - * @param duration Duration time, in seconds. - * @param sx Scale factor of x. - * @param sy Scale factor of y. - * @return An autoreleased ScaleBy object. - */ - static ScaleBy* create(float duration, float sx, float sy); - - /** - * Creates the action with X Y Z factor. - * @param duration Duration time, in seconds. - * @param sx Scale factor of x. - * @param sy Scale factor of y. - * @param sz Scale factor of z. - * @return An autoreleased ScaleBy object. - */ - static ScaleBy* create(float duration, float sx, float sy, float sz); - - // - // Overrides - // - virtual void startWithTarget(Node *target) override; - virtual ScaleBy* clone() const override; - virtual ScaleBy* reverse(void) const override; - -CC_CONSTRUCTOR_ACCESS: - ScaleBy() {} - virtual ~ScaleBy() {} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(ScaleBy); -}; - -/** @class Blink - * @brief Blinks a Node object by modifying it's visible attribute. -*/ -class CC_DLL Blink : public ActionInterval -{ -public: - /** - * Creates the action. - * @param duration Duration time, in seconds. - * @param blinks Blink times. - * @return An autoreleased Blink object. - */ - static Blink* create(float duration, int blinks); - - // - // Overrides - // - virtual Blink* clone() const override; - virtual Blink* reverse() const override; - /** - * @param time In seconds. - */ - virtual void update(float time) override; - virtual void startWithTarget(Node *target) override; - virtual void stop() override; - -CC_CONSTRUCTOR_ACCESS: - Blink() {} - virtual ~Blink() {} - - /** - * initializes the action - * @param duration in seconds - */ - bool initWithDuration(float duration, int blinks); - -protected: - int _times; - bool _originalState; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(Blink); -}; - - -/** @class FadeTo - * @brief Fades an object that implements the RGBAProtocol protocol. It modifies the opacity from the current value to a custom one. - @warning This action doesn't support "reverse" - */ -class CC_DLL FadeTo : public ActionInterval -{ -public: - /** - * Creates an action with duration and opacity. - * @param duration Duration time, in seconds. - * @param opacity A certain opacity, the range is from 0 to 255. - * @return An autoreleased FadeTo object. - */ - static FadeTo* create(float duration, GLubyte opacity); - - // - // Overrides - // - virtual FadeTo* clone() const override; - virtual FadeTo* reverse(void) const override; - virtual void startWithTarget(Node *target) override; - /** - * @param time In seconds. - */ - virtual void update(float time) override; - -CC_CONSTRUCTOR_ACCESS: - FadeTo() {} - virtual ~FadeTo() {} - - /** - * initializes the action with duration and opacity - * @param duration in seconds - */ - bool initWithDuration(float duration, GLubyte opacity); - -protected: - GLubyte _toOpacity; - GLubyte _fromOpacity; - friend class FadeOut; - friend class FadeIn; -private: - CC_DISALLOW_COPY_AND_ASSIGN(FadeTo); -}; - -/** @class FadeIn - * @brief Fades In an object that implements the RGBAProtocol protocol. It modifies the opacity from 0 to 255. - The "reverse" of this action is FadeOut - */ -class CC_DLL FadeIn : public FadeTo -{ -public: - /** - * Creates the action. - * @param d Duration time, in seconds. - * @return An autoreleased FadeIn object. - */ - static FadeIn* create(float d); - - // - // Overrides - // - virtual void startWithTarget(Node *target) override; - virtual FadeIn* clone() const override; - virtual FadeTo* reverse(void) const override; - - /** - * @js NA - */ - void setReverseAction(FadeTo* ac); - -CC_CONSTRUCTOR_ACCESS: - FadeIn():_reverseAction(nullptr) {} - virtual ~FadeIn() {} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(FadeIn); - FadeTo* _reverseAction; -}; - -/** @class FadeOut - * @brief Fades Out an object that implements the RGBAProtocol protocol. It modifies the opacity from 255 to 0. - The "reverse" of this action is FadeIn -*/ -class CC_DLL FadeOut : public FadeTo -{ -public: - /** - * Creates the action. - * @param d Duration time, in seconds. - */ - static FadeOut* create(float d); - - // - // Overrides - // - virtual void startWithTarget(Node *target) override; - virtual FadeOut* clone() const override; - virtual FadeTo* reverse(void) const override; - - /** - * @js NA - */ - void setReverseAction(FadeTo* ac); - -CC_CONSTRUCTOR_ACCESS: - FadeOut():_reverseAction(nullptr) {} - virtual ~FadeOut() {} -private: - CC_DISALLOW_COPY_AND_ASSIGN(FadeOut); - FadeTo* _reverseAction; -}; - -/** @class TintTo - * @brief Tints a Node that implements the NodeRGB protocol from current tint to a custom one. - @warning This action doesn't support "reverse" - @since v0.7.2 -*/ -class CC_DLL TintTo : public ActionInterval -{ -public: - /** - * Creates an action with duration and color. - * @param duration Duration time, in seconds. - * @param red Red Color, from 0 to 255. - * @param green Green Color, from 0 to 255. - * @param blue Blue Color, from 0 to 255. - * @return An autoreleased TintTo object. - */ - static TintTo* create(float duration, GLubyte red, GLubyte green, GLubyte blue); - /** - * Creates an action with duration and color. - * @param duration Duration time, in seconds. - * @param color It's a Color3B type. - * @return An autoreleased TintTo object. - */ - static TintTo* create(float duration, const Color3B& color); - - // - // Overrides - // - virtual TintTo* clone() const override; - virtual TintTo* reverse(void) const override; - virtual void startWithTarget(Node *target) override; - /** - * @param time In seconds. - */ - virtual void update(float time) override; - -CC_CONSTRUCTOR_ACCESS: - TintTo() {} - virtual ~TintTo() {} - - /** initializes the action with duration and color */ - bool initWithDuration(float duration, GLubyte red, GLubyte green, GLubyte blue); - -protected: - Color3B _to; - Color3B _from; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(TintTo); -}; - -/** @class TintBy - @brief Tints a Node that implements the NodeRGB protocol from current tint to a custom one. - @since v0.7.2 - */ -class CC_DLL TintBy : public ActionInterval -{ -public: - /** - * Creates an action with duration and color. - * @param duration Duration time, in seconds. - * @param deltaRed Delta red color. - * @param deltaGreen Delta green color. - * @param deltaBlue Delta blue color. - * @return An autoreleased TintBy object. - */ - static TintBy* create(float duration, GLshort deltaRed, GLshort deltaGreen, GLshort deltaBlue); - - // - // Overrides - // - virtual TintBy* clone() const override; - virtual TintBy* reverse() const override; - virtual void startWithTarget(Node *target) override; - /** - * @param time In seconds. - */ - virtual void update(float time) override; - -CC_CONSTRUCTOR_ACCESS: - TintBy() {} - virtual ~TintBy() {} - - /** initializes the action with duration and color */ - bool initWithDuration(float duration, GLshort deltaRed, GLshort deltaGreen, GLshort deltaBlue); - -protected: - GLshort _deltaR; - GLshort _deltaG; - GLshort _deltaB; - - GLshort _fromR; - GLshort _fromG; - GLshort _fromB; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(TintBy); -}; - -/** @class DelayTime - * @brief Delays the action a certain amount of seconds. -*/ -class CC_DLL DelayTime : public ActionInterval -{ -public: - /** - * Creates the action. - * @param d Duration time, in seconds. - * @return An autoreleased DelayTime object. - */ - static DelayTime* create(float d); - - // - // Overrides - // - /** - * @param time In seconds. - */ - virtual void update(float time) override; - virtual DelayTime* reverse() const override; - virtual DelayTime* clone() const override; - -CC_CONSTRUCTOR_ACCESS: - DelayTime() {} - virtual ~DelayTime() {} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(DelayTime); -}; - -/** @class ReverseTime - * @brief Executes an action in reverse order, from time=duration to time=0 - - @warning Use this action carefully. This action is not - sequenceable. Use it as the default "reversed" method - of your own actions, but using it outside the "reversed" - scope is not recommended. -*/ -class CC_DLL ReverseTime : public ActionInterval -{ -public: - /** Creates the action. - * - * @param action a certain action. - * @return An autoreleased ReverseTime object. - */ - static ReverseTime* create(FiniteTimeAction *action); - - // - // Overrides - // - virtual ReverseTime* reverse() const override; - virtual ReverseTime* clone() const override; - virtual void startWithTarget(Node *target) override; - virtual void stop(void) override; - /** - * @param time In seconds. - */ - virtual void update(float time) override; - -CC_CONSTRUCTOR_ACCESS: - ReverseTime(); - virtual ~ReverseTime(void); - - /** initializes the action */ - bool initWithAction(FiniteTimeAction *action); - -protected: - FiniteTimeAction *_other; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(ReverseTime); -}; - -class Texture2D; -/** @class Animate - * @brief Animates a sprite given the name of an Animation. - */ -class CC_DLL Animate : public ActionInterval -{ -public: - /** Creates the action with an Animation and will restore the original frame when the animation is over. - * - * @param animation A certain animation. - * @return An autoreleased Animate object. - */ - static Animate* create(Animation *animation); - - /** Sets the Animation object to be animated - * - * @param animation certain animation. - */ - void setAnimation( Animation* animation ); - /** returns the Animation object that is being animated - * - * @return Gets the animation object that is being animated. - */ - Animation* getAnimation() { return _animation; } - const Animation* getAnimation() const { return _animation; } - - /** - * Gets the index of sprite frame currently displayed. - * @return int the index of sprite frame currently displayed. - */ - int getCurrentFrameIndex() { return _currFrameIndex; } - // - // Overrides - // - virtual Animate* clone() const override; - virtual Animate* reverse() const override; - virtual void startWithTarget(Node *target) override; - virtual void stop(void) override; - /** - * @param t In seconds. - */ - virtual void update(float t) override; - -CC_CONSTRUCTOR_ACCESS: - Animate(); - virtual ~Animate(); - - /** initializes the action with an Animation and will restore the original frame when the animation is over */ - bool initWithAnimation(Animation *animation); - -protected: - std::vector* _splitTimes; - int _nextFrame; - SpriteFrame* _origFrame; - int _currFrameIndex; - unsigned int _executedLoops; - Animation* _animation; - - EventCustom* _frameDisplayedEvent; - AnimationFrame::DisplayedEventInfo _frameDisplayedEventInfo; -private: - CC_DISALLOW_COPY_AND_ASSIGN(Animate); -}; - -/** @class TargetedAction - * @brief Overrides the target of an action so that it always runs on the target - * specified at action creation rather than the one specified by runAction. - */ -class CC_DLL TargetedAction : public ActionInterval -{ -public: - /** Create an action with the specified action and forced target. - * - * @param target The target needs to override. - * @param action The action needs to override. - * @return An autoreleased TargetedAction object. - */ - static TargetedAction* create(Node* target, FiniteTimeAction* action); - - /** Sets the target that the action will be forced to run with. - * - * @param forcedTarget The target that the action will be forced to run with. - */ - void setForcedTarget(Node* forcedTarget); - /** returns the target that the action is forced to run with. - * - * @return The target that the action is forced to run with. - */ - Node* getForcedTarget() { return _forcedTarget; } - const Node* getForcedTarget() const { return _forcedTarget; } - - // - // Overrides - // - virtual TargetedAction* clone() const override; - virtual TargetedAction* reverse() const override; - virtual void startWithTarget(Node *target) override; - virtual void stop(void) override; - /** - * @param time In seconds. - */ - virtual void update(float time) override; - -CC_CONSTRUCTOR_ACCESS: - TargetedAction(); - virtual ~TargetedAction(); - - /** Init an action with the specified action and forced target */ - bool initWithTarget(Node* target, FiniteTimeAction* action); - -protected: - FiniteTimeAction* _action; - Node* _forcedTarget; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(TargetedAction); -}; - -/** - * @class ActionFloat - * @brief Action used to animate any value in range [from,to] over specified time interval - */ -class CC_DLL ActionFloat : public ActionInterval -{ -public: - /** - * Callback function used to report back result - */ - typedef std::function ActionFloatCallback; - - /** - * Creates FloatAction with specified duration, from value, to value and callback to report back - * results - * @param duration of the action - * @param from value to start from - * @param to value to be at the end of the action - * @param callback to report back result - * - * @return An autoreleased ActionFloat object - */ - static ActionFloat* create(float duration, float from, float to, ActionFloatCallback callback); - - /** - * Overridden ActionInterval methods - */ - void startWithTarget(Node* target) override; - void update(float delta) override; - ActionFloat* reverse() const override; - ActionFloat* clone() const override; - -CC_CONSTRUCTOR_ACCESS: - ActionFloat() {}; - virtual ~ActionFloat() {}; - - bool initWithDuration(float duration, float from, float to, ActionFloatCallback callback); - -protected: - /* From value */ - float _from; - /* To value */ - float _to; - /* delta time */ - float _delta; - - /* Callback to report back results */ - ActionFloatCallback _callback; -private: - CC_DISALLOW_COPY_AND_ASSIGN(ActionFloat); -}; - -// end of actions group -/// @} - -NS_CC_END - -#endif //__ACTION_CCINTERVAL_ACTION_H__ diff --git a/native/cocos/2d/CCActionManager.cpp b/native/cocos/2d/CCActionManager.cpp deleted file mode 100644 index 2d0c8e17ac..0000000000 --- a/native/cocos/2d/CCActionManager.cpp +++ /dev/null @@ -1,505 +0,0 @@ -/**************************************************************************** -Copyright (c) 2008-2010 Ricardo Quesada -Copyright (c) 2009 Valentin Milea -Copyright (c) 2010-2012 cocos2d-x.org -Copyright (c) 2011 Zynga Inc. -CopyRight (c) 2013-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ - -#include "2d/CCActionManager.h" -#include "2d/CCNode.h" -#include "2d/CCAction.h" -#include "base/CCScheduler.h" -#include "base/ccMacros.h" -#include "base/ccCArray.h" -#include "base/uthash.h" - -NS_CC_BEGIN -// -// singleton stuff -// -typedef struct _hashElement -{ - struct _ccArray *actions; - Node *target; - int actionIndex; - Action *currentAction; - bool currentActionSalvaged; - bool paused; - UT_hash_handle hh; -} tHashElement; - -ActionManager::ActionManager() -: _targets(nullptr), - _currentTarget(nullptr), - _currentTargetSalvaged(false) -{ - -} - -ActionManager::~ActionManager() -{ - CCLOGINFO("deallocing ActionManager: %p", this); - - removeAllActions(); -} - -// private - -void ActionManager::deleteHashElement(tHashElement *element) -{ - ccArrayFree(element->actions); - HASH_DEL(_targets, element); - element->target->release(); - free(element); -} - -void ActionManager::actionAllocWithHashElement(tHashElement *element) -{ - // 4 actions per Node by default - if (element->actions == nullptr) - { - element->actions = ccArrayNew(4); - }else - if (element->actions->num == element->actions->max) - { - ccArrayDoubleCapacity(element->actions); - } - -} - -void ActionManager::removeActionAtIndex(ssize_t index, tHashElement *element) -{ - Action *action = (Action*)element->actions->arr[index]; - - if (action == element->currentAction && (! element->currentActionSalvaged)) - { - element->currentAction->retain(); - element->currentActionSalvaged = true; - } - -#if CC_ENABLE_GC_FOR_NATIVE_OBJECTS - auto sEngine = ScriptEngineManager::getInstance()->getScriptEngine(); - if (sEngine) - { - sEngine->releaseScriptObject(this, action); - } -#endif // CC_ENABLE_GC_FOR_NATIVE_OBJECTS - ccArrayRemoveObjectAtIndex(element->actions, index, true); - - // update actionIndex in case we are in tick. looping over the actions - if (element->actionIndex >= index) - { - element->actionIndex--; - } - - if (element->actions->num == 0) - { - if (_currentTarget == element) - { - _currentTargetSalvaged = true; - } - else - { - deleteHashElement(element); - } - } -} - -// pause / resume - -void ActionManager::pauseTarget(Node *target) -{ - tHashElement *element = nullptr; - HASH_FIND_PTR(_targets, &target, element); - if (element) - { - element->paused = true; - } -} - -void ActionManager::resumeTarget(Node *target) -{ - tHashElement *element = nullptr; - HASH_FIND_PTR(_targets, &target, element); - if (element) - { - element->paused = false; - } -} - -Vector ActionManager::pauseAllRunningActions() -{ - Vector idsWithActions; - - for (tHashElement *element=_targets; element != nullptr; element = (tHashElement *)element->hh.next) - { - if (! element->paused) - { - element->paused = true; - idsWithActions.pushBack(element->target); - } - } - - return idsWithActions; -} - -void ActionManager::resumeTargets(const Vector& targetsToResume) -{ - for(const auto &node : targetsToResume) - { - this->resumeTarget(node); - } -} - -// run - -void ActionManager::addAction(Action *action, Node *target, bool paused) -{ - CCASSERT(action != nullptr, "action can't be nullptr!"); - CCASSERT(target != nullptr, "target can't be nullptr!"); - if(action == nullptr || target == nullptr) - return; - - tHashElement *element = nullptr; - // we should convert it to Ref*, because we save it as Ref* - Ref *tmp = target; - HASH_FIND_PTR(_targets, &tmp, element); - if (! element) - { - element = (tHashElement*)calloc(sizeof(*element), 1); - element->paused = paused; - target->retain(); - element->target = target; - HASH_ADD_PTR(_targets, target, element); - } - - actionAllocWithHashElement(element); - - CCASSERT(! ccArrayContainsObject(element->actions, action), "action already be added!"); - ccArrayAppendObject(element->actions, action); -#if CC_ENABLE_GC_FOR_NATIVE_OBJECTS - auto sEngine = ScriptEngineManager::getInstance()->getScriptEngine(); - if (sEngine) - { - sEngine->retainScriptObject(this, action); - } -#endif // CC_ENABLE_GC_FOR_NATIVE_OBJECTS - - action->startWithTarget(target); -} - -// remove - -void ActionManager::removeAllActions() -{ - for (tHashElement *element = _targets; element != nullptr; ) - { - auto target = element->target; - element = (tHashElement*)element->hh.next; - removeAllActionsFromTarget(target); - } -} - -void ActionManager::removeAllActionsFromTarget(Node *target) -{ - // explicit null handling - if (target == nullptr) - { - return; - } - - tHashElement *element = nullptr; - HASH_FIND_PTR(_targets, &target, element); - if (element) - { - if (ccArrayContainsObject(element->actions, element->currentAction) && (! element->currentActionSalvaged)) - { - element->currentAction->retain(); - element->currentActionSalvaged = true; - } - - ccArrayRemoveAllObjects(element->actions); - -#if CC_ENABLE_GC_FOR_NATIVE_OBJECTS - auto sEngine = ScriptEngineManager::getInstance()->getScriptEngine(); - if (sEngine) - { - auto limit = element->actions->num; - for (int i = 0; i < limit; ++i) - { - Action *action = (Action*)element->actions->arr[i]; - if (!element->currentActionSalvaged || element->currentAction != action) - { - sEngine->releaseScriptObject(this, action); - } - } - } -#endif // CC_ENABLE_GC_FOR_NATIVE_OBJECTS - - if (_currentTarget == element) - { - _currentTargetSalvaged = true; - } - else - { - deleteHashElement(element); - } - } -} - -void ActionManager::removeAction(Action *action) -{ - // explicit null handling - if (action == nullptr) - { - return; - } - - tHashElement *element = nullptr; - Ref *target = action->getOriginalTarget(); - HASH_FIND_PTR(_targets, &target, element); - if (element) - { - auto i = ccArrayGetIndexOfObject(element->actions, action); - if (i != CC_INVALID_INDEX) - { - removeActionAtIndex(i, element); - } - } -} - -void ActionManager::removeActionByTag(int tag, Node *target) -{ - CCASSERT(tag != Action::INVALID_TAG, "Invalid tag value!"); - CCASSERT(target != nullptr, "target can't be nullptr!"); - if (target == nullptr) - { - return; - } - - tHashElement *element = nullptr; - HASH_FIND_PTR(_targets, &target, element); - - if (element) - { - auto limit = element->actions->num; - for (int i = 0; i < limit; ++i) - { - Action *action = (Action*)element->actions->arr[i]; - - if (action->getTag() == (int)tag && action->getOriginalTarget() == target) - { - removeActionAtIndex(i, element); - break; - } - } - } -} - -void ActionManager::removeAllActionsByTag(int tag, Node *target) -{ - CCASSERT(tag != Action::INVALID_TAG, "Invalid tag value!"); - CCASSERT(target != nullptr, "target can't be nullptr!"); - if (target == nullptr) - { - return; - } - - tHashElement *element = nullptr; - HASH_FIND_PTR(_targets, &target, element); - - if (element) - { - auto limit = element->actions->num; - for (int i = 0; i < limit;) - { - Action *action = (Action*)element->actions->arr[i]; - - if (action->getTag() == (int)tag && action->getOriginalTarget() == target) - { - removeActionAtIndex(i, element); - --limit; - } - else - { - ++i; - } - } - } -} - -void ActionManager::removeActionsByFlags(unsigned int flags, Node *target) -{ - if (flags == 0) - { - return; - } - CCASSERT(target != nullptr, "target can't be nullptr!"); - if (target == nullptr) - { - return; - } - - tHashElement *element = nullptr; - HASH_FIND_PTR(_targets, &target, element); - - if (element) - { - auto limit = element->actions->num; - for (int i = 0; i < limit;) - { - Action *action = (Action*)element->actions->arr[i]; - - if ((action->getFlags() & flags) != 0 && action->getOriginalTarget() == target) - { - removeActionAtIndex(i, element); - --limit; - } - else - { - ++i; - } - } - } -} - -// get - -// FIXME: Passing "const O *" instead of "const O&" because HASH_FIND_IT requires the address of a pointer -// and, it is not possible to get the address of a reference -Action* ActionManager::getActionByTag(int tag, const Node *target) const -{ - CCASSERT(tag != Action::INVALID_TAG, "Invalid tag value!"); - - tHashElement *element = nullptr; - HASH_FIND_PTR(_targets, &target, element); - - if (element) - { - if (element->actions != nullptr) - { - auto limit = element->actions->num; - for (int i = 0; i < limit; ++i) - { - Action *action = (Action*)element->actions->arr[i]; - - if (action->getTag() == (int)tag) - { - return action; - } - } - } - } - - return nullptr; -} - -// FIXME: Passing "const O *" instead of "const O&" because HASH_FIND_IT requires the address of a pointer -// and, it is not possible to get the address of a reference -ssize_t ActionManager::getNumberOfRunningActionsInTarget(const Node *target) const -{ - tHashElement *element = nullptr; - HASH_FIND_PTR(_targets, &target, element); - if (element) - { - return element->actions ? element->actions->num : 0; - } - - return 0; -} - -// main loop -void ActionManager::update(float dt) -{ - for (tHashElement *elt = _targets; elt != nullptr; ) - { - _currentTarget = elt; - _currentTargetSalvaged = false; - - if (! _currentTarget->paused) - { - // The 'actions' MutableArray may change while inside this loop. - for (_currentTarget->actionIndex = 0; _currentTarget->actionIndex < _currentTarget->actions->num; - _currentTarget->actionIndex++) - { - _currentTarget->currentAction = (Action*)_currentTarget->actions->arr[_currentTarget->actionIndex]; - if (_currentTarget->currentAction == nullptr) - { - continue; - } - - _currentTarget->currentActionSalvaged = false; - - _currentTarget->currentAction->step(dt); - - if (_currentTarget->currentActionSalvaged) - { - // The currentAction told the node to remove it. To prevent the action from - // accidentally deallocating itself before finishing its step, we retained - // it. Now that step is done, it's safe to release it. - _currentTarget->currentAction->release(); -#if CC_ENABLE_GC_FOR_NATIVE_OBJECTS - auto sEngine = ScriptEngineManager::getInstance()->getScriptEngine(); - if (sEngine) - { - sEngine->releaseScriptObject(this, _currentTarget->currentAction); - } -#endif // CC_ENABLE_GC_FOR_NATIVE_OBJECTS - } else - if (_currentTarget->currentAction->isDone()) - { - _currentTarget->currentAction->stop(); - - Action *action = _currentTarget->currentAction; - // Make currentAction nil to prevent removeAction from salvaging it. - _currentTarget->currentAction = nullptr; - removeAction(action); - } - - _currentTarget->currentAction = nullptr; - } - } - - // elt, at this moment, is still valid - // so it is safe to ask this here (issue #490) - elt = (tHashElement*)(elt->hh.next); - - // only delete currentTarget if no actions were scheduled during the cycle (issue #481) - if (_currentTargetSalvaged && _currentTarget->actions->num == 0) - { - deleteHashElement(_currentTarget); - } - //if some node reference 'target', it's reference count >= 2 (issues #14050) - else if (_currentTarget->target->getReferenceCount() == 1) - { - deleteHashElement(_currentTarget); - } - } - - // issue #635 - _currentTarget = nullptr; -} - -NS_CC_END diff --git a/native/cocos/2d/CCActionManager.h b/native/cocos/2d/CCActionManager.h deleted file mode 100644 index 81b938af37..0000000000 --- a/native/cocos/2d/CCActionManager.h +++ /dev/null @@ -1,193 +0,0 @@ -/**************************************************************************** -Copyright (c) 2008-2010 Ricardo Quesada -Copyright (c) 2009 Valentin Milea -Copyright (c) 2010-2012 cocos2d-x.org -Copyright (c) 2011 Zynga Inc. -CopyRight (c) 2013-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ - -#ifndef __ACTION_CCACTION_MANAGER_H__ -#define __ACTION_CCACTION_MANAGER_H__ - -#include "2d/CCAction.h" -#include "base/CCVector.h" -#include "base/CCRef.h" - -NS_CC_BEGIN - -class Action; - -struct _hashElement; - -/** - * @addtogroup actions - * @{ - */ - -/** @class ActionManager - @brief ActionManager is a singleton that manages all the actions. - Normally you won't need to use this singleton directly. 99% of the cases you will use the Node interface, - which uses this singleton. - But there are some cases where you might need to use this singleton. - Examples: - - When you want to run an action where the target is different from a Node. - - When you want to pause / resume the actions. - - @since v0.8 - */ -class CC_DLL ActionManager : public Ref -{ -public: - /** - * @js ctor - */ - ActionManager(void); - - /** - * @js NA - * @lua NA - */ - ~ActionManager(void); - - // actions - - /** Adds an action with a target. - If the target is already present, then the action will be added to the existing target. - If the target is not present, a new instance of this target will be created either paused or not, and the action will be added to the newly created target. - When the target is paused, the queued actions won't be 'ticked'. - * - * @param action A certain action. - * @param target The target which need to be added an action. - * @param paused Is the target paused or not. - */ - void addAction(Action *action, Node *target, bool paused); - - /** Removes all actions from all the targets. - */ - void removeAllActions(); - - /** Removes all actions from a certain target. - All the actions that belongs to the target will be removed. - * - * @param target A certain target. - */ - void removeAllActionsFromTarget(Node *target); - - /** Removes an action given an action reference. - * - * @param action A certain target. - */ - void removeAction(Action *action); - - /** Removes an action given its tag and the target. - * - * @param tag The action's tag. - * @param target A certain target. - */ - void removeActionByTag(int tag, Node *target); - - /** Removes all actions given its tag and the target. - * - * @param tag The actions' tag. - * @param target A certain target. - * @js NA - */ - void removeAllActionsByTag(int tag, Node *target); - - /** Removes all actions matching at least one bit in flags and the target. - * - * @param flags The flag field to match the actions' flags based on bitwise AND. - * @param target A certain target. - * @js NA - */ - void removeActionsByFlags(unsigned int flags, Node *target); - - /** Gets an action given its tag an a target. - * - * @param tag The action's tag. - * @param target A certain target. - * @return The Action the with the given tag. - */ - Action* getActionByTag(int tag, const Node *target) const; - - /** Returns the numbers of actions that are running in a certain target. - * Composable actions are counted as 1 action. Example: - * - If you are running 1 Sequence of 7 actions, it will return 1. - * - If you are running 7 Sequences of 2 actions, it will return 7. - * - * @param target A certain target. - * @return The numbers of actions that are running in a certain target. - * @js NA - */ - ssize_t getNumberOfRunningActionsInTarget(const Node *target) const; - - /** Pauses the target: all running actions and newly added actions will be paused. - * - * @param target A certain target. - */ - void pauseTarget(Node *target); - - /** Resumes the target. All queued actions will be resumed. - * - * @param target A certain target. - */ - void resumeTarget(Node *target); - - /** Pauses all running actions, returning a list of targets whose actions were paused. - * - * @return A list of targets whose actions were paused. - */ - Vector pauseAllRunningActions(); - - /** Resume a set of targets (convenience function to reverse a pauseAllRunningActions call). - * - * @param targetsToResume A set of targets need to be resumed. - */ - void resumeTargets(const Vector& targetsToResume); - - /** Main loop of ActionManager. - * @param dt In seconds. - */ - void update(float dt); - -protected: - // declared in ActionManager.m - - void removeActionAtIndex(ssize_t index, struct _hashElement *element); - void deleteHashElement(struct _hashElement *element); - void actionAllocWithHashElement(struct _hashElement *element); - -protected: - struct _hashElement *_targets; - struct _hashElement *_currentTarget; - bool _currentTargetSalvaged; -}; - -// end of actions group -/// @} - -NS_CC_END - -#endif // __ACTION_CCACTION_MANAGER_H__ - diff --git a/native/cocos/2d/CCActionPageTurn3D.cpp b/native/cocos/2d/CCActionPageTurn3D.cpp deleted file mode 100644 index 6d48fae837..0000000000 --- a/native/cocos/2d/CCActionPageTurn3D.cpp +++ /dev/null @@ -1,134 +0,0 @@ -/**************************************************************************** -Copyright (c) 2009 Sindesso Pty Ltd http://www.sindesso.com/ -Copyright (c) 2010-2012 cocos2d-x.org -CopyRight (c) 2013-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ -#include "2d/CCActionPageTurn3D.h" -#include "2d/CCGrid.h" -#include "2d/CCNodeGrid.h" - -NS_CC_BEGIN - -PageTurn3D* PageTurn3D::create(float duration, const Size& gridSize) -{ - PageTurn3D *action = new (std::nothrow) PageTurn3D(); - - if (action && action->initWithDuration(duration, gridSize)) - { - action->autorelease(); - return action; - } - - delete action; - return nullptr; -} - -PageTurn3D *PageTurn3D::clone() const -{ - // no copy constructor - return PageTurn3D::create(_duration, _gridSize); -} - -GridBase* PageTurn3D::getGrid() -{ - auto result = Grid3D::create(_gridSize, _gridNodeTarget->getGridRect()); - if (result) - { - result->setNeedDepthTestForBlit(true); - } - - return result; -} - -/* - * Update each tick - * Time is the percentage of the way through the duration - */ -void PageTurn3D::update(float time) -{ - float tt = MAX(0, time - 0.25f); - float deltaAy = (tt * tt * 500); - float ay = -100 - deltaAy; - - float deltaTheta = sqrtf(time); - float theta = deltaTheta > 0.5f ? (float)M_PI_2*deltaTheta : (float)M_PI_2*(1-deltaTheta); - - float rotateByYAxis = (2-time)* M_PI; - - float sinTheta = sinf(theta); - float cosTheta = cosf(theta); - - for (int i = 0; i <= _gridSize.width; ++i) - { - for (int j = 0; j <= _gridSize.height; ++j) - { - // Get original vertex - Vec3 p = getOriginalVertex(Vec2(i ,j)); - - p.x -= getGridRect().origin.x; - float R = sqrtf((p.x * p.x) + ((p.y - ay) * (p.y - ay))); - float r = R * sinTheta; - float alpha = asinf( p.x / R ); - float beta = alpha / sinTheta; - float cosBeta = cosf( beta ); - - // If beta > PI then we've wrapped around the cone - // Reduce the radius to stop these points interfering with others - if (beta <= M_PI) - { - p.x = ( r * sinf(beta)); - } - else - { - // Force X = 0 to stop wrapped - // points - p.x = 0; - } - - p.y = ( R + ay - ( r * (1 - cosBeta) * sinTheta)); - - // We scale z here to avoid the animation being - // too much bigger than the screen due to perspective transform - - p.z = (r * ( 1 - cosBeta ) * cosTheta);// "100" didn't work for - p.x = p.z * sinf(rotateByYAxis) + p.x * cosf(rotateByYAxis); - p.z = p.z * cosf(rotateByYAxis) - p.x * sinf(rotateByYAxis); - p.z/=7; - // Stop z coord from dropping beneath underlying page in a transition - // issue #751 - if( p.z < 0.5f ) - { - p.z = 0.5f; - } - - // Set new coords - p.x += getGridRect().origin.x; - setVertex(Vec2(i, j), p); - - } - } -} - -NS_CC_END - diff --git a/native/cocos/2d/CCActionPageTurn3D.h b/native/cocos/2d/CCActionPageTurn3D.h deleted file mode 100644 index e3c83a37d3..0000000000 --- a/native/cocos/2d/CCActionPageTurn3D.h +++ /dev/null @@ -1,75 +0,0 @@ -/**************************************************************************** -Copyright (c) 2009 Sindesso Pty Ltd http://www.sindesso.com/ -Copyright (c) 2010-2012 cocos2d-x.org -CopyRight (c) 2013-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ -#ifndef __ACTION_CCPAGETURN3D_ACTION_H__ -#define __ACTION_CCPAGETURN3D_ACTION_H__ - -#include "2d/CCActionGrid3D.h" - -NS_CC_BEGIN - -/** - * @addtogroup actions - * @{ - */ - -/** - @brief This action simulates a page turn from the bottom right hand corner of the screen. - - @details It's not much use by itself but is used by the PageTurnTransition. - Based on an original paper by L Hong et al. - http://www.parc.com/publication/1638/turning-pages-of-3d-electronic-books.html - - @since v0.8.2 - */ -class CC_DLL PageTurn3D : public Grid3DAction -{ -public: - /** - * @js NA - */ - virtual GridBase* getGrid() override; - - /** - @brief Create an action with duration, grid size. - @param duration Specify the duration of the PageTurn3D action. It's a value in seconds. - @param gridSize Specify the size of the grid. - @return If the creation success, return a pointer of PageTurn3D action; otherwise, return nil. - */ - static PageTurn3D* create(float duration, const Size& gridSize); - - // Overrides - virtual PageTurn3D* clone() const override; - virtual void update(float time) override; -}; - -// end of actions group -/// @} - -NS_CC_END - -#endif // __ACTION_CCPAGETURN3D_ACTION_H__ - diff --git a/native/cocos/2d/CCActionProgressTimer.cpp b/native/cocos/2d/CCActionProgressTimer.cpp deleted file mode 100644 index 7012e3a100..0000000000 --- a/native/cocos/2d/CCActionProgressTimer.cpp +++ /dev/null @@ -1,135 +0,0 @@ -/**************************************************************************** -Copyright (C) 2010 Lam Pham -Copyright (c) 2010-2012 cocos2d-x.org -CopyRight (c) 2013-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ -#include "2d/CCActionProgressTimer.h" -#include "2d/CCProgressTimer.h" - -NS_CC_BEGIN - -#define kProgressTimerCast ProgressTimer* - -// implementation of ProgressTo - -ProgressTo* ProgressTo::create(float duration, float percent) -{ - ProgressTo *progressTo = new (std::nothrow) ProgressTo(); - if (progressTo && progressTo->initWithDuration(duration, percent)) - { - progressTo->autorelease(); - return progressTo; - } - - delete progressTo; - return nullptr; -} - -bool ProgressTo::initWithDuration(float duration, float percent) -{ - if (ActionInterval::initWithDuration(duration)) - { - _to = percent; - - return true; - } - - return false; -} - -ProgressTo* ProgressTo::clone() const -{ - // no copy constructor - return ProgressTo::create(_duration, _to); -} - -ProgressTo* ProgressTo::reverse() const -{ - CCASSERT(false, "reverse() not supported in ProgressTo"); - return nullptr; -} - -void ProgressTo::startWithTarget(Node *target) -{ - ActionInterval::startWithTarget(target); - _from = ((kProgressTimerCast)(target))->getPercentage(); -} - -void ProgressTo::update(float time) -{ - ((kProgressTimerCast)(_target))->setPercentage(_from + (_to - _from) * time); -} - -// implementation of ProgressFromTo - -ProgressFromTo* ProgressFromTo::create(float duration, float fromPercentage, float toPercentage) -{ - ProgressFromTo *progressFromTo = new (std::nothrow) ProgressFromTo(); - if (progressFromTo && progressFromTo->initWithDuration(duration, fromPercentage, toPercentage)) - { - progressFromTo->autorelease(); - return progressFromTo; - } - - delete progressFromTo; - return nullptr; -} - -bool ProgressFromTo::initWithDuration(float duration, float fromPercentage, float toPercentage) -{ - if (ActionInterval::initWithDuration(duration)) - { - _to = toPercentage; - _from = fromPercentage; - - return true; - } - - return false; -} - -ProgressFromTo* ProgressFromTo::clone() const -{ - // no copy constructor - return ProgressFromTo::create(_duration, _from, _to); -} - - -ProgressFromTo* ProgressFromTo::reverse() const -{ - return ProgressFromTo::create(_duration, _to, _from); -} - -void ProgressFromTo::startWithTarget(Node *target) -{ - ActionInterval::startWithTarget(target); -} - -void ProgressFromTo::update(float time) -{ - ((kProgressTimerCast)(_target))->setPercentage(_from + (_to - _from) * time); -} - -NS_CC_END - diff --git a/native/cocos/2d/CCActionProgressTimer.h b/native/cocos/2d/CCActionProgressTimer.h deleted file mode 100644 index 805b115b85..0000000000 --- a/native/cocos/2d/CCActionProgressTimer.h +++ /dev/null @@ -1,135 +0,0 @@ -/**************************************************************************** -Copyright (C) 2010 Lam Pham -Copyright (c) 2010-2012 cocos2d-x.org -CopyRight (c) 2013-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ -#ifndef __ACTION_CCPROGRESS_TIMER_H__ -#define __ACTION_CCPROGRESS_TIMER_H__ - -#include "2d/CCActionInterval.h" - -NS_CC_BEGIN - -/** - * @addtogroup actions - * @{ - */ - -/** -@brief Progress to percentage. -@details This action show the target node from current percentage to the specified percentage. - You should specify the destination percentage when creating the action. -@since v0.99.1 -*/ -class CC_DLL ProgressTo : public ActionInterval -{ -public: - /** - * @brief Create and initializes with a duration and a destination percentage. - * @param duration Specify the duration of the ProgressTo action. It's a value in seconds. - * @param percent Specify the destination percentage. - * @return If the creation success, return a pointer of ProgressTo action; otherwise, return nil. - */ - static ProgressTo* create(float duration, float percent); - - // - // Overrides - // - virtual ProgressTo* clone() const override; - virtual ProgressTo* reverse() const override; - virtual void startWithTarget(Node *target) override; - virtual void update(float time) override; - -CC_CONSTRUCTOR_ACCESS: - ProgressTo() {} - virtual ~ProgressTo() {} - - /** - * @brief Initializes with a duration and destination percentage. - * @param duration Specify the duration of the ProgressTo action. It's a value in seconds. - * @param percent Specify the destination percentage. - * @return If the creation success, return true; otherwise, return false. - */ - bool initWithDuration(float duration, float percent); - -protected: - float _to; - float _from; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(ProgressTo); -}; - -/** -@brief Progress from a percentage to another percentage. -@since v0.99.1 -*/ -class CC_DLL ProgressFromTo : public ActionInterval -{ -public: - /** - * @brief Create and initializes the action with a duration, a "from" percentage and a "to" percentage. - * @param duration Specify the duration of the ProgressFromTo action. It's a value in seconds. - * @param fromPercentage Specify the source percentage. - * @param toPercentage Specify the destination percentage. - * @return If the creation success, return a pointer of ProgressFromTo action; otherwise, return nil. - */ - static ProgressFromTo* create(float duration, float fromPercentage, float toPercentage); - - // - // Overrides - // - virtual ProgressFromTo* clone() const override; - virtual ProgressFromTo* reverse() const override; - virtual void startWithTarget(Node *target) override; - virtual void update(float time) override; - -CC_CONSTRUCTOR_ACCESS: - ProgressFromTo() {} - virtual ~ProgressFromTo() {} - - /** - * @brief Initializes the action with a duration, a "from" percentage and a "to" percentage. - * @param duration Specify the duration of the ProgressFromTo action. It's a value in seconds. - * @param fromPercentage Specify the source percentage. - * @param toPercentage Specify the destination percentage. - * @return If the creation success, return true; otherwise, return false. - */ - bool initWithDuration(float duration, float fromPercentage, float toPercentage); - -protected: - float _to; - float _from; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(ProgressFromTo); -}; - -// end of actions group -/// @} - -NS_CC_END - -#endif // __ACTION_CCPROGRESS_TIMER_H__ - diff --git a/native/cocos/2d/CCActionTiledGrid.cpp b/native/cocos/2d/CCActionTiledGrid.cpp deleted file mode 100644 index a3bb489bde..0000000000 --- a/native/cocos/2d/CCActionTiledGrid.cpp +++ /dev/null @@ -1,876 +0,0 @@ -/**************************************************************************** -Copyright (c) 2009 On-Core -Copyright (c) 2010-2012 cocos2d-x.org -CopyRight (c) 2013-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ -#include "2d/CCActionTiledGrid.h" -#include "2d/CCGrid.h" -#include "2d/CCNodeGrid.h" -#include "base/CCDirector.h" -#include "base/ccMacros.h" - -NS_CC_BEGIN - -struct Tile -{ - Vec2 position; - Vec2 startPosition; - Size delta; -}; - -// implementation of ShakyTiles3D - -ShakyTiles3D* ShakyTiles3D::create(float duration, const Size& gridSize, int range, bool shakeZ) -{ - ShakyTiles3D *action = new (std::nothrow) ShakyTiles3D(); - - if (action && action->initWithDuration(duration, gridSize, range, shakeZ)) - { - action->autorelease(); - return action; - } - - delete action; - return nullptr; -} - -bool ShakyTiles3D::initWithDuration(float duration, const Size& gridSize, int range, bool shakeZ) -{ - if (TiledGrid3DAction::initWithDuration(duration, gridSize)) - { - _randrange = range; - _shakeZ = shakeZ; - - return true; - } - - return false; -} - -ShakyTiles3D* ShakyTiles3D::clone() const -{ - // no copy constructor - return ShakyTiles3D::create(_duration, _gridSize, _randrange, _shakeZ); -} - -void ShakyTiles3D::update(float time) -{ - CC_UNUSED_PARAM(time); - int i, j; - - for (i = 0; i < _gridSize.width; ++i) - { - for (j = 0; j < _gridSize.height; ++j) - { - Quad3 coords = getOriginalTile(Vec2(i, j)); - - // X - coords.bl.x += ( rand() % (_randrange*2) ) - _randrange; - coords.br.x += ( rand() % (_randrange*2) ) - _randrange; - coords.tl.x += ( rand() % (_randrange*2) ) - _randrange; - coords.tr.x += ( rand() % (_randrange*2) ) - _randrange; - - // Y - coords.bl.y += ( rand() % (_randrange*2) ) - _randrange; - coords.br.y += ( rand() % (_randrange*2) ) - _randrange; - coords.tl.y += ( rand() % (_randrange*2) ) - _randrange; - coords.tr.y += ( rand() % (_randrange*2) ) - _randrange; - - if (_shakeZ) - { - coords.bl.z += ( rand() % (_randrange*2) ) - _randrange; - coords.br.z += ( rand() % (_randrange*2) ) - _randrange; - coords.tl.z += ( rand() % (_randrange*2) ) - _randrange; - coords.tr.z += ( rand() % (_randrange*2) ) - _randrange; - } - - setTile(Vec2(i, j), coords); - } - } -} - -// implementation of ShatteredTiles3D - -ShatteredTiles3D* ShatteredTiles3D::create(float duration, const Size& gridSize, int range, bool shatterZ) -{ - ShatteredTiles3D *action = new (std::nothrow) ShatteredTiles3D(); - - if (action && action->initWithDuration(duration, gridSize, range, shatterZ)) - { - action->autorelease(); - return action; - } - - delete action; - return nullptr; -} - -bool ShatteredTiles3D::initWithDuration(float duration, const Size& gridSize, int range, bool shatterZ) -{ - if (TiledGrid3DAction::initWithDuration(duration, gridSize)) - { - _once = false; - _randrange = range; - _shatterZ = shatterZ; - - return true; - } - - return false; -} - -ShatteredTiles3D* ShatteredTiles3D::clone() const -{ - // no copy constructor - return ShatteredTiles3D::create(_duration, _gridSize, _randrange, _shatterZ); -} - -void ShatteredTiles3D::update(float time) -{ - CC_UNUSED_PARAM(time); - int i, j; - - if (_once == false) - { - for (i = 0; i < _gridSize.width; ++i) - { - for (j = 0; j < _gridSize.height; ++j) - { - Quad3 coords = getOriginalTile(Vec2(i ,j)); - - // X - coords.bl.x += ( rand() % (_randrange*2) ) - _randrange; - coords.br.x += ( rand() % (_randrange*2) ) - _randrange; - coords.tl.x += ( rand() % (_randrange*2) ) - _randrange; - coords.tr.x += ( rand() % (_randrange*2) ) - _randrange; - - // Y - coords.bl.y += ( rand() % (_randrange*2) ) - _randrange; - coords.br.y += ( rand() % (_randrange*2) ) - _randrange; - coords.tl.y += ( rand() % (_randrange*2) ) - _randrange; - coords.tr.y += ( rand() % (_randrange*2) ) - _randrange; - - if (_shatterZ) - { - coords.bl.z += ( rand() % (_randrange*2) ) - _randrange; - coords.br.z += ( rand() % (_randrange*2) ) - _randrange; - coords.tl.z += ( rand() % (_randrange*2) ) - _randrange; - coords.tr.z += ( rand() % (_randrange*2) ) - _randrange; - } - - setTile(Vec2(i, j), coords); - } - } - - _once = true; - } -} - -// implementation of ShuffleTiles - -ShuffleTiles* ShuffleTiles::create(float duration, const Size& gridSize, unsigned int seed) -{ - ShuffleTiles *action = new (std::nothrow) ShuffleTiles(); - - if (action && action->initWithDuration(duration, gridSize, seed)) - { - action->autorelease(); - return action; - } - - delete action; - return nullptr; -} - -bool ShuffleTiles::initWithDuration(float duration, const Size& gridSize, unsigned int seed) -{ - if (TiledGrid3DAction::initWithDuration(duration, gridSize)) - { - _seed = seed; - _tilesOrder = nullptr; - _tiles = nullptr; - - return true; - } - - return false; -} - -ShuffleTiles* ShuffleTiles::clone() const -{ - // no copy constructor - return ShuffleTiles::create(_duration, _gridSize, _seed); -} - -ShuffleTiles::~ShuffleTiles() -{ - CC_SAFE_DELETE_ARRAY(_tilesOrder); - CC_SAFE_DELETE_ARRAY(_tiles); -} - -void ShuffleTiles::shuffle(unsigned int *array, unsigned int len) -{ - for (int i = len - 1; i >= 0; i-- ) - { - unsigned int j = rand() % (i+1); - unsigned int v = array[i]; - array[i] = array[j]; - array[j] = v; - } -} - -Size ShuffleTiles::getDelta(const Size& pos) const -{ - Vec2 pos2; - - unsigned int idx = pos.width * _gridSize.height + pos.height; - - pos2.x = (float)(_tilesOrder[idx] / (int)_gridSize.height); - pos2.y = (float)(_tilesOrder[idx] % (int)_gridSize.height); - - return Size((int)(pos2.x - pos.width), (int)(pos2.y - pos.height)); -} - -void ShuffleTiles::placeTile(const Vec2& pos, Tile *t) -{ - Quad3 coords = getOriginalTile(pos); - - Vec2 step = _gridNodeTarget->getGrid()->getStep(); - coords.bl.x += (int)(t->position.x * step.x); - coords.bl.y += (int)(t->position.y * step.y); - - coords.br.x += (int)(t->position.x * step.x); - coords.br.y += (int)(t->position.y * step.y); - - coords.tl.x += (int)(t->position.x * step.x); - coords.tl.y += (int)(t->position.y * step.y); - - coords.tr.x += (int)(t->position.x * step.x); - coords.tr.y += (int)(t->position.y * step.y); - - setTile(pos, coords); -} - -void ShuffleTiles::startWithTarget(Node *target) -{ - TiledGrid3DAction::startWithTarget(target); - - if (_seed != (unsigned int)-1) - { - std::srand(_seed); - } - - _tilesCount = _gridSize.width * _gridSize.height; - _tilesOrder = new unsigned int[_tilesCount]; - - /** - * Use k to loop. Because _tilesCount is unsigned int, - * and i is used later for int. - */ - for (unsigned int k = 0; k < _tilesCount; ++k) - { - _tilesOrder[k] = k; - } - - shuffle(_tilesOrder, _tilesCount); - - _tiles = (struct Tile *)new Tile[_tilesCount]; - Tile *tileArray = (Tile*) _tiles; - - for (int i = 0; i < _gridSize.width; ++i) - { - for ( int j = 0; j < _gridSize.height; ++j) - { - tileArray->position.set((float)i, (float)j); - tileArray->startPosition.set((float)i, (float)j); - tileArray->delta = getDelta(Size(i, j)); - ++tileArray; - } - } -} - -void ShuffleTiles::update(float time) -{ - Tile *tileArray = (Tile*)_tiles; - - for (int i = 0; i < _gridSize.width; ++i) - { - for (int j = 0; j < _gridSize.height; ++j) - { - tileArray->position = Vec2((float)tileArray->delta.width, (float)tileArray->delta.height) * time; - placeTile(Vec2(i, j), tileArray); - ++tileArray; - } - } -} - -// implementation of FadeOutTRTiles - -FadeOutTRTiles* FadeOutTRTiles::create(float duration, const Size& gridSize) -{ - FadeOutTRTiles *action = new (std::nothrow) FadeOutTRTiles(); - - if (action && action->initWithDuration(duration, gridSize)) - { - action->autorelease(); - return action; - } - - delete action; - return nullptr; -} - -FadeOutTRTiles* FadeOutTRTiles::clone() const -{ - // no copy constructor - return FadeOutTRTiles::create(_duration, _gridSize); -} - -float FadeOutTRTiles::testFunc(const Size& pos, float time) -{ - Vec2 n = Vec2((float)_gridSize.width, (float)_gridSize.height) * time; - if ((n.x + n.y) == 0.0f) - { - return 1.0f; - } - - return powf((pos.width + pos.height) / (n.x + n.y), 6); -} - -void FadeOutTRTiles::turnOnTile(const Vec2& pos) -{ - setTile(pos, getOriginalTile(pos)); -} - -void FadeOutTRTiles::turnOffTile(const Vec2& pos) -{ - Quad3 coords; - memset(&coords, 0, sizeof(Quad3)); - setTile(pos, coords); -} - -void FadeOutTRTiles::transformTile(const Vec2& pos, float distance) -{ - Quad3 coords = getOriginalTile(pos); - Vec2 step = _gridNodeTarget->getGrid()->getStep(); - - coords.bl.x += (step.x / 2) * (1.0f - distance); - coords.bl.y += (step.y / 2) * (1.0f - distance); - - coords.br.x -= (step.x / 2) * (1.0f - distance); - coords.br.y += (step.y / 2) * (1.0f - distance); - - coords.tl.x += (step.x / 2) * (1.0f - distance); - coords.tl.y -= (step.y / 2) * (1.0f - distance); - - coords.tr.x -= (step.x / 2) * (1.0f - distance); - coords.tr.y -= (step.y / 2) * (1.0f - distance); - - setTile(pos, coords); -} - -void FadeOutTRTiles::update(float time) -{ - for (int i = 0; i < _gridSize.width; ++i) - { - for (int j = 0; j < _gridSize.height; ++j) - { - float distance = testFunc(Size(i, j), time); - if ( distance == 0 ) - { - turnOffTile(Vec2(i, j)); - } else - if (distance < 1) - { - transformTile(Vec2(i, j), distance); - } - else - { - turnOnTile(Vec2(i, j)); - } - } - } -} - -// implementation of FadeOutBLTiles - -FadeOutBLTiles* FadeOutBLTiles::create(float duration, const Size& gridSize) -{ - FadeOutBLTiles *action = new (std::nothrow) FadeOutBLTiles(); - - if (action && action->initWithDuration(duration, gridSize)) - { - action->autorelease(); - return action; - } - - delete action; - return nullptr; -} - -FadeOutBLTiles* FadeOutBLTiles::clone() const -{ - // no copy constructor - return FadeOutBLTiles::create(_duration, _gridSize); -} - -float FadeOutBLTiles::testFunc(const Size& pos, float time) -{ - Vec2 n = Vec2((float)_gridSize.width, (float)_gridSize.height) * (1.0f - time); - if ((pos.width + pos.height) == 0) - { - return 1.0f; - } - - return powf((n.x + n.y) / (pos.width + pos.height), 6); -} - -// implementation of FadeOutUpTiles - -FadeOutUpTiles* FadeOutUpTiles::create(float duration, const Size& gridSize) -{ - FadeOutUpTiles *action = new (std::nothrow) FadeOutUpTiles(); - - if (action && action->initWithDuration(duration, gridSize)) - { - action->autorelease(); - return action; - } - - delete action; - return nullptr; -} - -FadeOutUpTiles* FadeOutUpTiles::clone() const -{ - // no copy constructor - return FadeOutUpTiles::create(_duration, _gridSize); -} - -float FadeOutUpTiles::testFunc(const Size& pos, float time) -{ - Vec2 n = Vec2((float)_gridSize.width, (float)_gridSize.height) * time; - if (n.y == 0.0f) - { - return 1.0f; - } - - return powf(pos.height / n.y, 6); -} - -void FadeOutUpTiles::transformTile(const Vec2& pos, float distance) -{ - Quad3 coords = getOriginalTile(pos); - Vec2 step = _gridNodeTarget->getGrid()->getStep(); - - coords.bl.y += (step.y / 2) * (1.0f - distance); - coords.br.y += (step.y / 2) * (1.0f - distance); - coords.tl.y -= (step.y / 2) * (1.0f - distance); - coords.tr.y -= (step.y / 2) * (1.0f - distance); - - setTile(pos, coords); -} - -// implementation of FadeOutDownTiles - -FadeOutDownTiles* FadeOutDownTiles::create(float duration, const Size& gridSize) -{ - FadeOutDownTiles *action = new (std::nothrow) FadeOutDownTiles(); - - if (action && action->initWithDuration(duration, gridSize)) - { - action->autorelease(); - return action; - } - - delete action; - return nullptr; -} - -FadeOutDownTiles* FadeOutDownTiles::clone() const -{ - // no copy constructor - return FadeOutDownTiles::create(_duration, _gridSize); -} - -float FadeOutDownTiles::testFunc(const Size& pos, float time) -{ - Vec2 n = Vec2((float)_gridSize.width, (float)_gridSize.height) * (1.0f - time); - - return powf(n.y / (pos.height > 0.0f ? pos.height : 0.1f), 6); -} - -// implementation of TurnOffTiles - -TurnOffTiles* TurnOffTiles::create(float duration, const Size& gridSize) -{ - TurnOffTiles* action = new (std::nothrow) TurnOffTiles(); - if (action && action->initWithDuration(duration, gridSize, 0)) - { - action->autorelease(); - return action; - } - - delete action; - return nullptr; -} - -TurnOffTiles* TurnOffTiles::create(float duration, const Size& gridSize, unsigned int seed) -{ - TurnOffTiles *action = new (std::nothrow) TurnOffTiles(); - - if (action && action->initWithDuration(duration, gridSize, seed)) - { - action->autorelease(); - return action; - } - - delete action; - return nullptr; -} - -bool TurnOffTiles::initWithDuration(float duration, const Size& gridSize, unsigned int seed) -{ - if (TiledGrid3DAction::initWithDuration(duration, gridSize)) - { - _seed = seed; - _tilesOrder = nullptr; - - return true; - } - - return false; -} - -TurnOffTiles* TurnOffTiles::clone() const -{ - // no copy constructor - return TurnOffTiles::create(_duration, _gridSize, _seed); -} - -TurnOffTiles::~TurnOffTiles(void) -{ - CC_SAFE_DELETE_ARRAY(_tilesOrder); -} - -void TurnOffTiles::shuffle(unsigned int *array, unsigned int len) -{ - for (int i = len - 1; i >= 0; i--) - { - unsigned int j = rand() % (i+1); - unsigned int v = array[i]; - array[i] = array[j]; - array[j] = v; - } -} - -void TurnOffTiles::turnOnTile(const Vec2& pos) -{ - setTile(pos, getOriginalTile(pos)); -} - -void TurnOffTiles::turnOffTile(const Vec2& pos) -{ - Quad3 coords; - - memset(&coords, 0, sizeof(Quad3)); - setTile(pos, coords); -} - -void TurnOffTiles::startWithTarget(Node *target) -{ - TiledGrid3DAction::startWithTarget(target); - - if (_seed != (unsigned int)-1) - { - std::srand(_seed); - } - - _tilesCount = _gridSize.width * _gridSize.height; - _tilesOrder = new unsigned int[_tilesCount]; - - for (unsigned int i = 0; i < _tilesCount; ++i) - { - _tilesOrder[i] = i; - } - - shuffle(_tilesOrder, _tilesCount); -} - -void TurnOffTiles::update(float time) -{ - unsigned int l = (unsigned int)(time * (float)_tilesCount); - - unsigned int t = 0; - for (unsigned int i = 0; i < _tilesCount; i++ ) - { - t = _tilesOrder[i]; - Vec2 tilePos( (unsigned int)(t / _gridSize.height), t % (unsigned int)_gridSize.height ); - - if ( i < l ) - { - turnOffTile(tilePos); - } - else - { - turnOnTile(tilePos); - } - } -} - -// implementation of WavesTiles3D - -WavesTiles3D* WavesTiles3D::create(float duration, const Size& gridSize, unsigned int waves, float amplitude) -{ - WavesTiles3D *action = new (std::nothrow) WavesTiles3D(); - - if (action && action->initWithDuration(duration, gridSize, waves, amplitude)) - { - action->autorelease(); - return action; - } - - delete action; - return nullptr; -} - -bool WavesTiles3D::initWithDuration(float duration, const Size& gridSize, unsigned int waves, float amplitude) -{ - if (TiledGrid3DAction::initWithDuration(duration, gridSize)) - { - _waves = waves; - _amplitude = amplitude; - _amplitudeRate = 1.0f; - - return true; - } - - return false; -} - -WavesTiles3D* WavesTiles3D::clone() const -{ - // no copy constructor - return WavesTiles3D::create(_duration, _gridSize, _waves, _amplitude); -} - -void WavesTiles3D::update(float time) -{ - for (int i = 0; i < _gridSize.width; i++ ) - { - for (int j = 0; j < _gridSize.height; j++ ) - { - Quad3 coords = getOriginalTile(Vec2(i, j)); - - coords.bl.z = (sinf(time * (float)M_PI *_waves * 2 + - (coords.bl.y+coords.bl.x) * .01f) * _amplitude * _amplitudeRate ); - coords.br.z = coords.bl.z; - coords.tl.z = coords.bl.z; - coords.tr.z = coords.bl.z; - - setTile(Vec2(i, j), coords); - } - } -} - -// implementation of JumpTiles3D - -JumpTiles3D* JumpTiles3D::create(float duration, const Size& gridSize, unsigned int numberOfJumps, float amplitude) -{ - JumpTiles3D *action = new (std::nothrow) JumpTiles3D(); - - if (action && action->initWithDuration(duration, gridSize, numberOfJumps, amplitude)) - { - action->autorelease(); - return action; - } - - delete action; - return nullptr; -} - -bool JumpTiles3D::initWithDuration(float duration, const Size& gridSize, unsigned int numberOfJumps, float amplitude) -{ - if (TiledGrid3DAction::initWithDuration(duration, gridSize)) - { - _jumps = numberOfJumps; - _amplitude = amplitude; - _amplitudeRate = 1.0f; - - return true; - } - - return false; -} - -JumpTiles3D* JumpTiles3D::clone() const -{ - // no copy constructor - return JumpTiles3D::create(_duration, _gridSize, _jumps, _amplitude); -} - -void JumpTiles3D::update(float time) -{ - float sinz = (sinf((float)M_PI * time * _jumps * 2) * _amplitude * _amplitudeRate ); - float sinz2 = (sinf((float)M_PI * (time * _jumps * 2 + 1)) * _amplitude * _amplitudeRate ); - - for (int i = 0; i < _gridSize.width; i++ ) - { - for (int j = 0; j < _gridSize.height; j++ ) - { - Quad3 coords = getOriginalTile(Vec2(i, j)); - - if ( ((i+j) % 2) == 0 ) - { - coords.bl.z += sinz; - coords.br.z += sinz; - coords.tl.z += sinz; - coords.tr.z += sinz; - } - else - { - coords.bl.z += sinz2; - coords.br.z += sinz2; - coords.tl.z += sinz2; - coords.tr.z += sinz2; - } - - setTile(Vec2(i, j), coords); - } - } -} - -// implementation of SplitRows - -SplitRows* SplitRows::create(float duration, unsigned int nRows) -{ - SplitRows *action = new (std::nothrow) SplitRows(); - - if (action && action->initWithDuration(duration, nRows)) - { - action->autorelease(); - return action; - } - - delete action; - return nullptr; -} - -bool SplitRows::initWithDuration(float duration, unsigned int rows) -{ - _rows = rows; - - return TiledGrid3DAction::initWithDuration(duration, Size(1, rows)); -} - -SplitRows* SplitRows::clone() const -{ - // no copy constructor - return SplitRows::create(_duration, _rows); -} - -void SplitRows::startWithTarget(Node *target) -{ - TiledGrid3DAction::startWithTarget(target); - _winSize = Director::getInstance()->getWinSizeInPixels(); -} - -void SplitRows::update(float time) -{ - for (unsigned int j = 0; j < _gridSize.height; ++j) - { - Quad3 coords = getOriginalTile(Vec2(0, j)); - float direction = 1; - - if ( (j % 2 ) == 0 ) - { - direction = -1; - } - - coords.bl.x += direction * _winSize.width * time; - coords.br.x += direction * _winSize.width * time; - coords.tl.x += direction * _winSize.width * time; - coords.tr.x += direction * _winSize.width * time; - - setTile(Vec2(0, j), coords); - } -} - -// implementation of SplitCols - -SplitCols* SplitCols::create(float duration, unsigned int cols) -{ - SplitCols *action = new (std::nothrow) SplitCols(); - - if (action && action->initWithDuration(duration, cols)) - { - action->autorelease(); - return action; - } - - delete action; - return nullptr; -} - -bool SplitCols::initWithDuration(float duration, unsigned int cols) -{ - _cols = cols; - return TiledGrid3DAction::initWithDuration(duration, Size(cols, 1)); -} - -SplitCols* SplitCols::clone() const -{ - // no copy constructor - return SplitCols::create(_duration, _cols); -} - -void SplitCols::startWithTarget(Node *target) -{ - TiledGrid3DAction::startWithTarget(target); - _winSize = Director::getInstance()->getWinSizeInPixels(); -} - -void SplitCols::update(float time) -{ - for (unsigned int i = 0; i < _gridSize.width; ++i) - { - Quad3 coords = getOriginalTile(Vec2(i, 0)); - float direction = 1; - - if ( (i % 2 ) == 0 ) - { - direction = -1; - } - - coords.bl.y += direction * _winSize.height * time; - coords.br.y += direction * _winSize.height * time; - coords.tl.y += direction * _winSize.height * time; - coords.tr.y += direction * _winSize.height * time; - - setTile(Vec2(i, 0), coords); - } -} - -NS_CC_END - diff --git a/native/cocos/2d/CCActionTiledGrid.h b/native/cocos/2d/CCActionTiledGrid.h deleted file mode 100644 index fc6439bc0e..0000000000 --- a/native/cocos/2d/CCActionTiledGrid.h +++ /dev/null @@ -1,611 +0,0 @@ -/**************************************************************************** -Copyright (c) 2009 On-Core -Copyright (c) 2010-2012 cocos2d-x.org -CopyRight (c) 2013-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ -#ifndef __ACTION_CCTILEDGRID_ACTION_H__ -#define __ACTION_CCTILEDGRID_ACTION_H__ - -#include "2d/CCActionGrid.h" - -NS_CC_BEGIN - -/** - * @addtogroup actions - * @{ - */ - -/** -@brief ShakyTiles3D action. -@details This action is make the target node shake with many tiles. - You can create the action by these parameters: - duration, grid size, range, whether shake on the z axis. - */ -class CC_DLL ShakyTiles3D : public TiledGrid3DAction -{ -public: - /** - @brief Create the action with a range, shake Z vertices, a grid and duration. - @param duration Specify the duration of the ShakyTiles3D action. It's a value in seconds. - @param gridSize Specify the size of the grid. - @param range Specify the range of the shaky effect. - @param shakeZ Specify whether shake on the z axis. - @return If the creation success, return a pointer of ShakyTiles3D action; otherwise, return nil. - */ - static ShakyTiles3D* create(float duration, const Size& gridSize, int range, bool shakeZ); - - // Override - virtual ShakyTiles3D* clone() const override; - virtual void update(float time) override; - -CC_CONSTRUCTOR_ACCESS: - ShakyTiles3D() {} - virtual ~ShakyTiles3D() {} - - /** - @brief Initializes the action with a range, shake Z vertices, grid size and duration. - @param duration Specify the duration of the ShakyTiles3D action. It's a value in seconds. - @param gridSize Specify the size of the grid. - @param range Specify the range of the shaky effect. - @param shakeZ Specify whether shake on the z axis. - @return If the Initialization success, return true; otherwise, return false. - */ - bool initWithDuration(float duration, const Size& gridSize, int range, bool shakeZ); - -protected: - int _randrange; - bool _shakeZ; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(ShakyTiles3D); -}; - -/** -@brief ShatteredTiles3D action. -@details This action make the target node shattered with many tiles. - You can create the action by these parameters: - duration, grid size, range, whether shatter on the z axis. -*/ -class CC_DLL ShatteredTiles3D : public TiledGrid3DAction -{ -public: - /** - * @brief Create the action with a range, whether of not to shatter Z vertices, grid size and duration. - * @param duration Specify the duration of the ShatteredTiles3D action. It's a value in seconds. - * @param gridSize Specify the size of the grid. - * @param range Specify the range of the shatter effect. - * @param shatterZ Specify whether shatter on the z axis. - * @return If the creation success, return a pointer of ShatteredTiles3D action; otherwise, return nil. - */ - static ShatteredTiles3D* create(float duration, const Size& gridSize, int range, bool shatterZ); - - // Override - virtual ShatteredTiles3D* clone() const override; - virtual void update(float time) override; - -CC_CONSTRUCTOR_ACCESS: - ShatteredTiles3D() {} - virtual ~ShatteredTiles3D() {} - - /** - @brief Initializes the action with a range, shatter Z vertices, grid size and duration. - @param duration Specify the duration of the ShatteredTiles3D action. It's a value in seconds. - @param gridSize Specify the size of the grid. - @param range Specify the range of the shatter effect. - @param shatterZ Specify whether shake on the z axis. - @return If the Initialization success, return true; otherwise, return false. - */ - bool initWithDuration(float duration, const Size& gridSize, int range, bool shatterZ); - -protected: - int _randrange; - bool _once; - bool _shatterZ; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(ShatteredTiles3D); -}; - -struct Tile; -/** -@brief ShuffleTiles action. -@details This action make the target node shuffle with many tiles in random order. - You can create the action by these parameters: - duration, grid size, the random seed. -*/ -class CC_DLL ShuffleTiles : public TiledGrid3DAction -{ -public: - /** - * @brief Create the action with grid size, random seed and duration. - * @param duration Specify the duration of the ShuffleTiles action. It's a value in seconds. - * @param gridSize Specify the size of the grid. - * @param seed Specify the random seed. - * @return If the creation success, return a pointer of ShuffleTiles action; otherwise, return nil. - */ - static ShuffleTiles* create(float duration, const Size& gridSize, unsigned int seed); - - void shuffle(unsigned int *array, unsigned int len); - Size getDelta(const Size& pos) const; - void placeTile(const Vec2& pos, Tile *t); - - // Overrides - virtual void startWithTarget(Node *target) override; - virtual void update(float time) override; - virtual ShuffleTiles* clone() const override; - -CC_CONSTRUCTOR_ACCESS: - ShuffleTiles() {} - virtual ~ShuffleTiles(); - - /** - * @brief Initializes the action with grid size, random seed and duration. - * @param duration Specify the duration of the ShuffleTiles action. It's a value in seconds. - * @param gridSize Specify the size of the grid. - * @param seed Specify the random seed. - * @return If the Initialization success, return true; otherwise, return false. - */ - bool initWithDuration(float duration, const Size& gridSize, unsigned int seed); - -protected: - unsigned int _seed; - unsigned int _tilesCount; - unsigned int* _tilesOrder; - Tile* _tiles; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(ShuffleTiles); -}; - -/** -@brief FadeOutTRTiles action. -@details Fades out the target node with many tiles from Bottom-Left to Top-Right. - */ -class CC_DLL FadeOutTRTiles : public TiledGrid3DAction -{ -public: - /** - * @brief Create the action with the grid size and the duration. - * @param duration Specify the duration of the FadeOutTRTiles action. It's a value in seconds. - * @param gridSize Specify the size of the grid. - * @return If the creation success, return a pointer of FadeOutTRTiles action; otherwise, return nil. - */ - static FadeOutTRTiles* create(float duration, const Size& gridSize); - - /** - @brief Calculate the percentage a tile should be shown. - @param pos The position index of the tile. - @param time The current percentage of the action. - @return Return the percentage the tile should be shown. - */ - virtual float testFunc(const Size& pos, float time); - - /** - @brief Show the tile at specified position. - @param pos The position index of the tile should be shown. - */ - void turnOnTile(const Vec2& pos); - - /** - @brief Hide the tile at specified position. - @param pos The position index of the tile should be hide. - */ - void turnOffTile(const Vec2& pos); - - /** - @brief Show part of the tile. - @param pos The position index of the tile should be shown. - @param distance The percentage that the tile should be shown. - */ - virtual void transformTile(const Vec2& pos, float distance); - - // Overrides - virtual void update(float time) override; - virtual FadeOutTRTiles* clone() const override; - -CC_CONSTRUCTOR_ACCESS: - FadeOutTRTiles() {} - virtual ~FadeOutTRTiles() {} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(FadeOutTRTiles); -}; - -/** -@brief FadeOutBLTiles action. -@details Fades out the target node with many tiles from Top-Right to Bottom-Left. - */ -class CC_DLL FadeOutBLTiles : public FadeOutTRTiles -{ -public: - /** - * @brief Create the action with the grid size and the duration. - * @param duration Specify the duration of the FadeOutBLTiles action. It's a value in seconds. - * @param gridSize Specify the size of the grid. - * @return If the creation success, return a pointer of FadeOutBLTiles action; otherwise, return nil. - */ - static FadeOutBLTiles* create(float duration, const Size& gridSize); - - // Overrides - virtual float testFunc(const Size& pos, float time) override; - virtual FadeOutBLTiles* clone() const override; - -CC_CONSTRUCTOR_ACCESS: - FadeOutBLTiles() {} - virtual ~FadeOutBLTiles() {} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(FadeOutBLTiles); -}; - -/** -@brief FadeOutUpTiles action. -@details Fades out the target node with many tiles from bottom to top. - */ -class CC_DLL FadeOutUpTiles : public FadeOutTRTiles -{ -public: - /** - * @brief Create the action with the grid size and the duration. - * @param duration Specify the duration of the FadeOutUpTiles action. It's a value in seconds. - * @param gridSize Specify the size of the grid. - * @return If the creation success, return a pointer of FadeOutUpTiles action; otherwise, return nil. - */ - static FadeOutUpTiles* create(float duration, const Size& gridSize); - - virtual void transformTile(const Vec2& pos, float distance) override; - - // Overrides - virtual FadeOutUpTiles* clone() const override; - virtual float testFunc(const Size& pos, float time) override; - -CC_CONSTRUCTOR_ACCESS: - FadeOutUpTiles() {} - virtual ~FadeOutUpTiles() {} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(FadeOutUpTiles); -}; - -/** -@brief FadeOutDownTiles action. -@details Fades out the target node with many tiles from top to bottom. - */ -class CC_DLL FadeOutDownTiles : public FadeOutUpTiles -{ -public: - /** - * @brief Create the action with the grid size and the duration. - * @param duration Specify the duration of the FadeOutDownTiles action. It's a value in seconds. - * @param gridSize Specify the size of the grid. - * @return If the creation success, return a pointer of FadeOutDownTiles action; otherwise, return nil. - */ - static FadeOutDownTiles* create(float duration, const Size& gridSize); - - // Overrides - virtual FadeOutDownTiles* clone() const override; - virtual float testFunc(const Size& pos, float time) override; - -CC_CONSTRUCTOR_ACCESS: - FadeOutDownTiles() {} - virtual ~FadeOutDownTiles() {} - -private: - CC_DISALLOW_COPY_AND_ASSIGN(FadeOutDownTiles); -}; - -/** -@brief TurnOffTiles action. -@details Turn off the target node with many tiles in random order. - */ -class CC_DLL TurnOffTiles : public TiledGrid3DAction -{ -public: - /** - * @brief Create the action with the grid size and the duration. - * @param duration Specify the duration of the TurnOffTiles action. It's a value in seconds. - * @param gridSize Specify the size of the grid. - * @return If the creation success, return a pointer of TurnOffTiles action; otherwise, return nil. - */ - static TurnOffTiles* create(float duration, const Size& gridSize); - /** - * @brief Create the action with the grid size and the duration. - * @param duration Specify the duration of the TurnOffTiles action. It's a value in seconds. - * @param gridSize Specify the size of the grid. - * @param seed Specify the random seed. - * @return If the creation success, return a pointer of TurnOffTiles action; otherwise, return nil. - */ - static TurnOffTiles* create(float duration, const Size& gridSize, unsigned int seed); - - /** - @brief Shuffle the array specified. - @param array The array will be shuffled. - @param len The size of the array. - */ - void shuffle(unsigned int *array, unsigned int len); - - /** - @brief Show the tile at specified position. - @param pos The position index of the tile should be shown. - */ - void turnOnTile(const Vec2& pos); - - /** - @brief Hide the tile at specified position. - @param pos The position index of the tile should be hide. - */ - void turnOffTile(const Vec2& pos); - - // Overrides - virtual TurnOffTiles* clone() const override; - virtual void startWithTarget(Node *target) override; - virtual void update(float time) override; - -CC_CONSTRUCTOR_ACCESS: - TurnOffTiles() {} - virtual ~TurnOffTiles(); - - /** - * @brief Initializes the action with grid size, random seed and duration. - * @param duration Specify the duration of the TurnOffTiles action. It's a value in seconds. - * @param gridSize Specify the size of the grid. - * @param seed Specify the random seed. - * @return If the Initialization success, return true; otherwise, return false. - */ - bool initWithDuration(float duration, const Size& gridSize, unsigned int seed); - -protected: - unsigned int _seed; - unsigned int _tilesCount; - unsigned int* _tilesOrder; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(TurnOffTiles); -}; - -/** -@brief WavesTiles3D action. -@details This action wave the target node with many tiles. -*/ -class CC_DLL WavesTiles3D : public TiledGrid3DAction -{ -public: - /** - * @brief Create the action with a number of waves, the waves amplitude, the grid size and the duration. - * @param duration Specify the duration of the WavesTiles3D action. It's a value in seconds. - * @param gridSize Specify the size of the grid. - * @param waves Specify the waves count of the WavesTiles3D action. - * @param amplitude Specify the amplitude of the WavesTiles3D action. - * @return If the creation success, return a pointer of WavesTiles3D action; otherwise, return nil. - */ - static WavesTiles3D* create(float duration, const Size& gridSize, unsigned int waves, float amplitude); - - /** - @brief Get the amplitude of the effect. - @return Return the amplitude of the effect. - */ - inline float getAmplitude() const { return _amplitude; } - /** - @brief Set the amplitude to the effect. - @param amplitude The value of amplitude will be set. - */ - inline void setAmplitude(float amplitude) { _amplitude = amplitude; } - - /** - @brief Get the amplitude rate of the effect. - @return Return the amplitude rate of the effect. - */ - inline float getAmplitudeRate() const { return _amplitudeRate; } - /** - @brief Set the amplitude rate of the effect. - @param amplitudeRate The value of amplitude rate will be set. - */ - inline void setAmplitudeRate(float amplitudeRate) { _amplitudeRate = amplitudeRate; } - - // Override - virtual WavesTiles3D* clone() const override; - virtual void update(float time) override; - -CC_CONSTRUCTOR_ACCESS: - WavesTiles3D() {} - virtual ~WavesTiles3D() {} - - /** - @brief Initializes an action with duration, grid size, waves count and amplitude. - @param duration Specify the duration of the WavesTiles3D action. It's a value in seconds. - @param gridSize Specify the size of the grid. - @param waves Specify the waves count of the WavesTiles3D action. - @param amplitude Specify the amplitude of the WavesTiles3D action. - @return If the initialization success, return true; otherwise, return false. - */ - bool initWithDuration(float duration, const Size& gridSize, unsigned int waves, float amplitude); - -protected: - unsigned int _waves; - float _amplitude; - float _amplitudeRate; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(WavesTiles3D); -}; - -/** -@brief JumpTiles3D action. -@details Move the tiles of a target node across the Z axis. -*/ -class CC_DLL JumpTiles3D : public TiledGrid3DAction -{ -public: - /** - * @brief Create the action with the number of jumps, the sin amplitude, the grid size and the duration. - * @param duration Specify the duration of the JumpTiles3D action. It's a value in seconds. - * @param gridSize Specify the size of the grid. - * @param numberOfJumps Specify the jump tiles count. - * @param amplitude Specify the amplitude of the JumpTiles3D action. - * @return If the creation success, return a pointer of JumpTiles3D action; otherwise, return nil. - */ - static JumpTiles3D* create(float duration, const Size& gridSize, unsigned int numberOfJumps, float amplitude); - - /** - @brief Get the amplitude of the effect. - @return Return the amplitude of the effect. - */ - inline float getAmplitude() const { return _amplitude; } - /** - @brief Set the amplitude to the effect. - @param amplitude The value of amplitude will be set. - */ - inline void setAmplitude(float amplitude) { _amplitude = amplitude; } - - /** - @brief Get the amplitude rate of the effect. - @return Return the amplitude rate of the effect. - */ - inline float getAmplitudeRate() const { return _amplitudeRate; } - /** - @brief Set the amplitude rate of the effect. - @param amplitudeRate The value of amplitude rate will be set. - */ - inline void setAmplitudeRate(float amplitudeRate) { _amplitudeRate = amplitudeRate; } - - // Override - virtual JumpTiles3D* clone() const override; - virtual void update(float time) override; - -CC_CONSTRUCTOR_ACCESS: - JumpTiles3D() {} - virtual ~JumpTiles3D() {} - - /** - * @brief Initializes the action with the number of jumps, the sin amplitude, the grid size and the duration. - * @param duration Specify the duration of the JumpTiles3D action. It's a value in seconds. - * @param gridSize Specify the size of the grid. - * @param numberOfJumps Specify the jump tiles count. - * @param amplitude Specify the amplitude of the JumpTiles3D action. - * @return If the initialization success, return true; otherwise, return false. - */ - bool initWithDuration(float duration, const Size& gridSize, unsigned int numberOfJumps, float amplitude); - -protected: - unsigned int _jumps; - float _amplitude; - float _amplitudeRate; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(JumpTiles3D); -}; - -/** -@brief SplitRows action. -@details Split the target node in many rows. - Then move out some rows from left, move out the other rows from right. -*/ -class CC_DLL SplitRows : public TiledGrid3DAction -{ -public : - /** - * @brief Create the action with the number of rows and the duration. - * @param duration Specify the duration of the SplitRows action. It's a value in seconds. - * @param rows Specify the rows count should be split. - * @return If the creation success, return a pointer of SplitRows action; otherwise, return nil. - */ - static SplitRows* create(float duration, unsigned int rows); - - // Overrides - virtual SplitRows* clone() const override; - virtual void update(float time) override; - virtual void startWithTarget(Node *target) override; - -CC_CONSTRUCTOR_ACCESS: - SplitRows() {} - virtual ~SplitRows() {} - - /** - * @brief Initializes the action with the number rows and the duration. - * @param duration Specify the duration of the SplitRows action. It's a value in seconds. - * @param rows Specify the rows count should be split. - * @return If the creation success, return true; otherwise, return false. - */ - bool initWithDuration(float duration, unsigned int rows); - -protected: - unsigned int _rows; - Size _winSize; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(SplitRows); -}; - -/** -@brief SplitCols action. -@details Split the target node in many columns. - Then move out some columns from top, move out the other columns from bottom. -*/ -class CC_DLL SplitCols : public TiledGrid3DAction -{ -public: - - /** - * @brief Create the action with the number of columns and the duration. - * @param duration Specify the duration of the SplitCols action. It's a value in seconds. - * @param cols Specify the columns count should be split. - * @return If the creation success, return a pointer of SplitCols action; otherwise, return nil. - */ - static SplitCols* create(float duration, unsigned int cols); - - // Overrides - virtual SplitCols* clone() const override; - /** - * @param time in seconds - */ - virtual void update(float time) override; - virtual void startWithTarget(Node *target) override; - -CC_CONSTRUCTOR_ACCESS: - SplitCols() {} - virtual ~SplitCols() {} - - /** - * @brief Initializes the action with the number columns and the duration. - * @param duration Specify the duration of the SplitCols action. It's a value in seconds. - * @param cols Specify the columns count should be split. - * @return If the creation success, return true; otherwise, return false. - */ - bool initWithDuration(float duration, unsigned int cols); - -protected: - unsigned int _cols; - Size _winSize; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(SplitCols); -}; - -// end of actions group -/// @} - -NS_CC_END - -#endif // __ACTION_CCTILEDGRID_ACTION_H__ - diff --git a/native/cocos/2d/CCActionTween.cpp b/native/cocos/2d/CCActionTween.cpp deleted file mode 100644 index 881e3174bc..0000000000 --- a/native/cocos/2d/CCActionTween.cpp +++ /dev/null @@ -1,81 +0,0 @@ -/**************************************************************************** -Copyright (c) 2009 lhunath (Maarten Billemont) -Copyright (c) 2010-2012 cocos2d-x.org -CopyRight (c) 2013-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ - -#include "2d/CCActionTween.h" - -NS_CC_BEGIN - -ActionTween* ActionTween::create(float duration, const std::string& key, float from, float to) -{ - ActionTween* ret = new (std::nothrow) ActionTween(); - if (ret && ret->initWithDuration(duration, key, from, to)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -bool ActionTween::initWithDuration(float duration, const std::string& key, float from, float to) -{ - if (ActionInterval::initWithDuration(duration)) - { - _key = key; - _to = to; - _from = from; - return true; - } - - return false; -} - -ActionTween *ActionTween::clone() const -{ - return ActionTween::create(_duration, _key, _from, _to); -} - -void ActionTween::startWithTarget(Node *target) -{ - CCASSERT(dynamic_cast(target), "target must implement ActionTweenDelegate"); - ActionInterval::startWithTarget(target); - _delta = _to - _from; -} - -void ActionTween::update(float dt) -{ - dynamic_cast(_target)->updateTweenAction(_to - _delta * (1 - dt), _key); -} - -ActionTween* ActionTween::reverse() const -{ - return ActionTween::create(_duration, _key, _to, _from); -} - -NS_CC_END - diff --git a/native/cocos/2d/CCActionTween.h b/native/cocos/2d/CCActionTween.h deleted file mode 100644 index 8ea660a9cf..0000000000 --- a/native/cocos/2d/CCActionTween.h +++ /dev/null @@ -1,127 +0,0 @@ -/**************************************************************************** -Copyright (c) 2009 lhunath (Maarten Billemont) -Copyright (c) 2010-2012 cocos2d-x.org -CopyRight (c) 2013-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ -#ifndef __CCACTIONTWEEN_H__ -#define __CCACTIONTWEEN_H__ - -#include "2d/CCActionInterval.h" - -NS_CC_BEGIN - -/** - * @addtogroup actions - * @{ - */ - -/** -@brief The delegate class for ActionTween. -@details If you want to use ActionTween on a node. - You should implement the node follow these steps: - 1. The node should be inherit from ActionTweenDelegate. - 2. Override the virtual method updateTweenAction in the node. - - Then once you running ActionTween on the node, the method updateTweenAction will be invoked. -*/ -class CC_DLL ActionTweenDelegate -{ -public: - /** - * @js NA - * @lua NA - */ - virtual ~ActionTweenDelegate() {} - - /** - @brief The callback function when ActionTween is running. - @param value The new value of the specified key. - @param key The key of property which should be updated. - */ - virtual void updateTweenAction(float value, const std::string& key) = 0; -}; - -/** ActionTween - - ActionTween is an action that lets you update any property of an object. - For example, if you want to modify the "width" property of a target from 200 to 300 in 2 seconds, then: - - @code - auto modifyWidth = ActionTween::create(2, "width", 200, 300); - target->runAction(modifyWidth); - @endcode - - Another example: ScaleTo action could be rewritten using PropertyAction: - - @code - // scaleA and scaleB are equivalents - auto scaleA = ScaleTo::create(2, 3); // (duration, to) - auto scaleB = ActionTween::create(2, "scale", 1, 3); // (duration, key, from, to) - @endcode - - @since v0.99.2 - */ -class CC_DLL ActionTween : public ActionInterval -{ -public: - /** - * @brief Create and initializes the action with the property name (key), and the from and to parameters. - * @param duration The duration of the ActionTween. It's a value in seconds. - * @param key The key of property which should be updated. - * @param from The value of the specified property when the action begin. - * @param to The value of the specified property when the action end. - * @return If the creation success, return a pointer of ActionTween; otherwise, return nil. - */ - static ActionTween* create(float duration, const std::string& key, float from, float to); - - // Overrides - void startWithTarget(Node *target) override; - void update(float dt) override; - ActionTween* reverse() const override; - ActionTween *clone() const override; - -CC_CONSTRUCTOR_ACCESS: - /** - * @brief Initializes the action with the property name (key), and the from and to parameters. - * @param duration The duration of the ActionTween. It's a value in seconds. - * @param key The key of property which should be updated. - * @param from The value of the specified property when the action begin. - * @param to The value of the specified property when the action end. - * @return If the initialization success, return true; otherwise, return false. - */ - bool initWithDuration(float duration, const std::string& key, float from, float to); - -protected: - std::string _key; - float _from, _to; - float _delta; -}; - -// end of actions group -/// @} - -NS_CC_END - -#endif /* __CCACTIONTWEEN_H__ */ - diff --git a/native/cocos/2d/CCAnimation.cpp b/native/cocos/2d/CCAnimation.cpp deleted file mode 100644 index 9da448aaf2..0000000000 --- a/native/cocos/2d/CCAnimation.cpp +++ /dev/null @@ -1,204 +0,0 @@ -/**************************************************************************** -Copyright (c) 2008-2010 Ricardo Quesada -Copyright (c) 2010-2012 cocos2d-x.org -Copyright (c) 2011 Zynga Inc. -CopyRight (c) 2013-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ -#include "2d/CCAnimation.h" -#include "renderer/CCTextureCache.h" -#include "renderer/CCTexture2D.h" -#include "base/CCDirector.h" - -NS_CC_BEGIN - -AnimationFrame* AnimationFrame::create(SpriteFrame* spriteFrame, float delayUnits, const ValueMap& userInfo) -{ - auto ret = new (std::nothrow) AnimationFrame(); - if (ret && ret->initWithSpriteFrame(spriteFrame, delayUnits, userInfo)) - { - ret->autorelease(); - } - else - { - CC_SAFE_DELETE(ret); - } - return ret; -} - -AnimationFrame::AnimationFrame() -: _spriteFrame(nullptr) -, _delayUnits(0.0f) -{ - -} - -bool AnimationFrame::initWithSpriteFrame(SpriteFrame* spriteFrame, float delayUnits, const ValueMap& userInfo) -{ - setSpriteFrame(spriteFrame); - setDelayUnits(delayUnits); - setUserInfo(userInfo); - - return true; -} - -AnimationFrame::~AnimationFrame() -{ - CCLOGINFO( "deallocing AnimationFrame: %p", this); - - CC_SAFE_RELEASE(_spriteFrame); -} - -AnimationFrame* AnimationFrame::clone() const -{ - // no copy constructor - auto frame = new (std::nothrow) AnimationFrame(); - frame->initWithSpriteFrame(_spriteFrame->clone(), - _delayUnits, - _userInfo); - - frame->autorelease(); - return frame; -} - -// implementation of Animation - -Animation* Animation::create() -{ - Animation *animation = new (std::nothrow) Animation(); - animation->init(); - animation->autorelease(); - - return animation; -} - -Animation* Animation::createWithSpriteFrames(const Vector& frames, float delay/* = 0.0f*/, unsigned int loops/* = 1*/) -{ - Animation *animation = new (std::nothrow) Animation(); - animation->initWithSpriteFrames(frames, delay, loops); - animation->autorelease(); - - return animation; -} - -Animation* Animation::create(const Vector& arrayOfAnimationFrameNames, float delayPerUnit, unsigned int loops /* = 1 */) -{ - Animation *animation = new (std::nothrow) Animation(); - animation->initWithAnimationFrames(arrayOfAnimationFrameNames, delayPerUnit, loops); - animation->autorelease(); - return animation; -} - -bool Animation::init() -{ - _loops = 1; - _delayPerUnit = 0.0f; - - return true; -} - -bool Animation::initWithSpriteFrames(const Vector& frames, float delay/* = 0.0f*/, unsigned int loops/* = 1*/) -{ - _delayPerUnit = delay; - _loops = loops; - - for (auto& spriteFrame : frames) - { - auto animFrame = AnimationFrame::create(spriteFrame, 1, ValueMap()); - _frames.pushBack(animFrame); - _totalDelayUnits++; - } - - return true; -} - -bool Animation::initWithAnimationFrames(const Vector& arrayOfAnimationFrames, float delayPerUnit, unsigned int loops) -{ - _delayPerUnit = delayPerUnit; - _loops = loops; - - setFrames(arrayOfAnimationFrames); - - for (auto& animFrame : _frames) - { - _totalDelayUnits += animFrame->getDelayUnits(); - } - return true; -} - -Animation::Animation() -: _totalDelayUnits(0.0f) -, _delayPerUnit(0.0f) -, _duration(0.0f) -, _restoreOriginalFrame(false) -, _loops(0) -{ - -} - -Animation::~Animation(void) -{ - CCLOGINFO("deallocing Animation: %p", this); -} - -void Animation::addSpriteFrame(SpriteFrame* spriteFrame) -{ - AnimationFrame *animFrame = AnimationFrame::create(spriteFrame, 1.0f, ValueMap()); - _frames.pushBack(animFrame); - - // update duration - _totalDelayUnits++; -} - -void Animation::addSpriteFrameWithFile(const std::string& filename) -{ - Texture2D *texture = Director::getInstance()->getTextureCache()->addImage(filename); - Rect rect = Rect::ZERO; - rect.size = texture->getContentSize(); - SpriteFrame *frame = SpriteFrame::createWithTexture(texture, rect); - addSpriteFrame(frame); -} - -void Animation::addSpriteFrameWithTexture(Texture2D *pobTexture, const Rect& rect) -{ - SpriteFrame *frame = SpriteFrame::createWithTexture(pobTexture, rect); - addSpriteFrame(frame); -} - -float Animation::getDuration(void) const -{ - return _totalDelayUnits * _delayPerUnit; -} - -Animation* Animation::clone() const -{ - // no copy constructor - auto a = new (std::nothrow) Animation(); - a->initWithAnimationFrames(_frames, _delayPerUnit, _loops); - a->setRestoreOriginalFrame(_restoreOriginalFrame); - a->autorelease(); - return a; -} - -NS_CC_END - diff --git a/native/cocos/2d/CCAnimation.h b/native/cocos/2d/CCAnimation.h deleted file mode 100644 index dd772e7b15..0000000000 --- a/native/cocos/2d/CCAnimation.h +++ /dev/null @@ -1,326 +0,0 @@ -/**************************************************************************** -Copyright (c) 2008-2010 Ricardo Quesada -Copyright (c) 2010-2012 cocos2d-x.org -Copyright (c) 2011 Zynga Inc. -CopyRight (c) 2013-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ -#ifndef __CC_ANIMATION_H__ -#define __CC_ANIMATION_H__ - -#include "platform/CCPlatformConfig.h" -#include "base/CCRef.h" -#include "base/CCValue.h" -#include "base/CCVector.h" -#include "2d/CCSpriteFrame.h" - -#include - -NS_CC_BEGIN - -class Texture2D; -class SpriteFrame; - -/** - * @addtogroup _2d - * @{ - */ - -/** @class AnimationFrame - * - * A frame of the animation. It contains information like: - * - sprite frame name. - * - # of delay units. - * - offset - - @since v2.0 - */ -class CC_DLL AnimationFrame : public Ref, public Clonable -{ -public: - /** @struct DisplayedEventInfo - * When the animation display,Dispatches the event of UserData. - */ - struct DisplayedEventInfo - { - Node* target; - const ValueMap* userInfo; - }; - - /** - * Creates the animation frame with a spriteframe, number of delay units and a notification user info. - * - * @param spriteFrame The animation frame with a spriteframe. - * @param delayUnits Number of delay units. - * @param userInfo A notification user info. - * @since 3.0 - */ - static AnimationFrame* create(SpriteFrame* spriteFrame, float delayUnits, const ValueMap& userInfo); - /** Return a SpriteFrameName to be used. - * - * @return a SpriteFrameName to be used. - */ - SpriteFrame* getSpriteFrame() const { return _spriteFrame; }; - /** Set the SpriteFrame. - * - * @param frame A SpriteFrame will be used. - */ - void setSpriteFrame(SpriteFrame* frame) - { - CC_SAFE_RETAIN(frame); - CC_SAFE_RELEASE(_spriteFrame); - _spriteFrame = frame; - } - - /** Gets the units of time the frame takes. - * - * @return The units of time the frame takes. - */ - float getDelayUnits() const { return _delayUnits; }; - - /** Sets the units of time the frame takes. - * - * @param delayUnits The units of time the frame takes. - */ - void setDelayUnits(float delayUnits) { _delayUnits = delayUnits; }; - - /** @brief Gets user information - * A AnimationFrameDisplayedNotification notification will be broadcast when the frame is displayed with this dictionary as UserInfo. - * If UserInfo is nil, then no notification will be broadcast. - * - * @return A dictionary as UserInfo - */ - const ValueMap& getUserInfo() const { return _userInfo; }; - ValueMap& getUserInfo() { return _userInfo; }; - - /** Sets user information. - * @param userInfo A dictionary as UserInfo. - */ - void setUserInfo(const ValueMap& userInfo) - { - _userInfo = userInfo; - } - - // Overrides - virtual AnimationFrame *clone() const override; - -CC_CONSTRUCTOR_ACCESS: - /** - * @js ctor - */ - AnimationFrame(); - /** - * @js NA - * @lua NA - */ - virtual ~AnimationFrame(); - - /** initializes the animation frame with a spriteframe, number of delay units and a notification user info */ - bool initWithSpriteFrame(SpriteFrame* spriteFrame, float delayUnits, const ValueMap& userInfo); - -protected: - - /** SpriteFrameName to be used */ - SpriteFrame* _spriteFrame; - - /** how many units of time the frame takes */ - float _delayUnits; - - /** A AnimationFrameDisplayedNotification notification will be broadcast when the frame is displayed with this dictionary as UserInfo. If UserInfo is nil, then no notification will be broadcast. */ - ValueMap _userInfo; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(AnimationFrame); -}; - - - - -/** @class Animation - * A Animation object is used to perform animations on the Sprite objects. - * The Animation object contains AnimationFrame objects, and a possible delay between the frames. - * You can animate a Animation object by using the Animate action. Example: - * @code - * sprite->runAction(Animate::create(animation)); - * @endcode -*/ -class CC_DLL Animation : public Ref, public Clonable -{ -public: - /** Creates an animation. - * @since v0.99.5 - */ - static Animation* create(void); - - /* Creates an animation with an array of SpriteFrame and a delay between frames in seconds. - * The frames will be added with one "delay unit". - * @since v0.99.5 - * @param arrayOfSpriteFrameNames An array of SpriteFrame. - * @param delay A delay between frames in seconds. - * @param loops The times the animation is going to loop. - */ - static Animation* createWithSpriteFrames(const Vector& arrayOfSpriteFrameNames, float delay = 0.0f, unsigned int loops = 1); - - /* Creates an animation with an array of AnimationFrame, the delay per units in seconds and how many times it should be executed. - * @since v2.0 - * @param arrayOfAnimationFrameNames An animation with an array of AnimationFrame. - * @param delayPerUnit The delay per units in seconds and how many times it should be executed. - * @param loops The times the animation is going to loop. - */ - static Animation* create(const Vector& arrayOfAnimationFrameNames, float delayPerUnit, unsigned int loops = 1); - - /** Adds a SpriteFrame to a Animation. - * - * @param frame The frame will be added with one "delay unit". - */ - void addSpriteFrame(SpriteFrame *frame); - - /** Adds a frame with an image filename. Internally it will create a SpriteFrame and it will add it. - * The frame will be added with one "delay unit". - * Added to facilitate the migration from v0.8 to v0.9. - * @param filename The path of SpriteFrame. - */ - void addSpriteFrameWithFile(const std::string& filename); - - /** Adds a frame with a texture and a rect. Internally it will create a SpriteFrame and it will add it. - * The frame will be added with one "delay unit". - * Added to facilitate the migration from v0.8 to v0.9. - * @param pobTexture A frame with a texture. - * @param rect The Texture of rect. - */ - void addSpriteFrameWithTexture(Texture2D* pobTexture, const Rect& rect); - - /** Gets the total Delay units of the Animation. - * - * @return The total Delay units of the Animation. - */ - float getTotalDelayUnits() const { return _totalDelayUnits; }; - - /** Sets the delay in seconds of the "delay unit". - * - * @param delayPerUnit The delay in seconds of the "delay unit". - */ - void setDelayPerUnit(float delayPerUnit) { _delayPerUnit = delayPerUnit; }; - - /** Gets the delay in seconds of the "delay unit". - * - * @return The delay in seconds of the "delay unit". - */ - float getDelayPerUnit() const { return _delayPerUnit; }; - - - /** Gets the duration in seconds of the whole animation. It is the result of totalDelayUnits * delayPerUnit. - * - * @return Result of totalDelayUnits * delayPerUnit. - */ - float getDuration() const; - - /** Gets the array of AnimationFrames. - * - * @return The array of AnimationFrames. - */ - const Vector& getFrames() const { return _frames; }; - - /** Sets the array of AnimationFrames. - * - * @param frames The array of AnimationFrames. - */ - void setFrames(const Vector& frames) - { - _frames = frames; - } - - /** Checks whether to restore the original frame when animation finishes. - * - * @return Restore the original frame when animation finishes. - */ - bool getRestoreOriginalFrame() const { return _restoreOriginalFrame; }; - - /** Sets whether to restore the original frame when animation finishes. - * - * @param restoreOriginalFrame Whether to restore the original frame when animation finishes. - */ - void setRestoreOriginalFrame(bool restoreOriginalFrame) { _restoreOriginalFrame = restoreOriginalFrame; }; - - /** Gets the times the animation is going to loop. 0 means animation is not animated. 1, animation is executed one time, ... - * - * @return The times the animation is going to loop. - */ - unsigned int getLoops() const { return _loops; }; - - /** Sets the times the animation is going to loop. 0 means animation is not animated. 1, animation is executed one time, ... - * - * @param loops The times the animation is going to loop. - */ - void setLoops(unsigned int loops) { _loops = loops; }; - - // overrides - virtual Animation *clone() const override; - -CC_CONSTRUCTOR_ACCESS: - Animation(); - virtual ~Animation(void); - - /** Initializes a Animation. */ - bool init(); - - /** Initializes a Animation with frames and a delay between frames. - * @since v0.99.5 - */ - bool initWithSpriteFrames(const Vector& arrayOfSpriteFrameNames, float delay = 0.0f, unsigned int loops = 1); - - /** Initializes a Animation with AnimationFrame. - * @since v2.0 - */ - bool initWithAnimationFrames(const Vector& arrayOfAnimationFrameNames, float delayPerUnit, unsigned int loops); - -protected: - /** total Delay units of the Animation. */ - float _totalDelayUnits; - - /** Delay in seconds of the "delay unit". */ - float _delayPerUnit; - - /** duration in seconds of the whole animation. It is the result of totalDelayUnits * delayPerUnit. */ - float _duration; - - /** array of AnimationFrames. */ - Vector _frames; - - /** whether or not it shall restore the original frame when the animation finishes. */ - bool _restoreOriginalFrame; - - /** how many times the animation is going to loop. 0 means animation is not animated. 1, animation is executed one time, ... */ - unsigned int _loops; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(Animation); -}; - -// end of sprite_nodes group -/// @} - -NS_CC_END - -#endif // __CC_ANIMATION_H__ - diff --git a/native/cocos/2d/CCAnimationCache.cpp b/native/cocos/2d/CCAnimationCache.cpp deleted file mode 100644 index 2c6a3d1eda..0000000000 --- a/native/cocos/2d/CCAnimationCache.cpp +++ /dev/null @@ -1,250 +0,0 @@ -/**************************************************************************** -Copyright (c) 2008-2010 Ricardo Quesada -Copyright (c) 2010-2012 cocos2d-x.org -Copyright (c) 2011 Zynga Inc. -CopyRight (c) 2013-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ -#include "2d/CCAnimationCache.h" -#include "2d/CCSpriteFrameCache.h" -#include "platform/CCFileUtils.h" - -using namespace std; - -NS_CC_BEGIN - -AnimationCache* AnimationCache::s_sharedAnimationCache = nullptr; - -AnimationCache* AnimationCache::getInstance() -{ - if (! s_sharedAnimationCache) - { - s_sharedAnimationCache = new (std::nothrow) AnimationCache(); - s_sharedAnimationCache->init(); - } - - return s_sharedAnimationCache; -} - -void AnimationCache::destroyInstance() -{ - CC_SAFE_RELEASE_NULL(s_sharedAnimationCache); -} - -bool AnimationCache::init() -{ - return true; -} - -AnimationCache::AnimationCache() -{ -} - -AnimationCache::~AnimationCache() -{ - CCLOGINFO("deallocing AnimationCache: %p", this); -} - -void AnimationCache::addAnimation(Animation *animation, const std::string& name) -{ - _animations.insert(name, animation); -} - -void AnimationCache::removeAnimation(const std::string& name) -{ - if (name.empty()) - return; - - _animations.erase(name); -} - -Animation* AnimationCache::getAnimation(const std::string& name) -{ - return _animations.at(name); -} - -void AnimationCache::parseVersion1(const ValueMap& animations) -{ - SpriteFrameCache *frameCache = SpriteFrameCache::getInstance(); - - for (auto iter = animations.cbegin(); iter != animations.cend(); ++iter) - { - const ValueMap& animationDict = iter->second.asValueMap(); - const ValueVector& frameNames = animationDict.at("frames").asValueVector(); - float delay = animationDict.at("delay").asFloat(); - Animation* animation = nullptr; - - if ( frameNames.empty() ) - { - CCLOG("cocos2d: AnimationCache: Animation '%s' found in dictionary without any frames - cannot add to animation cache.", iter->first.c_str()); - continue; - } - - ssize_t frameNameSize = frameNames.size(); - Vector frames(frameNameSize); - - for (auto& frameName : frameNames) - { - SpriteFrame* spriteFrame = frameCache->getSpriteFrameByName(frameName.asString()); - - if ( ! spriteFrame ) - { - CCLOG("cocos2d: AnimationCache: Animation '%s' refers to frame '%s' which is not currently in the SpriteFrameCache. This frame will not be added to the animation.", iter->first.c_str(), frameName.asString().c_str()); - - continue; - } - - AnimationFrame* animFrame = AnimationFrame::create(spriteFrame, 1, ValueMap()); - frames.pushBack(animFrame); - } - - if ( frames.empty() ) - { - CCLOG("cocos2d: AnimationCache: None of the frames for animation '%s' were found in the SpriteFrameCache. Animation is not being added to the Animation Cache.", iter->first.c_str()); - continue; - } - else if ( frames.size() != frameNameSize ) - { - CCLOG("cocos2d: AnimationCache: An animation in your dictionary refers to a frame which is not in the SpriteFrameCache. Some or all of the frames for the animation '%s' may be missing.", iter->first.c_str()); - } - - animation = Animation::create(frames, delay, 1); - - AnimationCache::getInstance()->addAnimation(animation, iter->first); - } -} - -void AnimationCache::parseVersion2(const ValueMap& animations) -{ - SpriteFrameCache *frameCache = SpriteFrameCache::getInstance(); - - for (auto iter = animations.cbegin(); iter != animations.cend(); ++iter) - { - std::string name = iter->first; - ValueMap& animationDict = const_cast(iter->second.asValueMap()); - - const Value& loops = animationDict["loops"]; - bool restoreOriginalFrame = animationDict["restoreOriginalFrame"].asBool(); - - ValueVector& frameArray = animationDict["frames"].asValueVector(); - - if ( frameArray.empty() ) - { - CCLOG("cocos2d: AnimationCache: Animation '%s' found in dictionary without any frames - cannot add to animation cache.", name.c_str()); - continue; - } - - // Array of AnimationFrames - Vector array(static_cast(frameArray.size())); - - for (auto& obj : frameArray) - { - ValueMap& entry = obj.asValueMap(); - std::string spriteFrameName = entry["spriteframe"].asString(); - SpriteFrame *spriteFrame = frameCache->getSpriteFrameByName(spriteFrameName); - - if( ! spriteFrame ) - { - CCLOG("cocos2d: AnimationCache: Animation '%s' refers to frame '%s' which is not currently in the SpriteFrameCache. This frame will not be added to the animation.", name.c_str(), spriteFrameName.c_str()); - - continue; - } - - float delayUnits = entry["delayUnits"].asFloat(); - Value& userInfo = entry["notification"]; - - AnimationFrame *animFrame = AnimationFrame::create(spriteFrame, delayUnits, userInfo.getType() == Value::Type::MAP ? userInfo.asValueMap() : ValueMapNull); - - array.pushBack(animFrame); - } - - float delayPerUnit = animationDict["delayPerUnit"].asFloat(); - Animation *animation = Animation::create(array, delayPerUnit, loops.getType() != Value::Type::NONE ? loops.asInt() : 1); - - animation->setRestoreOriginalFrame(restoreOriginalFrame); - - AnimationCache::getInstance()->addAnimation(animation, name); - } -} - -void AnimationCache::addAnimationsWithDictionary(const ValueMap& dictionary,const std::string& plist) -{ - if ( dictionary.find("animations") == dictionary.end() ) - { - CCLOG("cocos2d: AnimationCache: No animations were found in provided dictionary."); - return; - } - - const Value& animations = dictionary.at("animations"); - unsigned int version = 1; - - if( dictionary.find("properties") != dictionary.end() ) - { - const ValueMap& properties = dictionary.at("properties").asValueMap(); - version = properties.at("format").asInt(); - const ValueVector& spritesheets = properties.at("spritesheets").asValueVector(); - - for(const auto &value : spritesheets) - { - std::string path = FileUtils::getInstance()->fullPathFromRelativeFile(value.asString(),plist); - SpriteFrameCache::getInstance()->addSpriteFramesWithFile(path); - } - } - - switch (version) - { - case 1: - parseVersion1(animations.asValueMap()); - break; - case 2: - parseVersion2(animations.asValueMap()); - break; - default: - CCASSERT(false, "Invalid animation format"); - } -} - -/** Read an NSDictionary from a plist file and parse it automatically for animations */ -void AnimationCache::addAnimationsWithFile(const std::string& plist) -{ - CCASSERT(!plist.empty(), "Invalid texture file name"); - if (plist.empty()) - { - log("%s error:file name is empty!", __FUNCTION__); - return; - } - - ValueMap dict = FileUtils::getInstance()->getValueMapFromFile(plist); - - CCASSERT( !dict.empty(), "CCAnimationCache: File could not be found"); - if (dict.empty()) - { - log("AnimationCache::addAnimationsWithFile error:%s not exist!", plist.c_str()); - } - - addAnimationsWithDictionary(dict,plist); -} - - -NS_CC_END - diff --git a/native/cocos/2d/CCAnimationCache.h b/native/cocos/2d/CCAnimationCache.h deleted file mode 100644 index 4dafac40ff..0000000000 --- a/native/cocos/2d/CCAnimationCache.h +++ /dev/null @@ -1,134 +0,0 @@ -/**************************************************************************** -Copyright (c) 2008-2010 Ricardo Quesada -Copyright (c) 2010-2012 cocos2d-x.org -Copyright (c) 2011 Zynga Inc. -CopyRight (c) 2013-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ -#ifndef __CC_ANIMATION_CACHE_H__ -#define __CC_ANIMATION_CACHE_H__ - -#include "base/CCRef.h" -#include "base/CCMap.h" -#include "base/CCValue.h" -#include "2d/CCAnimation.h" - -#include - -NS_CC_BEGIN - - -class Animation; - -/** - * @addtogroup _2d - * @{ - */ - -/** Singleton that manages the Animations. -It saves in a cache the animations. You should use this class if you want to save your animations in a cache. - -Before v0.99.5, the recommend way was to save them on the Sprite. Since v0.99.5, you should use this class instead. - -@since v0.99.5 -@js cc.animationCache -*/ -class CC_DLL AnimationCache : public Ref -{ -public: - /** - * @js ctor - */ - AnimationCache(); - /** - * @js NA - * @lua NA - */ - ~AnimationCache(); - /** Returns the shared instance of the Animation cache - @js NA - */ - static AnimationCache* getInstance(); - - /** Purges the cache. It releases all the Animation objects and the shared instance. - @js NA - */ - static void destroyInstance(); - - bool init(void); - - /** Adds a Animation with a name. - * - * @param animation An animation. - * @param name The name of animation. - */ - void addAnimation(Animation *animation, const std::string& name); - - /** Deletes a Animation from the cache. - * - * @param name The name of animation. - */ - void removeAnimation(const std::string& name); - - /** Returns a Animation that was previously added. - * If the name is not found it will return nil. - * You should retain the returned copy if you are going to use it. - * - * @return A Animation that was previously added. If the name is not found it will return nil. - */ - Animation* getAnimation(const std::string& name); - - /** Adds an animation from an NSDictionary. - * Make sure that the frames were previously loaded in the SpriteFrameCache. - * @param dictionary An NSDictionary. - * @param plist The path of the relative file,it use to find the plist path for load SpriteFrames. - * @since v1.1 - @js NA - */ - void addAnimationsWithDictionary(const ValueMap& dictionary,const std::string& plist); - - /** Adds an animation from a plist file. - * Make sure that the frames were previously loaded in the SpriteFrameCache. - * @since v1.1 - * @js addAnimations - * @lua addAnimations - * @param plist An animation from a plist file. - */ - void addAnimationsWithFile(const std::string& plist); - -private: - void parseVersion1(const ValueMap& animations); - void parseVersion2(const ValueMap& animations); - -private: - Map _animations; - static AnimationCache* s_sharedAnimationCache; -}; - -// end of sprite_nodes group -/// @} - -NS_CC_END - -#endif // __CC_ANIMATION_CACHE_H__ - diff --git a/native/cocos/2d/CCAtlasNode.cpp b/native/cocos/2d/CCAtlasNode.cpp deleted file mode 100644 index 5ccc7b9035..0000000000 --- a/native/cocos/2d/CCAtlasNode.cpp +++ /dev/null @@ -1,259 +0,0 @@ -/**************************************************************************** -Copyright (c) 2008-2010 Ricardo Quesada -Copyright (c) 2010-2012 cocos2d-x.org -Copyright (c) 2011 Zynga Inc. -CopyRight (c) 2013-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ - -#include "2d/CCAtlasNode.h" -#include "renderer/CCTextureAtlas.h" -#include "base/CCDirector.h" -#include "renderer/CCTextureCache.h" -#include "renderer/CCRenderer.h" -#include "renderer/CCGLProgram.h" - -NS_CC_BEGIN - -// implementation AtlasNode - -// AtlasNode - Creation & Init - -AtlasNode::AtlasNode() -: _itemsPerRow(0) -, _itemsPerColumn(0) -, _itemWidth(0) -, _itemHeight(0) -, _textureAtlas(nullptr) -, _isOpacityModifyRGB(false) -, _quadsToDraw(0) -, _uniformColor(0) -, _ignoreContentScaleFactor(false) -{ -} - -AtlasNode::~AtlasNode() -{ - CC_SAFE_RELEASE(_textureAtlas); -} - -AtlasNode * AtlasNode::create(const std::string& tile, int tileWidth, int tileHeight, int itemsToRender) -{ - AtlasNode * ret = new (std::nothrow) AtlasNode(); - if (ret->initWithTileFile(tile, tileWidth, tileHeight, itemsToRender)) - { - ret->autorelease(); - return ret; - } - CC_SAFE_DELETE(ret); - return nullptr; -} - -bool AtlasNode::initWithTileFile(const std::string& tile, int tileWidth, int tileHeight, int itemsToRender) -{ - CCASSERT(tile.size() > 0, "file size should not be empty"); - Texture2D *texture = Director::getInstance()->getTextureCache()->addImage(tile); - return initWithTexture(texture, tileWidth, tileHeight, itemsToRender); -} - -bool AtlasNode::initWithTexture(Texture2D* texture, int tileWidth, int tileHeight, int itemsToRender) -{ - _itemWidth = tileWidth; - _itemHeight = tileHeight; - - _colorUnmodified = Color3B::WHITE; - _isOpacityModifyRGB = true; - - _blendFunc = BlendFunc::ALPHA_PREMULTIPLIED; - - _textureAtlas = new (std::nothrow) TextureAtlas(); - _textureAtlas->initWithTexture(texture, itemsToRender); - - if (! _textureAtlas) - { - CCLOG("cocos2d: Could not initialize AtlasNode. Invalid Texture."); - return false; - } - - this->updateBlendFunc(); - this->updateOpacityModifyRGB(); - - this->calculateMaxItems(); - - _quadsToDraw = itemsToRender; - - // shader stuff - setGLProgramState(GLProgramState::getOrCreateWithGLProgramName(GLProgram::SHADER_NAME_POSITION_TEXTURE_COLOR_NO_MVP)); - - return true; -} - - -// AtlasNode - Atlas generation - -void AtlasNode::calculateMaxItems() -{ - Size s = _textureAtlas->getTexture()->getContentSize(); - - if (_ignoreContentScaleFactor) - { - s = _textureAtlas->getTexture()->getContentSizeInPixels(); - } - - _itemsPerColumn = (int)(s.height / _itemHeight); - _itemsPerRow = (int)(s.width / _itemWidth); -} - -void AtlasNode::updateAtlasValues() -{ - CCASSERT(false, "CCAtlasNode:Abstract updateAtlasValue not overridden"); -} - -// AtlasNode - draw -void AtlasNode::draw(Renderer *renderer, const Mat4 &transform, uint32_t flags) -{ - // ETC1 ALPHA supports. - _quadCommand.init(_globalZOrder, _textureAtlas->getTexture(), getGLProgramState(), _blendFunc, _textureAtlas->getQuads(), _quadsToDraw, transform, flags); - - renderer->addCommand(&_quadCommand); - -} - -// AtlasNode - RGBA protocol - -const Color3B& AtlasNode::getColor() const -{ - if(_isOpacityModifyRGB) - { - return _colorUnmodified; - } - return Node::getColor(); -} - -void AtlasNode::setColor(const Color3B& color3) -{ - Color3B tmp = color3; - _colorUnmodified = color3; - - if( _isOpacityModifyRGB ) - { - tmp.r = tmp.r * _displayedOpacity/255; - tmp.g = tmp.g * _displayedOpacity/255; - tmp.b = tmp.b * _displayedOpacity/255; - } - Node::setColor(tmp); -} - -void AtlasNode::setOpacity(GLubyte opacity) -{ - Node::setOpacity(opacity); - - // special opacity for premultiplied textures - if( _isOpacityModifyRGB ) - this->setColor(_colorUnmodified); -} - -void AtlasNode::setOpacityModifyRGB(bool value) -{ - Color3B oldColor = this->getColor(); - _isOpacityModifyRGB = value; - this->setColor(oldColor); -} - -bool AtlasNode::isOpacityModifyRGB() const -{ - return _isOpacityModifyRGB; -} - -void AtlasNode::updateOpacityModifyRGB() -{ - _isOpacityModifyRGB = _textureAtlas->getTexture()->hasPremultipliedAlpha(); -} - -void AtlasNode::setIgnoreContentScaleFactor(bool ignoreContentScaleFactor) -{ - _ignoreContentScaleFactor = ignoreContentScaleFactor; -} - -// AtlasNode - CocosNodeTexture protocol - -const BlendFunc& AtlasNode::getBlendFunc() const -{ - return _blendFunc; -} - -void AtlasNode::setBlendFunc(const BlendFunc &blendFunc) -{ - _blendFunc = blendFunc; -} - -void AtlasNode::updateBlendFunc() -{ - if( ! _textureAtlas->getTexture()->hasPremultipliedAlpha() ) - { - _blendFunc = BlendFunc::ALPHA_NON_PREMULTIPLIED; - setOpacityModifyRGB(false); - } - else - { - _blendFunc = BlendFunc::ALPHA_PREMULTIPLIED; - setOpacityModifyRGB(true); - } -} - -void AtlasNode::setTexture(Texture2D *texture) -{ - _textureAtlas->setTexture(texture); - this->updateBlendFunc(); - this->updateOpacityModifyRGB(); -} - -Texture2D * AtlasNode::getTexture() const -{ - return _textureAtlas->getTexture(); -} - -void AtlasNode::setTextureAtlas(TextureAtlas* textureAtlas) -{ - CC_SAFE_RETAIN(textureAtlas); - CC_SAFE_RELEASE(_textureAtlas); - _textureAtlas = textureAtlas; -} - -TextureAtlas * AtlasNode::getTextureAtlas() const -{ - return _textureAtlas; -} - -ssize_t AtlasNode::getQuadsToDraw() const -{ - return _quadsToDraw; -} - -void AtlasNode::setQuadsToDraw(ssize_t quadsToDraw) -{ - _quadsToDraw = quadsToDraw; -} - -NS_CC_END - diff --git a/native/cocos/2d/CCAtlasNode.h b/native/cocos/2d/CCAtlasNode.h deleted file mode 100644 index 19e7709da2..0000000000 --- a/native/cocos/2d/CCAtlasNode.h +++ /dev/null @@ -1,159 +0,0 @@ -/**************************************************************************** -Copyright (c) 2008-2010 Ricardo Quesada -Copyright (c) 2010-2012 cocos2d-x.org -Copyright (c) 2011 Zynga Inc. -CopyRight (c) 2013-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ - -#ifndef __CCATLAS_NODE_H__ -#define __CCATLAS_NODE_H__ - -#include "2d/CCNode.h" -#include "base/CCProtocols.h" -#include "base/ccTypes.h" -#include "renderer/CCQuadCommand.h" - -NS_CC_BEGIN - -/** - * @addtogroup _2d - * @{ - */ - -class TextureAtlas; - -/** @brief AtlasNode is a subclass of Node that implements the RGBAProtocol and TextureProtocol protocol. - * It knows how to render a TextureAtlas object. - * If you are going to render a TextureAtlas consider subclassing AtlasNode (or a subclass of AtlasNode). - * All features from Node are valid, plus the following features: - * - opacity and RGB colors. - */ -class CC_DLL AtlasNode : public Node, public TextureProtocol -{ -public: - /** creates a AtlasNode with an Atlas file the width and height of each item and the quantity of items to render. - * - * @param filename The path of Atlas file. - * @param tileWidth The width of the item. - * @param tileHeight The height of the item. - * @param itemsToRender The quantity of items to render. - */ - static AtlasNode * create(const std::string& filename, int tileWidth, int tileHeight, int itemsToRender); - - /** updates the Atlas (indexed vertex array). - * Shall be overridden in subclasses. - */ - virtual void updateAtlasValues(); - - /** Set an buffer manager of the texture vertex. */ - void setTextureAtlas(TextureAtlas* textureAtlas); - - /** Return the buffer manager of the texture vertex. - * - * @return Return A TextureAtlas. - */ - TextureAtlas* getTextureAtlas() const; - - void setQuadsToDraw(ssize_t quadsToDraw); - ssize_t getQuadsToDraw() const; - - - // Overrides - virtual void draw(Renderer *renderer, const Mat4 &transform, uint32_t flags) override; - virtual Texture2D* getTexture() const override; - virtual void setTexture(Texture2D *texture) override; - virtual bool isOpacityModifyRGB() const override; - virtual void setOpacityModifyRGB(bool isOpacityModifyRGB) override; - virtual const Color3B& getColor(void) const override; - virtual void setColor(const Color3B& color) override; - virtual void setOpacity(GLubyte opacity) override; - /** - * @code - * When this function bound into js or lua,the parameter will be changed - * In js: var setBlendFunc(var src, var dst) - * @endcode - * @lua NA - */ - virtual void setBlendFunc(const BlendFunc& blendFunc) override; - /** - * @lua NA - */ - virtual const BlendFunc& getBlendFunc() const override; - -CC_CONSTRUCTOR_ACCESS: - AtlasNode(); - virtual ~AtlasNode(); - - /** Initializes an AtlasNode with an Atlas file the width and height of each item and the quantity of items to render*/ - bool initWithTileFile(const std::string& tile, int tileWidth, int tileHeight, int itemsToRender); - - /** Initializes an AtlasNode with a texture the width and height of each item measured in points and the quantity of items to render*/ - bool initWithTexture(Texture2D* texture, int tileWidth, int tileHeight, int itemsToRender); - -protected: - void calculateMaxItems(); - void updateBlendFunc(); - void updateOpacityModifyRGB(); - - friend class Director; - void setIgnoreContentScaleFactor(bool bIgnoreContentScaleFactor); - - /** Chars per row. */ - int _itemsPerRow; - /** Chars per column. */ - int _itemsPerColumn; - - /** Width of each char. */ - int _itemWidth; - /** Height of each char. */ - int _itemHeight; - - Color3B _colorUnmodified; - - TextureAtlas* _textureAtlas; - /** Protocol variables. */ - bool _isOpacityModifyRGB; - BlendFunc _blendFunc; - - /** Quads to draw. */ - ssize_t _quadsToDraw; - /** Color uniform. */ - GLint _uniformColor; - /** This variable is only used for LabelAtlas FPS display. So plz don't modify its value. */ - bool _ignoreContentScaleFactor; - /** Quad command. */ - QuadCommand _quadCommand; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(AtlasNode); - -}; - -// end of base_node group -/// @} - -NS_CC_END - -#endif // __CCATLAS_NODE_H__ - diff --git a/native/cocos/2d/CCAutoPolygon.cpp b/native/cocos/2d/CCAutoPolygon.cpp deleted file mode 100644 index 83f2d1d71f..0000000000 --- a/native/cocos/2d/CCAutoPolygon.cpp +++ /dev/null @@ -1,704 +0,0 @@ -/**************************************************************************** -Copyright (c) 2015-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ - -#include "2d/CCAutoPolygon.h" -#include "poly2tri/poly2tri.h" -#include "base/CCDirector.h" -#include "renderer/CCTextureCache.h" -#include "clipper/clipper.hpp" -#include -#include - -USING_NS_CC; - -static unsigned short quadIndices[]={0,1,2, 3,2,1}; -const static float PRECISION = 10.0f; - -PolygonInfo::PolygonInfo() -: rect(cocos2d::Rect::ZERO) -, filename("") -, isVertsOwner(true) -{ - triangles.verts = nullptr; - triangles.indices = nullptr; - triangles.vertCount = 0; - triangles.indexCount = 0; -}; - -PolygonInfo::PolygonInfo(const PolygonInfo& other) -: triangles() -, rect() -, isVertsOwner(true) -{ - filename = other.filename; - isVertsOwner = true; - rect = other.rect; - triangles.verts = new (std::nothrow) V3F_C4B_T2F[other.triangles.vertCount]; - triangles.indices = new (std::nothrow) unsigned short[other.triangles.indexCount]; - CCASSERT(triangles.verts && triangles.indices, "not enough memory"); - triangles.vertCount = other.triangles.vertCount; - triangles.indexCount = other.triangles.indexCount; - memcpy(triangles.verts, other.triangles.verts, other.triangles.vertCount * sizeof(other.triangles.verts[0])); - memcpy(triangles.indices, other.triangles.indices, other.triangles.indexCount * sizeof(other.triangles.indices[0])); -}; - -PolygonInfo& PolygonInfo::operator= (const PolygonInfo& other) -{ - if(this != &other) - { - releaseVertsAndIndices(); - filename = other.filename; - isVertsOwner = true; - rect = other.rect; - triangles.verts = new (std::nothrow) V3F_C4B_T2F[other.triangles.vertCount]; - triangles.indices = new (std::nothrow) unsigned short[other.triangles.indexCount]; - CCASSERT(triangles.verts && triangles.indices, "not enough memory"); - triangles.vertCount = other.triangles.vertCount; - triangles.indexCount = other.triangles.indexCount; - memcpy(triangles.verts, other.triangles.verts, other.triangles.vertCount * sizeof(other.triangles.verts[0])); - memcpy(triangles.indices, other.triangles.indices, other.triangles.indexCount * sizeof(other.triangles.indices[0])); - } - return *this; -} - -PolygonInfo::~PolygonInfo() -{ - releaseVertsAndIndices(); -} - -void PolygonInfo::setQuad(V3F_C4B_T2F_Quad *quad) -{ - releaseVertsAndIndices(); - isVertsOwner = false; - triangles.indices = quadIndices; - triangles.vertCount = 4; - triangles.indexCount = 6; - triangles.verts = (V3F_C4B_T2F*)quad; -} - -void PolygonInfo::setTriangles(const TrianglesCommand::Triangles& other) -{ - this->releaseVertsAndIndices(); - isVertsOwner = false; - - this->triangles.vertCount = other.vertCount; - this->triangles.indexCount = other.indexCount; - this->triangles.verts = other.verts; - this->triangles.indices = other.indices; -} - -void PolygonInfo::releaseVertsAndIndices() -{ - if(isVertsOwner) - { - if(nullptr != triangles.verts) - { - CC_SAFE_DELETE_ARRAY(triangles.verts); - } - - if(nullptr != triangles.indices) - { - CC_SAFE_DELETE_ARRAY(triangles.indices); - } - } -} - -unsigned int PolygonInfo::getVertCount() const -{ - return (unsigned int)triangles.vertCount; -} - -unsigned int PolygonInfo::getTrianglesCount() const -{ - return (unsigned int)triangles.indexCount/3; -} - -float PolygonInfo::getArea() const -{ - float area = 0; - V3F_C4B_T2F *verts = triangles.verts; - unsigned short *indices = triangles.indices; - for(int i = 0; i < triangles.indexCount; i+=3) - { - auto A = verts[indices[i]].vertices; - auto B = verts[indices[i+1]].vertices; - auto C = verts[indices[i+2]].vertices; - area += (A.x*(B.y-C.y) + B.x*(C.y-A.y) + C.x*(A.y - B.y))/2; - } - return area; -} - -AutoPolygon::AutoPolygon(const std::string &filename) -:_image(nullptr) -,_data(nullptr) -,_filename("") -,_width(0) -,_height(0) -,_scaleFactor(0) -{ - _filename = filename; - _image = new (std::nothrow) Image(); - _image->initWithImageFile(filename); - CCASSERT(_image->getRenderFormat()==Texture2D::PixelFormat::RGBA8888, "unsupported format, currently only supports rgba8888"); - _data = _image->getData(); - _width = _image->getWidth(); - _height = _image->getHeight(); - _scaleFactor = Director::getInstance()->getContentScaleFactor(); -} - -AutoPolygon::~AutoPolygon() -{ - CC_SAFE_RELEASE(_image); -} - -std::vector AutoPolygon::trace(const Rect& rect, const float& threshold) -{ - Vec2 first = findFirstNoneTransparentPixel(rect, threshold); - return marchSquare(rect, first, threshold); -} - -Vec2 AutoPolygon::findFirstNoneTransparentPixel(const Rect& rect, const float& threshold) -{ - bool found = false; - Vec2 i; - for(i.y = rect.origin.y; i.y < rect.origin.y+rect.size.height; i.y++) - { - if(found)break; - for(i.x = rect.origin.x; i.x < rect.origin.x+rect.size.width; i.x++) - { - auto alpha = getAlphaByPos(i); - if(alpha>threshold) - { - found = true; - break; - } - } - } - CCASSERT(found, "image is all transparent!"); - return i; -} - -unsigned char AutoPolygon::getAlphaByIndex(const unsigned int& i) -{ - return *(_data+i*4+3); -} -unsigned char AutoPolygon::getAlphaByPos(const Vec2& pos) -{ - return *(_data+((int)pos.y*_width+(int)pos.x)*4+3); -} - -unsigned int AutoPolygon::getSquareValue(const unsigned int& x, const unsigned int& y, const Rect& rect, const float& threshold) -{ - /* - checking the 2x2 pixel grid, assigning these values to each pixel, if not transparent - +---+---+ - | 1 | 2 | - +---+---+ - | 4 | 8 | <- current pixel (curx,cury) - +---+---+ - */ - unsigned int sv = 0; - //NOTE: due to the way we pick points from texture, rect needs to be smaller, otherwise it goes outside 1 pixel - auto fixedRect = Rect(rect.origin, rect.size-Size(2,2)); - - Vec2 tl = Vec2(x-1, y-1); - sv += (fixedRect.containsPoint(tl) && getAlphaByPos(tl) > threshold)? 1 : 0; - Vec2 tr = Vec2(x, y-1); - sv += (fixedRect.containsPoint(tr) && getAlphaByPos(tr) > threshold)? 2 : 0; - Vec2 bl = Vec2(x-1, y); - sv += (fixedRect.containsPoint(bl) && getAlphaByPos(bl) > threshold)? 4 : 0; - Vec2 br = Vec2(x, y); - sv += (fixedRect.containsPoint(br) && getAlphaByPos(br) > threshold)? 8 : 0; - CCASSERT(sv != 0 && sv != 15, "square value should not be 0, or 15"); - return sv; -} - -std::vector AutoPolygon::marchSquare(const Rect& rect, const Vec2& start, const float& threshold) -{ - int stepx = 0; - int stepy = 0; - int prevx = 0; - int prevy = 0; - int startx = start.x; - int starty = start.y; - int curx = startx; - int cury = starty; - unsigned int count = 0; - bool problem = false; - std::vector case9s; - std::vector case6s; - int i; - std::vector::iterator it; - std::vector _points; - do{ - int sv = getSquareValue(curx, cury, rect, threshold); - switch(sv){ - - case 1: - case 5: - case 13: - /* going UP with these cases: - 1 5 13 - +---+---+ +---+---+ +---+---+ - | 1 | | | 1 | | | 1 | | - +---+---+ +---+---+ +---+---+ - | | | | 4 | | | 4 | 8 | - +---+---+ +---+---+ +---+---+ - */ - stepx = 0; - stepy = -1; - break; - - - case 8: - case 10: - case 11: - /* going DOWN with these cases: - 8 10 11 - +---+---+ +---+---+ +---+---+ - | | | | | 2 | | 1 | 2 | - +---+---+ +---+---+ +---+---+ - | | 8 | | | 8 | | | 8 | - +---+---+ +---+---+ +---+---+ - */ - stepx = 0; - stepy = 1; - break; - - - case 4: - case 12: - case 14: - /* going LEFT with these cases: - 4 12 14 - +---+---+ +---+---+ +---+---+ - | | | | | | | | 2 | - +---+---+ +---+---+ +---+---+ - | 4 | | | 4 | 8 | | 4 | 8 | - +---+---+ +---+---+ +---+---+ - */ - stepx = -1; - stepy = 0; - break; - - - case 2 : - case 3 : - case 7 : - /* going RIGHT with these cases: - 2 3 7 - +---+---+ +---+---+ +---+---+ - | | 2 | | 1 | 2 | | 1 | 2 | - +---+---+ +---+---+ +---+---+ - | | | | | | | 4 | | - +---+---+ +---+---+ +---+---+ - */ - stepx=1; - stepy=0; - break; - case 9 : - /* - +---+---+ - | 1 | | - +---+---+ - | | 8 | - +---+---+ - this should normally go UP, but if we already been here, we go down - */ - //find index from xy; - i = getIndexFromPos(curx, cury); - it = find (case9s.begin(), case9s.end(), i); - if (it != case9s.end()) - { - //found, so we go down, and delete from case9s; - stepx = 0; - stepy = 1; - case9s.erase(it); - problem = true; - } - else - { - //not found, we go up, and add to case9s; - stepx = 0; - stepy = -1; - case9s.push_back(i); - } - break; - case 6 : - /* - 6 - +---+---+ - | | 2 | - +---+---+ - | 4 | | - +---+---+ - this normally go RIGHT, but if its coming from UP, it should go LEFT - */ - i = getIndexFromPos(curx, cury); - it = find (case6s.begin(), case6s.end(), i); - if (it != case6s.end()) - { - //found, so we go down, and delete from case9s; - stepx = -1; - stepy = 0; - case6s.erase(it); - problem = true; - } - else{ - //not found, we go up, and add to case9s; - stepx = 1; - stepy = 0; - case6s.push_back(i); - } - break; - default: - CCLOG("this shouldn't happen."); - } - //little optimization - // if previous direction is same as current direction, - // then we should modify the last vec to current - curx += stepx; - cury += stepy; - if(stepx == prevx && stepy == prevy) - { - _points.back().x = (float)(curx-rect.origin.x) / _scaleFactor; - _points.back().y = (float)(rect.size.height - cury + rect.origin.y) / _scaleFactor; - } - else if(problem) - { - //TODO: we triangulation cannot work collinear points, so we need to modify same point a little - //TODO: maybe we can detect if we go into a hole and coming back the hole, we should extract those points and remove them - _points.push_back(Vec2((float)(curx- rect.origin.x) / _scaleFactor, (float)(rect.size.height - cury + rect.origin.y) / _scaleFactor)); - } - else{ - _points.push_back(Vec2((float)(curx-rect.origin.x) / _scaleFactor, (float)(rect.size.height - cury + rect.origin.y) / _scaleFactor)); - } - - count++; - prevx = stepx; - prevy = stepy; - problem = false; - -#if defined(COCOS2D_DEBUG) && (COCOS2D_DEBUG > 0) - const auto totalPixel = _width * _height; - CCASSERT(count <= totalPixel, "oh no, marching square cannot find starting position"); -#endif - } while(curx != startx || cury != starty); - return _points; -} - -float AutoPolygon::perpendicularDistance(const cocos2d::Vec2& i, const cocos2d::Vec2& start, const cocos2d::Vec2& end) -{ - float res; - float slope; - float intercept; - - if(start.x == end.x) - { - res = fabsf(i.x- end.x); - } - else if (start.y == end.y) - { - res = fabsf(i.y - end.y); - } - else{ - slope = (end.y - start.y) / (end.x - start.x); - intercept = start.y - (slope*start.x); - res = fabsf(slope * i.x - i.y + intercept) / sqrtf(powf(slope, 2)+1); - } - return res; -} -std::vector AutoPolygon::rdp(const std::vector& v, float optimization) -{ - if(v.size() < 3) - return v; - - int index = -1; - float dist = 0; - //not looping first and last point - for(size_t i = 1; i < v.size()-1; i++) - { - float cdist = perpendicularDistance(v[i], v.front(), v.back()); - if(cdist > dist) - { - dist = cdist; - index = static_cast(i); - } - } - if (dist>optimization) - { - std::vector::const_iterator begin = v.begin(); - std::vector::const_iterator end = v.end(); - std::vector l1(begin, begin+index+1); - std::vector l2(begin+index, end); - - std::vector r1 = rdp(l1, optimization); - std::vector r2 = rdp(l2, optimization); - - r1.insert(r1.end(), r2.begin()+1, r2.end()); - return r1; - } - else { - std::vector ret; - ret.push_back(v.front()); - ret.push_back(v.back()); - return ret; - } -} -std::vector AutoPolygon::reduce(const std::vector& points, const Rect& rect , const float& epsilon) -{ - auto size = points.size(); - // if there are less than 3 points, then we have nothing - if(size<3) - { - log("AUTOPOLYGON: cannot reduce points for %s that has less than 3 points in input, e: %f", _filename.c_str(), epsilon); - return std::vector(); - } - // if there are less than 9 points (but more than 3), then we don't need to reduce it - else if (size < 9) - { - log("AUTOPOLYGON: cannot reduce points for %s e: %f",_filename.c_str(), epsilon); - return points; - } - float maxEp = MIN(rect.size.width, rect.size.height); - float ep = clampf(epsilon, 0.0, maxEp/_scaleFactor/2); - std::vector result = rdp(points, ep); - - auto last = result.back(); - if (last.y > result.front().y && last.getDistance(result.front()) < ep * 0.5f) - { - result.front().y = last.y; - result.pop_back(); - } - return result; -} - -std::vector AutoPolygon::expand(const std::vector& points, const cocos2d::Rect &rect, const float& epsilon) -{ - auto size = points.size(); - // if there are less than 3 points, then we have nothing - if(size<3) - { - log("AUTOPOLYGON: cannot expand points for %s with less than 3 points, e: %f", _filename.c_str(), epsilon); - return std::vector(); - } - ClipperLib::Path subj; - ClipperLib::PolyTree solution; - ClipperLib::PolyTree out; - for(std::vector::const_iterator it = points.begin(); it x* PRECISION, it->y * PRECISION); - } - ClipperLib::ClipperOffset co; - co.AddPath(subj, ClipperLib::jtMiter, ClipperLib::etClosedPolygon); - co.Execute(solution, epsilon * PRECISION); - - ClipperLib::PolyNode* p = solution.GetFirst(); - if(!p) - { - log("AUTOPOLYGON: Clipper failed to expand the points"); - return points; - } - while(p->IsHole()){ - p = p->GetNext(); - } - - //turn the result into simply polygon (AKA, fix overlap) - - //clamp into the specified rect - ClipperLib::Clipper cl; - cl.StrictlySimple(true); - cl.AddPath(p->Contour, ClipperLib::ptSubject, true); - //create the clipping rect - ClipperLib::Path clamp; - clamp.push_back(ClipperLib::IntPoint(0, 0)); - clamp.push_back(ClipperLib::IntPoint(rect.size.width/_scaleFactor * PRECISION, 0)); - clamp.push_back(ClipperLib::IntPoint(rect.size.width/_scaleFactor * PRECISION, rect.size.height/_scaleFactor * PRECISION)); - clamp.push_back(ClipperLib::IntPoint(0, rect.size.height/_scaleFactor * PRECISION)); - cl.AddPath(clamp, ClipperLib::ptClip, true); - cl.Execute(ClipperLib::ctIntersection, out); - - std::vector outPoints; - ClipperLib::PolyNode* p2 = out.GetFirst(); - while(p2->IsHole()){ - p2 = p2->GetNext(); - } - auto end = p2->Contour.end(); - for(std::vector::const_iterator pt = p2->Contour.begin(); pt < end; pt++) - { - outPoints.push_back(Vec2(pt->X/PRECISION, pt->Y/PRECISION)); - } - return outPoints; -} - -TrianglesCommand::Triangles AutoPolygon::triangulate(const std::vector& points) -{ - // if there are less than 3 points, then we can't triangulate - if(points.size()<3) - { - log("AUTOPOLYGON: cannot triangulate %s with less than 3 points", _filename.c_str()); - return TrianglesCommand::Triangles(); - } - std::vector p2points; - for(std::vector::const_iterator it = points.begin(); itx, it->y); - p2points.push_back(p); - } - p2t::CDT cdt(p2points); - cdt.Triangulate(); - std::vector tris = cdt.GetTriangles(); - - // we won't know the size of verts and indices until we process all of the triangles! - std::vector verts; - std::vector indices; - - unsigned short idx = 0; - unsigned short vdx = 0; - - for(std::vector::const_iterator ite = tris.begin(); ite != tris.end(); ite++) - { - for(int i = 0; i < 3; i++) - { - auto p = (*ite)->GetPoint(i); - auto v3 = Vec3(p->x, p->y, 0); - bool found = false; - size_t j; - size_t length = vdx; - for(j = 0; j < length; j++) - { - if(verts[j].vertices == v3) - { - found = true; - break; - } - } - if(found) - { - //if we found the same vertex, don't add to verts, but use the same vertex with indices - indices.push_back(j); - idx++; - } - else - { - //vert does not exist yet, so we need to create a new one, - auto c4b = Color4B::WHITE; - auto t2f = Tex2F(0,0); // don't worry about tex coords now, we calculate that later - V3F_C4B_T2F vert = {v3,c4b,t2f}; - verts.push_back(vert); - indices.push_back(vdx); - idx++; - vdx++; - } - } - } - for(auto j : p2points) - { - delete j; - }; - - // now that we know the size of verts and indices we can create the buffers - V3F_C4B_T2F* vertsBuf = new (std::nothrow) V3F_C4B_T2F[verts.size()]; - memcpy(vertsBuf, verts.data(), verts.size() * sizeof(V3F_C4B_T2F)); - - unsigned short* indicesBuf = new (std::nothrow) unsigned short[indices.size()]; - memcpy(indicesBuf, indices.data(), indices.size() * sizeof(short)); - - // Triangles should really use std::vector and not arrays for verts and indices. - // Then the above memcpy would not be necessary - TrianglesCommand::Triangles triangles = { vertsBuf, indicesBuf, static_cast(verts.size()), static_cast(indices.size()) }; - return triangles; -} - -void AutoPolygon::calculateUV(const Rect& rect, V3F_C4B_T2F* verts, const ssize_t& count) -{ - /* - whole texture UV coordination - 0,0 1,0 - +---------------------+ - | |0.1 - | |0.2 - | +--------+ |0.3 - | |texRect | |0.4 - | | | |0.5 - | | | |0.6 - | +--------+ |0.7 - | |0.8 - | |0.9 - +---------------------+ - 0,1 1,1 - */ - - CCASSERT(_width && _height, "please specify width and height for this AutoPolygon instance"); - float texWidth = _width; - float texHeight = _height; - - auto end = &verts[count]; - for(auto i = verts; i != end; i++) - { - // for every point, offset with the center point - float u = (i->vertices.x*_scaleFactor + rect.origin.x) / texWidth; - float v = (rect.origin.y+rect.size.height - i->vertices.y*_scaleFactor) / texHeight; - i->texCoords.u = u; - i->texCoords.v = v; - } -} - -Rect AutoPolygon::getRealRect(const Rect& rect) -{ - Rect realRect = rect; - //check rect to see if its zero - if(realRect.equals(Rect::ZERO)) - { - //if the instance doesn't have width and height, then the whole operation is kaput - CCASSERT(_height && _width, "Please specify a width and height for this instance before using its functions"); - realRect = Rect(0,0, _width, _height); - } - else{ - //rect is specified, so convert to real rect - realRect = CC_RECT_POINTS_TO_PIXELS(rect); - } - return realRect; -} - -PolygonInfo AutoPolygon::generateTriangles(const Rect& rect, const float& epsilon, const float& threshold) -{ - Rect realRect = getRealRect(rect); - auto p = trace(realRect, threshold); - p = reduce(p, realRect, epsilon); - p = expand(p, realRect, epsilon); - auto tri = triangulate(p); - calculateUV(realRect, tri.verts, tri.vertCount); - PolygonInfo ret; - ret.triangles = tri; - ret.filename = _filename; - ret.rect = realRect; - return ret; -} -PolygonInfo AutoPolygon::generatePolygon(const std::string& filename, const Rect& rect, const float epsilon, const float threshold) -{ - AutoPolygon ap(filename); - return ap.generateTriangles(rect, epsilon, threshold); -} diff --git a/native/cocos/2d/CCAutoPolygon.h b/native/cocos/2d/CCAutoPolygon.h deleted file mode 100644 index 2dc8bdceca..0000000000 --- a/native/cocos/2d/CCAutoPolygon.h +++ /dev/null @@ -1,268 +0,0 @@ -/**************************************************************************** -Copyright (c) 2015-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ - -#ifndef COCOS_2D_CCAUTOPOLYGON_H__ -#define COCOS_2D_CCAUTOPOLYGON_H__ - -#include -#include -#include "platform/CCImage.h" -#include "renderer/CCTrianglesCommand.h" - -NS_CC_BEGIN - -/** - * @addtogroup _2d - * @{ - */ - -/** - * PolygonInfo is an object holding the required data to display Sprites. - * It can be a simple as a triangle, or as complex as a whole 3D mesh - */ -class CC_DLL PolygonInfo -{ -public: - /// @name Creators - /// @{ - /** - * Creates an empty Polygon info - * @memberof PolygonInfo - * @return PolygonInfo object - */ - PolygonInfo(); - - /** - * Create an polygoninfo from the data of another Polygoninfo - * @param other another PolygonInfo to be copied - * @return duplicate of the other PolygonInfo - */ - PolygonInfo(const PolygonInfo& other); - // end of creators group - /// @} - - /** - * Copy the member of the other PolygonInfo - * @param other another PolygonInfo to be copied - */ - PolygonInfo& operator= (const PolygonInfo &other); - ~PolygonInfo(); - - /** - * set the data to be a pointer to a quad - * the member verts will not be released when this PolygonInfo destructs - * as the verts memory are managed by other objects - * @param quad a pointer to the V3F_C4B_T2F_Quad object - */ - void setQuad(V3F_C4B_T2F_Quad *quad); - - /** - * set the data to be a pointer to a triangles - * the member verts will not be released when this PolygonInfo destructs - * as the verts memory are managed by other objects - * @param triangles a pointer to the TrianglesCommand::Triangles object - */ - void setTriangles(const TrianglesCommand::Triangles& triangles); - - /** - * get vertex count - * @return number of vertices - */ - unsigned int getVertCount() const; - - /** - * get triangles count - * @return number of triangles - */ - unsigned int getTrianglesCount() const; - - /** - * get sum of all triangle area size - * @return sum of all triangle area size - */ - float getArea() const; - - Rect rect; - std::string filename; - TrianglesCommand::Triangles triangles; - -protected: - bool isVertsOwner; - -private: - void releaseVertsAndIndices(); -}; - - -/** - * AutoPolygon is a helper Object - * AutoPolygon's purpose is to process an image into 2d polygon mesh in runtime - * It has functions for each step in the process, from tracing all the points, to triangulation - * the result can be then passed to Sprite::create() to create a Polygon Sprite - */ -class CC_DLL AutoPolygon -{ -public: - /** - * create an AutoPolygon and initialize it with an image file - * the image must be a 32bit PNG for current version 3.7 - * @param filename a path to image file, e.g., "scene1/monster.png". - * @return an AutoPolygon object; - */ - AutoPolygon(const std::string &filename); - - /** - * Destructor of AutoPolygon. - */ - ~AutoPolygon(); - - /** - * trace all the points along the outline of the image, - * @warning must create AutoPolygon with filename to use this function - * @param rect a texture rect for specify an area of the image - * @param threshold the value when alpha is greater than this value will be counted as opaque, default to 0.0 - * @return a vector of vec2 of all the points found in clockwise order - * @code - * auto ap = AutoPolygon("grossini.png"); - * auto rect = Rect(100, 100, 200, 200); - * std::vector points = ap.trace(rect);//default threshold is 0.0 - * @endcode - */ - std::vector trace(const cocos2d::Rect& rect, const float& threshold = 0.0); - - /** - * reduce the amount of points so its faster for GPU to process and draw - * based on Ramer-Douglas-Puecker algorithm - * @param points a vector of Vec2 points as input - * @param rect a texture rect for specify an area of the image to avoid over reduction - * @param epsilon the perpendicular distance where points smaller than this value will be discarded - * @return a vector of Vec2 of the remaining points in clockwise order - * @code - * auto ap = AutoPolygon(); - * std::vector reduced = ap.reduce(inputPoints, rect);//default epsilon is 2 - * @endcode - */ - std::vector reduce(const std::vector& points, const Rect& rect, const float& epsilon = 2.0); - - /** - * expand the points along their edge, useful after you reduce the points that cuts into the sprite - * using ClipperLib - * @param points a vector of Vec2 points as input - * @param rect a texture rect for specify an area of the image, the expanded points will be clamped in this rect, ultimately resulting in a quad if the expansion is too great - * @param epsilon the distance which the edges will expand - * @return a vector of Vec2 as the result of the expansion - * @code - * auto ap = AutoPolygon(); - * std::vector expanded = ap.expand(inputPoints, rect, 2.0); - * @endcode - */ - std::vector expand(const std::vector& points, const Rect& rect, const float& epsilon); - - /** - * Triangulate the input points into triangles for rendering - * using poly2tri - * @warning points must be closed loop, cannot have 2 points sharing the same position and cannot intersect itself - * @param points a vector of vec2 points as input - * @return a Triangles object with points and indices - * @code - * auto ap = AutoPolygon(); - * TrianglesCommand::Triangles myPolygons = ap.triangulate(myPoints); - * @endcode - */ - TrianglesCommand::Triangles triangulate(const std::vector& points); - - /** - * calculate the UV coordinates for each points based on a texture rect - * @warning This method requires the AutoPolygon object to know the texture file dimension - * @param rect a texture rect to specify where to map the UV - * @param verts a pointer to the verts array, served both as input and output verts - * @param count the count for the verts array - * @code - * auto ap = AutoPolygon("grossini.png"); - * TrianglesCommand::Triangles myPolygons = ap.triangulate(myPoints); - * ap.calculateUV(rect, myPolygons.verts, 20); - * @endcode - */ - void calculateUV(const Rect& rect, V3F_C4B_T2F* verts, const ssize_t& count); - - /** - * a helper function, packing trace, reduce, expand, triangulate and calculate uv in one function - * @param rect texture rect, use Rect::ZERO for the size of the texture, default is Rect::ZERO - * @param epsilon the value used to reduce and expand, default to 2.0 - * @param threshold the value where bigger than the threshold will be counted as opaque, used in trace - * @return a PolygonInfo, to use with sprite - * @code - * auto ap = AutoPolygon("grossini.png"); - * PolygonInfo myInfo = ap.generateTriangles();//use all default values - * auto sp1 = Sprite::create(myInfo); - * polygonInfo myInfo2 = ap.generateTriangles(Rect::ZERO, 5.0, 0.1);//ap can be reused to generate another set of PolygonInfo with different settings - * auto sp2 = Sprite::create(myInfo2); - * @endcode - */ - PolygonInfo generateTriangles(const Rect& rect = Rect::ZERO, const float& epsilon = 2.0, const float& threshold = 0.05); - - /** - * a helper function, packing autoPolygon creation, trace, reduce, expand, triangulate and calculate uv in one function - * @warning if you want to repetitively generate polygons, consider create an AutoPolygon object, and use generateTriangles function, as it only reads the file once - * @param filename A path to image file, e.g., "scene1/monster.png". - * @param rect texture rect, use Rect::ZERO for the size of the texture, default is Rect::ZERO - * @param epsilon the value used to reduce and expand, default to 2.0 - * @param threshold the value where bigger than the threshold will be counted as opaque, used in trace - * @return a PolygonInfo, to use with sprite - * @code - * auto sp = Sprite::create(AutoPolygon::generatePolygon("grossini.png")); - * @endcode - */ - static PolygonInfo generatePolygon(const std::string& filename, const Rect& rect = Rect::ZERO, const float epsilon = 2.0, const float threshold = 0.05); -protected: - Vec2 findFirstNoneTransparentPixel(const Rect& rect, const float& threshold); - std::vector marchSquare(const Rect& rect, const Vec2& first, const float& threshold); - unsigned int getSquareValue(const unsigned int& x, const unsigned int& y, const Rect& rect, const float& threshold); - - unsigned char getAlphaByIndex(const unsigned int& i); - unsigned char getAlphaByPos(const Vec2& pos); - - int getIndexFromPos(const unsigned int& x, const unsigned int& y){return y*_width+x;}; - cocos2d::Vec2 getPosFromIndex(const unsigned int& i){return cocos2d::Vec2(i%_width, i/_width);}; - - std::vector rdp(const std::vector& v, float optimization); - float perpendicularDistance(const cocos2d::Vec2& i, const cocos2d::Vec2& start, const cocos2d::Vec2& end); - - //real rect is the size that is in scale with the texture file - Rect getRealRect(const Rect& rect); - - Image* _image; - unsigned char * _data; - std::string _filename; - unsigned int _width; - unsigned int _height; - float _scaleFactor; - unsigned int _threshold; -}; - -NS_CC_END - -#endif // #ifndef COCOS_2D_CCAUTOPOLYGON_H__ - diff --git a/native/cocos/2d/CCClippingNode.cpp b/native/cocos/2d/CCClippingNode.cpp deleted file mode 100644 index cb6ad28698..0000000000 --- a/native/cocos/2d/CCClippingNode.cpp +++ /dev/null @@ -1,369 +0,0 @@ -/* - * Copyright (c) 2012 Pierre-David Bélanger - * Copyright (c) 2012 cocos2d-x.org - * Copyright (c) 2013-2016 Chukong Technologies Inc. - * Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - * - * cocos2d-x: http://www.cocos2d-x.org - * - * Permission is hereby granted, free of charge, to any person obtaining a copy - * of this software and associated documentation files (the "Software"), to deal - * in the Software without restriction, including without limitation the rights - * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell - * copies of the Software, and to permit persons to whom the Software is - * furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice shall be included in - * all copies or substantial portions of the Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN - * THE SOFTWARE. - * - */ - -#include "2d/CCClippingNode.h" -#include "2d/CCDrawingPrimitives.h" -#include "renderer/CCGLProgramCache.h" -#include "renderer/ccGLStateCache.h" -#include "renderer/CCRenderer.h" -#include "base/CCDirector.h" -#include "base/CCStencilStateManager.hpp" - -#if (CC_TARGET_PLATFORM == CC_PLATFORM_MAC || CC_TARGET_PLATFORM == CC_PLATFORM_WIN32 || CC_TARGET_PLATFORM == CC_PLATFORM_LINUX) -#define CC_CLIPPING_NODE_OPENGLES 0 -#else -#define CC_CLIPPING_NODE_OPENGLES 1 -#endif - -NS_CC_BEGIN - -#if CC_CLIPPING_NODE_OPENGLES -static void setProgram(Node *n, GLProgram *p) -{ - n->setGLProgram(p); - - auto& children = n->getChildren(); - for(const auto &child : children) { - setProgram(child, p); - } -} -#endif - -ClippingNode::ClippingNode() -: _stencil(nullptr) -,_stencilStateManager(new StencilStateManager()) -,_originStencilProgram(nullptr) -{ -} - -ClippingNode::~ClippingNode() -{ - if (_stencil) - { - _stencil->stopAllActions(); - _stencil->release(); - } - CC_SAFE_DELETE(_stencilStateManager); -} - -ClippingNode* ClippingNode::create() -{ - ClippingNode *ret = new (std::nothrow) ClippingNode(); - if (ret && ret->init()) - { - ret->autorelease(); - } - else - { - CC_SAFE_DELETE(ret); - } - - return ret; -} - -ClippingNode* ClippingNode::create(Node *pStencil) -{ - ClippingNode *ret = new (std::nothrow) ClippingNode(); - if (ret && ret->init(pStencil)) - { - ret->autorelease(); - } - else - { - CC_SAFE_DELETE(ret); - } - - return ret; -} - -bool ClippingNode::init() -{ - return init(nullptr); -} - -bool ClippingNode::init(Node *stencil) -{ - setStencil(stencil); - return true; -} - -void ClippingNode::onEnter() -{ -#if CC_ENABLE_SCRIPT_BINDING - if (_scriptType == kScriptTypeJavascript) - { - if (ScriptEngineManager::sendNodeEventToJSExtended(this, kNodeOnEnter)) - return; - } -#endif - - Node::onEnter(); - - if (_stencil != nullptr) - { - _stencil->onEnter(); - } - else - { - CCLOG("ClippingNode warning: _stencil is nil."); - } -} - -void ClippingNode::onEnterTransitionDidFinish() -{ -#if CC_ENABLE_SCRIPT_BINDING - if (_scriptType == kScriptTypeJavascript) - { - if (ScriptEngineManager::sendNodeEventToJSExtended(this, kNodeOnEnterTransitionDidFinish)) - return; - } -#endif - - Node::onEnterTransitionDidFinish(); - - if (_stencil != nullptr) - { - _stencil->onEnterTransitionDidFinish(); - } -} - -void ClippingNode::onExitTransitionDidStart() -{ -#if CC_ENABLE_SCRIPT_BINDING - if (_scriptType == kScriptTypeJavascript) - { - if (ScriptEngineManager::sendNodeEventToJSExtended(this, kNodeOnExitTransitionDidStart)) - return; - } -#endif - - if (_stencil != nullptr) - { - _stencil->onExitTransitionDidStart(); - } - - Node::onExitTransitionDidStart(); -} - -void ClippingNode::onExit() -{ -#if CC_ENABLE_SCRIPT_BINDING - if (_scriptType == kScriptTypeJavascript) - { - if (ScriptEngineManager::sendNodeEventToJSExtended(this, kNodeOnExit)) - return; - } -#endif - - if (_stencil != nullptr) - { - _stencil->onExit(); - } - - Node::onExit(); -} - - -void ClippingNode::visit(Renderer *renderer, const Mat4 &parentTransform, uint32_t parentFlags) -{ - if (!_visible || !hasContent()) - return; - - if (_beforeVisitCallback && *_beforeVisitCallback) { - (*_beforeVisitCallback)(renderer); - } - - uint32_t flags = processParentFlags(parentTransform, parentFlags); - - // IMPORTANT: - // To ease the migration to v3.0, we still support the Mat4 stack, - // but it is deprecated and your code should not rely on it - Director* director = Director::getInstance(); - CCASSERT(nullptr != director, "Director is null when setting matrix stack"); - director->pushMatrix(MATRIX_STACK_TYPE::MATRIX_STACK_MODELVIEW); - director->loadMatrix(MATRIX_STACK_TYPE::MATRIX_STACK_MODELVIEW, _modelViewTransform); - - //Add group command - - _groupCommand.init(_globalZOrder); - renderer->addCommand(&_groupCommand); - - renderer->pushGroup(_groupCommand.getRenderQueueID()); - - _beforeVisitCmd.init(_globalZOrder); - _beforeVisitCmd.func = CC_CALLBACK_0(StencilStateManager::onBeforeVisit, _stencilStateManager); - renderer->addCommand(&_beforeVisitCmd); - - auto alphaThreshold = this->getAlphaThreshold(); - if (alphaThreshold < 1) - { -#if CC_CLIPPING_NODE_OPENGLES - // since glAlphaTest do not exists in OES, use a shader that writes - // pixel only if greater than an alpha threshold - GLProgram *program = GLProgramCache::getInstance()->getGLProgram(GLProgram::SHADER_NAME_POSITION_TEXTURE_ALPHA_TEST_NO_MV); - GLint alphaValueLocation = glGetUniformLocation(program->getProgram(), GLProgram::UNIFORM_NAME_ALPHA_TEST_VALUE); - // set our alphaThreshold - program->use(); - program->setUniformLocationWith1f(alphaValueLocation, alphaThreshold); - // we need to recursively apply this shader to all the nodes in the stencil node - // FIXME: we should have a way to apply shader to all nodes without having to do this - setProgram(_stencil, program); -#endif - - } - - if (_stencil != nullptr) - _stencil->visit(renderer, _modelViewTransform, flags); - - _afterDrawStencilCmd.init(_globalZOrder); - _afterDrawStencilCmd.func = CC_CALLBACK_0(StencilStateManager::onAfterDrawStencil, _stencilStateManager); - renderer->addCommand(&_afterDrawStencilCmd); - - int i = 0; - - if(!_children.empty()) - { - sortAllChildren(); - // draw children zOrder < 0 - for( ; i < _children.size(); i++ ) - { - auto node = _children.at(i); - - if ( node && node->getLocalZOrder() < 0 ) - node->visit(renderer, _modelViewTransform, flags); - else - break; - } - - // self draw - draw(renderer, _modelViewTransform, flags); - - for(auto it=_children.cbegin()+i; it != _children.cend(); ++it) - (*it)->visit(renderer, _modelViewTransform, flags); - } - else - { - draw(renderer, _modelViewTransform, flags); - } - - _afterVisitCmd.init(_globalZOrder); - _afterVisitCmd.func = CC_CALLBACK_0(StencilStateManager::onAfterVisit, _stencilStateManager); - renderer->addCommand(&_afterVisitCmd); - - renderer->popGroup(); - - _director->popMatrix(MATRIX_STACK_TYPE::MATRIX_STACK_MODELVIEW); - - if (_afterVisitCallback && *_afterVisitCallback) { - (*_afterVisitCallback)(renderer); - } -} - -Node* ClippingNode::getStencil() const -{ - return _stencil; -} - -void ClippingNode::setStencil(Node *stencil) -{ - //early out if the stencil is already set - if (_stencil == stencil) - return; - -#if CC_ENABLE_GC_FOR_NATIVE_OBJECTS - auto sEngine = ScriptEngineManager::getInstance()->getScriptEngine(); - if (sEngine) - { - if (_stencil) - sEngine->releaseScriptObject(this, _stencil); - if (stencil) - sEngine->retainScriptObject(this, stencil); - } -#endif // CC_ENABLE_GC_FOR_NATIVE_OBJECTS - - //cleanup current stencil - if(_stencil != nullptr && _stencil->isRunning()) - { - _stencil->onExitTransitionDidStart(); - _stencil->onExit(); - } - CC_SAFE_RELEASE_NULL(_stencil); - - //initialise new stencil - _stencil = stencil; - CC_SAFE_RETAIN(_stencil); - if(_stencil != nullptr && this->isRunning()) - { - _stencil->onEnter(); - if(this->_isTransitionFinished) - { - _stencil->onEnterTransitionDidFinish(); - } - } - - if (_stencil != nullptr) - _originStencilProgram = _stencil->getGLProgram(); -} - -bool ClippingNode::hasContent() const -{ - return _children.size() > 0; -} - -GLfloat ClippingNode::getAlphaThreshold() const -{ - return _stencilStateManager->getAlphaThreshold(); -} - -void ClippingNode::setAlphaThreshold(GLfloat alphaThreshold) -{ -#if CC_CLIPPING_NODE_OPENGLES - if (alphaThreshold == 1 && alphaThreshold != _stencilStateManager->getAlphaThreshold()) - { - // should reset program used by _stencil - if (_stencil) - setProgram(_stencil, _originStencilProgram); - } -#endif - - _stencilStateManager->setAlphaThreshold(alphaThreshold); -} - -bool ClippingNode::isInverted() const -{ - return _stencilStateManager->isInverted(); -} - -void ClippingNode::setInverted(bool inverted) -{ - _stencilStateManager->setInverted(inverted); -} - - -NS_CC_END - diff --git a/native/cocos/2d/CCClippingNode.h b/native/cocos/2d/CCClippingNode.h deleted file mode 100644 index 1305ec741f..0000000000 --- a/native/cocos/2d/CCClippingNode.h +++ /dev/null @@ -1,174 +0,0 @@ -/* - * Copyright (c) 2012 Pierre-David Bélanger - * Copyright (c) 2012 cocos2d-x.org - * Copyright (c) 2013-2016 Chukong Technologies Inc. - * Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - * - * http://www.cocos2d-x.org - * - * Permission is hereby granted, free of charge, to any person obtaining a copy - * of this software and associated documentation files (the "Software"), to deal - * in the Software without restriction, including without limitation the rights - * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell - * copies of the Software, and to permit persons to whom the Software is - * furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice shall be included in - * all copies or substantial portions of the Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN - * THE SOFTWARE. - * - */ - -#ifndef __MISCNODE_CCCLIPPING_NODE_H__ -#define __MISCNODE_CCCLIPPING_NODE_H__ - -#include "2d/CCNode.h" -#include "platform/CCGL.h" -#include "renderer/CCGroupCommand.h" -#include "renderer/CCCustomCommand.h" - -NS_CC_BEGIN - -class StencilStateManager; -/** - * @addtogroup _2d - * @{ - */ -/** ClippingNode is a subclass of Node. - * It draws its content (children) clipped using a stencil. - * The stencil is an other Node that will not be drawn. - * The clipping is done using the alpha part of the stencil (adjusted with an alphaThreshold). - */ -class CC_DLL ClippingNode : public Node -{ -public: - /** Creates and initializes a clipping node without a stencil. - * - * @return An autorelease ClippingNode. - */ - static ClippingNode* create(); - - /** Creates and initializes a clipping node with an other node as its stencil. - * The stencil node will be retained. - * @param stencil The stencil node. - */ - static ClippingNode* create(Node *stencil); - - /** The Node to use as a stencil to do the clipping. - * The stencil node will be retained. - * This default to nil. - * - * @return The stencil node. - */ - Node* getStencil() const; - - /** Set the Node to use as a stencil to do the clipping. - * - * @param stencil The Node to use as a stencil to do the clipping. - */ - void setStencil(Node *stencil); - - /** If stencil has no children it will not be drawn. - * If you have custom stencil-based node with stencil drawing mechanics other then children-based, - * then this method should return true every time you wish stencil to be visited. - * By default returns true if has any children attached. - * - * @return If you have custom stencil-based node with stencil drawing mechanics other then children-based, - * then this method should return true every time you wish stencil to be visited. - * By default returns true if has any children attached. - * @js NA - */ - virtual bool hasContent() const; - - /** The alpha threshold. - * The content is drawn only where the stencil have pixel with alpha greater than the alphaThreshold. - * Should be a float between 0 and 1. - * This default to 1 (so alpha test is disabled). - * - * @return The alpha threshold value,Should be a float between 0 and 1. - */ - GLfloat getAlphaThreshold() const; - - /** Set the alpha threshold. - * - * @param alphaThreshold The alpha threshold. - */ - void setAlphaThreshold(GLfloat alphaThreshold); - - /** Inverted. If this is set to true, - * the stencil is inverted, so the content is drawn where the stencil is NOT drawn. - * This default to false. - * - * @return If the clippingNode is Inverted, it will be return true. - */ - bool isInverted() const; - - /** Set the ClippingNode whether or not invert. - * - * @param inverted A bool Type,to set the ClippingNode whether or not invert. - */ - void setInverted(bool inverted); - - // Overrides - /** - * @lua NA - */ - virtual void onEnter() override; - /** - * @lua NA - */ - virtual void onEnterTransitionDidFinish() override; - /** - * @lua NA - */ - virtual void onExitTransitionDidStart() override; - /** - * @lua NA - */ - virtual void onExit() override; - virtual void visit(Renderer *renderer, const Mat4 &parentTransform, uint32_t parentFlags) override; - -CC_CONSTRUCTOR_ACCESS: - ClippingNode(); - - /** - * @js NA - * @lua NA - */ - virtual ~ClippingNode(); - - /** Initializes a clipping node without a stencil. - */ - virtual bool init() override; - - /** Initializes a clipping node with an other node as its stencil. - The stencil node will be retained, and its parent will be set to this clipping node. - */ - virtual bool init(Node *stencil); - -protected: - Node* _stencil; - GLProgram* _originStencilProgram; - - StencilStateManager* _stencilStateManager; - - GroupCommand _groupCommand; - CustomCommand _beforeVisitCmd; - CustomCommand _afterDrawStencilCmd; - CustomCommand _afterVisitCmd; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(ClippingNode); -}; -/** @} */ -NS_CC_END - -#endif // __MISCNODE_CCCLIPPING_NODE_H__ - diff --git a/native/cocos/2d/CCClippingRectangleNode.cpp b/native/cocos/2d/CCClippingRectangleNode.cpp deleted file mode 100644 index 61ff1b1851..0000000000 --- a/native/cocos/2d/CCClippingRectangleNode.cpp +++ /dev/null @@ -1,110 +0,0 @@ -/**************************************************************************** - Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - - http://www.cocos.com - - Permission is hereby granted, free of charge, to any person obtaining a copy - of this software and associated engine source code (the "Software"), a limited, - worldwide, royalty-free, non-assignable, revocable and non-exclusive license - to use Cocos Creator solely to develop games on your target platforms. You shall - not use Cocos Creator software for developing other software or tools that's - used for developing games. You are not granted to publish, distribute, - sublicense, and/or sell copies of Cocos Creator. - - The software or tools in this License Agreement are licensed, not sold. - Xiamen Yaji Software Co., Ltd. reserves all rights not expressly granted to you. - - THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN - THE SOFTWARE. - ****************************************************************************/ - - -#include "2d/CCClippingRectangleNode.h" -#include "base/CCDirector.h" -#include "renderer/CCRenderer.h" -#include "math/Vec2.h" -#include "platform/CCGLView.h" - -NS_CC_BEGIN - -ClippingRectangleNode* ClippingRectangleNode::create(const Rect& clippingRegion) -{ - ClippingRectangleNode* node = new (std::nothrow) ClippingRectangleNode(); - if (node && node->init()) { - node->setClippingRegion(clippingRegion); - node->autorelease(); - } else { - CC_SAFE_DELETE(node); - } - - return node; -} - -ClippingRectangleNode* ClippingRectangleNode::create() -{ - ClippingRectangleNode* node = new (std::nothrow) ClippingRectangleNode(); - if (node && node->init()) { - node->autorelease(); - } else { - CC_SAFE_DELETE(node); - } - - return node; -} - -void ClippingRectangleNode::setClippingRegion(const Rect &clippingRegion) -{ - _clippingRegion = clippingRegion; -} - -void ClippingRectangleNode::onBeforeVisitScissor() -{ - if (_clippingEnabled) { - glEnable(GL_SCISSOR_TEST); - - float scaleX = _scaleX; - float scaleY = _scaleY; - Node *parent = this->getParent(); - while (parent) { - scaleX *= parent->getScaleX(); - scaleY *= parent->getScaleY(); - parent = parent->getParent(); - } - - const Point pos = convertToWorldSpace(Point(_clippingRegion.origin.x, _clippingRegion.origin.y)); - GLView* glView = Director::getInstance()->getOpenGLView(); - glView->setScissorInPoints(pos.x, - pos.y, - _clippingRegion.size.width * scaleX, - _clippingRegion.size.height * scaleY); - } -} - -void ClippingRectangleNode::onAfterVisitScissor() -{ - if (_clippingEnabled) - { - glDisable(GL_SCISSOR_TEST); - } -} - -void ClippingRectangleNode::visit(Renderer *renderer, const Mat4 &parentTransform, uint32_t parentFlags) -{ - _beforeVisitCmdScissor.init(_globalZOrder); - _beforeVisitCmdScissor.func = CC_CALLBACK_0(ClippingRectangleNode::onBeforeVisitScissor, this); - renderer->addCommand(&_beforeVisitCmdScissor); - - Node::visit(renderer, parentTransform, parentFlags); - - _afterVisitCmdScissor.init(_globalZOrder); - _afterVisitCmdScissor.func = CC_CALLBACK_0(ClippingRectangleNode::onAfterVisitScissor, this); - renderer->addCommand(&_afterVisitCmdScissor); -} - -NS_CC_END - diff --git a/native/cocos/2d/CCClippingRectangleNode.h b/native/cocos/2d/CCClippingRectangleNode.h deleted file mode 100644 index 8840de714f..0000000000 --- a/native/cocos/2d/CCClippingRectangleNode.h +++ /dev/null @@ -1,119 +0,0 @@ -/* - * cocos2d for iPhone: http://www.cocos2d-iphone.org - * cocos2d-x: http://www.cocos2d-x.org - * - * Copyright (c) 2012 Pierre-David Bélanger - * Copyright (c) 2012 cocos2d-x.org - * Copyright (c) 2013-2016 Chukong Technologies Inc. - * Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - * - * Permission is hereby granted, free of charge, to any person obtaining a copy - * of this software and associated documentation files (the "Software"), to deal - * in the Software without restriction, including without limitation the rights - * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell - * copies of the Software, and to permit persons to whom the Software is - * furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice shall be included in - * all copies or substantial portions of the Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN - * THE SOFTWARE. - * - */ - -#ifndef __MISCNODE_CCCLIPPING_RECTANGLE_NODE_H__ -#define __MISCNODE_CCCLIPPING_RECTANGLE_NODE_H__ - -#include "2d/CCNode.h" -#include "renderer/CCCustomCommand.h" -#include "platform/CCGL.h" - -NS_CC_BEGIN - -/** - * @addtogroup _2d - * @{ - */ - -/** -@brief Clipping Rectangle Node. -@details A node that clipped with specified rectangle. - The region of ClippingRectangleNode doesn't support any transform except scale. -@js NA -*/ -class CC_DLL ClippingRectangleNode : public Node -{ -public: - /** - @brief Create node with specified clipping region. - @param clippingRegion Specify the clipping rectangle. - @return If the creation success, return a pointer of ClippingRectangleNode; otherwise return nil. - */ - static ClippingRectangleNode* create(const Rect& clippingRegion); - /** - @brief Create a clipping rectangle node. - @return If the creation success, return a pointer of ClippingRectangleNode; otherwise return nil. - */ - static ClippingRectangleNode* create(); - - /** - @brief Get the clipping rectangle. - @return The clipping rectangle. - */ - const Rect& getClippingRegion() const { - return _clippingRegion; - } - /** - @brief Set the clipping rectangle. - @param clippingRegion Specify the clipping rectangle. - */ - void setClippingRegion(const Rect& clippingRegion); - - /** - @brief Get whether the clipping is enabled or not. - @return Whether the clipping is enabled or not. Default is true. - */ - bool isClippingEnabled() const { - return _clippingEnabled; - } - - /** - @brief Enable/Disable the clipping. - @param enabled Pass true to enable clipping. Pass false to disable clipping. - */ - void setClippingEnabled(bool enabled) { - _clippingEnabled = enabled; - } - - //virtual void draw(Renderer* renderer, const Mat4 &transform, uint32_t flags) override; - virtual void visit(Renderer *renderer, const Mat4 &parentTransform, uint32_t parentFlags) override; - -protected: - ClippingRectangleNode() - : _clippingEnabled(true) - { - } - - void onBeforeVisitScissor(); - void onAfterVisitScissor(); - - Rect _clippingRegion; - bool _clippingEnabled; - - CustomCommand _beforeVisitCmdScissor; - CustomCommand _afterVisitCmdScissor; -}; - -// end of _2d group -/// @} - -NS_CC_END - -#endif - diff --git a/native/cocos/2d/CCComponent.cpp b/native/cocos/2d/CCComponent.cpp deleted file mode 100644 index 31fba16eee..0000000000 --- a/native/cocos/2d/CCComponent.cpp +++ /dev/null @@ -1,154 +0,0 @@ -/**************************************************************************** -Copyright (c) 2013-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ - -#include "2d/CCComponent.h" - -NS_CC_BEGIN - -Component::Component() -: _owner(nullptr) -, _enabled(true) -{ -#if CC_ENABLE_SCRIPT_BINDING - ScriptEngineProtocol* engine = ScriptEngineManager::getInstance()->getScriptEngine(); - _scriptType = engine != nullptr ? engine->getScriptType() : kScriptTypeNone; -#endif -} - -Component::~Component() -{ -} - -bool Component::init() -{ - return true; -} - -#if CC_ENABLE_SCRIPT_BINDING - -static bool sendComponentEventToJS(Component* node, int action) -{ - auto scriptEngine = ScriptEngineManager::getInstance()->getScriptEngine(); - - if (scriptEngine->isCalledFromScript()) - { - scriptEngine->setCalledFromScript(false); - } - else - { - BasicScriptData data(node,(void*)&action); - ScriptEvent scriptEvent(kComponentEvent,(void*)&data); - if (scriptEngine->sendEvent(&scriptEvent)) - return true; - } - - return false; -} - -#endif - -void Component::onEnter() -{ -#if CC_ENABLE_SCRIPT_BINDING - if (_scriptType == kScriptTypeJavascript) - { - sendComponentEventToJS(this, kComponentOnEnter); - } -#endif -} - -void Component::onExit() -{ -#if CC_ENABLE_SCRIPT_BINDING - if (_scriptType == kScriptTypeJavascript) - { - sendComponentEventToJS(this, kComponentOnExit); - } -#endif -} - -void Component::onAdd() -{ -#if CC_ENABLE_SCRIPT_BINDING - if (_scriptType == kScriptTypeJavascript) - { - sendComponentEventToJS(this, kComponentOnAdd); - } -#endif -} - -void Component::onRemove() -{ -#if CC_ENABLE_SCRIPT_BINDING - if (_scriptType == kScriptTypeJavascript) - { - sendComponentEventToJS(this, kComponentOnRemove); - } -#endif -} - -void Component::update(float delta) -{ -#if CC_ENABLE_SCRIPT_BINDING - if (_scriptType == kScriptTypeJavascript) - { - sendComponentEventToJS(this, kComponentOnUpdate); - } -#endif -} - -bool Component::serialize(void *ar) -{ - return true; -} - -Component* Component::create() -{ - Component * ret = new (std::nothrow) Component(); - - if (ret && ret->init()) - { - ret->autorelease(); - } - else - { - CC_SAFE_DELETE(ret); - } - - return ret; -} - -void Component::setOwner(Node *owner) -{ - _owner = owner; -} - -void Component::setEnabled(bool enabled) -{ - _enabled = enabled; -} - -NS_CC_END - diff --git a/native/cocos/2d/CCComponent.h b/native/cocos/2d/CCComponent.h deleted file mode 100644 index fd4434f8ac..0000000000 --- a/native/cocos/2d/CCComponent.h +++ /dev/null @@ -1,96 +0,0 @@ -/**************************************************************************** -Copyright (c) 2013-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ - -#ifndef __CC_FRAMEWORK_COMPONENT_H__ -#define __CC_FRAMEWORK_COMPONENT_H__ - -/// @cond DO_NOT_SHOW -#include -#include "base/CCRef.h" -#include "base/CCScriptSupport.h" - -NS_CC_BEGIN - -class Node; - -enum { - kComponentOnEnter, - kComponentOnExit, - kComponentOnAdd, - kComponentOnRemove, - kComponentOnUpdate -}; - -class CC_DLL Component : public Ref -{ -public: - static Component* create(); - - /** - * @js NA - * @lua NA - */ - virtual ~Component(); - - virtual bool init(); - - bool isEnabled() const { return _enabled; } - virtual void setEnabled(bool enabled); - - const std::string& getName() const { return _name; } - virtual void setName(const std::string& name) { _name = name; } - - Node* getOwner() const { return _owner; } - virtual void setOwner(Node *owner); - - virtual void update(float delta); - virtual bool serialize(void* r); - - virtual void onEnter(); - virtual void onExit(); - virtual void onAdd(); - virtual void onRemove(); - -CC_CONSTRUCTOR_ACCESS: - /** - * @js ctor - */ - Component(); - -protected: - Node* _owner; - std::string _name; - bool _enabled; - -#if CC_ENABLE_SCRIPT_BINDING - ccScriptType _scriptType; ///< type of script binding, lua or javascript -#endif -}; - -NS_CC_END - -/// @endcond -#endif // __CC_FRAMEWORK_COMPONENT_H__ - diff --git a/native/cocos/2d/CCComponentContainer.cpp b/native/cocos/2d/CCComponentContainer.cpp deleted file mode 100644 index b108867a36..0000000000 --- a/native/cocos/2d/CCComponentContainer.cpp +++ /dev/null @@ -1,153 +0,0 @@ -/**************************************************************************** -Copyright (c) 2013-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ - - -#include "2d/CCComponentContainer.h" -#include "2d/CCComponent.h" -#include "2d/CCNode.h" - -NS_CC_BEGIN - -ComponentContainer::ComponentContainer(Node* node) -: _owner(node) -{ -} - -ComponentContainer::~ComponentContainer() -{ -} - -Component* ComponentContainer::get(const std::string& name) const -{ - Component* ret = nullptr; - - auto it = _componentMap.find(name); - if (it != _componentMap.end()) - { - ret = it->second; - } - - return ret; -} - -bool ComponentContainer::add(Component *com) -{ - bool ret = false; - CCASSERT(com != nullptr, "Component must be non-nil"); - CCASSERT(com->getOwner() == nullptr, "Component already added. It can't be added again"); - do - { - auto componentName = com->getName(); - - if (_componentMap.find(componentName) != _componentMap.end()) - { - CCASSERT(false, "ComponentContainer already have this kind of component"); - break; - } - _componentMap[componentName] = com; - com->retain(); - com->setOwner(_owner); - com->onAdd(); - - ret = true; - } while(0); - return ret; -} - -bool ComponentContainer::remove(const std::string& componentName) -{ - bool ret = false; - do - { - auto iter = _componentMap.find(componentName); - CC_BREAK_IF(iter == _componentMap.end()); - - auto component = iter->second; - _componentMap.erase(componentName); - - component->onRemove(); - component->setOwner(nullptr); - component->release(); - - ret = true; - } while(0); - - return ret; - } - -bool ComponentContainer::remove(Component *com) -{ - return remove(com->getName()); -} - -void ComponentContainer::removeAll() -{ - if (!_componentMap.empty()) - { - for (auto iter = _componentMap.begin(); iter != _componentMap.end(); ++iter) - { - auto component = iter->second; - component->onRemove(); - component->setOwner(nullptr); - component->release(); - } - - _componentMap.clear(); - _owner->unscheduleUpdate(); - } -} - -void ComponentContainer::visit(float delta) -{ - if (!_componentMap.empty()) - { - CC_SAFE_RETAIN(_owner); - auto iterEnd = _componentMap.end(); - for (auto iter = _componentMap.begin(); iter != iterEnd; ++iter) - { - iter->second->update(delta); - } - CC_SAFE_RELEASE(_owner); - } -} - -void ComponentContainer::onEnter() -{ - for (auto iter = _componentMap.begin(); iter != _componentMap.end(); ++iter) - { - iter->second->onEnter(); - } -} - -void ComponentContainer::onExit() -{ - for (auto iter = _componentMap.begin(); iter != _componentMap.end(); ++iter) - { - iter->second->onExit(); - } -} - -NS_CC_END - diff --git a/native/cocos/2d/CCComponentContainer.h b/native/cocos/2d/CCComponentContainer.h deleted file mode 100644 index c7e4e45618..0000000000 --- a/native/cocos/2d/CCComponentContainer.h +++ /dev/null @@ -1,80 +0,0 @@ -/**************************************************************************** -Copyright (c) 2013-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ - -#ifndef __CC_FRAMEWORK_COMCONTAINER_H__ -#define __CC_FRAMEWORK_COMCONTAINER_H__ - -/// @cond DO_NOT_SHOW - -#include "base/CCMap.h" -#include - -NS_CC_BEGIN - -class Component; -class Node; - -class CC_DLL ComponentContainer -{ -protected: - /** - * @js ctor - */ - ComponentContainer(Node* node); - -public: - /** - * @js NA - * @lua NA - */ - ~ComponentContainer(); - - /** - * @js getComponent - */ - Component* get(const std::string& name) const; - - bool add(Component *com); - bool remove(const std::string& name); - bool remove(Component *com); - void removeAll(); - void visit(float delta); - - void onEnter(); - void onExit(); - - bool isEmpty() const { return _componentMap.empty(); } -private: - std::unordered_map _componentMap; - Node *_owner; - - friend class Node; -}; - -NS_CC_END - -/// @endcond -#endif // __CC_FRAMEWORK_COMCONTAINER_H__ - diff --git a/native/cocos/2d/CCDrawNode.cpp b/native/cocos/2d/CCDrawNode.cpp deleted file mode 100644 index d353aa5b7d..0000000000 --- a/native/cocos/2d/CCDrawNode.cpp +++ /dev/null @@ -1,953 +0,0 @@ -/* Copyright (c) 2012 Scott Lembcke and Howling Moon Software - * Copyright (c) 2012 cocos2d-x.org - * Copyright (c) 2013-2016 Chukong Technologies Inc. - * Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - * - * Permission is hereby granted, free of charge, to any person obtaining a copy - * of this software and associated documentation files (the "Software"), to deal - * in the Software without restriction, including without limitation the rights - * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell - * copies of the Software, and to permit persons to whom the Software is - * furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice shall be included in - * all copies or substantial portions of the Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE - * SOFTWARE. - */ - -#include "2d/CCDrawNode.h" -#include "base/CCEventType.h" -#include "base/CCConfiguration.h" -#include "renderer/CCRenderer.h" -#include "renderer/ccGLStateCache.h" -#include "renderer/CCGLProgramState.h" -#include "renderer/CCGLProgramCache.h" -#include "base/CCDirector.h" -#include "base/CCEventListenerCustom.h" -#include "base/CCEventDispatcher.h" -#include "2d/CCActionCatmullRom.h" -#include "platform/CCGL.h" - -NS_CC_BEGIN - -// Vec2 == CGPoint in 32-bits, but not in 64-bits (OS X) -// that's why the "v2f" functions are needed -static Vec2 v2fzero(0.0f,0.0f); - -static inline Vec2 v2f(float x, float y) -{ - Vec2 ret(x, y); - return ret; -} - -static inline Vec2 v2fadd(const Vec2 &v0, const Vec2 &v1) -{ - return v2f(v0.x+v1.x, v0.y+v1.y); -} - -static inline Vec2 v2fsub(const Vec2 &v0, const Vec2 &v1) -{ - return v2f(v0.x-v1.x, v0.y-v1.y); -} - -static inline Vec2 v2fmult(const Vec2 &v, float s) -{ - return v2f(v.x * s, v.y * s); -} - -static inline Vec2 v2fperp(const Vec2 &p0) -{ - return v2f(-p0.y, p0.x); -} - -static inline Vec2 v2fneg(const Vec2 &p0) -{ - return v2f(-p0.x, - p0.y); -} - -static inline float v2fdot(const Vec2 &p0, const Vec2 &p1) -{ - return p0.x * p1.x + p0.y * p1.y; -} - -static inline Vec2 v2fforangle(float _a_) -{ - return v2f(cosf(_a_), sinf(_a_)); -} - -static inline Vec2 v2fnormalize(const Vec2 &p) -{ - Vec2 r(p.x, p.y); - r.normalize(); - return v2f(r.x, r.y); -} - -static inline Vec2 __v2f(const Vec2 &v) -{ -//#ifdef __LP64__ - return v2f(v.x, v.y); -// #else -// return * ((Vec2*) &v); -// #endif -} - -static inline Tex2F __t(const Vec2 &v) -{ - return *(Tex2F*)&v; -} - -// implementation of DrawNode - -DrawNode::DrawNode(int lineWidth) -: _vao(0) -, _vbo(0) -, _vaoGLPoint(0) -, _vboGLPoint(0) -, _vaoGLLine(0) -, _vboGLLine(0) -, _bufferCapacity(0) -, _bufferCount(0) -, _buffer(nullptr) -, _bufferCapacityGLPoint(0) -, _bufferCountGLPoint(0) -, _bufferGLPoint(nullptr) -, _bufferCapacityGLLine(0) -, _bufferCountGLLine(0) -, _bufferGLLine(nullptr) -, _dirty(false) -, _dirtyGLPoint(false) -, _dirtyGLLine(false) -, _lineWidth(lineWidth) -, _defaultLineWidth(lineWidth) -{ - _blendFunc = BlendFunc::ALPHA_PREMULTIPLIED; -} - -DrawNode::~DrawNode() -{ - free(_buffer); - _buffer = nullptr; - free(_bufferGLPoint); - _bufferGLPoint = nullptr; - free(_bufferGLLine); - _bufferGLLine = nullptr; - - glDeleteBuffers(1, &_vbo); - glDeleteBuffers(1, &_vboGLLine); - glDeleteBuffers(1, &_vboGLPoint); - _vbo = 0; - _vboGLPoint = 0; - _vboGLLine = 0; - - if (Configuration::getInstance()->supportsShareableVAO()) - { - GL::bindVAO(0); - glDeleteVertexArrays(1, &_vao); - glDeleteVertexArrays(1, &_vaoGLLine); - glDeleteVertexArrays(1, &_vaoGLPoint); - _vao = _vaoGLLine = _vaoGLPoint = 0; - } -} - -DrawNode* DrawNode::create(int defaultLineWidth) -{ - DrawNode* ret = new (std::nothrow) DrawNode(defaultLineWidth); - if (ret && ret->init()) - { - ret->autorelease(); - } - else - { - CC_SAFE_DELETE(ret); - } - - return ret; -} - -void DrawNode::ensureCapacity(int count) -{ - CCASSERT(count>=0, "capacity must be >= 0"); - - if(_bufferCount + count > _bufferCapacity) - { - _bufferCapacity += MAX(_bufferCapacity, count); - _buffer = (V2F_C4B_T2F*)realloc(_buffer, _bufferCapacity*sizeof(V2F_C4B_T2F)); - } -} - -void DrawNode::ensureCapacityGLPoint(int count) -{ - CCASSERT(count>=0, "capacity must be >= 0"); - - if(_bufferCountGLPoint + count > _bufferCapacityGLPoint) - { - _bufferCapacityGLPoint += MAX(_bufferCapacityGLPoint, count); - _bufferGLPoint = (V2F_C4B_T2F*)realloc(_bufferGLPoint, _bufferCapacityGLPoint*sizeof(V2F_C4B_T2F)); - } -} - -void DrawNode::ensureCapacityGLLine(int count) -{ - CCASSERT(count>=0, "capacity must be >= 0"); - - if(_bufferCountGLLine + count > _bufferCapacityGLLine) - { - _bufferCapacityGLLine += MAX(_bufferCapacityGLLine, count); - _bufferGLLine = (V2F_C4B_T2F*)realloc(_bufferGLLine, _bufferCapacityGLLine*sizeof(V2F_C4B_T2F)); - } -} - -bool DrawNode::init() -{ - _blendFunc = BlendFunc::ALPHA_PREMULTIPLIED; - - setGLProgramState(GLProgramState::getOrCreateWithGLProgramName(GLProgram::SHADER_NAME_POSITION_LENGTH_TEXTURE_COLOR)); - - ensureCapacity(512); - ensureCapacityGLPoint(64); - ensureCapacityGLLine(256); - - if (Configuration::getInstance()->supportsShareableVAO()) - { - glGenVertexArrays(1, &_vao); - GL::bindVAO(_vao); - glGenBuffers(1, &_vbo); - glBindBuffer(GL_ARRAY_BUFFER, _vbo); - glBufferData(GL_ARRAY_BUFFER, sizeof(V2F_C4B_T2F)* _bufferCapacity, _buffer, GL_STREAM_DRAW); - // vertex - glEnableVertexAttribArray(GLProgram::VERTEX_ATTRIB_POSITION); - glVertexAttribPointer(GLProgram::VERTEX_ATTRIB_POSITION, 2, GL_FLOAT, GL_FALSE, sizeof(V2F_C4B_T2F), (GLvoid *)offsetof(V2F_C4B_T2F, vertices)); - // color - glEnableVertexAttribArray(GLProgram::VERTEX_ATTRIB_COLOR); - glVertexAttribPointer(GLProgram::VERTEX_ATTRIB_COLOR, 4, GL_UNSIGNED_BYTE, GL_TRUE, sizeof(V2F_C4B_T2F), (GLvoid *)offsetof(V2F_C4B_T2F, colors)); - // texcood - glEnableVertexAttribArray(GLProgram::VERTEX_ATTRIB_TEX_COORD); - glVertexAttribPointer(GLProgram::VERTEX_ATTRIB_TEX_COORD, 2, GL_FLOAT, GL_FALSE, sizeof(V2F_C4B_T2F), (GLvoid *)offsetof(V2F_C4B_T2F, texCoords)); - - glGenVertexArrays(1, &_vaoGLLine); - GL::bindVAO(_vaoGLLine); - glGenBuffers(1, &_vboGLLine); - glBindBuffer(GL_ARRAY_BUFFER, _vboGLLine); - glBufferData(GL_ARRAY_BUFFER, sizeof(V2F_C4B_T2F)*_bufferCapacityGLLine, _bufferGLLine, GL_STREAM_DRAW); - // vertex - glEnableVertexAttribArray(GLProgram::VERTEX_ATTRIB_POSITION); - glVertexAttribPointer(GLProgram::VERTEX_ATTRIB_POSITION, 2, GL_FLOAT, GL_FALSE, sizeof(V2F_C4B_T2F), (GLvoid *)offsetof(V2F_C4B_T2F, vertices)); - // color - glEnableVertexAttribArray(GLProgram::VERTEX_ATTRIB_COLOR); - glVertexAttribPointer(GLProgram::VERTEX_ATTRIB_COLOR, 4, GL_UNSIGNED_BYTE, GL_TRUE, sizeof(V2F_C4B_T2F), (GLvoid *)offsetof(V2F_C4B_T2F, colors)); - // texcood - glEnableVertexAttribArray(GLProgram::VERTEX_ATTRIB_TEX_COORD); - glVertexAttribPointer(GLProgram::VERTEX_ATTRIB_TEX_COORD, 2, GL_FLOAT, GL_FALSE, sizeof(V2F_C4B_T2F), (GLvoid *)offsetof(V2F_C4B_T2F, texCoords)); - - glGenVertexArrays(1, &_vaoGLPoint); - GL::bindVAO(_vaoGLPoint); - glGenBuffers(1, &_vboGLPoint); - glBindBuffer(GL_ARRAY_BUFFER, _vboGLPoint); - glBufferData(GL_ARRAY_BUFFER, sizeof(V2F_C4B_T2F)*_bufferCapacityGLPoint, _bufferGLPoint, GL_STREAM_DRAW); - // vertex - glEnableVertexAttribArray(GLProgram::VERTEX_ATTRIB_POSITION); - glVertexAttribPointer(GLProgram::VERTEX_ATTRIB_POSITION, 2, GL_FLOAT, GL_FALSE, sizeof(V2F_C4B_T2F), (GLvoid *)offsetof(V2F_C4B_T2F, vertices)); - // color - glEnableVertexAttribArray(GLProgram::VERTEX_ATTRIB_COLOR); - glVertexAttribPointer(GLProgram::VERTEX_ATTRIB_COLOR, 4, GL_UNSIGNED_BYTE, GL_TRUE, sizeof(V2F_C4B_T2F), (GLvoid *)offsetof(V2F_C4B_T2F, colors)); - // Texture coord as pointsize - glEnableVertexAttribArray(GLProgram::VERTEX_ATTRIB_TEX_COORD); - glVertexAttribPointer(GLProgram::VERTEX_ATTRIB_TEX_COORD, 2, GL_FLOAT, GL_FALSE, sizeof(V2F_C4B_T2F), (GLvoid *)offsetof(V2F_C4B_T2F, texCoords)); - - GL::bindVAO(0); - glBindBuffer(GL_ARRAY_BUFFER, 0); - - } - else - { - glGenBuffers(1, &_vbo); - glBindBuffer(GL_ARRAY_BUFFER, _vbo); - glBufferData(GL_ARRAY_BUFFER, sizeof(V2F_C4B_T2F)* _bufferCapacity, _buffer, GL_STREAM_DRAW); - - glGenBuffers(1, &_vboGLLine); - glBindBuffer(GL_ARRAY_BUFFER, _vboGLLine); - glBufferData(GL_ARRAY_BUFFER, sizeof(V2F_C4B_T2F)*_bufferCapacityGLLine, _bufferGLLine, GL_STREAM_DRAW); - - glGenBuffers(1, &_vboGLPoint); - glBindBuffer(GL_ARRAY_BUFFER, _vboGLPoint); - glBufferData(GL_ARRAY_BUFFER, sizeof(V2F_C4B_T2F)*_bufferCapacityGLPoint, _bufferGLPoint, GL_STREAM_DRAW); - - glBindBuffer(GL_ARRAY_BUFFER, 0); - } - - CHECK_GL_ERROR_DEBUG(); - - _dirty = true; - _dirtyGLLine = true; - _dirtyGLPoint = true; - -#if CC_ENABLE_CACHE_TEXTURE_DATA - // Need to listen the event only when not use batchnode, because it will use VBO - auto listener = EventListenerCustom::create(EVENT_RENDERER_RECREATED, [this](EventCustom* event){ - /** listen the event that renderer was recreated on Android/WP8 */ - this->init(); - }); - - _eventDispatcher->addEventListenerWithSceneGraphPriority(listener, this); -#endif - - return true; -} - -void DrawNode::draw(Renderer *renderer, const Mat4 &transform, uint32_t flags) -{ - if(_bufferCount) - { - _customCommand.init(_globalZOrder, transform, flags); - _customCommand.func = CC_CALLBACK_0(DrawNode::onDraw, this, transform, flags); - renderer->addCommand(&_customCommand); - } - - if(_bufferCountGLPoint) - { - _customCommandGLPoint.init(_globalZOrder, transform, flags); - _customCommandGLPoint.func = CC_CALLBACK_0(DrawNode::onDrawGLPoint, this, transform, flags); - renderer->addCommand(&_customCommandGLPoint); - } - - if(_bufferCountGLLine) - { - _customCommandGLLine.init(_globalZOrder, transform, flags); - _customCommandGLLine.func = CC_CALLBACK_0(DrawNode::onDrawGLLine, this, transform, flags); - renderer->addCommand(&_customCommandGLLine); - } -} - -void DrawNode::onDraw(const Mat4 &transform, uint32_t flags) -{ - getGLProgramState()->apply(transform); - auto glProgram = this->getGLProgram(); - glProgram->setUniformLocationWith1f(glProgram->getUniformLocation("u_alpha"), _displayedOpacity / 255.0); - - GL::blendFunc(_blendFunc.src, _blendFunc.dst); - - if (_dirty) - { - glBindBuffer(GL_ARRAY_BUFFER, _vbo); - glBufferData(GL_ARRAY_BUFFER, sizeof(V2F_C4B_T2F)*_bufferCapacity, _buffer, GL_STREAM_DRAW); - - _dirty = false; - } - if (Configuration::getInstance()->supportsShareableVAO()) - { - GL::bindVAO(_vao); - } - else - { - GL::enableVertexAttribs(GL::VERTEX_ATTRIB_FLAG_POS_COLOR_TEX); - - glBindBuffer(GL_ARRAY_BUFFER, _vbo); - // vertex - glVertexAttribPointer(GLProgram::VERTEX_ATTRIB_POSITION, 2, GL_FLOAT, GL_FALSE, sizeof(V2F_C4B_T2F), (GLvoid *)offsetof(V2F_C4B_T2F, vertices)); - // color - glVertexAttribPointer(GLProgram::VERTEX_ATTRIB_COLOR, 4, GL_UNSIGNED_BYTE, GL_TRUE, sizeof(V2F_C4B_T2F), (GLvoid *)offsetof(V2F_C4B_T2F, colors)); - // texcood - glVertexAttribPointer(GLProgram::VERTEX_ATTRIB_TEX_COORD, 2, GL_FLOAT, GL_FALSE, sizeof(V2F_C4B_T2F), (GLvoid *)offsetof(V2F_C4B_T2F, texCoords)); - } - - glDrawArrays(GL_TRIANGLES, 0, _bufferCount); - glBindBuffer(GL_ARRAY_BUFFER, 0); - - if (Configuration::getInstance()->supportsShareableVAO()) - { - GL::bindVAO(0); - } - - CC_INCREMENT_GL_DRAWN_BATCHES_AND_VERTICES(1, _bufferCount); - CHECK_GL_ERROR_DEBUG(); -} - - -void DrawNode::onDrawGLLine(const Mat4 &transform, uint32_t flags) -{ - auto glProgram = GLProgramCache::getInstance()->getGLProgram(GLProgram::SHADER_NAME_POSITION_LENGTH_TEXTURE_COLOR); - glProgram->use(); - glProgram->setUniformsForBuiltins(transform); - glProgram->setUniformLocationWith1f(glProgram->getUniformLocation("u_alpha"), _displayedOpacity / 255.0); - - GL::blendFunc(_blendFunc.src, _blendFunc.dst); - - if (_dirtyGLLine) - { - glBindBuffer(GL_ARRAY_BUFFER, _vboGLLine); - glBufferData(GL_ARRAY_BUFFER, sizeof(V2F_C4B_T2F)*_bufferCapacityGLLine, _bufferGLLine, GL_STREAM_DRAW); - _dirtyGLLine = false; - } - if (Configuration::getInstance()->supportsShareableVAO()) - { - GL::bindVAO(_vaoGLLine); - } - else - { - glBindBuffer(GL_ARRAY_BUFFER, _vboGLLine); - GL::enableVertexAttribs(GL::VERTEX_ATTRIB_FLAG_POS_COLOR_TEX); - // vertex - glVertexAttribPointer(GLProgram::VERTEX_ATTRIB_POSITION, 2, GL_FLOAT, GL_FALSE, sizeof(V2F_C4B_T2F), (GLvoid *)offsetof(V2F_C4B_T2F, vertices)); - // color - glVertexAttribPointer(GLProgram::VERTEX_ATTRIB_COLOR, 4, GL_UNSIGNED_BYTE, GL_TRUE, sizeof(V2F_C4B_T2F), (GLvoid *)offsetof(V2F_C4B_T2F, colors)); - // texcood - glVertexAttribPointer(GLProgram::VERTEX_ATTRIB_TEX_COORD, 2, GL_FLOAT, GL_FALSE, sizeof(V2F_C4B_T2F), (GLvoid *)offsetof(V2F_C4B_T2F, texCoords)); - } - glLineWidth(_lineWidth); - glDrawArrays(GL_LINES, 0, _bufferCountGLLine); - - if (Configuration::getInstance()->supportsShareableVAO()) - { - GL::bindVAO(0); - } - - glBindBuffer(GL_ARRAY_BUFFER, 0); - - CC_INCREMENT_GL_DRAWN_BATCHES_AND_VERTICES(1,_bufferCountGLLine); - CHECK_GL_ERROR_DEBUG(); -} - -void DrawNode::onDrawGLPoint(const Mat4 &transform, uint32_t flags) -{ - auto glProgram = GLProgramCache::getInstance()->getGLProgram(GLProgram::SHADER_NAME_POSITION_COLOR_TEXASPOINTSIZE); - glProgram->use(); - glProgram->setUniformsForBuiltins(transform); - glProgram->setUniformLocationWith1f(glProgram->getUniformLocation("u_alpha"), _displayedOpacity / 255.0); - - GL::blendFunc(_blendFunc.src, _blendFunc.dst); - - if (_dirtyGLPoint) - { - glBindBuffer(GL_ARRAY_BUFFER, _vboGLPoint); - glBufferData(GL_ARRAY_BUFFER, sizeof(V2F_C4B_T2F)*_bufferCapacityGLPoint, _bufferGLPoint, GL_STREAM_DRAW); - - _dirtyGLPoint = false; - } - - if (Configuration::getInstance()->supportsShareableVAO()) - { - GL::bindVAO(_vaoGLPoint); - } - else - { - glBindBuffer(GL_ARRAY_BUFFER, _vboGLPoint); - GL::enableVertexAttribs( GL::VERTEX_ATTRIB_FLAG_POS_COLOR_TEX); - glVertexAttribPointer(GLProgram::VERTEX_ATTRIB_POSITION, 2, GL_FLOAT, GL_FALSE, sizeof(V2F_C4B_T2F), (GLvoid *)offsetof(V2F_C4B_T2F, vertices)); - glVertexAttribPointer(GLProgram::VERTEX_ATTRIB_COLOR, 4, GL_UNSIGNED_BYTE, GL_TRUE, sizeof(V2F_C4B_T2F), (GLvoid *)offsetof(V2F_C4B_T2F, colors)); - glVertexAttribPointer(GLProgram::VERTEX_ATTRIB_TEX_COORD, 2, GL_FLOAT, GL_FALSE, sizeof(V2F_C4B_T2F), (GLvoid *)offsetof(V2F_C4B_T2F, texCoords)); - } - - glDrawArrays(GL_POINTS, 0, _bufferCountGLPoint); - - if (Configuration::getInstance()->supportsShareableVAO()) - { - GL::bindVAO(0); - } - - glBindBuffer(GL_ARRAY_BUFFER, 0); - - CC_INCREMENT_GL_DRAWN_BATCHES_AND_VERTICES(1,_bufferCountGLPoint); - CHECK_GL_ERROR_DEBUG(); -} - -void DrawNode::drawPoint(const Vec2& position, const float pointSize, const Color4F &color) -{ - ensureCapacityGLPoint(1); - - V2F_C4B_T2F *point = (V2F_C4B_T2F*)(_bufferGLPoint + _bufferCountGLPoint); - V2F_C4B_T2F a = {position, Color4B(color), Tex2F(pointSize,0)}; - *point = a; - - _bufferCountGLPoint += 1; - _dirtyGLPoint = true; -} - -void DrawNode::drawPoints(const Vec2 *position, unsigned int numberOfPoints, const Color4F &color) -{ - drawPoints(position, numberOfPoints, 1.0, color); -} - -void DrawNode::drawPoints(const Vec2 *position, unsigned int numberOfPoints, const float pointSize, const Color4F &color) -{ - ensureCapacityGLPoint(numberOfPoints); - - V2F_C4B_T2F *point = (V2F_C4B_T2F*)(_bufferGLPoint + _bufferCountGLPoint); - - for(unsigned int i=0; i < numberOfPoints; i++,point++) - { - V2F_C4B_T2F a = {position[i], Color4B(color), Tex2F(pointSize,0)}; - *point = a; - } - - _bufferCountGLPoint += numberOfPoints; - _dirtyGLPoint = true; -} - -void DrawNode::drawLine(const Vec2 &origin, const Vec2 &destination, const Color4F &color) -{ - ensureCapacityGLLine(2); - - V2F_C4B_T2F *point = (V2F_C4B_T2F*)(_bufferGLLine + _bufferCountGLLine); - - V2F_C4B_T2F a = {origin, Color4B(color), Tex2F(0.0, 0.0)}; - V2F_C4B_T2F b = {destination, Color4B(color), Tex2F(0.0, 0.0)}; - - *point = a; - *(point+1) = b; - - _bufferCountGLLine += 2; - _dirtyGLLine = true; -} - -void DrawNode::drawRect(const Vec2 &origin, const Vec2 &destination, const Color4F &color) -{ - drawLine(Vec2(origin.x, origin.y), Vec2(destination.x, origin.y), color); - drawLine(Vec2(destination.x, origin.y), Vec2(destination.x, destination.y), color); - drawLine(Vec2(destination.x, destination.y), Vec2(origin.x, destination.y), color); - drawLine(Vec2(origin.x, destination.y), Vec2(origin.x, origin.y), color); -} - -void DrawNode::drawPoly(const Vec2 *poli, unsigned int numberOfPoints, bool closePolygon, const Color4F &color) -{ - unsigned int vertext_count; - if(closePolygon) - { - vertext_count = 2 * numberOfPoints; - ensureCapacityGLLine(vertext_count); - } - else - { - vertext_count = 2 * (numberOfPoints - 1); - ensureCapacityGLLine(vertext_count); - } - - V2F_C4B_T2F *point = (V2F_C4B_T2F*)(_bufferGLLine + _bufferCountGLLine); - - unsigned int i = 0; - for(; icount(); - - for( unsigned int i=0; i < segments+1;i++) { - - float dt = (float)i / segments; - - // border - if( dt == 1 ) { - p = config->count() - 1; - lt = 1; - } else { - p = dt / deltaT; - lt = (dt - deltaT * (float)p) / deltaT; - } - - // Interpolate - Vec2 pp0 = config->getControlPointAtIndex(p-1); - Vec2 pp1 = config->getControlPointAtIndex(p+0); - Vec2 pp2 = config->getControlPointAtIndex(p+1); - Vec2 pp3 = config->getControlPointAtIndex(p+2); - - Vec2 newPos = ccCardinalSplineAt( pp0, pp1, pp2, pp3, tension, lt); - vertices[i].x = newPos.x; - vertices[i].y = newPos.y; - } - - drawPoly(vertices, segments+1, false, color); - - CC_SAFE_DELETE_ARRAY(vertices); -} - -void DrawNode::drawCatmullRom(PointArray *points, unsigned int segments, const Color4F &color) -{ - drawCardinalSpline( points, 0.5f, segments, color); -} - -void DrawNode::drawDot(const Vec2 &pos, float radius, const Color4F &color) -{ - unsigned int vertex_count = 2*3; - ensureCapacity(vertex_count); - - V2F_C4B_T2F a = {Vec2(pos.x - radius, pos.y - radius), Color4B(color), Tex2F(-1.0, -1.0) }; - V2F_C4B_T2F b = {Vec2(pos.x - radius, pos.y + radius), Color4B(color), Tex2F(-1.0, 1.0) }; - V2F_C4B_T2F c = {Vec2(pos.x + radius, pos.y + radius), Color4B(color), Tex2F( 1.0, 1.0) }; - V2F_C4B_T2F d = {Vec2(pos.x + radius, pos.y - radius), Color4B(color), Tex2F( 1.0, -1.0) }; - - V2F_C4B_T2F_Triangle *triangles = (V2F_C4B_T2F_Triangle *)(_buffer + _bufferCount); - V2F_C4B_T2F_Triangle triangle0 = {a, b, c}; - V2F_C4B_T2F_Triangle triangle1 = {a, c, d}; - triangles[0] = triangle0; - triangles[1] = triangle1; - - _bufferCount += vertex_count; - - _dirty = true; -} - -void DrawNode::drawRect(const Vec2 &p1, const Vec2 &p2, const Vec2 &p3, const Vec2& p4, const Color4F &color) -{ - drawLine(Vec2(p1.x, p1.y), Vec2(p2.x, p2.y), color); - drawLine(Vec2(p2.x, p2.y), Vec2(p3.x, p3.y), color); - drawLine(Vec2(p3.x, p3.y), Vec2(p4.x, p4.y), color); - drawLine(Vec2(p4.x, p4.y), Vec2(p1.x, p1.y), color); -} - -void DrawNode::drawSegment(const Vec2 &from, const Vec2 &to, float radius, const Color4F &color) -{ - unsigned int vertex_count = 6*3; - ensureCapacity(vertex_count); - - Vec2 a = __v2f(from); - Vec2 b = __v2f(to); - - - Vec2 n = v2fnormalize(v2fperp(v2fsub(b, a))); - Vec2 t = v2fperp(n); - - Vec2 nw = v2fmult(n, radius); - Vec2 tw = v2fmult(t, radius); - Vec2 v0 = v2fsub(b, v2fadd(nw, tw)); - Vec2 v1 = v2fadd(b, v2fsub(nw, tw)); - Vec2 v2 = v2fsub(b, nw); - Vec2 v3 = v2fadd(b, nw); - Vec2 v4 = v2fsub(a, nw); - Vec2 v5 = v2fadd(a, nw); - Vec2 v6 = v2fsub(a, v2fsub(nw, tw)); - Vec2 v7 = v2fadd(a, v2fadd(nw, tw)); - - - V2F_C4B_T2F_Triangle *triangles = (V2F_C4B_T2F_Triangle *)(_buffer + _bufferCount); - - V2F_C4B_T2F_Triangle triangles0 = { - {v0, Color4B(color), __t(v2fneg(v2fadd(n, t)))}, - {v1, Color4B(color), __t(v2fsub(n, t))}, - {v2, Color4B(color), __t(v2fneg(n))}, - }; - triangles[0] = triangles0; - - V2F_C4B_T2F_Triangle triangles1 = { - {v3, Color4B(color), __t(n)}, - {v1, Color4B(color), __t(v2fsub(n, t))}, - {v2, Color4B(color), __t(v2fneg(n))}, - }; - triangles[1] = triangles1; - - V2F_C4B_T2F_Triangle triangles2 = { - {v3, Color4B(color), __t(n)}, - {v4, Color4B(color), __t(v2fneg(n))}, - {v2, Color4B(color), __t(v2fneg(n))}, - }; - triangles[2] = triangles2; - - V2F_C4B_T2F_Triangle triangles3 = { - {v3, Color4B(color), __t(n)}, - {v4, Color4B(color), __t(v2fneg(n))}, - {v5, Color4B(color), __t(n) }, - }; - triangles[3] = triangles3; - - V2F_C4B_T2F_Triangle triangles4 = { - {v6, Color4B(color), __t(v2fsub(t, n))}, - {v4, Color4B(color), __t(v2fneg(n)) }, - {v5, Color4B(color), __t(n)}, - }; - triangles[4] = triangles4; - - V2F_C4B_T2F_Triangle triangles5 = { - {v6, Color4B(color), __t(v2fsub(t, n))}, - {v7, Color4B(color), __t(v2fadd(n, t))}, - {v5, Color4B(color), __t(n)}, - }; - triangles[5] = triangles5; - - _bufferCount += vertex_count; - - _dirty = true; -} - -void DrawNode::drawPolygon(const Vec2 *verts, int count, const Color4F &fillColor, float borderWidth, const Color4F &borderColor) -{ - CCASSERT(count >= 0, "invalid count value"); - - bool outline = (borderColor.a > 0.0f && borderWidth > 0.0f); - - auto triangle_count = outline ? (3*count - 2) : (count - 2); - auto vertex_count = 3*triangle_count; - ensureCapacity(vertex_count); - - V2F_C4B_T2F_Triangle *triangles = (V2F_C4B_T2F_Triangle *)(_buffer + _bufferCount); - V2F_C4B_T2F_Triangle *cursor = triangles; - - for (int i = 0; i < count-2; i++) - { - V2F_C4B_T2F_Triangle tmp = { - {verts[0], Color4B(fillColor), __t(v2fzero)}, - {verts[i+1], Color4B(fillColor), __t(v2fzero)}, - {verts[i+2], Color4B(fillColor), __t(v2fzero)}, - }; - - *cursor++ = tmp; - } - - if(outline) - { - struct ExtrudeVerts {Vec2 offset, n;}; - struct ExtrudeVerts* extrude = (struct ExtrudeVerts*)malloc(sizeof(struct ExtrudeVerts)*count); - memset(extrude, 0, sizeof(struct ExtrudeVerts)*count); - - for (int i = 0; i < count; i++) - { - Vec2 v0 = __v2f(verts[(i-1+count)%count]); - Vec2 v1 = __v2f(verts[i]); - Vec2 v2 = __v2f(verts[(i+1)%count]); - - Vec2 n1 = v2fnormalize(v2fperp(v2fsub(v1, v0))); - Vec2 n2 = v2fnormalize(v2fperp(v2fsub(v2, v1))); - - Vec2 offset = v2fmult(v2fadd(n1, n2), 1.0f / (v2fdot(n1, n2) + 1.0f)); - struct ExtrudeVerts tmp = {offset, n2}; - extrude[i] = tmp; - } - - for(int i = 0; i < count; i++) - { - int j = (i+1)%count; - Vec2 v0 = __v2f(verts[i]); - Vec2 v1 = __v2f(verts[j]); - - Vec2 n0 = extrude[i].n; - - Vec2 offset0 = extrude[i].offset; - Vec2 offset1 = extrude[j].offset; - - Vec2 inner0 = v2fsub(v0, v2fmult(offset0, borderWidth)); - Vec2 inner1 = v2fsub(v1, v2fmult(offset1, borderWidth)); - Vec2 outer0 = v2fadd(v0, v2fmult(offset0, borderWidth)); - Vec2 outer1 = v2fadd(v1, v2fmult(offset1, borderWidth)); - - V2F_C4B_T2F_Triangle tmp1 = { - {inner0, Color4B(borderColor), __t(v2fneg(n0))}, - {inner1, Color4B(borderColor), __t(v2fneg(n0))}, - {outer1, Color4B(borderColor), __t(n0)} - }; - *cursor++ = tmp1; - - V2F_C4B_T2F_Triangle tmp2 = { - {inner0, Color4B(borderColor), __t(v2fneg(n0))}, - {outer0, Color4B(borderColor), __t(n0)}, - {outer1, Color4B(borderColor), __t(n0)} - }; - *cursor++ = tmp2; - } - - free(extrude); - } - - _bufferCount += vertex_count; - - _dirty = true; -} - -void DrawNode::drawSolidRect(const Vec2 &origin, const Vec2 &destination, const Color4F &color) -{ - Vec2 vertices[] = { - origin, - Vec2(destination.x, origin.y), - destination, - Vec2(origin.x, destination.y) - }; - - drawSolidPoly(vertices, 4, color ); -} - -void DrawNode::drawSolidPoly(const Vec2 *poli, unsigned int numberOfPoints, const Color4F &color) -{ - drawPolygon(poli, numberOfPoints, color, 0.0, Color4F(0.0, 0.0, 0.0, 0.0)); -} - -void DrawNode::drawSolidCircle(const Vec2& center, float radius, float angle, unsigned int segments, float scaleX, float scaleY, const Color4F &color) -{ - const float coef = 2.0f * (float)M_PI/segments; - - Vec2 *vertices = new (std::nothrow) Vec2[segments]; - if( ! vertices ) - return; - - for(unsigned int i = 0;i < segments; i++) - { - float rads = i*coef; - GLfloat j = radius * cosf(rads + angle) * scaleX + center.x; - GLfloat k = radius * sinf(rads + angle) * scaleY + center.y; - - vertices[i].x = j; - vertices[i].y = k; - } - - drawSolidPoly(vertices, segments, color); - - CC_SAFE_DELETE_ARRAY(vertices); -} - -void DrawNode::drawSolidCircle( const Vec2& center, float radius, float angle, unsigned int segments, const Color4F& color) -{ - drawSolidCircle(center, radius, angle, segments, 1.0f, 1.0f, color); -} - -void DrawNode::drawTriangle(const Vec2 &p1, const Vec2 &p2, const Vec2 &p3, const Color4F &color) -{ - unsigned int vertex_count = 3; - ensureCapacity(vertex_count); - - Color4B col = Color4B(color); - V2F_C4B_T2F a = {Vec2(p1.x, p1.y), col, Tex2F(0.0, 0.0) }; - V2F_C4B_T2F b = {Vec2(p2.x, p2.y), col, Tex2F(0.0, 0.0) }; - V2F_C4B_T2F c = {Vec2(p3.x, p3.y), col, Tex2F(0.0, 0.0) }; - - V2F_C4B_T2F_Triangle *triangles = (V2F_C4B_T2F_Triangle *)(_buffer + _bufferCount); - V2F_C4B_T2F_Triangle triangle = {a, b, c}; - triangles[0] = triangle; - - _bufferCount += vertex_count; - _dirty = true; -} - -void DrawNode::clear() -{ - _bufferCount = 0; - _dirty = true; - _bufferCountGLLine = 0; - _dirtyGLLine = true; - _bufferCountGLPoint = 0; - _dirtyGLPoint = true; - _lineWidth = _defaultLineWidth; -} - -const BlendFunc& DrawNode::getBlendFunc() const -{ - return _blendFunc; -} - -void DrawNode::setBlendFunc(const BlendFunc &blendFunc) -{ - _blendFunc = blendFunc; -} - -void DrawNode::setLineWidth(int lineWidth) -{ - _lineWidth = lineWidth; -} - -float DrawNode::getLineWidth() -{ - return this->_lineWidth; -} - -NS_CC_END - diff --git a/native/cocos/2d/CCDrawNode.h b/native/cocos/2d/CCDrawNode.h deleted file mode 100644 index 6d0f05a247..0000000000 --- a/native/cocos/2d/CCDrawNode.h +++ /dev/null @@ -1,361 +0,0 @@ -/* Copyright (c) 2012 Scott Lembcke and Howling Moon Software - * Copyright (c) 2012 cocos2d-x.org - * Copyright (c) 2013-2016 Chukong Technologies Inc. - * Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - * - * Permission is hereby granted, free of charge, to any person obtaining a copy - * of this software and associated documentation files (the "Software"), to deal - * in the Software without restriction, including without limitation the rights - * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell - * copies of the Software, and to permit persons to whom the Software is - * furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice shall be included in - * all copies or substantial portions of the Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE - * SOFTWARE. - */ - -/* - * Code copied & pasted from SpacePatrol game https://github.com/slembcke/SpacePatrol - * - * Renamed and added some changes for cocos2d - * - */ - -#ifndef __CCDRAWNODES_CCDRAW_NODE_H__ -#define __CCDRAWNODES_CCDRAW_NODE_H__ - -#include "2d/CCNode.h" -#include "base/ccTypes.h" -#include "renderer/CCCustomCommand.h" -#include "math/CCMath.h" - -NS_CC_BEGIN - -static const int DEFAULT_LINE_WIDTH = 2; - -class PointArray; -/** - * @addtogroup _2d - * @{ - */ - -/** @class DrawNode - * @brief Node that draws dots, segments and polygons. - * Faster than the "drawing primitives" since they draws everything in one single batch. - * @since v2.1 - */ -class CC_DLL DrawNode : public Node -{ -public: - /** creates and initialize a DrawNode node. - * - * @return Return an autorelease object. - */ - static DrawNode* create(int defaultLineWidth = DEFAULT_LINE_WIDTH); - - /** Draw a point. - * - * @param point A Vec2 used to point. - * @param pointSize The point size. - * @param color The point color. - * @js NA - */ - void drawPoint(const Vec2& point, const float pointSize, const Color4F &color); - - /** Draw a group point. - * - * @param position A Vec2 pointer. - * @param numberOfPoints The number of points. - * @param color The point color. - * @js NA - */ - void drawPoints(const Vec2 *position, unsigned int numberOfPoints, const Color4F &color); - - /** Draw a group point. - * - * @param position A Vec2 pointer. - * @param numberOfPoints The number of points. - * @param pointSize The point size. - * @param color The point color. - * @js NA - */ - void drawPoints(const Vec2 *position, unsigned int numberOfPoints, const float pointSize, const Color4F &color); - - /** Draw an line from origin to destination with color. - * - * @param origin The line origin. - * @param destination The line destination. - * @param color The line color. - * @js NA - */ - void drawLine(const Vec2 &origin, const Vec2 &destination, const Color4F &color); - - /** Draws a rectangle given the origin and destination point measured in points. - * The origin and the destination can not have the same x and y coordinate. - * - * @param origin The rectangle origin. - * @param destination The rectangle destination. - * @param color The rectangle color. - */ - void drawRect(const Vec2 &origin, const Vec2 &destination, const Color4F &color); - - /** Draws a polygon given a pointer to point coordinates and the number of vertices measured in points. - * The polygon can be closed or open. - * - * @param poli A pointer to point coordinates. - * @param numberOfPoints The number of vertices measured in points. - * @param closePolygon The polygon can be closed or open. - * @param color The polygon color. - */ - void drawPoly(const Vec2 *poli, unsigned int numberOfPoints, bool closePolygon, const Color4F &color); - - /** Draws a circle given the center, radius and number of segments. - * - * @param center The circle center point. - * @param radius The circle rotate of radius. - * @param angle The circle angle. - * @param segments The number of segments. - * @param drawLineToCenter Whether or not draw the line from the origin to center. - * @param scaleX The scale value in x. - * @param scaleY The scale value in y. - * @param color Set the circle color. - */ - void drawCircle( const Vec2& center, float radius, float angle, unsigned int segments, bool drawLineToCenter, float scaleX, float scaleY, const Color4F &color); - - /** Draws a circle given the center, radius and number of segments. - * - * @param center The circle center point. - * @param radius The circle rotate of radius. - * @param angle The circle angle. - * @param segments The number of segments. - * @param drawLineToCenter Whether or not draw the line from the origin to center. - * @param color Set the circle color. - */ - void drawCircle(const Vec2 ¢er, float radius, float angle, unsigned int segments, bool drawLineToCenter, const Color4F &color); - - /** Draws a quad bezier path. - * - * @param origin The origin of the bezier path. - * @param control The control of the bezier path. - * @param destination The destination of the bezier path. - * @param segments The number of segments. - * @param color Set the quad bezier color. - */ - void drawQuadBezier(const Vec2 &origin, const Vec2 &control, const Vec2 &destination, unsigned int segments, const Color4F &color); - - /** Draw a cubic bezier curve with color and number of segments - * - * @param origin The origin of the bezier path. - * @param control1 The first control of the bezier path. - * @param control2 The second control of the bezier path. - * @param destination The destination of the bezier path. - * @param segments The number of segments. - * @param color Set the cubic bezier color. - */ - void drawCubicBezier(const Vec2 &origin, const Vec2 &control1, const Vec2 &control2, const Vec2 &destination, unsigned int segments, const Color4F &color); - - /** Draws a Cardinal Spline path. - * - * @param config A array point. - * @param tension The tension of the spline. - * @param segments The number of segments. - * @param color Set the Spline color. - */ - void drawCardinalSpline(PointArray *config, float tension, unsigned int segments, const Color4F &color); - - /** Draws a Catmull Rom path. - * - * @param points A point array of control point. - * @param segments The number of segments. - * @param color The Catmull Rom color. - */ - void drawCatmullRom(PointArray *points, unsigned int segments, const Color4F &color); - - /** draw a dot at a position, with a given radius and color. - * - * @param pos The dot center. - * @param radius The dot radius. - * @param color The dot color. - */ - void drawDot(const Vec2 &pos, float radius, const Color4F &color); - - /** Draws a rectangle with 4 points. - * - * @param p1 The rectangle vertex point. - * @param p2 The rectangle vertex point. - * @param p3 The rectangle vertex point. - * @param p4 The rectangle vertex point. - * @param color The rectangle color. - */ - void drawRect(const Vec2 &p1, const Vec2 &p2, const Vec2 &p3, const Vec2& p4, const Color4F &color); - - /** Draws a solid rectangle given the origin and destination point measured in points. - * The origin and the destination can not have the same x and y coordinate. - * - * @param origin The rectangle origin. - * @param destination The rectangle destination. - * @param color The rectangle color. - * @js NA - */ - void drawSolidRect(const Vec2 &origin, const Vec2 &destination, const Color4F &color); - - /** Draws a solid polygon given a pointer to CGPoint coordinates, the number of vertices measured in points, and a color. - * - * @param poli A solid polygon given a pointer to CGPoint coordinates. - * @param numberOfPoints The number of vertices measured in points. - * @param color The solid polygon color. - * @js NA - */ - void drawSolidPoly(const Vec2 *poli, unsigned int numberOfPoints, const Color4F &color); - - /** Draws a solid circle given the center, radius and number of segments. - * @param center The circle center point. - * @param radius The circle rotate of radius. - * @param angle The circle angle. - * @param segments The number of segments. - * @param scaleX The scale value in x. - * @param scaleY The scale value in y. - * @param color The solid circle color. - * @js NA - */ - void drawSolidCircle(const Vec2& center, float radius, float angle, unsigned int segments, float scaleX, float scaleY, const Color4F &color); - - /** Draws a solid circle given the center, radius and number of segments. - * @param center The circle center point. - * @param radius The circle rotate of radius. - * @param angle The circle angle. - * @param segments The number of segments. - * @param color The solid circle color. - * @js NA - */ - void drawSolidCircle(const Vec2& center, float radius, float angle, unsigned int segments, const Color4F& color); - - /** draw a segment with a radius and color. - * - * @param from The segment origin. - * @param to The segment destination. - * @param radius The segment radius. - * @param color The segment color. - */ - void drawSegment(const Vec2 &from, const Vec2 &to, float radius, const Color4F &color); - - /** draw a polygon with a fill color and line color - * @code - * When this function bound into js or lua,the parameter will be changed - * In js: var drawPolygon(var Arrayofpoints, var fillColor, var width, var borderColor) - * In lua:local drawPolygon(local pointTable,local tableCount,local fillColor,local width,local borderColor) - * @endcode - * @param verts A pointer to point coordinates. - * @param count The number of verts measured in points. - * @param fillColor The color will fill in polygon. - * @param borderWidth The border of line width. - * @param borderColor The border of line color. - * @js NA - */ - void drawPolygon(const Vec2 *verts, int count, const Color4F &fillColor, float borderWidth, const Color4F &borderColor); - - /** draw a triangle with color. - * - * @param p1 The triangle vertex point. - * @param p2 The triangle vertex point. - * @param p3 The triangle vertex point. - * @param color The triangle color. - * @js NA - */ - void drawTriangle(const Vec2 &p1, const Vec2 &p2, const Vec2 &p3, const Color4F &color); - - /** Clear the geometry in the node's buffer. */ - void clear(); - /** Get the color mixed mode. - * @lua NA - */ - const BlendFunc& getBlendFunc() const; - /** Set the color mixed mode. - * @code - * When this function bound into js or lua,the parameter will be changed - * In js: var setBlendFunc(var src, var dst) - * @endcode - * @lua NA - */ - void setBlendFunc(const BlendFunc &blendFunc); - - /** - * @js NA - */ - virtual void onDraw(const Mat4 &transform, uint32_t flags); - /** - * @js NA - */ - virtual void onDrawGLLine(const Mat4 &transform, uint32_t flags); - /** - * @js NA - */ - virtual void onDrawGLPoint(const Mat4 &transform, uint32_t flags); - - // Overrides - virtual void draw(Renderer *renderer, const Mat4 &transform, uint32_t flags) override; - - void setLineWidth(int lineWidth); - - // Get CocosStudio guide lines width. - float getLineWidth(); - -CC_CONSTRUCTOR_ACCESS: - DrawNode(int lineWidth = DEFAULT_LINE_WIDTH); - virtual ~DrawNode(); - virtual bool init() override; - -protected: - void ensureCapacity(int count); - void ensureCapacityGLPoint(int count); - void ensureCapacityGLLine(int count); - - GLuint _vao; - GLuint _vbo; - GLuint _vaoGLPoint; - GLuint _vboGLPoint; - GLuint _vaoGLLine; - GLuint _vboGLLine; - - int _bufferCapacity; - GLsizei _bufferCount; - V2F_C4B_T2F *_buffer; - - int _bufferCapacityGLPoint; - GLsizei _bufferCountGLPoint; - V2F_C4B_T2F *_bufferGLPoint; - Color4F _pointColor; - int _pointSize; - - int _bufferCapacityGLLine; - GLsizei _bufferCountGLLine; - V2F_C4B_T2F *_bufferGLLine; - - BlendFunc _blendFunc; - CustomCommand _customCommand; - CustomCommand _customCommandGLPoint; - CustomCommand _customCommandGLLine; - - bool _dirty; - bool _dirtyGLPoint; - bool _dirtyGLLine; - - int _lineWidth; - - int _defaultLineWidth; -private: - CC_DISALLOW_COPY_AND_ASSIGN(DrawNode); -}; -/** @} */ -NS_CC_END - -#endif // __CCDRAWNODES_CCDRAW_NODE_H__ - diff --git a/native/cocos/2d/CCDrawingPrimitives.cpp b/native/cocos/2d/CCDrawingPrimitives.cpp deleted file mode 100644 index 5164747a96..0000000000 --- a/native/cocos/2d/CCDrawingPrimitives.cpp +++ /dev/null @@ -1,507 +0,0 @@ -/**************************************************************************** -Copyright (c) 2008-2010 Ricardo Quesada -Copyright (c) 2010-2013 cocos2d-x.org -Copyright (c) 2011 Zynga Inc. -Copyright (c) 2013-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ - -/* - * - * IMPORTANT IMPORTANT IMPORTANT IMPORTANT - * - * - * LEGACY FUNCTIONS - * - * USE DrawNode instead - * - */ - -#include "2d/CCDrawingPrimitives.h" - -#include -#include - -#include "2d/CCActionCatmullRom.h" -#include "base/CCDirector.h" -#include "renderer/ccGLStateCache.h" -#include "renderer/CCGLProgramCache.h" -#include "renderer/CCRenderer.h" -#include "platform/CCGL.h" - -NS_CC_BEGIN - -#if defined(__GNUC__) && ((__GNUC__ >= 4) || ((__GNUC__ == 3) && (__GNUC_MINOR__ >= 1))) -#pragma GCC diagnostic ignored "-Wdeprecated-declarations" -#elif _MSC_VER >= 1400 //vs 2005 or higher -#pragma warning (push) -#pragma warning (disable: 4996) -#endif - -#ifndef M_PI - #define M_PI 3.14159265358979323846 -#endif - -namespace DrawPrimitives { - -static bool s_initialized = false; -static GLProgram* s_shader = nullptr; -static int s_colorLocation = -1; -static Color4F s_color(1.0f,1.0f,1.0f,1.0f); -static int s_pointSizeLocation = -1; -static GLfloat s_pointSize = 1.0f; - - -static void lazy_init() -{ - if( ! s_initialized ) { - // - // Position and 1 color passed as a uniform (to simulate glColor4ub ) - // - s_shader = GLProgramCache::getInstance()->getGLProgram(GLProgram::SHADER_NAME_POSITION_U_COLOR); - s_shader->retain(); - - s_colorLocation = s_shader->getUniformLocation("u_color"); - CHECK_GL_ERROR_DEBUG(); - s_pointSizeLocation = s_shader->getUniformLocation("u_pointSize"); - CHECK_GL_ERROR_DEBUG(); - - s_initialized = true; - } -} - -// When switching from background to foreground on android, we want the parameters to be initialized again -void init() -{ - lazy_init(); -} - -void free() -{ - CC_SAFE_RELEASE_NULL(s_shader); - s_initialized = false; -} - -void drawPoint(const Vec2& point) -{ - lazy_init(); - - Vec2 p; - p.x = point.x; - p.y = point.y; - - GL::enableVertexAttribs( GL::VERTEX_ATTRIB_FLAG_POSITION ); - s_shader->use(); - s_shader->setUniformsForBuiltins(); - - s_shader->setUniformLocationWith4fv(s_colorLocation, (GLfloat*) &s_color.r, 1); - s_shader->setUniformLocationWith1f(s_pointSizeLocation, s_pointSize); - - glVertexAttribPointer(GLProgram::VERTEX_ATTRIB_POSITION, 2, GL_FLOAT, GL_FALSE, 0, &p); - - glDrawArrays(GL_POINTS, 0, 1); - - CC_INCREMENT_GL_DRAWN_BATCHES_AND_VERTICES(1,1); -} - -void drawPoints( const Vec2 *points, unsigned int numberOfPoints ) -{ - lazy_init(); - - GL::enableVertexAttribs( GL::VERTEX_ATTRIB_FLAG_POSITION ); - s_shader->use(); - s_shader->setUniformsForBuiltins(); - s_shader->setUniformLocationWith4fv(s_colorLocation, (GLfloat*) &s_color.r, 1); - s_shader->setUniformLocationWith1f(s_pointSizeLocation, s_pointSize); - - // FIXME: Mac OpenGL error. arrays can't go out of scope before draw is executed - Vec2* newPoints = new (std::nothrow) Vec2[numberOfPoints]; - - // iPhone and 32-bit machines optimization - if( sizeof(Vec2) == sizeof(Vec2) ) - { - glVertexAttribPointer(GLProgram::VERTEX_ATTRIB_POSITION, 2, GL_FLOAT, GL_FALSE, 0, points); - } - else - { - // Mac on 64-bit - for( unsigned int i=0; iuse(); - s_shader->setUniformsForBuiltins(); - s_shader->setUniformLocationWith4fv(s_colorLocation, (GLfloat*) &s_color.r, 1); - - GL::enableVertexAttribs( GL::VERTEX_ATTRIB_FLAG_POSITION ); - glVertexAttribPointer(GLProgram::VERTEX_ATTRIB_POSITION, 2, GL_FLOAT, GL_FALSE, 0, vertices); - glDrawArrays(GL_LINES, 0, 2); - - CC_INCREMENT_GL_DRAWN_BATCHES_AND_VERTICES(1,2); -} - -void drawRect( const Vec2& origin, const Vec2& destination ) -{ - drawLine(Vec2(origin.x, origin.y), Vec2(destination.x, origin.y)); - drawLine(Vec2(destination.x, origin.y), Vec2(destination.x, destination.y)); - drawLine(Vec2(destination.x, destination.y), Vec2(origin.x, destination.y)); - drawLine(Vec2(origin.x, destination.y), Vec2(origin.x, origin.y)); -} - -void drawSolidRect(const Vec2& origin, const Vec2& destination, const Color4F& color) -{ - Vec2 vertices[] = { - origin, - Vec2(destination.x, origin.y), - destination, - Vec2(origin.x, destination.y) - }; - - drawSolidPoly(vertices, 4, color ); -} - -void drawPoly(const Vec2 *poli, unsigned int numberOfPoints, bool closePolygon) -{ - lazy_init(); - - s_shader->use(); - s_shader->setUniformsForBuiltins(); - s_shader->setUniformLocationWith4fv(s_colorLocation, (GLfloat*) &s_color.r, 1); - - GL::enableVertexAttribs( GL::VERTEX_ATTRIB_FLAG_POSITION ); - - // iPhone and 32-bit machines optimization - if( sizeof(Vec2) == sizeof(Vec2) ) - { - glVertexAttribPointer(GLProgram::VERTEX_ATTRIB_POSITION, 2, GL_FLOAT, GL_FALSE, 0, poli); - - if( closePolygon ) - glDrawArrays(GL_LINE_LOOP, 0, (GLsizei) numberOfPoints); - else - glDrawArrays(GL_LINE_STRIP, 0, (GLsizei) numberOfPoints); - } - else - { - // Mac on 64-bit - // FIXME: Mac OpenGL error. arrays can't go out of scope before draw is executed - Vec2* newPoli = new (std::nothrow) Vec2[numberOfPoints]; - for( unsigned int i=0; iuse(); - s_shader->setUniformsForBuiltins(); - s_shader->setUniformLocationWith4fv(s_colorLocation, (GLfloat*) &color.r, 1); - - GL::enableVertexAttribs( GL::VERTEX_ATTRIB_FLAG_POSITION ); - - // FIXME: Mac OpenGL error. arrays can't go out of scope before draw is executed - Vec2* newPoli = new (std::nothrow) Vec2[numberOfPoints]; - - // iPhone and 32-bit machines optimization - if (sizeof(Vec2) == sizeof(Vec2)) - { - glVertexAttribPointer(GLProgram::VERTEX_ATTRIB_POSITION, 2, GL_FLOAT, GL_FALSE, 0, poli); - } - else - { - // Mac on 64-bit - for(unsigned int i = 0; i < numberOfPoints; i++) - { - newPoli[i].set(poli[i].x, poli[i].y); - } - glVertexAttribPointer(GLProgram::VERTEX_ATTRIB_POSITION, 2, GL_FLOAT, GL_FALSE, 0, newPoli); - } - - glDrawArrays(GL_TRIANGLE_FAN, 0, (GLsizei) numberOfPoints); - - CC_SAFE_DELETE_ARRAY(newPoli); - CC_INCREMENT_GL_DRAWN_BATCHES_AND_VERTICES(1, numberOfPoints); -} - -void drawCircle( const Vec2& center, float radius, float angle, unsigned int segments, bool drawLineToCenter, float scaleX, float scaleY) -{ - lazy_init(); - - int additionalSegment = 1; - if (drawLineToCenter) - additionalSegment++; - - const float coef = 2.0f * (float)M_PI/segments; - - GLfloat *vertices = (GLfloat*)calloc( sizeof(GLfloat)*2*(segments+2), 1); - if( ! vertices ) - return; - - for(unsigned int i = 0;i <= segments; i++) { - float rads = i*coef; - GLfloat j = radius * cosf(rads + angle) * scaleX + center.x; - GLfloat k = radius * sinf(rads + angle) * scaleY + center.y; - - vertices[i*2] = j; - vertices[i*2+1] = k; - } - vertices[(segments+1)*2] = center.x; - vertices[(segments+1)*2+1] = center.y; - - s_shader->use(); - s_shader->setUniformsForBuiltins(); - s_shader->setUniformLocationWith4fv(s_colorLocation, (GLfloat*) &s_color.r, 1); - - GL::enableVertexAttribs( GL::VERTEX_ATTRIB_FLAG_POSITION ); - - glVertexAttribPointer(GLProgram::VERTEX_ATTRIB_POSITION, 2, GL_FLOAT, GL_FALSE, 0, vertices); - glDrawArrays(GL_LINE_STRIP, 0, (GLsizei) segments+additionalSegment); - - ::free( vertices ); - - CC_INCREMENT_GL_DRAWN_BATCHES_AND_VERTICES(1,segments+additionalSegment); -} - -void drawCircle( const Vec2& center, float radius, float angle, unsigned int segments, bool drawLineToCenter) -{ - drawCircle(center, radius, angle, segments, drawLineToCenter, 1.0f, 1.0f); -} - -void drawSolidCircle( const Vec2& center, float radius, float angle, unsigned int segments, float scaleX, float scaleY) -{ - lazy_init(); - - const float coef = 2.0f * (float)M_PI/segments; - - GLfloat *vertices = (GLfloat*)calloc( sizeof(GLfloat)*2*(segments+2), 1); - if( ! vertices ) - return; - - for(unsigned int i = 0;i <= segments; i++) { - float rads = i*coef; - GLfloat j = radius * cosf(rads + angle) * scaleX + center.x; - GLfloat k = radius * sinf(rads + angle) * scaleY + center.y; - - vertices[i*2] = j; - vertices[i*2+1] = k; - } - vertices[(segments+1)*2] = center.x; - vertices[(segments+1)*2+1] = center.y; - - s_shader->use(); - s_shader->setUniformsForBuiltins(); - s_shader->setUniformLocationWith4fv(s_colorLocation, (GLfloat*) &s_color.r, 1); - - GL::enableVertexAttribs( GL::VERTEX_ATTRIB_FLAG_POSITION ); - - glVertexAttribPointer(GLProgram::VERTEX_ATTRIB_POSITION, 2, GL_FLOAT, GL_FALSE, 0, vertices); - - glDrawArrays(GL_TRIANGLE_FAN, 0, (GLsizei) segments+1); - - ::free( vertices ); - - CC_INCREMENT_GL_DRAWN_BATCHES_AND_VERTICES(1,segments+1); -} - -void drawSolidCircle( const Vec2& center, float radius, float angle, unsigned int segments) -{ - drawSolidCircle(center, radius, angle, segments, 1.0f, 1.0f); -} - -void drawQuadBezier(const Vec2& origin, const Vec2& control, const Vec2& destination, unsigned int segments) -{ - lazy_init(); - - Vec2* vertices = new (std::nothrow) Vec2[segments + 1]; - - float t = 0.0f; - for(unsigned int i = 0; i < segments; i++) - { - vertices[i].x = powf(1 - t, 2) * origin.x + 2.0f * (1 - t) * t * control.x + t * t * destination.x; - vertices[i].y = powf(1 - t, 2) * origin.y + 2.0f * (1 - t) * t * control.y + t * t * destination.y; - t += 1.0f / segments; - } - vertices[segments].x = destination.x; - vertices[segments].y = destination.y; - - s_shader->use(); - s_shader->setUniformsForBuiltins(); - s_shader->setUniformLocationWith4fv(s_colorLocation, (GLfloat*) &s_color.r, 1); - - GL::enableVertexAttribs( GL::VERTEX_ATTRIB_FLAG_POSITION ); - - glVertexAttribPointer(GLProgram::VERTEX_ATTRIB_POSITION, 2, GL_FLOAT, GL_FALSE, 0, vertices); - glDrawArrays(GL_LINE_STRIP, 0, (GLsizei) segments + 1); - CC_SAFE_DELETE_ARRAY(vertices); - - CC_INCREMENT_GL_DRAWN_BATCHES_AND_VERTICES(1,segments+1); -} - -void drawCatmullRom( PointArray *points, unsigned int segments ) -{ - drawCardinalSpline( points, 0.5f, segments ); -} - -void drawCardinalSpline( PointArray *config, float tension, unsigned int segments ) -{ - lazy_init(); - - Vec2* vertices = new (std::nothrow) Vec2[segments + 1]; - - ssize_t p; - float lt; - float deltaT = 1.0f / config->count(); - - for( unsigned int i=0; i < segments+1;i++) { - - float dt = (float)i / segments; - - // border - if( dt == 1 ) { - p = config->count() - 1; - lt = 1; - } else { - p = dt / deltaT; - lt = (dt - deltaT * (float)p) / deltaT; - } - - // Interpolate - Vec2 pp0 = config->getControlPointAtIndex(p-1); - Vec2 pp1 = config->getControlPointAtIndex(p+0); - Vec2 pp2 = config->getControlPointAtIndex(p+1); - Vec2 pp3 = config->getControlPointAtIndex(p+2); - - Vec2 newPos = ccCardinalSplineAt( pp0, pp1, pp2, pp3, tension, lt); - vertices[i].x = newPos.x; - vertices[i].y = newPos.y; - } - - s_shader->use(); - s_shader->setUniformsForBuiltins(); - s_shader->setUniformLocationWith4fv(s_colorLocation, (GLfloat*)&s_color.r, 1); - - GL::enableVertexAttribs( GL::VERTEX_ATTRIB_FLAG_POSITION ); - - glVertexAttribPointer(GLProgram::VERTEX_ATTRIB_POSITION, 2, GL_FLOAT, GL_FALSE, 0, vertices); - glDrawArrays(GL_LINE_STRIP, 0, (GLsizei) segments + 1); - - CC_SAFE_DELETE_ARRAY(vertices); - CC_INCREMENT_GL_DRAWN_BATCHES_AND_VERTICES(1,segments+1); -} - -void drawCubicBezier(const Vec2& origin, const Vec2& control1, const Vec2& control2, const Vec2& destination, unsigned int segments) -{ - lazy_init(); - - Vec2* vertices = new (std::nothrow) Vec2[segments + 1]; - - float t = 0; - for (unsigned int i = 0; i < segments; i++) - { - vertices[i].x = powf(1 - t, 3) * origin.x + 3.0f * powf(1 - t, 2) * t * control1.x + 3.0f * (1 - t) * t * t * control2.x + t * t * t * destination.x; - vertices[i].y = powf(1 - t, 3) * origin.y + 3.0f * powf(1 - t, 2) * t * control1.y + 3.0f * (1 - t) * t * t * control2.y + t * t * t * destination.y; - t += 1.0f / segments; - } - vertices[segments].x = destination.x; - vertices[segments].y = destination.y; - - s_shader->use(); - s_shader->setUniformsForBuiltins(); - s_shader->setUniformLocationWith4fv(s_colorLocation, (GLfloat*) &s_color.r, 1); - - GL::enableVertexAttribs( GL::VERTEX_ATTRIB_FLAG_POSITION ); - - glVertexAttribPointer(GLProgram::VERTEX_ATTRIB_POSITION, 2, GL_FLOAT, GL_FALSE, 0, vertices); - glDrawArrays(GL_LINE_STRIP, 0, (GLsizei) segments + 1); - CC_SAFE_DELETE_ARRAY(vertices); - - CC_INCREMENT_GL_DRAWN_BATCHES_AND_VERTICES(1,segments+1); -} - -void setDrawColor4F( GLfloat r, GLfloat g, GLfloat b, GLfloat a ) -{ - s_color.r = r; - s_color.g = g; - s_color.b = b; - s_color.a = a; -} - -void setPointSize( GLfloat pointSize ) -{ - s_pointSize = pointSize * CC_CONTENT_SCALE_FACTOR(); - - // TODO: glPointSize( pointSize ); - -} - -void setDrawColor4B( GLubyte r, GLubyte g, GLubyte b, GLubyte a ) -{ - s_color.r = r/255.0f; - s_color.g = g/255.0f; - s_color.b = b/255.0f; - s_color.a = a/255.0f; -} - -} // DrawPrimitives namespace - -#if defined(__GNUC__) && ((__GNUC__ >= 4) || ((__GNUC__ == 3) && (__GNUC_MINOR__ >= 1))) -#pragma GCC diagnostic warning "-Wdeprecated-declarations" -#elif _MSC_VER >= 1400 //vs 2005 or higher -#pragma warning (pop) -#endif - -NS_CC_END - diff --git a/native/cocos/2d/CCDrawingPrimitives.h b/native/cocos/2d/CCDrawingPrimitives.h deleted file mode 100644 index b805de0402..0000000000 --- a/native/cocos/2d/CCDrawingPrimitives.h +++ /dev/null @@ -1,274 +0,0 @@ -/**************************************************************************** -Copyright (c) 2008-2010 Ricardo Quesada -Copyright (c) 2010-2013 cocos2d-x.org -Copyright (c) 2011 Zynga Inc. -Copyright (c) 2013-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ - -/* - * - * IMPORTANT IMPORTANT IMPORTANT IMPORTANT - * - * - * LEGACY FUNCTIONS - * - * USE DrawNode instead - * - */ - - -#ifndef __CCDRAWING_PRIMITIVES__ -#define __CCDRAWING_PRIMITIVES__ - - -#include "base/ccTypes.h" -#include "base/ccMacros.h" -#include "math/CCMath.h" - -/** - @file - Drawing OpenGL ES primitives. - - drawPoint, drawPoints - - drawLine - - drawRect, drawSolidRect - - drawPoly, drawSolidPoly - - drawCircle - - drawQuadBezier - - drawCubicBezier - - drawCatmullRom - - drawCardinalSpline - - You can change the color, point size, width by calling: - - drawColor4B(), drawColor4F() - - ccPointSize() - - glLineWidth() - - @warning These functions draws the Line, Vec2, Polygon, immediately. They aren't batched. If you are going to make a game that depends on these primitives, I suggest creating a batch. Instead you should use DrawNode - - */ - -NS_CC_BEGIN - -/** - * @addtogroup _2d - * @{ - */ - -class PointArray; - -/** -* @js cc.DrawingPrimitiveCanvas/cc.DrawingPrimitiveWebGL -*/ -namespace DrawPrimitives -{ - /** - * Initializes the drawing primitives. - * @js NA - */ - CC_DEPRECATED_ATTRIBUTE void CC_DLL init(); - - /** - * Frees allocated resources by the drawing primitives. - * @js NA - */ - CC_DEPRECATED_ATTRIBUTE void CC_DLL free(); - - /** Draws a point given x and y coordinate measured in points - * - * @param point A Vec2 with a point given x and y coordinate. - */ - CC_DEPRECATED_ATTRIBUTE void CC_DLL drawPoint(const Vec2& point); - - /** Draws an array of points. - * - * @param points A point coordinates. - * @param numberOfPoints The number of points. - * @since v0.7.2 - */ - CC_DEPRECATED_ATTRIBUTE void CC_DLL drawPoints(const Vec2 *points, unsigned int numberOfPoints); - - /** Draws a line given the origin and destination point measured in points - * - * @param origin A Vec2 Type point used to the line origin. - * @param destination A Vec2 Type point used to the line destination. - */ - CC_DEPRECATED_ATTRIBUTE void CC_DLL drawLine(const Vec2& origin, const Vec2& destination); - - /** Draws a rectangle given the origin and destination point measured in points. - * The origin and the destination can not have the same x and y coordinate. - * - * @param origin The rectangle origin. - * @param destination The rectangle destination. - */ - CC_DEPRECATED_ATTRIBUTE void CC_DLL drawRect(const Vec2& origin, const Vec2& destination); - - /** Draws a solid rectangle given the origin and destination point measured in points. - * The origin and the destination can not have the same x and y coordinate. - * - * @param origin The rectangle origin. - * @param destination The rectangle destination. - * @param color The rectangle color. - * @since 1.1 - */ - CC_DEPRECATED_ATTRIBUTE void CC_DLL drawSolidRect(const Vec2& origin, const Vec2& destination, const Color4F& color); - - /** Draws a polygon given a pointer to point coordinates and the number of vertices measured in points. - * The polygon can be closed or open. - * - * @param vertices A pointer to point coordinates. - * @param numOfVertices The number of vertices measured in points. - * @param closePolygon The polygon can be closed or open. - */ - CC_DEPRECATED_ATTRIBUTE void CC_DLL drawPoly(const Vec2 *vertices, unsigned int numOfVertices, bool closePolygon); - - /** Draws a solid polygon given a pointer to CGPoint coordinates, the number of vertices measured in points, and a color. - * - * @param poli A solid polygon given a pointer to CGPoint coordinates. - * @param numberOfPoints The number of vertices measured in points. - * @param color The solid polygon color. - */ - CC_DEPRECATED_ATTRIBUTE void CC_DLL drawSolidPoly(const Vec2 *poli, unsigned int numberOfPoints, Color4F color); - - /** Draws a circle given the center, radius and number of segments. - * - * @param center The circle center point. - * @param radius The circle rotate of radius. - * @param angle The circle angle. - * @param segments The number of segments. - * @param drawLineToCenter Whether or not draw the line from the origin to center. - * @param scaleX The scale value in x. - * @param scaleY The scale value in y. - */ - CC_DEPRECATED_ATTRIBUTE void CC_DLL drawCircle(const Vec2& center, float radius, float angle, unsigned int segments, bool drawLineToCenter, float scaleX, float scaleY); - - /** Draws a circle given the center, radius and number of segments. - * - * @param center The circle center point. - * @param radius The circle rotate of radius. - * @param angle The circle angle. - * @param segments The number of segments. - * @param drawLineToCenter Whether or not draw the line from the origin to center. - */ - CC_DEPRECATED_ATTRIBUTE void CC_DLL drawCircle(const Vec2& center, float radius, float angle, unsigned int segments, bool drawLineToCenter); - - /** Draws a solid circle given the center, radius and number of segments. - * @param center The circle center point. - * @param radius The circle rotate of radius. - * @param angle The circle angle. - * @param segments The number of segments. - * @param scaleX The scale value in x. - * @param scaleY The scale value in y. - * @js NA - */ - CC_DEPRECATED_ATTRIBUTE void CC_DLL drawSolidCircle(const Vec2& center, float radius, float angle, unsigned int segments, float scaleX, float scaleY); - - /** Draws a solid circle given the center, radius and number of segments. - * @param center The circle center point. - * @param radius The circle rotate of radius. - * @param angle The circle angle. - * @param segments The number of segments. - * @js NA - */ - CC_DEPRECATED_ATTRIBUTE void CC_DLL drawSolidCircle(const Vec2& center, float radius, float angle, unsigned int segments); - - /** Draws a quad bezier path. - * - * @param origin The origin of the bezier path. - * @param control The control of the bezier path. - * @param destination The destination of the bezier path. - * @param segments The number of segments. - * @warning This function could be pretty slow. Use it only for debugging purposes. - * @since v0.8 - */ - CC_DEPRECATED_ATTRIBUTE void CC_DLL drawQuadBezier(const Vec2& origin, const Vec2& control, const Vec2& destination, unsigned int segments); - - /** Draws a cubic bezier path. - * - * @param origin The origin of the bezier path. - * @param control1 The first control of the bezier path. - * @param control2 The second control of the bezier path. - * @param destination The destination of the bezier path. - * @param segments The number of segments. - * @warning This function could be pretty slow. Use it only for debugging purposes. - * @since v0.8 - */ - CC_DEPRECATED_ATTRIBUTE void CC_DLL drawCubicBezier(const Vec2& origin, const Vec2& control1, const Vec2& control2, const Vec2& destination, unsigned int segments); - - /** Draws a Catmull Rom path. - * - * @param arrayOfControlPoints A point array of control point. - * @param segments The number of segments. - * @warning This function could be pretty slow. Use it only for debugging purposes. - * @since v2.0 - */ - CC_DEPRECATED_ATTRIBUTE void CC_DLL drawCatmullRom(PointArray *arrayOfControlPoints, unsigned int segments); - - /** Draws a Cardinal Spline path. - * - * @param config A array point. - * @param tension The tension of the spline. - * @param segments The number of segments. - * @warning This function could be pretty slow. Use it only for debugging purposes. - * @since v2.0 - */ - CC_DEPRECATED_ATTRIBUTE void CC_DLL drawCardinalSpline(PointArray *config, float tension, unsigned int segments); - - /** Set the drawing color with 4 unsigned bytes. - * - * @param r The red color with a unsigned bytes. - * @param g The green color with a unsigned bytes. - * @param b The blue color with a unsigned bytes. - * @param a Alpha with a unsigned bytes. - * @since v2.0 - * @js setDrawColor - */ - CC_DEPRECATED_ATTRIBUTE void CC_DLL setDrawColor4B(GLubyte r, GLubyte g, GLubyte b, GLubyte a); - - /** Set the drawing color with 4 floats. - * - * @param r The red color with an floats. - * @param g The green color with an floats. - * @param b The blue color with an floats. - * @param a Alpha with an floats. - * @since v2.0 - * @js setDrawColor - */ - CC_DEPRECATED_ATTRIBUTE void CC_DLL setDrawColor4F(GLfloat r, GLfloat g, GLfloat b, GLfloat a); - - /** Set the point size in points. Default 1. - * - * @param pointSize The point size with an float. - * @since v2.0 - */ - CC_DEPRECATED_ATTRIBUTE void CC_DLL setPointSize(GLfloat pointSize); - -}; - -// end of global group -/** @} */ - -NS_CC_END - -#endif // __CCDRAWING_PRIMITIVES__ - diff --git a/native/cocos/2d/CCFastTMXLayer.cpp b/native/cocos/2d/CCFastTMXLayer.cpp deleted file mode 100644 index 8080b5304d..0000000000 --- a/native/cocos/2d/CCFastTMXLayer.cpp +++ /dev/null @@ -1,883 +0,0 @@ -/**************************************************************************** -Copyright (c) 2014-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ - -/* - Original rewrite of TMXLayer was based on HKTMXTiledMap by HKASoftware http://hkasoftware.com - Further info: http://www.cocos2d-iphone.org/forums/topic/hktmxtiledmap/ - - It was rewritten again, and only a small part of the original HK ideas/code remains in this implementation - - */ -#include "2d/CCFastTMXLayer.h" -#include "2d/CCFastTMXTiledMap.h" -#include "2d/CCSprite.h" -#include "renderer/CCTextureCache.h" -#include "renderer/CCGLProgramCache.h" -#include "renderer/ccGLStateCache.h" -#include "renderer/CCRenderer.h" -#include "renderer/CCVertexIndexBuffer.h" -#include "base/CCDirector.h" -#include "base/ccUTF8.h" - -NS_CC_BEGIN -namespace experimental { - -const int TMXLayer::FAST_TMX_ORIENTATION_ORTHO = 0; -const int TMXLayer::FAST_TMX_ORIENTATION_HEX = 1; -const int TMXLayer::FAST_TMX_ORIENTATION_ISO = 2; - -// FastTMXLayer - init & alloc & dealloc -TMXLayer * TMXLayer::create(TMXTilesetInfo *tilesetInfo, TMXLayerInfo *layerInfo, TMXMapInfo *mapInfo) -{ - TMXLayer *ret = new (std::nothrow) TMXLayer(); - if (ret->initWithTilesetInfo(tilesetInfo, layerInfo, mapInfo)) - { - ret->autorelease(); - return ret; - } - - CC_SAFE_DELETE(ret); - - return nullptr; -} - -bool TMXLayer::initWithTilesetInfo(TMXTilesetInfo *tilesetInfo, TMXLayerInfo *layerInfo, TMXMapInfo *mapInfo) -{ - if( tilesetInfo ) - { - if (nullptr != tilesetInfo->_preloadedTexture) - { - _texture = tilesetInfo->_preloadedTexture; - } - else - { - _texture = Director::getInstance()->getTextureCache()->addImage(tilesetInfo->_sourceImage); - } - _texture->retain(); - } - - // layerInfo - _layerName = layerInfo->_name; - _layerSize = layerInfo->_layerSize; - _tiles = layerInfo->_tiles; - _quadsDirty = true; - setOpacity( layerInfo->_opacity ); - setProperties(layerInfo->getProperties()); - - // tilesetInfo - _tileSet = tilesetInfo; - CC_SAFE_RETAIN(_tileSet); - - // mapInfo - _mapTileSize = mapInfo->getTileSize(); - _layerOrientation = mapInfo->getOrientation(); - - // offset (after layer orientation is set); - Vec2 offset = this->calculateLayerOffset(layerInfo->_offset); - this->setPosition(CC_POINT_PIXELS_TO_POINTS(offset)); - - this->setContentSize(CC_SIZE_PIXELS_TO_POINTS(Size(_layerSize.width * _mapTileSize.width, _layerSize.height * _mapTileSize.height))); - - this->tileToNodeTransform(); - - // shader, and other stuff - setGLProgram(GLProgramCache::getInstance()->getGLProgram(GLProgram::SHADER_NAME_POSITION_TEXTURE_COLOR)); - - _useAutomaticVertexZ = false; - _vertexZvalue = 0; - - return true; -} - -TMXLayer::TMXLayer() -: _layerName("") -, _layerSize(Size::ZERO) -, _mapTileSize(Size::ZERO) -, _tiles(nullptr) -, _tileSet(nullptr) -, _layerOrientation(FAST_TMX_ORIENTATION_ORTHO) -, _texture(nullptr) -, _vertexZvalue(0) -, _useAutomaticVertexZ(false) -, _quadsDirty(true) -, _dirty(true) -, _vertexBuffer(nullptr) -, _vData(nullptr) -, _indexBuffer(nullptr) -{ -} - -TMXLayer::~TMXLayer() -{ - CC_SAFE_RELEASE(_tileSet); - CC_SAFE_RELEASE(_texture); - CC_SAFE_FREE(_tiles); - CC_SAFE_RELEASE(_vData); - CC_SAFE_RELEASE(_vertexBuffer); - CC_SAFE_RELEASE(_indexBuffer); - -} - -void TMXLayer::draw(Renderer *renderer, const Mat4& transform, uint32_t flags) -{ - updateTotalQuads(); - - if( flags != 0 || _dirty || _quadsDirty ) - { - Size s = Director::getInstance()->getVisibleSize(); - auto rect = Rect(0, 0, s.width, s.height); - - Mat4 inv = transform; - inv.inverse(); - rect = RectApplyTransform(rect, inv); - - updateTiles(rect); - updateIndexBuffer(); - updatePrimitives(); - _dirty = false; - } - - if(_renderCommands.size() < static_cast(_primitives.size())) - { - _renderCommands.resize(_primitives.size()); - } - - int index = 0; - for(const auto& iter : _primitives) - { - if(iter.second->getCount() > 0) - { - auto& cmd = _renderCommands[index++]; - auto blendfunc = _texture->hasPremultipliedAlpha() ? BlendFunc::ALPHA_PREMULTIPLIED : BlendFunc::ALPHA_NON_PREMULTIPLIED; - cmd.init(iter.first, _texture->getName(), getGLProgramState(), blendfunc, iter.second, _modelViewTransform, flags); - renderer->addCommand(&cmd); - } - } -} - -void TMXLayer::onDraw(Primitive *primitive) -{ - GL::bindTexture2D(_texture->getName()); - getGLProgramState()->apply(_modelViewTransform); - - GL::bindVAO(0); - primitive->draw(); - glBindBuffer(GL_ARRAY_BUFFER, 0); - glBindBuffer(GL_ELEMENT_ARRAY_BUFFER, 0); - CC_INCREMENT_GL_DRAWN_BATCHES_AND_VERTICES(1, primitive->getCount() * 4); -} - -void TMXLayer::updateTiles(const Rect& culledRect) -{ - Rect visibleTiles = culledRect; - Size mapTileSize = CC_SIZE_PIXELS_TO_POINTS(_mapTileSize); - Size tileSize = CC_SIZE_PIXELS_TO_POINTS(_tileSet->_tileSize); - Mat4 nodeToTileTransform = _tileToNodeTransform.getInversed(); - //transform to tile - visibleTiles = RectApplyTransform(visibleTiles, nodeToTileTransform); - // tile coordinate is upside-down, so we need to make the tile coordinate use top-left for the start point. - visibleTiles.origin.y += 1; - - // if x=0.7, width=9.5, we need to draw number 0~10 of tiles, and so is height. - visibleTiles.size.width = ceil(visibleTiles.origin.x + visibleTiles.size.width) - floor(visibleTiles.origin.x); - visibleTiles.size.height = ceil(visibleTiles.origin.y + visibleTiles.size.height) - floor(visibleTiles.origin.y); - visibleTiles.origin.x = floor(visibleTiles.origin.x); - visibleTiles.origin.y = floor(visibleTiles.origin.y); - - // for the bigger tiles. - int tilesOverX = 0; - int tilesOverY = 0; - // for diagonal orientation tiles - float tileSizeMax = std::max(tileSize.width, tileSize.height); - if (_layerOrientation == FAST_TMX_ORIENTATION_ORTHO) - { - tilesOverX = ceil(tileSizeMax / mapTileSize.width) - 1; - tilesOverY = ceil(tileSizeMax / mapTileSize.height) - 1; - - if (tilesOverX < 0) tilesOverX = 0; - if (tilesOverY < 0) tilesOverY = 0; - } - else if(_layerOrientation == FAST_TMX_ORIENTATION_ISO) - { - Rect overTileRect(0, 0, tileSizeMax - mapTileSize.width, tileSizeMax - mapTileSize.height); - if (overTileRect.size.width < 0) overTileRect.size.width = 0; - if (overTileRect.size.height < 0) overTileRect.size.height = 0; - overTileRect = RectApplyTransform(overTileRect, nodeToTileTransform); - - tilesOverX = ceil(overTileRect.origin.x + overTileRect.size.width) - floor(overTileRect.origin.x); - tilesOverY = ceil(overTileRect.origin.y + overTileRect.size.height) - floor(overTileRect.origin.y); - } - - _indicesVertexZNumber.clear(); - - for(const auto& iter : _indicesVertexZOffsets) - { - _indicesVertexZNumber[iter.first] = iter.second; - } - - int yBegin = std::max(0.f,visibleTiles.origin.y - tilesOverY); - int yEnd = std::min(_layerSize.height,visibleTiles.origin.y + visibleTiles.size.height + tilesOverY); - int xBegin = std::max(0.f,visibleTiles.origin.x - tilesOverX); - int xEnd = std::min(_layerSize.width,visibleTiles.origin.x + visibleTiles.size.width + tilesOverX); - - for (int y = yBegin; y < yEnd; ++y) - { - for (int x = xBegin; x < xEnd; ++x) - { - int tileIndex = getTileIndexByPos(x, y); - if(_tiles[tileIndex] == 0) continue; - - int vertexZ = getVertexZForPos(Vec2(x,y)); - auto iter = _indicesVertexZNumber.find(vertexZ); - int offset = iter->second; - iter->second++; - - int quadIndex = _tileToQuadIndex[tileIndex]; - CC_ASSERT(-1 != quadIndex); - _indices[6 * offset + 0] = quadIndex * 4 + 0; - _indices[6 * offset + 1] = quadIndex * 4 + 1; - _indices[6 * offset + 2] = quadIndex * 4 + 2; - _indices[6 * offset + 3] = quadIndex * 4 + 3; - _indices[6 * offset + 4] = quadIndex * 4 + 2; - _indices[6 * offset + 5] = quadIndex * 4 + 1; - - } // for x - } // for y - - for(const auto& iter : _indicesVertexZOffsets) - { - _indicesVertexZNumber[iter.first] -= iter.second; - if(_indicesVertexZNumber[iter.first] == 0) - { - _indicesVertexZNumber.erase(iter.first); - } - } - -} - -void TMXLayer::updateVertexBuffer() -{ - GL::bindVAO(0); - if(nullptr == _vData) - { - _vertexBuffer = VertexBuffer::create(sizeof(V3F_C4B_T2F), (int)_totalQuads.size() * 4); - _vData = VertexData::create(); - _vData->setStream(_vertexBuffer, VertexStreamAttribute(0, GLProgram::VERTEX_ATTRIB_POSITION, GL_FLOAT, 3)); - _vData->setStream(_vertexBuffer, VertexStreamAttribute(offsetof(V3F_C4B_T2F, colors), GLProgram::VERTEX_ATTRIB_COLOR, GL_UNSIGNED_BYTE, 4, true)); - _vData->setStream(_vertexBuffer, VertexStreamAttribute(offsetof(V3F_C4B_T2F, texCoords), GLProgram::VERTEX_ATTRIB_TEX_COORD, GL_FLOAT, 2)); - CC_SAFE_RETAIN(_vData); - CC_SAFE_RETAIN(_vertexBuffer); - } - if(_vertexBuffer) - { - _vertexBuffer->updateVertices((void*)&_totalQuads[0], (int)_totalQuads.size() * 4, 0); - } - -} - -void TMXLayer::updateIndexBuffer() -{ - if(nullptr == _indexBuffer) - { - _indexBuffer = IndexBuffer::create(IndexBuffer::IndexType::INDEX_TYPE_SHORT_16, (int)_indices.size()); - CC_SAFE_RETAIN(_indexBuffer); - } - _indexBuffer->updateIndices(&_indices[0], (int)_indices.size(), 0); - -} - -// FastTMXLayer - setup Tiles -void TMXLayer::setupTiles() -{ - // Optimization: quick hack that sets the image size on the tileset - _tileSet->_imageSize = _texture->getContentSizeInPixels(); - - // By default all the tiles are aliased - // pros: easier to render - // cons: difficult to scale / rotate / etc. - _texture->setAliasTexParameters(); - - //CFByteOrder o = CFByteOrderGetCurrent(); - - // Parse cocos2d properties - this->parseInternalProperties(); - - Size screenSize = Director::getInstance()->getWinSize(); - - switch (_layerOrientation) - { - case FAST_TMX_ORIENTATION_ORTHO: - _screenGridSize.width = ceil(screenSize.width / _mapTileSize.width) + 1; - _screenGridSize.height = ceil(screenSize.height / _mapTileSize.height) + 1; - - // tiles could be bigger than the grid, add additional rows if needed - _screenGridSize.height += _tileSet->_tileSize.height / _mapTileSize.height; - break; - case FAST_TMX_ORIENTATION_ISO: - _screenGridSize.width = ceil(screenSize.width / _mapTileSize.width) + 2; - _screenGridSize.height = ceil(screenSize.height / (_mapTileSize.height/2)) + 4; - break; - case FAST_TMX_ORIENTATION_HEX: - default: - CCLOGERROR("FastTMX does not support type %d", _layerOrientation); - break; - } - - _screenTileCount = _screenGridSize.width * _screenGridSize.height; - -} - -Mat4 TMXLayer::tileToNodeTransform() -{ - float w = _mapTileSize.width / CC_CONTENT_SCALE_FACTOR(); - float h = _mapTileSize.height / CC_CONTENT_SCALE_FACTOR(); - float offY = (_layerSize.height - 1) * h; - - switch(_layerOrientation) - { - case FAST_TMX_ORIENTATION_ORTHO: - { - _tileToNodeTransform = Mat4 - ( - w, 0.0f, 0.0f, 0.0f, - 0.0f, -h, 0.0f, offY, - 0.0f, 0.0f, 1.0f, 0.0f, - 0.0f, 0.0, 0.0f, 1.0f - ); - - return _tileToNodeTransform; - } - case FAST_TMX_ORIENTATION_ISO: - { - float offX = (_layerSize.width - 1) * w / 2; - _tileToNodeTransform = Mat4 - ( - w/2, -w/2, 0.0f, offX, - -h/2, -h/2, 0.0f, offY, - 0.0f, 0.0f, 1.0f, 0.0f, - 0.0f, 0.0f, 0.0f, 1.0f - ); - return _tileToNodeTransform; - } - case FAST_TMX_ORIENTATION_HEX: - { - _tileToNodeTransform = Mat4 - ( - h * sqrtf(0.75), 0, 0, 0, - -h/2, -h, 0, offY, - 0, 0, 1, 0, - 0, 0, 0, 1 - ); - return _tileToNodeTransform; - } - default: - { - _tileToNodeTransform = Mat4::IDENTITY; - return _tileToNodeTransform; - } - } - -} - -void TMXLayer::updatePrimitives() -{ - for(const auto& iter : _indicesVertexZNumber) - { - int start = _indicesVertexZOffsets.at(iter.first); - - auto primitiveIter= _primitives.find(iter.first); - if(primitiveIter == _primitives.end()) - { - auto primitive = Primitive::create(_vData, _indexBuffer, GL_TRIANGLES); - primitive->setCount(iter.second * 6); - primitive->setStart(start * 6); - - _primitives.insert(iter.first, primitive); - } - else - { - primitiveIter->second->setCount(iter.second * 6); - primitiveIter->second->setStart(start * 6); - } - } -} - -void TMXLayer::updateTotalQuads() -{ - if(_quadsDirty) - { - Size tileSize = CC_SIZE_PIXELS_TO_POINTS(_tileSet->_tileSize); - Size texSize = _tileSet->_imageSize; - _tileToQuadIndex.clear(); - _totalQuads.resize(int(_layerSize.width * _layerSize.height)); - _indices.resize(6 * int(_layerSize.width * _layerSize.height)); - _tileToQuadIndex.resize(int(_layerSize.width * _layerSize.height),-1); - _indicesVertexZOffsets.clear(); - - int quadIndex = 0; - for(int y = 0; y < _layerSize.height; ++y) - { - for(int x =0; x < _layerSize.width; ++x) - { - int tileIndex = getTileIndexByPos(x, y); - int tileGID = _tiles[tileIndex]; - - if(tileGID == 0) continue; - - _tileToQuadIndex[tileIndex] = quadIndex; - - auto& quad = _totalQuads[quadIndex]; - - Vec3 nodePos(float(x), float(y), 0); - _tileToNodeTransform.transformPoint(&nodePos); - - float left, right, top, bottom, z; - - z = getVertexZForPos(Vec2(x, y)); - auto iter = _indicesVertexZOffsets.find(z); - if(iter == _indicesVertexZOffsets.end()) - { - _indicesVertexZOffsets[z] = 1; - } - else - { - iter->second++; - } - // vertices - if (tileGID & kTMXTileDiagonalFlag) - { - left = nodePos.x; - right = nodePos.x + tileSize.height; - bottom = nodePos.y + tileSize.width; - top = nodePos.y; - } - else - { - left = nodePos.x; - right = nodePos.x + tileSize.width; - bottom = nodePos.y + tileSize.height; - top = nodePos.y; - } - - if(tileGID & kTMXTileVerticalFlag) - std::swap(top, bottom); - if(tileGID & kTMXTileHorizontalFlag) - std::swap(left, right); - - if(tileGID & kTMXTileDiagonalFlag) - { - // FIXME: not working correctly - quad.bl.vertices.x = left; - quad.bl.vertices.y = bottom; - quad.bl.vertices.z = z; - quad.br.vertices.x = left; - quad.br.vertices.y = top; - quad.br.vertices.z = z; - quad.tl.vertices.x = right; - quad.tl.vertices.y = bottom; - quad.tl.vertices.z = z; - quad.tr.vertices.x = right; - quad.tr.vertices.y = top; - quad.tr.vertices.z = z; - } - else - { - quad.bl.vertices.x = left; - quad.bl.vertices.y = bottom; - quad.bl.vertices.z = z; - quad.br.vertices.x = right; - quad.br.vertices.y = bottom; - quad.br.vertices.z = z; - quad.tl.vertices.x = left; - quad.tl.vertices.y = top; - quad.tl.vertices.z = z; - quad.tr.vertices.x = right; - quad.tr.vertices.y = top; - quad.tr.vertices.z = z; - } - - // texcoords - Rect tileTexture = _tileSet->getRectForGID(tileGID); - left = (tileTexture.origin.x / texSize.width); - right = left + (tileTexture.size.width / texSize.width); - bottom = (tileTexture.origin.y / texSize.height); - top = bottom + (tileTexture.size.height / texSize.height); - - quad.bl.texCoords.u = left; - quad.bl.texCoords.v = bottom; - quad.br.texCoords.u = right; - quad.br.texCoords.v = bottom; - quad.tl.texCoords.u = left; - quad.tl.texCoords.v = top; - quad.tr.texCoords.u = right; - quad.tr.texCoords.v = top; - - quad.bl.colors = Color4B::WHITE; - quad.br.colors = Color4B::WHITE; - quad.tl.colors = Color4B::WHITE; - quad.tr.colors = Color4B::WHITE; - - ++quadIndex; - } - } - - int offset = 0; - for(auto iter = _indicesVertexZOffsets.begin(); iter != _indicesVertexZOffsets.end(); ++iter) - { - std::swap(offset, iter->second); - offset += iter->second; - } - updateVertexBuffer(); - - _quadsDirty = false; - } -} - -// removing / getting tiles -Sprite* TMXLayer::getTileAt(const Vec2& tileCoordinate) -{ - CCASSERT( tileCoordinate.x < _layerSize.width && tileCoordinate.y < _layerSize.height && tileCoordinate.x >=0 && tileCoordinate.y >=0, "TMXLayer: invalid position"); - CCASSERT( _tiles, "TMXLayer: the tiles map has been released"); - - Sprite *tile = nullptr; - int gid = this->getTileGIDAt(tileCoordinate); - - // if GID == 0, then no tile is present - if( gid ) { - int index = (int)tileCoordinate.x + (int)tileCoordinate.y * _layerSize.width; - - auto it = _spriteContainer.find(index); - if (it != _spriteContainer.end()) - { - tile = it->second.first; - } - else - { - // tile not created yet. create it - Rect rect = _tileSet->getRectForGID(gid); - rect = CC_RECT_PIXELS_TO_POINTS(rect); - tile = Sprite::createWithTexture(_texture, rect); - - Vec2 p = this->getPositionAt(tileCoordinate); - tile->setAnchorPoint(Vec2::ZERO); - tile->setPosition(p); - tile->setPositionZ((float)getVertexZForPos(tileCoordinate)); - tile->setOpacity(this->getOpacity()); - tile->setTag(index); - this->addChild(tile, index); - _spriteContainer.insert(std::pair >(index, std::pair(tile, gid))); - - // tile is converted to sprite. - setFlaggedTileGIDByIndex(index, 0); - } - } - return tile; -} - -int TMXLayer::getTileGIDAt(const Vec2& tileCoordinate, TMXTileFlags* flags/* = nullptr*/) -{ - CCASSERT(tileCoordinate.x < _layerSize.width && tileCoordinate.y < _layerSize.height && tileCoordinate.x >=0 && tileCoordinate.y >=0, "TMXLayer: invalid position"); - CCASSERT(_tiles, "TMXLayer: the tiles map has been released"); - - int idx = static_cast(((int)tileCoordinate.x + (int)tileCoordinate.y * _layerSize.width)); - - // Bits on the far end of the 32-bit global tile ID are used for tile flags - int tile = _tiles[idx]; - auto it = _spriteContainer.find(idx); - - // converted to sprite. - if (tile == 0 && it != _spriteContainer.end()) - { - tile = it->second.second; - } - - // issue1264, flipped tiles can be changed dynamically - if (flags) - { - *flags = (TMXTileFlags)(tile & kTMXFlipedAll); - } - - return (tile & kTMXFlippedMask); -} - -Vec2 TMXLayer::getPositionAt(const Vec2& pos) -{ - return PointApplyTransform(pos, _tileToNodeTransform); -} - -int TMXLayer::getVertexZForPos(const Vec2& pos) -{ - int ret = 0; - int maxVal = 0; - if (_useAutomaticVertexZ) - { - switch (_layerOrientation) - { - case FAST_TMX_ORIENTATION_ISO: - maxVal = static_cast(_layerSize.width + _layerSize.height); - ret = static_cast(-(maxVal - (pos.x + pos.y))); - break; - case FAST_TMX_ORIENTATION_ORTHO: - ret = static_cast(-(_layerSize.height-pos.y)); - break; - case FAST_TMX_ORIENTATION_HEX: - CCASSERT(0, "TMX Hexa vertexZ not supported"); - break; - default: - CCASSERT(0, "TMX invalid value"); - break; - } - } - else - { - ret = _vertexZvalue; - } - - return ret; -} - -void TMXLayer::removeTileAt(const Vec2& tileCoordinate) -{ - - CCASSERT( tileCoordinate.x < _layerSize.width && tileCoordinate.y < _layerSize.height && tileCoordinate.x >=0 && tileCoordinate.y >=0, "TMXLayer: invalid position"); - - int gid = this->getTileGIDAt(tileCoordinate); - - if( gid ) { - - int z = (int)tileCoordinate.x + (int)tileCoordinate.y * _layerSize.width; - - // remove tile from GID map - setFlaggedTileGIDByIndex(z, 0); - - // remove it from sprites - auto it = _spriteContainer.find(z); - if (it != _spriteContainer.end()) - { - this->removeChild(it->second.first); - } - } -} - -void TMXLayer::setFlaggedTileGIDByIndex(int index, int gid) -{ - if(gid == _tiles[index]) return; - _tiles[index] = gid; - _quadsDirty = true; - _dirty = true; -} - -void TMXLayer::removeChild(Node* node, bool cleanup) -{ - int tag = node->getTag(); - auto it = _spriteContainer.find(tag); - if (it != _spriteContainer.end() && it->second.first == node) - { - _spriteContainer.erase(it); - } - Node::removeChild(node, cleanup); -} - -// TMXLayer - Properties -Value TMXLayer::getProperty(const std::string& propertyName) const -{ - if (_properties.find(propertyName) != _properties.end()) - return _properties.at(propertyName); - - return Value(); -} - -void TMXLayer::parseInternalProperties() -{ - auto vertexz = getProperty("cc_vertexz"); - if (vertexz.isNull()) return; - - std::string vertexZStr = vertexz.asString(); - // If "automatic" is on, then parse the "cc_alpha_func" too - if (vertexZStr == "automatic") - { - _useAutomaticVertexZ = true; - auto alphaFuncVal = getProperty("cc_alpha_func"); - float alphaFuncValue = alphaFuncVal.asFloat(); - setGLProgram(GLProgramCache::getInstance()->getGLProgram(GLProgram::SHADER_NAME_POSITION_TEXTURE_ALPHA_TEST)); - - GLint alphaValueLocation = glGetUniformLocation(getGLProgram()->getProgram(), GLProgram::UNIFORM_NAME_ALPHA_TEST_VALUE); - - // NOTE: alpha test shader is hard-coded to use the equivalent of a glAlphaFunc(GL_GREATER) comparison - - // use shader program to set uniform - getGLProgram()->use(); - getGLProgram()->setUniformLocationWith1f(alphaValueLocation, alphaFuncValue); - CHECK_GL_ERROR_DEBUG(); - } - else - { - _vertexZvalue = vertexz.asInt(); - } -} - -//CCTMXLayer2 - obtaining positions, offset -Vec2 TMXLayer::calculateLayerOffset(const Vec2& pos) -{ - Vec2 ret; - switch (_layerOrientation) - { - case FAST_TMX_ORIENTATION_ORTHO: - ret.set( pos.x * _mapTileSize.width, -pos.y *_mapTileSize.height); - break; - case FAST_TMX_ORIENTATION_ISO: - ret.set((_mapTileSize.width /2) * (pos.x - pos.y), - (_mapTileSize.height /2 ) * (-pos.x - pos.y)); - break; - case FAST_TMX_ORIENTATION_HEX: - default: - CCASSERT(pos.isZero(), "offset for this map not implemented yet"); - break; - } - return ret; -} - -// TMXLayer - adding / remove tiles -void TMXLayer::setTileGID(int gid, const Vec2& tileCoordinate) -{ - setTileGID(gid, tileCoordinate, (TMXTileFlags)0); -} - -void TMXLayer::setTileGID(int gid, const Vec2& tileCoordinate, TMXTileFlags flags) -{ - CCASSERT(tileCoordinate.x < _layerSize.width && tileCoordinate.y < _layerSize.height && tileCoordinate.x >=0 && tileCoordinate.y >=0, "TMXLayer: invalid position"); - CCASSERT(_tiles, "TMXLayer: the tiles map has been released"); - CCASSERT(gid == 0 || gid >= _tileSet->_firstGid, "TMXLayer: invalid gid" ); - - TMXTileFlags currentFlags; - int currentGID = getTileGIDAt(tileCoordinate, ¤tFlags); - - if (currentGID == gid && currentFlags == flags) return; - - int gidAndFlags = gid | flags; - - // setting gid=0 is equal to remove the tile - if (gid == 0) - { - removeTileAt(tileCoordinate); - } - // empty tile. create a new one - else if (currentGID == 0) - { - int z = (int)tileCoordinate.x + (int)tileCoordinate.y * _layerSize.width; - setFlaggedTileGIDByIndex(z, gidAndFlags); - } - // modifying an existing tile with a non-empty tile - else - { - int z = (int)tileCoordinate.x + (int)tileCoordinate.y * _layerSize.width; - auto it = _spriteContainer.find(z); - if (it != _spriteContainer.end()) - { - Sprite *sprite = it->second.first; - Rect rect = _tileSet->getRectForGID(gid); - rect = CC_RECT_PIXELS_TO_POINTS(rect); - - sprite->setTextureRect(rect, false, rect.size); - this->reorderChild(sprite, z); - if (flags) - { - setupTileSprite(sprite, sprite->getPosition(), gidAndFlags); - } - - it->second.second = gidAndFlags; - } - else - { - setFlaggedTileGIDByIndex(z, gidAndFlags); - } - } -} - -void TMXLayer::setupTileSprite(Sprite* sprite, const Vec2& pos, int gid) -{ - sprite->setPosition(getPositionAt(pos)); - sprite->setPositionZ((float)getVertexZForPos(pos)); - sprite->setAnchorPoint(Vec2::ZERO); - sprite->setOpacity(this->getOpacity()); - - //issue 1264, flip can be undone as well - sprite->setFlippedX(false); - sprite->setFlippedY(false); - sprite->setRotation(0.0f); - - // Rotation in tiled is achieved using 3 flipped states, flipping across the horizontal, vertical, and diagonal axes of the tiles. - if (gid & kTMXTileDiagonalFlag) - { - // put the anchor in the middle for ease of rotation. - sprite->setAnchorPoint(Vec2::ANCHOR_MIDDLE); - sprite->setPosition(getPositionAt(pos).x + sprite->getContentSize().height/2, - getPositionAt(pos).y + sprite->getContentSize().width/2 ); - - int flag = gid & (kTMXTileHorizontalFlag | kTMXTileVerticalFlag ); - - // handle the 4 diagonally flipped states. - if (flag == kTMXTileHorizontalFlag) - { - sprite->setRotation(90.0f); - } - else if (flag == kTMXTileVerticalFlag) - { - sprite->setRotation(270.0f); - } - else if (flag == (kTMXTileVerticalFlag | kTMXTileHorizontalFlag) ) - { - sprite->setRotation(90.0f); - sprite->setFlippedX(true); - } - else - { - sprite->setRotation(270.0f); - sprite->setFlippedX(true); - } - } - else - { - if (gid & kTMXTileHorizontalFlag) - { - sprite->setFlippedX(true); - } - - if (gid & kTMXTileVerticalFlag) - { - sprite->setFlippedY(true); - } - } -} - -std::string TMXLayer::getDescription() const -{ - return StringUtils::format("", _tag, (int)_mapTileSize.width, (int)_mapTileSize.height); -} - -} //end of namespace experimental - -NS_CC_END - diff --git a/native/cocos/2d/CCFastTMXLayer.h b/native/cocos/2d/CCFastTMXLayer.h deleted file mode 100644 index 891e95275f..0000000000 --- a/native/cocos/2d/CCFastTMXLayer.h +++ /dev/null @@ -1,363 +0,0 @@ -/**************************************************************************** -Copyright (c) 2014-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ -#ifndef __CC_FAST_TMX_LAYER_H__ -#define __CC_FAST_TMX_LAYER_H__ - -#include -#include -#include "2d/CCNode.h" -#include "2d/CCTMXXMLParser.h" -#include "renderer/CCPrimitiveCommand.h" -#include "base/CCMap.h" - -NS_CC_BEGIN - -class TMXMapInfo; -class TMXLayerInfo; -class TMXTilesetInfo; -class Texture2D; -class Sprite; -struct _ccCArray; - -namespace experimental{ - -/** - * @addtogroup _2d - * @{ - */ - -/** @brief FastTMXLayer represents the TMX layer. - - * It is a subclass of SpriteBatchNode. By default the tiles are rendered using a TextureAtlas. - * If you modify a tile on runtime, then, that tile will become a Sprite, otherwise no Sprite objects are created. - * The benefits of using Sprite objects as tiles are: - * - tiles (Sprite) can be rotated/scaled/moved with a nice API. - - * If the layer contains a property named "cc_vertexz" with an integer (in can be positive or negative), - * then all the tiles belonging to the layer will use that value as their OpenGL vertex Z for depth. - - * On the other hand, if the "cc_vertexz" property has the "automatic" value, then the tiles will use an automatic vertex Z value. - * Also before drawing the tiles, GL_ALPHA_TEST will be enabled, and disabled after drawing them. The used alpha func will be: - - * glAlphaFunc( GL_GREATER, value ). - - * "value" by default is 0, but you can change it from Tiled by adding the "cc_alpha_func" property to the layer. - * The value 0 should work for most cases, but if you have tiles that are semi-transparent, then you might want to use a different - * value, like 0.5. - - * For further information, please see the programming guide: - * http://www.cocos2d-iphone.org/wiki/doku.php/prog_guide:tiled_maps - - * @since v3.2 - * @js NA - */ - -class CC_DLL TMXLayer : public Node -{ -public: - /** Creates a FastTMXLayer with an tileset info, a layer info and a map info. - * - * @param tilesetInfo An tileset info. - * @param layerInfo A layer info. - * @param mapInfo A map info. - * @return Return an autorelease object. - */ - static TMXLayer * create(TMXTilesetInfo *tilesetInfo, TMXLayerInfo *layerInfo, TMXMapInfo *mapInfo); - /** - * @js ctor - */ - TMXLayer(); - /** - * @js NA - * @lua NA - */ - virtual ~TMXLayer(); - - /** Returns the tile gid at a given tile coordinate. It also returns the tile flags. - * - * @param tileCoordinate The tile coordinate. - * @param flags A TMXTileFlags. - * @return The tile gid at a given tile coordinate. It also returns the tile flags. - */ - int getTileGIDAt(const Vec2& tileCoordinate, TMXTileFlags* flags = nullptr); - - /** Sets the tile gid (gid = tile global id) at a given tile coordinate. - * The Tile GID can be obtained by using the method "tileGIDAt" or by using the TMX editor -> Tileset Mgr +1. - * If a tile is already placed at that position, then it will be removed. - * @param gid The gid value. - * @param tileCoordinate The tile coordinate. - */ - void setTileGID(int gid, const Vec2& tileCoordinate); - - /** Sets the tile gid (gid = tile global id) at a given tile coordinate. - * The Tile GID can be obtained by using the method "tileGIDAt" or by using the TMX editor -> Tileset Mgr +1. - * If a tile is already placed at that position, then it will be removed. - * Use withFlags if the tile flags need to be changed as well. - * - * @param gid A integer value,it will be sets the tile gid. - * @param tileCoordinate The tile coordinate. - * @param flags A TMXTileFlags. - */ - void setTileGID(int gid, const Vec2& tileCoordinate, TMXTileFlags flags); - - /** Removes a tile at given tile coordinate. - * - * @param tileCoordinate The tile Coordinate. - */ - void removeTileAt(const Vec2& tileCoordinate); - - /** Returns the position in points of a given tile coordinate. - * - * @param tileCoordinate The tile Coordinate. - * @return The position in points of a given tile coordinate. - */ - Vec2 getPositionAt(const Vec2& tileCoordinate); - - /** Return the value for the specific property name. - * - * @param propertyName The value for the specific property name. - * @return The value for the specific property name. - */ - Value getProperty(const std::string& propertyName) const; - - /** Creates the tiles. */ - void setupTiles(); - - /** Get the tile layer name. - * - * @return The tile layer name. - */ - inline const std::string& getLayerName(){ return _layerName; } - - /** Set the tile layer name. - * - * @param layerName The new layer name. - */ - inline void setLayerName(const std::string& layerName){ _layerName = layerName; } - - /** Size of the layer in tiles. - * - * @return Size of the layer in tiles. - */ - inline const Size& getLayerSize() const { return _layerSize; }; - - /** Set the size of the layer in tiles. - * - * @param size The new size of the layer in tiles. - */ - inline void setLayerSize(const Size& size) { _layerSize = size; }; - - /** Size of the map's tile (could be different from the tile's size). - * - * @return Size of the map's tile (could be different from the tile's size). - */ - inline const Size& getMapTileSize() const { return _mapTileSize; }; - - /** Set the size of the map's tile. - * - * @param size The new size of the map's tile. - */ - inline void setMapTileSize(const Size& size) { _mapTileSize = size; }; - - /** Pointer to the map of tiles. - * @js NA - * @lua NA - * @return The pointer to the map of tiles. - */ - const uint32_t* getTiles() const { return _tiles; }; - - /** Set the pointer to the map of tiles. - * - * @param tiles The pointer to the map of tiles. - */ - void setTiles(uint32_t* tiles) { _tiles = tiles; _quadsDirty = true;}; - - /** Tileset information for the layer. - * - * @return Tileset information for the layer. - */ - inline TMXTilesetInfo* getTileSet() const { return _tileSet; }; - - /** Set the tileset information for the layer. - * - * @param info The new tileset information for the layer. - */ - inline void setTileSet(TMXTilesetInfo* info) { - CC_SAFE_RETAIN(info); - CC_SAFE_RELEASE(_tileSet); - _tileSet = info; - }; - - /** Layer orientation, which is the same as the map orientation. - * - * @return Layer orientation, which is the same as the map orientation. - */ - inline int getLayerOrientation() const { return _layerOrientation; }; - - /** Set Layer orientation, which is the same as the map orientation. - * - * @param orientation Layer orientation, which is the same as the map orientation. - */ - inline void setLayerOrientation(int orientation) { _layerOrientation = orientation; }; - - /** Properties from the layer. They can be added using Tiled. - * - * @return Properties from the layer. They can be added using Tiled. - */ - inline const ValueMap& getProperties() const { return _properties; }; - - /** Properties from the layer. They can be added using Tiled. - * - * @return Properties from the layer. They can be added using Tiled. - */ - inline ValueMap& getProperties() { return _properties; }; - - /** Set the properties to the layer. - * - * @param properties The properties to the layer. - */ - inline void setProperties(const ValueMap& properties) - { - _properties = properties; - }; - - /** Returns the tile (Sprite) at a given a tile coordinate. - * The returned Sprite will be already added to the TMXLayer. Don't add it again. - * The Sprite can be treated like any other Sprite: rotated, scaled, translated, opacity, color, etc. - * You can remove either by calling: - * - layer->removeChild(sprite, cleanup); - * - * @return Returns the tile (Sprite) at a given a tile coordinate. - */ - Sprite* getTileAt(const Vec2& tileCoordinate); - - /** Set an sprite to the tile,with the tile coordinate and gid. - * - * @param sprite A Sprite. - * @param pos The tile coordinate. - * @param gid The tile gid. - */ - void setupTileSprite(Sprite* sprite, const Vec2& pos, int gid); - - // - // Override - // - virtual std::string getDescription() const override; - virtual void draw(Renderer *renderer, const Mat4& transform, uint32_t flags) override; - void removeChild(Node* child, bool cleanup = true) override; - -CC_CONSTRUCTOR_ACCESS: - bool initWithTilesetInfo(TMXTilesetInfo *tilesetInfo, TMXLayerInfo *layerInfo, TMXMapInfo *mapInfo); - -protected: - void updateTiles(const Rect& culledRect); - Vec2 calculateLayerOffset(const Vec2& offset); - - /* The layer recognizes some special properties, like cc_vertez */ - void parseInternalProperties(); - - Mat4 tileToNodeTransform(); - Rect tileBoundsForClipTransform(const Mat4 &tileToClip); - - int getVertexZForPos(const Vec2& pos); - - //Flip flags is packed into gid - void setFlaggedTileGIDByIndex(int index, int gid); - - // - void updateTotalQuads(); - - void onDraw(Primitive* primitive); - inline int getTileIndexByPos(int x, int y) const { return x + y * (int) _layerSize.width; } - - void updateVertexBuffer(); - void updateIndexBuffer(); - void updatePrimitives(); -protected: - - //! name of the layer - std::string _layerName; - - /** size of the layer in tiles */ - Size _layerSize; - /** size of the map's tile (could be different from the tile's size) */ - Size _mapTileSize; - /** pointer to the map of tiles */ - uint32_t* _tiles; - /** Tileset information for the layer */ - TMXTilesetInfo* _tileSet; - /** Layer orientation, which is the same as the map orientation */ - int _layerOrientation; - /** properties from the layer. They can be added using Tiled */ - ValueMap _properties; - - Texture2D *_texture; - - /** container for sprite children. map > */ - std::map > _spriteContainer; - - //GLuint _buffersVBO; //0: vertex, 1: indices - - Size _screenGridSize; - Rect _screenGridRect; - int _screenTileCount; - - int _vertexZvalue; - bool _useAutomaticVertexZ; - - /** tile coordinate to node coordinate transform */ - Mat4 _tileToNodeTransform; - /** data for rendering */ - bool _quadsDirty; - std::vector _tileToQuadIndex; - std::vector _totalQuads; - std::vector _indices; - std::map _indicesVertexZOffsets; - std::unordered_map _indicesVertexZNumber; - std::vector _renderCommands; - bool _dirty; - - VertexBuffer* _vertexBuffer; - - VertexData* _vData; - - IndexBuffer* _indexBuffer; - - Map _primitives; - -public: - /** Possible orientations of the TMX map */ - static const int FAST_TMX_ORIENTATION_ORTHO; - static const int FAST_TMX_ORIENTATION_HEX; - static const int FAST_TMX_ORIENTATION_ISO; -}; - -// end of tilemap_parallax_nodes group -/// @} -} //end of namespace experimental -NS_CC_END - -#endif //__CCTMX_LAYER2_H__ - diff --git a/native/cocos/2d/CCFastTMXTiledMap.cpp b/native/cocos/2d/CCFastTMXTiledMap.cpp deleted file mode 100644 index 6317d97928..0000000000 --- a/native/cocos/2d/CCFastTMXTiledMap.cpp +++ /dev/null @@ -1,278 +0,0 @@ -/**************************************************************************** -Copyright (c) 2014-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ -#include "2d/CCFastTMXTiledMap.h" -#include "2d/CCFastTMXLayer.h" -#include "base/ccUTF8.h" - -NS_CC_BEGIN -namespace experimental { - -// implementation FastTMXTiledMap - -TMXTiledMap * TMXTiledMap::create(const std::string& tmxFile) -{ - TMXTiledMap *ret = new (std::nothrow) TMXTiledMap(); - if (ret->initWithTMXFile(tmxFile)) - { - ret->autorelease(); - return ret; - } - CC_SAFE_DELETE(ret); - return nullptr; -} - -TMXTiledMap* TMXTiledMap::createWithXML(const std::string& tmxString, const std::string& resourcePath) -{ - TMXTiledMap *ret = new (std::nothrow) TMXTiledMap(); - if (ret->initWithXML(tmxString, resourcePath)) - { - ret->autorelease(); - return ret; - } - CC_SAFE_DELETE(ret); - return nullptr; -} - -bool TMXTiledMap::initWithTMXFile(const std::string& tmxFile) -{ - CCASSERT(!tmxFile.empty(), "FastTMXTiledMap: tmx file should not be empty"); - if (tmxFile.empty()) { - return false; - } - - setContentSize(Size::ZERO); - - TMXMapInfo *mapInfo = TMXMapInfo::create(tmxFile); - - if (! mapInfo) - { - return false; - } - CCASSERT( !mapInfo->getTilesets().empty(), "FastTMXTiledMap: Map not found. Please check the filename."); - buildWithMapInfo(mapInfo); - - return true; -} - -bool TMXTiledMap::initWithXML(const std::string& tmxString, const std::string& resourcePath) -{ - setContentSize(Size::ZERO); - - TMXMapInfo *mapInfo = TMXMapInfo::createWithXML(tmxString, resourcePath); - - CCASSERT( !mapInfo->getTilesets().empty(), "FastTMXTiledMap: Map not found. Please check the filename."); - buildWithMapInfo(mapInfo); - - return true; -} - -TMXTiledMap::TMXTiledMap() - :_mapSize(Size::ZERO) - ,_tileSize(Size::ZERO) -{ -} - -TMXTiledMap::~TMXTiledMap() -{ -} - -// private -TMXLayer * TMXTiledMap::parseLayer(TMXLayerInfo *layerInfo, TMXMapInfo *mapInfo) -{ - TMXTilesetInfo *tileset = tilesetForLayer(layerInfo, mapInfo); - if (tileset == nullptr) - return nullptr; - - TMXLayer *layer = TMXLayer::create(tileset, layerInfo, mapInfo); - - // tell the layerinfo to release the ownership of the tiles map. - layerInfo->_ownTiles = false; - layer->setupTiles(); - - return layer; -} - -TMXTilesetInfo * TMXTiledMap::tilesetForLayer(TMXLayerInfo *layerInfo, TMXMapInfo *mapInfo) -{ - Size size = layerInfo->_layerSize; - auto& tilesets = mapInfo->getTilesets(); - - for (auto iter = tilesets.crbegin(); iter != tilesets.crend(); ++iter) - { - TMXTilesetInfo* tilesetInfo = *iter; - if (tilesetInfo) - { - for( int y=0; y < size.height; y++ ) - { - for( int x=0; x < size.width; x++ ) - { - int pos = static_cast(x + size.width * y); - int gid = layerInfo->_tiles[ pos ]; - - // gid are stored in little endian. - // if host is big endian, then swap - //if( o == CFByteOrderBigEndian ) - // gid = CFSwapInt32( gid ); - /* We support little endian.*/ - - // FIXME: gid == 0 --> empty tile - if( gid != 0 ) - { - // Optimization: quick return - // if the layer is invalid (more than 1 tileset per layer) an CCASSERT will be thrown later - if( (gid & kTMXFlippedMask) >= tilesetInfo->_firstGid ) - return tilesetInfo; - } - } - } - } - } - - // If all the tiles are 0, return empty tileset - CCLOG("cocos2d: Warning: TMX Layer '%s' has no tiles", layerInfo->_name.c_str()); - return nullptr; -} - -void TMXTiledMap::buildWithMapInfo(TMXMapInfo* mapInfo) -{ - _mapSize = mapInfo->getMapSize(); - _tileSize = mapInfo->getTileSize(); - _mapOrientation = mapInfo->getOrientation(); - - _properties = mapInfo->getProperties(); - - _tileProperties = mapInfo->getTileProperties(); - - int idx=0; - - auto& layers = mapInfo->getLayers(); - for(const auto &layerInfo : layers) { - if (layerInfo->_visible) - { - TMXLayer *child = parseLayer(layerInfo, mapInfo); - if (child == nullptr) { - idx++; - continue; - } - addChild(child, idx, idx); - - // update content size with the max size - const Size& childSize = child->getContentSize(); - Size currentSize = this->getContentSize(); - currentSize.width = std::max( currentSize.width, childSize.width ); - currentSize.height = std::max( currentSize.height, childSize.height ); - this->setContentSize(currentSize); - - idx++; - } - } -} - -// public -TMXLayer * TMXTiledMap::getLayer(const std::string& layerName) const -{ - CCASSERT(!layerName.empty(), "Invalid layer name!"); - if (layerName.empty()) { - return nullptr; - } - - for (auto& child : _children) - { - TMXLayer* layer = dynamic_cast(child); - if(layer) - { - if(layerName.compare( layer->getLayerName()) == 0) - { - return layer; - } - } - } - - // layer not found - return nullptr; -} - -TMXObjectGroup * TMXTiledMap::getObjectGroup(const std::string& groupName) const -{ - CCASSERT(!groupName.empty(), "Invalid group name!"); - - if (groupName.empty()) { - return nullptr; - } - - for (auto& child : _children) - { - TMXObjectGroup* group = dynamic_cast(child); - if(group) - { - if(groupName.compare( group->getGroupName()) == 0) - { - return group; - } - } - } - - // objectGroup not found - return nullptr; -} - -Vector TMXTiledMap::getObjectGroups() -{ - Vector groups; - for (auto& child : _children) - { - TMXObjectGroup* group = dynamic_cast(child); - if(group) - { - groups.pushBack(group); - } - } - return groups; -} -Value TMXTiledMap::getProperty(const std::string& propertyName) const -{ - if (_properties.find(propertyName) != _properties.end()) - return _properties.at(propertyName); - - return Value(); -} - -Value TMXTiledMap::getPropertiesForGID(int GID) const -{ - if (_tileProperties.find(GID) != _tileProperties.end()) - return _tileProperties.at(GID); - - return Value(); -} - -std::string TMXTiledMap::getDescription() const -{ - return StringUtils::format("(_children.size())); -} - -} //end of namespace experimental - -NS_CC_END - diff --git a/native/cocos/2d/CCFastTMXTiledMap.h b/native/cocos/2d/CCFastTMXTiledMap.h deleted file mode 100644 index b67bf673b0..0000000000 --- a/native/cocos/2d/CCFastTMXTiledMap.h +++ /dev/null @@ -1,242 +0,0 @@ -/**************************************************************************** -Copyright (c) 2014-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ -#ifndef __CC_FAST_TMX_TILEMAP_H__ -#define __CC_FAST_TMX_TILEMAP_H__ - -#include "2d/CCNode.h" -#include "2d/CCTMXObjectGroup.h" - -NS_CC_BEGIN - -class TMXLayerInfo; -class TMXTilesetInfo; -class TMXMapInfo; -namespace experimental { -class TMXLayer; - -/** - * @addtogroup _2d - * @{ - */ - -/** @brief FastTMXTiledMap knows how to parse and render a TMX map. - - * It adds support for the TMX tiled map format used by http://www.mapeditor.org. - * It supports isometric, hexagonal and orthogonal tiles. - * It also supports object groups, objects, and properties. - - * Features: - * - Each tile will be treated as an Sprite. - * - The sprites are created on demand. They will be created only when you call "layer->tileAt(position)". - * - Each tile can be rotated / moved / scaled / tinted / "opaqued", since each tile is a Sprite. - * - Tiles can be added/removed in runtime. - * - The z-order of the tiles can be modified in runtime. - * - Each tile has an anchorPoint of (0,0). - * - The anchorPoint of the TMXTileMap is (0,0). - * - The TMX layers will be added as a child. - * - The TMX layers will be aliased by default. - * - The tileset image will be loaded using the TextureCache. - * - Each tile will have a unique tag. - * - Each tile will have a unique z value. top-left: z=1, bottom-right: z=max z. - * - Each object group will be treated as an MutableArray. - * - Object class which will contain all the properties in a dictionary. - * - Properties can be assigned to the Map, Layer, Object Group, and Object. - - * Limitations: - * - It only supports one tileset per layer. - * - Embedded images are not supported. - * - It only supports the XML format (the JSON format is not supported). - - * Technical description: - * Each layer is created using an FastTMXLayer (subclass of SpriteBatchNode). If you have 5 layers, then 5 FastTMXLayer will be created, - * unless the layer visibility is off. In that case, the layer won't be created at all. - * You can obtain the layers (FastTMXLayer objects) at runtime by: - * - map->getChildByTag(tag_number); // 0=1st layer, 1=2nd layer, 2=3rd layer, etc... - * - map->getLayer(name_of_the_layer); - - * Each object group is created using a TMXObjectGroup which is a subclass of MutableArray. - * You can obtain the object groups at runtime by: - * - map->getObjectGroup(name_of_the_object_group); - - * Each object is a TMXObject. - - * Each property is stored as a key-value pair in an MutableDictionary. - * You can obtain the properties at runtime by: - - * map->getProperty(name_of_the_property); - * layer->getProperty(name_of_the_property); - * objectGroup->getProperty(name_of_the_property); - * object->getProperty(name_of_the_property); - - * @since v3.2 - * @js NA - */ -class CC_DLL TMXTiledMap : public Node -{ -public: - /** Creates a TMX Tiled Map with a TMX file. - * - * @return An autorelease object. - */ - static TMXTiledMap* create(const std::string& tmxFile); - - /** Initializes a TMX Tiled Map with a TMX formatted XML string and a path to TMX resources. - * - * @param tmxString A TMX formatted XML string. - * @param resourcePath A path to TMX resources. - * @return An autorelease object. - */ - static TMXTiledMap* createWithXML(const std::string& tmxString, const std::string& resourcePath); - - /** Return the FastTMXLayer for the specific layer. - * - * @return Return the FastTMXLayer for the specific layer. - */ - TMXLayer* getLayer(const std::string& layerName) const; - - /** Return the TMXObjectGroup for the specific group. - * - * @return Return the TMXObjectGroup for the specific group. - */ - TMXObjectGroup* getObjectGroup(const std::string& groupName) const; - - /** Return the value for the specific property name. - * - * @return Return the value for the specific property name. - */ - Value getProperty(const std::string& propertyName) const; - - /** Return properties dictionary for tile GID. - * - * @return Return properties dictionary for tile GID. - */ - Value getPropertiesForGID(int GID) const; - - /** The map's size property measured in tiles. - * - * @return The map's size property measured in tiles. - */ - inline const Size& getMapSize() const { return _mapSize; }; - - /** Set the map's size property measured in tiles. - * - * @param mapSize The map's size property measured in tiles. - */ - inline void setMapSize(const Size& mapSize) { _mapSize = mapSize; }; - - /** The tiles's size property measured in pixels. - * - * @return The tiles's size property measured in pixels. - */ - inline const Size& getTileSize() const { return _tileSize; }; - - /** Set the tiles's size property measured in pixels. - * - * @param tileSize The tiles's size property measured in pixels. - */ - inline void setTileSize(const Size& tileSize) { _tileSize = tileSize; }; - - /** Get map orientation. - * - * @return The map orientation. - */ - inline int getMapOrientation() const { return _mapOrientation; }; - - /** Set map orientation. - * - * @param mapOrientation The map orientation. - */ - inline void setMapOrientation(int mapOrientation) { _mapOrientation = mapOrientation; }; - - /** Get object groups. - * - * @return Object groups. - */ - Vector getObjectGroups(); - - /** Get properties. - * - * @return Properties. - */ - inline const ValueMap& getProperties() const { return _properties; }; - - /** Set properties. - * - * @param properties An ValueMap Properties. - */ - inline void setProperties(const ValueMap& properties) { - _properties = properties; - }; - - virtual std::string getDescription() const override; - -CC_CONSTRUCTOR_ACCESS: - /** - * @js ctor - */ - TMXTiledMap(); - /** - * @js NA - * @lua NA - */ - virtual ~TMXTiledMap(); - - /** initializes a TMX Tiled Map with a TMX file */ - bool initWithTMXFile(const std::string& tmxFile); - - /** initializes a TMX Tiled Map with a TMX formatted XML string and a path to TMX resources */ - bool initWithXML(const std::string& tmxString, const std::string& resourcePath); - -protected: - TMXLayer * parseLayer(TMXLayerInfo *layerInfo, TMXMapInfo *mapInfo); - TMXTilesetInfo * tilesetForLayer(TMXLayerInfo *layerInfo, TMXMapInfo *mapInfo); - void buildWithMapInfo(TMXMapInfo* mapInfo); - - /** the map's size property measured in tiles */ - Size _mapSize; - /** the tiles's size property measured in pixels */ - Size _tileSize; - /** map orientation */ - int _mapOrientation; - /** object groups */ - /** properties */ - ValueMap _properties; - - //! tile properties - ValueMapIntKey _tileProperties; - -private: - CC_DISALLOW_COPY_AND_ASSIGN(TMXTiledMap); - -}; - -// end of tilemap_parallax_nodes group -/** @} */ -} //end of namespace experimental - -NS_CC_END - -#endif //__CCTMX_TILE_MAP2_H__ - diff --git a/native/cocos/2d/CCFont.cpp b/native/cocos/2d/CCFont.cpp deleted file mode 100644 index ad1b675d5e..0000000000 --- a/native/cocos/2d/CCFont.cpp +++ /dev/null @@ -1,27 +0,0 @@ -/**************************************************************************** - Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - - http://www.cocos.com - - Permission is hereby granted, free of charge, to any person obtaining a copy - of this software and associated engine source code (the "Software"), a limited, - worldwide, royalty-free, non-assignable, revocable and non-exclusive license - to use Cocos Creator solely to develop games on your target platforms. You shall - not use Cocos Creator software for developing other software or tools that's - used for developing games. You are not granted to publish, distribute, - sublicense, and/or sell copies of Cocos Creator. - - The software or tools in this License Agreement are licensed, not sold. - Xiamen Yaji Software Co., Ltd. reserves all rights not expressly granted to you. - - THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN - THE SOFTWARE. - ****************************************************************************/ - - - diff --git a/native/cocos/2d/CCFontAtlas.cpp b/native/cocos/2d/CCFontAtlas.cpp deleted file mode 100644 index 723bcb7aa3..0000000000 --- a/native/cocos/2d/CCFontAtlas.cpp +++ /dev/null @@ -1,490 +0,0 @@ -/**************************************************************************** - Copyright (c) 2013 Zynga Inc. - Copyright (c) 2013-2016 Chukong Technologies Inc. - Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - - http://www.cocos2d-x.org - - Permission is hereby granted, free of charge, to any person obtaining a copy - of this software and associated documentation files (the "Software"), to deal - in the Software without restriction, including without limitation the rights - to use, copy, modify, merge, publish, distribute, sublicense, and/or sell - copies of the Software, and to permit persons to whom the Software is - furnished to do so, subject to the following conditions: - - The above copyright notice and this permission notice shall be included in - all copies or substantial portions of the Software. - - THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN - THE SOFTWARE. - ****************************************************************************/ - -#include "2d/CCFontAtlas.h" -#if CC_TARGET_PLATFORM != CC_PLATFORM_WIN32 && CC_TARGET_PLATFORM != CC_PLATFORM_WINRT && CC_TARGET_PLATFORM != CC_PLATFORM_ANDROID -#include -#elif CC_TARGET_PLATFORM == CC_PLATFORM_ANDROID -#include "platform/android/jni/Java_org_cocos2dx_lib_Cocos2dxHelper.h" -#endif -#include "2d/CCFontFreeType.h" -#include "base/ccUTF8.h" -#include "base/CCDirector.h" -#include "base/CCEventListenerCustom.h" -#include "base/CCEventDispatcher.h" -#include "base/CCEventType.h" - -NS_CC_BEGIN - -const int FontAtlas::CacheTextureWidth = 512; -const int FontAtlas::CacheTextureHeight = 512; -const char* FontAtlas::CMD_PURGE_FONTATLAS = "__cc_PURGE_FONTATLAS"; -const char* FontAtlas::CMD_RESET_FONTATLAS = "__cc_RESET_FONTATLAS"; - -FontAtlas::FontAtlas(Font &theFont) -: _font(&theFont) -, _fontFreeType(nullptr) -, _iconv(nullptr) -, _currentPageData(nullptr) -, _fontAscender(0) -, _rendererRecreatedListener(nullptr) -, _antialiasEnabled(true) -, _currLineHeight(0) -{ - _font->retain(); - - _fontFreeType = dynamic_cast(_font); - if (_fontFreeType) - { - _lineHeight = _font->getFontMaxHeight(); - _fontAscender = _fontFreeType->getFontAscender(); - auto texture = new (std::nothrow) Texture2D; - _currentPage = 0; - _currentPageOrigX = 0; - _currentPageOrigY = 0; - _letterEdgeExtend = 2; - _letterPadding = 0; - - if (_fontFreeType->isDistanceFieldEnabled()) - { - _letterPadding += 2 * FontFreeType::DistanceMapSpread; - } - _currentPageDataSize = CacheTextureWidth * CacheTextureHeight; - auto outlineSize = _fontFreeType->getOutlineSize(); - if(outlineSize > 0) - { - _lineHeight += 2 * outlineSize; - _currentPageDataSize *= 2; - } - - _currentPageData = new (std::nothrow) unsigned char[_currentPageDataSize]; - memset(_currentPageData, 0, _currentPageDataSize); - - auto pixelFormat = outlineSize > 0 ? Texture2D::PixelFormat::AI88 : Texture2D::PixelFormat::A8; - texture->initWithData(_currentPageData, _currentPageDataSize, - pixelFormat, CacheTextureWidth, CacheTextureHeight, Size(CacheTextureWidth,CacheTextureHeight) ); - - addTexture(texture,0); - texture->release(); - -#if CC_ENABLE_CACHE_TEXTURE_DATA - auto eventDispatcher = Director::getInstance()->getEventDispatcher(); - - _rendererRecreatedListener = EventListenerCustom::create(EVENT_RENDERER_RECREATED, CC_CALLBACK_1(FontAtlas::listenRendererRecreated, this)); - eventDispatcher->addEventListenerWithFixedPriority(_rendererRecreatedListener, 1); -#endif - } -} - -FontAtlas::~FontAtlas() -{ -#if CC_ENABLE_CACHE_TEXTURE_DATA - if (_fontFreeType && _rendererRecreatedListener) - { - auto eventDispatcher = Director::getInstance()->getEventDispatcher(); - eventDispatcher->removeEventListener(_rendererRecreatedListener); - _rendererRecreatedListener = nullptr; - } -#endif - - _font->release(); - releaseTextures(); - - delete []_currentPageData; - -#if CC_TARGET_PLATFORM != CC_PLATFORM_WIN32 && CC_TARGET_PLATFORM != CC_PLATFORM_WINRT && CC_TARGET_PLATFORM != CC_PLATFORM_ANDROID - if (_iconv) - { - iconv_close(_iconv); - _iconv = nullptr; - } -#endif -} - -void FontAtlas::reset() -{ - releaseTextures(); - - _currLineHeight = 0; - _currentPage = 0; - _currentPageOrigX = 0; - _currentPageOrigY = 0; - _letterDefinitions.clear(); -} - -void FontAtlas::releaseTextures() -{ - for( auto &item: _atlasTextures) - { - item.second->release(); - } - _atlasTextures.clear(); -} - -void FontAtlas::purgeTexturesAtlas() -{ - if (_fontFreeType) - { - reset(); - auto eventDispatcher = Director::getInstance()->getEventDispatcher(); - eventDispatcher->dispatchCustomEvent(CMD_PURGE_FONTATLAS,this); - eventDispatcher->dispatchCustomEvent(CMD_RESET_FONTATLAS,this); - } -} - -void FontAtlas::listenRendererRecreated(EventCustom *event) -{ - purgeTexturesAtlas(); -} - -void FontAtlas::addLetterDefinition(char16_t utf16Char, const FontLetterDefinition &letterDefinition) -{ - _letterDefinitions[utf16Char] = letterDefinition; -} - -void FontAtlas::scaleFontLetterDefinition(float scaleFactor) -{ - for (auto&& fontDefinition : _letterDefinitions) { - auto& letterDefinition = fontDefinition.second; - letterDefinition.width *= scaleFactor; - letterDefinition.height *= scaleFactor; - letterDefinition.offsetX *= scaleFactor; - letterDefinition.offsetY *= scaleFactor; - letterDefinition.xAdvance *= scaleFactor; - } -} - -bool FontAtlas::getLetterDefinitionForChar(char16_t utf16Char, FontLetterDefinition &letterDefinition) -{ - auto outIterator = _letterDefinitions.find(utf16Char); - - if (outIterator != _letterDefinitions.end()) - { - letterDefinition = (*outIterator).second; - return letterDefinition.validDefinition; - } - else - { - return false; - } -} - -void FontAtlas::conversionU16TOGB2312(const std::u16string& u16Text, std::unordered_map& charCodeMap) -{ - size_t strLen = u16Text.length(); - auto gb2312StrSize = strLen * 2; - auto gb2312Text = new (std::nothrow) char[gb2312StrSize]; - memset(gb2312Text, 0, gb2312StrSize); - - switch (_fontFreeType->getEncoding()) - { - case FT_ENCODING_GB2312: - { -#if CC_TARGET_PLATFORM == CC_PLATFORM_WIN32 || CC_TARGET_PLATFORM == CC_PLATFORM_WINRT - WideCharToMultiByte(936, NULL, (LPCWCH)u16Text.c_str(), strLen, (LPSTR)gb2312Text, gb2312StrSize, NULL, NULL); -#elif CC_TARGET_PLATFORM == CC_PLATFORM_ANDROID - conversionEncodingJNI((char*)u16Text.c_str(), gb2312StrSize, "UTF-16LE", gb2312Text, "GB2312"); -#else - if (_iconv == nullptr) - { - _iconv = iconv_open("GBK//TRANSLIT", "UTF-16LE"); - } - - if (_iconv == (iconv_t)-1) - { - CCLOG("conversion from utf16 to gb2312 not available"); - } - else - { - char* pin = (char*)u16Text.c_str(); - char* pout = gb2312Text; - size_t inLen = strLen * 2; - size_t outLen = gb2312StrSize; - - iconv(_iconv, (char**)&pin, &inLen, &pout, &outLen); - } -#endif - } - break; - default: - CCLOG("Unsupported encoding:%d", _fontFreeType->getEncoding()); - break; - } - - unsigned short gb2312Code = 0; - unsigned char* dst = (unsigned char*)&gb2312Code; - unsigned short u16Code; - for (size_t index = 0, gbIndex = 0; index < strLen; ++index) - { - u16Code = u16Text[index]; - if (u16Code < 256) - { - charCodeMap[u16Code] = u16Code; - gbIndex += 1; - } - else - { - dst[0] = gb2312Text[gbIndex + 1]; - dst[1] = gb2312Text[gbIndex]; - charCodeMap[u16Code] = gb2312Code; - - gbIndex += 2; - } - } - - delete[] gb2312Text; -} - -void FontAtlas::findNewCharacters(const std::u16string& u16Text, std::unordered_map& charCodeMap) -{ - std::u16string newChars; - FT_Encoding charEncoding = _fontFreeType->getEncoding(); - - //find new characters - if (_letterDefinitions.empty()) - { - // fixed #16169: new android project crash in android 5.0.2 device (Nexus 7) when use 3.12. - // While using clang compiler with gnustl_static on android, the copy assignment operator of `std::u16string` - // will affect the memory validity, it means after `newChars` is destroyed, the memory of `u16Text` holds - // will be a dead region. `u16text` represents the variable in `Label::_utf16Text`, when somewhere - // allocates memory by `malloc, realloc, new, new[]`, the generated memory address may be the same - // as `Label::_utf16Text` holds. If doing a `memset` or other memory operations, the orignal `Label::_utf16Text` - // will be in an unknown state. Meanwhile, a bunch lots of logic which depends on `Label::_utf16Text` - // will be broken. - - // newChars = u16Text; - - // Using `append` method is a workaround for this issue. So please be carefuly while using the assignment operator - // of `std::u16string`. - newChars.append(u16Text); - } - else - { - auto length = u16Text.length(); - newChars.reserve(length); - for (size_t i = 0; i < length; ++i) - { - auto outIterator = _letterDefinitions.find(u16Text[i]); - if (outIterator == _letterDefinitions.end()) - { - newChars.push_back(u16Text[i]); - } - } - } - - if (!newChars.empty()) - { - switch (charEncoding) - { - case FT_ENCODING_UNICODE: - { - for (auto u16Code : newChars) - { - charCodeMap[u16Code] = u16Code; - } - break; - } - case FT_ENCODING_GB2312: - { - conversionU16TOGB2312(newChars, charCodeMap); - break; - } - default: - CCLOG("FontAtlas::findNewCharacters: Unsupported encoding:%d", charEncoding); - break; - } - } -} - -bool FontAtlas::prepareLetterDefinitions(const std::u16string& utf16Text) -{ - if (_fontFreeType == nullptr) - { - return false; - } - - std::unordered_map codeMapOfNewChar; - findNewCharacters(utf16Text, codeMapOfNewChar); - if (codeMapOfNewChar.empty()) - { - return false; - } - - int adjustForDistanceMap = _letterPadding / 2; - int adjustForExtend = _letterEdgeExtend / 2; - long bitmapWidth; - long bitmapHeight; - int glyphHeight; - Rect tempRect; - FontLetterDefinition tempDef; - - auto scaleFactor = CC_CONTENT_SCALE_FACTOR(); - auto pixelFormat = _fontFreeType->getOutlineSize() > 0 ? Texture2D::PixelFormat::AI88 : Texture2D::PixelFormat::A8; - - float startY = _currentPageOrigY; - - for (auto&& it : codeMapOfNewChar) - { - auto bitmap = _fontFreeType->getGlyphBitmap(it.second, bitmapWidth, bitmapHeight, tempRect, tempDef.xAdvance); - if (bitmap && bitmapWidth > 0 && bitmapHeight > 0) - { - tempDef.validDefinition = true; - tempDef.width = tempRect.size.width + _letterPadding + _letterEdgeExtend; - tempDef.height = tempRect.size.height + _letterPadding + _letterEdgeExtend; - tempDef.offsetX = tempRect.origin.x - adjustForDistanceMap - adjustForExtend; - tempDef.offsetY = _fontAscender + tempRect.origin.y - adjustForDistanceMap - adjustForExtend; - - if (_currentPageOrigX + tempDef.width > CacheTextureWidth) - { - _currentPageOrigY += _currLineHeight; - _currLineHeight = 0; - _currentPageOrigX = 0; - if (_currentPageOrigY + _lineHeight + _letterPadding + _letterEdgeExtend >= CacheTextureHeight) - { - unsigned char *data = nullptr; - if (pixelFormat == Texture2D::PixelFormat::AI88) - { - data = _currentPageData + CacheTextureWidth * (int)startY * 2; - } - else - { - data = _currentPageData + CacheTextureWidth * (int)startY; - } - _atlasTextures[_currentPage]->updateWithData(data, 0, startY, - CacheTextureWidth, CacheTextureHeight - startY); - - startY = 0.0f; - - _currentPageOrigY = 0; - memset(_currentPageData, 0, _currentPageDataSize); - _currentPage++; - auto tex = new (std::nothrow) Texture2D; - if (_antialiasEnabled) - { - tex->setAntiAliasTexParameters(); - } - else - { - tex->setAliasTexParameters(); - } - tex->initWithData(_currentPageData, _currentPageDataSize, - pixelFormat, CacheTextureWidth, CacheTextureHeight, Size(CacheTextureWidth, CacheTextureHeight)); - addTexture(tex, _currentPage); - tex->release(); - } - } - glyphHeight = static_cast(bitmapHeight) + _letterPadding + _letterEdgeExtend; - if (glyphHeight > _currLineHeight) - { - _currLineHeight = glyphHeight; - } - _fontFreeType->renderCharAt(_currentPageData, _currentPageOrigX + adjustForExtend, _currentPageOrigY + adjustForExtend, bitmap, bitmapWidth, bitmapHeight); - - tempDef.U = _currentPageOrigX; - tempDef.V = _currentPageOrigY; - tempDef.textureID = _currentPage; - _currentPageOrigX += tempDef.width + 1; - // take from pixels to points - tempDef.width = tempDef.width / scaleFactor; - tempDef.height = tempDef.height / scaleFactor; - tempDef.U = tempDef.U / scaleFactor; - tempDef.V = tempDef.V / scaleFactor; - } - else{ - if (tempDef.xAdvance) - tempDef.validDefinition = true; - else - tempDef.validDefinition = false; - - tempDef.width = 0; - tempDef.height = 0; - tempDef.U = 0; - tempDef.V = 0; - tempDef.offsetX = 0; - tempDef.offsetY = 0; - tempDef.textureID = 0; - _currentPageOrigX += 1; - } - - _letterDefinitions[it.first] = tempDef; - } - - unsigned char *data = nullptr; - if (pixelFormat == Texture2D::PixelFormat::AI88) - { - data = _currentPageData + CacheTextureWidth * (int)startY * 2; - } - else - { - data = _currentPageData + CacheTextureWidth * (int)startY; - } - _atlasTextures[_currentPage]->updateWithData(data, 0, startY, CacheTextureWidth, _currentPageOrigY - startY + _currLineHeight); - - return true; -} - -void FontAtlas::addTexture(Texture2D *texture, int slot) -{ - texture->retain(); - _atlasTextures[slot] = texture; -} - -Texture2D* FontAtlas::getTexture(int slot) -{ - return _atlasTextures[slot]; -} - -void FontAtlas::setLineHeight(float newHeight) -{ - _lineHeight = newHeight; -} - -void FontAtlas::setAliasTexParameters() -{ - if (_antialiasEnabled) - { - _antialiasEnabled = false; - for (const auto & tex : _atlasTextures) - { - tex.second->setAliasTexParameters(); - } - } -} - -void FontAtlas::setAntiAliasTexParameters() -{ - if (! _antialiasEnabled) - { - _antialiasEnabled = true; - for (const auto & tex : _atlasTextures) - { - tex.second->setAntiAliasTexParameters(); - } - } -} - -NS_CC_END - diff --git a/native/cocos/2d/CCFontAtlas.h b/native/cocos/2d/CCFontAtlas.h deleted file mode 100644 index 5a936ec014..0000000000 --- a/native/cocos/2d/CCFontAtlas.h +++ /dev/null @@ -1,156 +0,0 @@ -/**************************************************************************** - Copyright (c) 2013 Zynga Inc. - Copyright (c) 2013-2016 Chukong Technologies Inc. - Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - - http://www.cocos2d-x.org - - Permission is hereby granted, free of charge, to any person obtaining a copy - of this software and associated documentation files (the "Software"), to deal - in the Software without restriction, including without limitation the rights - to use, copy, modify, merge, publish, distribute, sublicense, and/or sell - copies of the Software, and to permit persons to whom the Software is - furnished to do so, subject to the following conditions: - - The above copyright notice and this permission notice shall be included in - all copies or substantial portions of the Software. - - THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN - THE SOFTWARE. - ****************************************************************************/ - -#ifndef _CCFontAtlas_h_ -#define _CCFontAtlas_h_ - -/// @cond DO_NOT_SHOW - -#include -#include - -#include "platform/CCPlatformMacros.h" -#include "base/CCRef.h" -#include "platform/CCStdC.h" // ssize_t on windows - -NS_CC_BEGIN - -class Font; -class Texture2D; -class EventCustom; -class EventListenerCustom; -class FontFreeType; - -struct FontLetterDefinition -{ - float U; - float V; - float width; - float height; - float offsetX; - float offsetY; - int textureID; - bool validDefinition; - int xAdvance; -}; - -class CC_DLL FontAtlas : public Ref -{ -public: - static const int CacheTextureWidth; - static const int CacheTextureHeight; - static const char* CMD_PURGE_FONTATLAS; - static const char* CMD_RESET_FONTATLAS; - /** - * @js ctor - */ - FontAtlas(Font &theFont); - /** - * @js NA - * @lua NA - */ - virtual ~FontAtlas(); - - void addLetterDefinition(char16_t utf16Char, const FontLetterDefinition &letterDefinition); - bool getLetterDefinitionForChar(char16_t utf16Char, FontLetterDefinition &letterDefinition); - - bool prepareLetterDefinitions(const std::u16string& utf16String); - - inline const std::unordered_map& getTextures() const{ return _atlasTextures;} - void addTexture(Texture2D *texture, int slot); - float getLineHeight() const { return _lineHeight; } - void setLineHeight(float newHeight); - - Texture2D* getTexture(int slot); - const Font* getFont() const { return _font; } - - /** listen the event that renderer was recreated on Android/WP8 - It only has effect on Android and WP8. - */ - void listenRendererRecreated(EventCustom *event); - - /** Removes textures atlas. - It will purge the textures atlas and if multiple texture exist in the FontAtlas. - */ - void purgeTexturesAtlas(); - - /** sets font texture parameters: - - GL_TEXTURE_MIN_FILTER = GL_LINEAR - - GL_TEXTURE_MAG_FILTER = GL_LINEAR - */ - void setAntiAliasTexParameters(); - - /** sets font texture parameters: - - GL_TEXTURE_MIN_FILTER = GL_NEAREST - - GL_TEXTURE_MAG_FILTER = GL_NEAREST - */ - void setAliasTexParameters(); - -protected: - void reset(); - - void releaseTextures(); - - void findNewCharacters(const std::u16string& u16Text, std::unordered_map& charCodeMap); - - void conversionU16TOGB2312(const std::u16string& u16Text, std::unordered_map& charCodeMap); - - /** - * Scale each font letter by scaleFactor. - * - * @param scaleFactor A float scale factor for scaling font letter info. - */ - void scaleFontLetterDefinition(float scaleFactor); - - std::unordered_map _atlasTextures; - std::unordered_map _letterDefinitions; - float _lineHeight; - Font* _font; - FontFreeType* _fontFreeType; - void* _iconv; - - // Dynamic GlyphCollection related stuff - int _currentPage; - unsigned char *_currentPageData; - int _currentPageDataSize; - float _currentPageOrigX; - float _currentPageOrigY; - int _letterPadding; - int _letterEdgeExtend; - - int _fontAscender; - EventListenerCustom* _rendererRecreatedListener; - bool _antialiasEnabled; - int _currLineHeight; - - friend class Label; -}; - -NS_CC_END - -/// @endcond -#endif /* defined(__cocos2d_libs__CCFontAtlas__) */ - diff --git a/native/cocos/2d/CCFontAtlasCache.cpp b/native/cocos/2d/CCFontAtlasCache.cpp deleted file mode 100644 index d8e4bca2ea..0000000000 --- a/native/cocos/2d/CCFontAtlasCache.cpp +++ /dev/null @@ -1,281 +0,0 @@ -/**************************************************************************** - Copyright (c) 2013 Zynga Inc. - Copyright (c) 2013-2016 Chukong Technologies Inc. - Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - - http://www.cocos2d-x.org - - Permission is hereby granted, free of charge, to any person obtaining a copy - of this software and associated documentation files (the "Software"), to deal - in the Software without restriction, including without limitation the rights - to use, copy, modify, merge, publish, distribute, sublicense, and/or sell - copies of the Software, and to permit persons to whom the Software is - furnished to do so, subject to the following conditions: - - The above copyright notice and this permission notice shall be included in - all copies or substantial portions of the Software. - - THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN - THE SOFTWARE. - ****************************************************************************/ -#include "2d/CCFontAtlasCache.h" - -#include "base/CCDirector.h" -#include "2d/CCFontFNT.h" -#include "2d/CCFontFreeType.h" -#include "2d/CCFontAtlas.h" -#include "2d/CCFontCharMap.h" -#include "2d/CCLabel.h" -#include "2d/CCSpriteFrame.h" - -NS_CC_BEGIN - -std::unordered_map FontAtlasCache::_atlasMap; -#define ATLAS_MAP_KEY_BUFFER 255 - -void FontAtlasCache::purgeCachedData() -{ - auto atlasMapCopy = _atlasMap; - for (auto&& atlas : atlasMapCopy) - { - atlas.second->purgeTexturesAtlas(); - } - _atlasMap.clear(); -} - -FontAtlas* FontAtlasCache::getFontAtlasTTF(const _ttfConfig* config) -{ - bool useDistanceField = config->distanceFieldEnabled; - if(config->outlineSize > 0) - { - useDistanceField = false; - } - - char tmp[ATLAS_MAP_KEY_BUFFER]; - if (useDistanceField) { - snprintf(tmp, ATLAS_MAP_KEY_BUFFER, "df %.2f %d %s", config->fontSize, config->outlineSize, - config->fontFilePath.c_str()); - } else { - snprintf(tmp, ATLAS_MAP_KEY_BUFFER, "%.2f %d %s", config->fontSize, config->outlineSize, - config->fontFilePath.c_str()); - } - std::string atlasName = tmp; - - auto it = _atlasMap.find(atlasName); - - if ( it == _atlasMap.end() ) - { - auto font = FontFreeType::create(config->fontFilePath, config->fontSize, config->glyphs, - config->customGlyphs, useDistanceField, config->outlineSize); - if (font) - { - auto tempAtlas = font->createFontAtlas(); - if (tempAtlas) - { - _atlasMap[atlasName] = tempAtlas; - return _atlasMap[atlasName]; - } - } - } - else - { - _atlasMap[atlasName]->retain(); - return _atlasMap[atlasName]; - } - - return nullptr; -} - -FontAtlas* FontAtlasCache::getFontAtlasFNT(const std::string& fntDataString, - SpriteFrame* spriteFrame, - const Vec2& imageOffset /* = Vec2::ZERO */) -{ - char tmp[ATLAS_MAP_KEY_BUFFER]; - snprintf(tmp, ATLAS_MAP_KEY_BUFFER, "%.2f %.2f %p", imageOffset.x, imageOffset.y, spriteFrame); - std::string atlasName = tmp; - - auto it = _atlasMap.find(atlasName); - if ( it == _atlasMap.end() ) - { - auto font = FontFNT::create(fntDataString, spriteFrame, imageOffset); - - if(font) - { - auto tempAtlas = font->createFontAtlas(); - if (tempAtlas) - { - _atlasMap[atlasName] = tempAtlas; - return _atlasMap[atlasName]; - } - } - } - else - { - _atlasMap[atlasName]->retain(); - return _atlasMap[atlasName]; - } - - return nullptr; -} - -FontAtlas* FontAtlasCache::getFontAtlasCharMap(const std::string& plistFile) -{ - std::string atlasName = plistFile; - - auto it = _atlasMap.find(atlasName); - if ( it == _atlasMap.end() ) - { - auto font = FontCharMap::create(plistFile); - - if(font) - { - auto tempAtlas = font->createFontAtlas(); - if (tempAtlas) - { - _atlasMap[atlasName] = tempAtlas; - return _atlasMap[atlasName]; - } - } - } - else - { - _atlasMap[atlasName]->retain(); - return _atlasMap[atlasName]; - } - - return nullptr; -} - -FontAtlas* FontAtlasCache::getFontAtlasCharMap(Texture2D* texture, int itemWidth, int itemHeight, int startCharMap) -{ - char tmp[30]; - sprintf(tmp,"name:%u_%d_%d_%d",texture->getName(),itemWidth,itemHeight,startCharMap); - std::string atlasName = tmp; - - auto it = _atlasMap.find(atlasName); - if ( it == _atlasMap.end() ) - { - auto font = FontCharMap::create(texture,itemWidth,itemHeight,startCharMap); - - if(font) - { - auto tempAtlas = font->createFontAtlas(); - if (tempAtlas) - { - _atlasMap[atlasName] = tempAtlas; - return _atlasMap[atlasName]; - } - } - } - else - { - _atlasMap[atlasName]->retain(); - return _atlasMap[atlasName]; - } - - return nullptr; -} - -FontAtlas* FontAtlasCache::getFontAtlasCharMap(const std::string& charMapFile, int itemWidth, int itemHeight, int startCharMap) -{ - char tmp[ATLAS_MAP_KEY_BUFFER]; - snprintf(tmp, ATLAS_MAP_KEY_BUFFER, "%d %d %d %s", itemWidth, itemHeight, startCharMap, charMapFile.c_str()); - std::string atlasName = tmp; - - auto it = _atlasMap.find(atlasName); - if ( it == _atlasMap.end() ) - { - auto font = FontCharMap::create(charMapFile,itemWidth,itemHeight,startCharMap); - - if(font) - { - auto tempAtlas = font->createFontAtlas(); - if (tempAtlas) - { - _atlasMap[atlasName] = tempAtlas; - return _atlasMap[atlasName]; - } - } - } - else - { - _atlasMap[atlasName]->retain(); - return _atlasMap[atlasName]; - } - - return nullptr; -} - -bool FontAtlasCache::releaseFontAtlas(FontAtlas *atlas) -{ - if (nullptr != atlas) - { - for( auto &item: _atlasMap ) - { - if ( item.second == atlas ) - { - if (atlas->getReferenceCount() == 1) - { - _atlasMap.erase(item.first); - } - - atlas->release(); - - return true; - } - } - } - - return false; -} - -void FontAtlasCache::reloadFontAtlasFNT(const std::string& fntDataString, - SpriteFrame* spriteFrame, - const Vec2& imageOffset/* = Vec2::ZERO*/) -{ - char tmp[ATLAS_MAP_KEY_BUFFER]; - snprintf(tmp, ATLAS_MAP_KEY_BUFFER, "%.2f %.2f %p", imageOffset.x, imageOffset.y, spriteFrame); - std::string atlasName = tmp; - - auto it = _atlasMap.find(atlasName); - if (it != _atlasMap.end()) - { - CC_SAFE_RELEASE_NULL(it->second); - _atlasMap.erase(it); - } - - auto font = FontFNT::create(fntDataString, - spriteFrame, - imageOffset); - if (font) - { - auto tempAtlas = font->createFontAtlas(); - if (tempAtlas) - { - _atlasMap[atlasName] = tempAtlas; - } - } - -} - -void FontAtlasCache::unloadFontAtlasTTF(const std::string& fontFileName) -{ - auto item = _atlasMap.begin(); - while (item != _atlasMap.end()) - { - if (item->first.find(fontFileName) != std::string::npos) - { - CC_SAFE_RELEASE_NULL(item->second); - item = _atlasMap.erase(item); - } - else - item++; - } -} - -NS_CC_END diff --git a/native/cocos/2d/CCFontAtlasCache.h b/native/cocos/2d/CCFontAtlasCache.h deleted file mode 100644 index 30ee791437..0000000000 --- a/native/cocos/2d/CCFontAtlasCache.h +++ /dev/null @@ -1,82 +0,0 @@ -/**************************************************************************** - Copyright (c) 2013 Zynga Inc. - Copyright (c) 2013-2016 Chukong Technologies Inc. - Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - - http://www.cocos2d-x.org - - Permission is hereby granted, free of charge, to any person obtaining a copy - of this software and associated documentation files (the "Software"), to deal - in the Software without restriction, including without limitation the rights - to use, copy, modify, merge, publish, distribute, sublicense, and/or sell - copies of the Software, and to permit persons to whom the Software is - furnished to do so, subject to the following conditions: - - The above copyright notice and this permission notice shall be included in - all copies or substantial portions of the Software. - - THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN - THE SOFTWARE. - ****************************************************************************/ - -#ifndef _CCFontAtlasCache_h_ -#define _CCFontAtlasCache_h_ - -/// @cond DO_NOT_SHOW - -#include -#include "base/ccTypes.h" - -NS_CC_BEGIN - -class FontAtlas; -class Texture2D; -struct _ttfConfig; -class SpriteFrame; - -class CC_DLL FontAtlasCache -{ -public: - static FontAtlas* getFontAtlasTTF(const _ttfConfig* config); - static FontAtlas* getFontAtlasFNT(const std::string& fntDataString, - SpriteFrame* spriteFrame, - const Vec2& imageOffset = Vec2::ZERO); - - static FontAtlas* getFontAtlasCharMap(const std::string& charMapFile, int itemWidth, int itemHeight, int startCharMap); - static FontAtlas* getFontAtlasCharMap(Texture2D* texture, int itemWidth, int itemHeight, int startCharMap); - static FontAtlas* getFontAtlasCharMap(const std::string& plistFile); - - static bool releaseFontAtlas(FontAtlas *atlas); - - /** Removes cached data. - It will purge the textures atlas and if multiple texture exist in one FontAtlas. - */ - static void purgeCachedData(); - - /** Release current FNT texture and reload it. - CAUTION : All component use this font texture should be reset font name, though the file name is same! - otherwise, it will cause program crash! - */ - static void reloadFontAtlasFNT(const std::string& fntDataString, - SpriteFrame* spriteFrame, - const Vec2& imageOffset = Vec2::ZERO); - - /** Unload all texture atlas texture create by special file name. - CAUTION : All component use this font texture should be reset font name, though the file name is same! - otherwise, it will cause program crash! - */ - static void unloadFontAtlasTTF(const std::string& fontFileName); - -private: - static std::unordered_map _atlasMap; -}; - -NS_CC_END - -/// @endcond -#endif diff --git a/native/cocos/2d/CCFontCharMap.cpp b/native/cocos/2d/CCFontCharMap.cpp deleted file mode 100644 index bdd542dbba..0000000000 --- a/native/cocos/2d/CCFontCharMap.cpp +++ /dev/null @@ -1,155 +0,0 @@ -/**************************************************************************** - Copyright (c) 2013 Zynga Inc. - Copyright (c) 2013-2016 Chukong Technologies Inc. - Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - - http://www.cocos2d-x.org - - Permission is hereby granted, free of charge, to any person obtaining a copy - of this software and associated documentation files (the "Software"), to deal - in the Software without restriction, including without limitation the rights - to use, copy, modify, merge, publish, distribute, sublicense, and/or sell - copies of the Software, and to permit persons to whom the Software is - furnished to do so, subject to the following conditions: - - The above copyright notice and this permission notice shall be included in - all copies or substantial portions of the Software. - - THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN - THE SOFTWARE. - ****************************************************************************/ - -#include "2d/CCFontCharMap.h" -#include "2d/CCFontAtlas.h" -#include "platform/CCFileUtils.h" -#include "base/CCDirector.h" -#include "renderer/CCTextureCache.h" - -NS_CC_BEGIN - -FontCharMap * FontCharMap::create(const std::string& plistFile) -{ - auto fileUtils = FileUtils::getInstance(); - std::string pathStr = fileUtils->fullPathForFilename(plistFile); - if (pathStr.empty()) { - return nullptr; - } - - std::string relPathStr = pathStr.substr(0, pathStr.find_last_of("/"))+"/"; - - ValueMap dict = FileUtils::getInstance()->getValueMapFromFile(pathStr); - - CCASSERT(dict["version"].asInt() == 1, "Unsupported version. Upgrade cocos2d version"); - - std::string textureFilename = relPathStr + dict["textureFilename"].asString(); - - unsigned int width = dict["itemWidth"].asInt(); - unsigned int height = dict["itemHeight"].asInt(); - unsigned int startChar = dict["firstChar"].asInt(); - - Texture2D *tempTexture = Director::getInstance()->getTextureCache()->addImage(textureFilename); - if (!tempTexture) - { - return nullptr; - } - - FontCharMap *tempFont = new FontCharMap(tempTexture,width,height,startChar); - - if (!tempFont) - { - return nullptr; - } - tempFont->autorelease(); - - return tempFont; -} - -FontCharMap* FontCharMap::create(const std::string& charMapFile, int itemWidth, int itemHeight, int startCharMap) -{ - Texture2D *tempTexture = Director::getInstance()->getTextureCache()->addImage(charMapFile); - - if (!tempTexture) - { - return nullptr; - } - - FontCharMap *tempFont = new FontCharMap(tempTexture,itemWidth,itemHeight,startCharMap); - - if (!tempFont) - { - return nullptr; - } - tempFont->autorelease(); - return tempFont; -} - -FontCharMap* FontCharMap::create(Texture2D* texture, int itemWidth, int itemHeight, int startCharMap) -{ - FontCharMap *tempFont = new FontCharMap(texture, itemWidth, itemHeight, startCharMap); - - if (!tempFont) - { - return nullptr; - } - tempFont->autorelease(); - return tempFont; -} - -FontCharMap::~FontCharMap() -{ - -} - -int* FontCharMap::getHorizontalKerningForTextUTF16(const std::u16string& text, int &outNumLetters) const -{ - return nullptr; -} - -FontAtlas * FontCharMap::createFontAtlas() -{ - FontAtlas *tempAtlas = new (std::nothrow) FontAtlas(*this); - if (!tempAtlas) - return nullptr; - - Size s = _texture->getContentSizeInPixels(); - int itemsPerColumn = (int)(s.height / _itemHeight); - int itemsPerRow = (int)(s.width / _itemWidth); - - tempAtlas->setLineHeight(_itemHeight); - - auto contentScaleFactor = CC_CONTENT_SCALE_FACTOR(); - - FontLetterDefinition tempDefinition; - tempDefinition.textureID = 0; - tempDefinition.offsetX = 0.0f; - tempDefinition.offsetY = 0.0f; - tempDefinition.validDefinition = true; - tempDefinition.width = _itemWidth / contentScaleFactor; - tempDefinition.height = _itemHeight / contentScaleFactor; - tempDefinition.xAdvance = _itemWidth; - - int charId = _mapStartChar; - for (int row = 0; row < itemsPerColumn; ++row) - { - for (int col = 0; col < itemsPerRow; ++col) - { - tempDefinition.U = _itemWidth * col / contentScaleFactor; - tempDefinition.V = _itemHeight * row / contentScaleFactor; - - tempAtlas->addLetterDefinition(charId, tempDefinition); - charId++; - } - } - - tempAtlas->addTexture(_texture,0); - - return tempAtlas; -} - -NS_CC_END - diff --git a/native/cocos/2d/CCFontFNT.cpp b/native/cocos/2d/CCFontFNT.cpp deleted file mode 100644 index a00035c31a..0000000000 --- a/native/cocos/2d/CCFontFNT.cpp +++ /dev/null @@ -1,922 +0,0 @@ -/**************************************************************************** - Copyright (c) 2013 Zynga Inc. - Copyright (c) 2013-2016 Chukong Technologies Inc. - Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - - http://www.cocos2d-x.org - - Permission is hereby granted, free of charge, to any person obtaining a copy - of this software and associated documentation files (the "Software"), to deal - in the Software without restriction, including without limitation the rights - to use, copy, modify, merge, publish, distribute, sublicense, and/or sell - copies of the Software, and to permit persons to whom the Software is - furnished to do so, subject to the following conditions: - - The above copyright notice and this permission notice shall be included in - all copies or substantial portions of the Software. - - THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN - THE SOFTWARE. - ****************************************************************************/ - -#include "2d/CCFontFNT.h" -#include -#include -#include "base/uthash.h" -#include "2d/CCFontAtlas.h" -#include "platform/CCFileUtils.h" -#include "base/CCConfiguration.h" -#include "base/CCDirector.h" -#include "base/CCMap.h" -#include "base/ccUTF8.h" -#include "renderer/CCTextureCache.h" -#include "2d/CCSpriteFrame.h" -#include "json/document-wrapper.h" - -using namespace std; -NS_CC_BEGIN - -/** - * @addtogroup GUI - * @{ - * @addtogroup label - * @{ - */ - -enum { - kLabelAutomaticWidth = -1, -}; - -struct _FontDefHashElement; - -/** -@struct BMFontDef -BMFont definition -*/ -typedef struct _BMFontDef { - //! ID of the character - unsigned int charID; - //! origin and size of the font - Rect rect; - //! The X amount the image should be offset when drawing the image (in pixels) - short xOffset; - //! The Y amount the image should be offset when drawing the image (in pixels) - short yOffset; - //! The amount to move the current position after drawing the character (in pixels) - short xAdvance; -} BMFontDef; - -/** @struct BMFontPadding -BMFont padding -@since v0.8.2 -*/ -typedef struct _BMFontPadding { - /// padding left - int left; - /// padding top - int top; - /// padding right - int right; - /// padding bottom - int bottom; -} BMFontPadding; - -typedef struct _FontDefHashElement -{ - unsigned int key; // key. Font Unicode value - BMFontDef fontDef; // font definition - UT_hash_handle hh; -} tFontDefHashElement; - -// Equal function for targetSet. -typedef struct _KerningHashElement -{ - int key; // key for the hash. 16-bit for 1st element, 16-bit for 2nd element - int amount; - UT_hash_handle hh; -} tKerningHashElement; - -class SpriteFrame; - -/** @brief BMFontConfiguration has parsed configuration of the .fnt file -@since v0.8 -*/ -class CC_DLL BMFontConfiguration : public Ref -{ - // FIXME: Creating a public interface so that the bitmapFontArray[] is accessible -public://@public - // BMFont definitions - tFontDefHashElement *_fontDefDictionary; - - //! FNTConfig: Common Height Should be signed (issue #1343) - int _commonHeight; - //! Padding - BMFontPadding _padding; - //! atlas name - std::string _atlasName; - SpriteFrame* _spriteFrame; - //! values for kerning - tKerningHashElement *_kerningDictionary; - - // Character Set defines the letters that actually exist in the font - std::set *_characterSet; - //! Font Size - int _fontSize; -public: - /** - * @js ctor - */ - BMFontConfiguration(); - /** - * @js NA - * @lua NA - */ - virtual ~BMFontConfiguration(); - /** - * @js NA - * @lua NA - */ - std::string description() const; - - /** allocates a BMFontConfiguration with a FNT file */ - static BMFontConfiguration * create(const std::string& fntDataString, SpriteFrame* spriteFrame); - static BMFontConfiguration * createWithJsonString(const std::string& jsonString, SpriteFrame* spriteFrame); - - /** initializes a BitmapFontConfiguration with a FNT file */ - bool initWithFNTfile(const std::string& fntDataString, SpriteFrame* spriteFrame); - /** initializes a BitmapFontConfiguration with a JSON string */ - bool initWithJsonString(const std::string& jsonString, SpriteFrame* spriteFrame); - - - inline const std::string& getAtlasName(){ return _atlasName; } - inline void setAtlasName(const std::string& atlasName) { _atlasName = atlasName; } - - std::set* getCharacterSet() const; -private: - std::set* parseConfigFile(const std::string& fntDataString); - std::set* parseJsonConfigFile(const std::string& jsonDataString); - std::set* parseBinaryConfigFile(unsigned char* pData, unsigned long size, const std::string& controlFile); - void parseCharacterDefinition(const char* line, BMFontDef *characterDefinition); - void parseInfoArguments(const char* line); - void parseCommonArguments(const char* line); - void parseImageFileName(const char* line, const std::string& fntFile); - void parseKerningEntry(const char* line); - void purgeKerningDictionary(); - void purgeFontDefDictionary(); - rapidjson::Document _json; -}; - -BMFontConfiguration* FNTConfigLoadJson(const std::string& jsonString, SpriteFrame* spriteFrame) -{ - BMFontConfiguration* ret = nullptr; - - - ret = BMFontConfiguration::createWithJsonString(jsonString, spriteFrame); - - return ret; -} - -BMFontConfiguration* FNTConfigLoadFile(const std::string& fntDataString, SpriteFrame* spriteFrame) -{ - BMFontConfiguration* ret = nullptr; - - - ret = BMFontConfiguration::create(fntDataString, spriteFrame); - - return ret; -} - -// -//BitmapFontConfiguration -// - -BMFontConfiguration * BMFontConfiguration::create(const std::string& fntDataString, SpriteFrame* spriteFrame) -{ - BMFontConfiguration * ret = new (std::nothrow) BMFontConfiguration(); - if (ret->initWithFNTfile(fntDataString, spriteFrame)) - { - ret->autorelease(); - return ret; - } - CC_SAFE_DELETE(ret); - return nullptr; -} - -BMFontConfiguration * BMFontConfiguration::createWithJsonString(const std::string& jsonString, - SpriteFrame* spriteFrame) -{ - BMFontConfiguration * ret = new (std::nothrow) BMFontConfiguration(); - if (ret->initWithJsonString(jsonString, spriteFrame)) - { - ret->autorelease(); - return ret; - } - CC_SAFE_DELETE(ret); - return nullptr; -} - -bool BMFontConfiguration::initWithJsonString(const std::string& jsonString, SpriteFrame* spriteFrame) -{ - _kerningDictionary = nullptr; - _fontDefDictionary = nullptr; - _spriteFrame = spriteFrame; - - _characterSet = this->parseJsonConfigFile(jsonString); - - if (! _characterSet) - { - return false; - } - - return true; -} - -bool BMFontConfiguration::initWithFNTfile(const std::string& fntDataString, SpriteFrame* spriteFrame) -{ - _kerningDictionary = nullptr; - _fontDefDictionary = nullptr; - _spriteFrame = spriteFrame; - - _characterSet = this->parseConfigFile(fntDataString); - - if (! _characterSet) - { - return false; - } - - return true; -} - -std::set* BMFontConfiguration::getCharacterSet() const -{ - return _characterSet; -} - -BMFontConfiguration::BMFontConfiguration() -: _fontDefDictionary(nullptr) -, _commonHeight(0) -, _kerningDictionary(nullptr) -, _characterSet(nullptr) -, _fontSize(0) -{ - -} - -BMFontConfiguration::~BMFontConfiguration() -{ - CCLOGINFO( "deallocing BMFontConfiguration: %p", this ); - this->purgeFontDefDictionary(); - this->purgeKerningDictionary(); - _atlasName.clear(); - CC_SAFE_DELETE(_characterSet); -} - -std::string BMFontConfiguration::description(void) const -{ - return StringUtils::format( - "", - (size_t)this, - HASH_COUNT(_fontDefDictionary), - HASH_COUNT(_kerningDictionary), - _atlasName.c_str() - ); -} - -void BMFontConfiguration::purgeKerningDictionary() -{ - tKerningHashElement *current; - while(_kerningDictionary) - { - current = _kerningDictionary; - HASH_DEL(_kerningDictionary,current); - free(current); - } -} - -void BMFontConfiguration::purgeFontDefDictionary() -{ - tFontDefHashElement *current, *tmp; - - HASH_ITER(hh, _fontDefDictionary, current, tmp) { - HASH_DEL(_fontDefDictionary, current); - free(current); - } -} - -std::set* BMFontConfiguration::parseJsonConfigFile(const std::string& jsonDataString) -{ - _json.Parse<0>(jsonDataString.c_str()); - std::set *validCharsString = new (std::nothrow) std::set(); - _fontSize = _json["fontSize"].GetInt(); - _commonHeight = _json["commonHeight"].GetInt(); - _atlasName = _json["atlasName"].GetString(); - - auto fontDefDictionary = _json["fontDefDictionary"].GetObject(); - for (rapidjson::Value::ConstMemberIterator itr = fontDefDictionary.MemberBegin(); - itr != fontDefDictionary.MemberEnd(); ++itr) - { - tFontDefHashElement* element = (tFontDefHashElement*)malloc( sizeof(*element) ); - unsigned int charID = atoi(itr->name.GetString()); - element->fontDef.charID = charID; - - auto charObj = itr->value.GetObject(); - int i = 0; - for (rapidjson::Value::ConstMemberIterator charObjItr = charObj.MemberBegin(); - charObjItr != charObj.MemberEnd(); ++charObjItr) - { - if (i == 0) { - int j = 0; - auto rectObjc = charObjItr->value.GetObject(); - for (rapidjson::Value::ConstMemberIterator rectObjItr = rectObjc.MemberBegin(); - rectObjItr != rectObjc.MemberEnd(); ++rectObjItr) - { - if (j == 0) { - element->fontDef.rect.origin.x = rectObjItr->value.GetInt(); - }else if (j == 1) { - element->fontDef.rect.origin.y = rectObjItr->value.GetInt(); - }else if (j == 2) { - element->fontDef.rect.size.width = rectObjItr->value.GetInt(); - }else if (j == 3) { - element->fontDef.rect.size.height = rectObjItr->value.GetInt(); - } - j++; - } - } else if (i == 1) { - element->fontDef.xOffset = charObjItr->value.GetInt(); - }else if (i == 2) { - element->fontDef.yOffset = charObjItr->value.GetInt(); - }else if (i == 3) { - element->fontDef.xAdvance = charObjItr->value.GetInt(); - } - ++i; - } - - element->key = element->fontDef.charID; - HASH_ADD_INT(_fontDefDictionary, key, element); - - validCharsString->insert(element->fontDef.charID); - } - - auto kerning = _json["kerningDict"].GetObject(); - - for (rapidjson::Value::ConstMemberIterator itr = kerning.MemberBegin(); - itr != kerning.MemberEnd(); ++itr) - { - tKerningHashElement *element = (tKerningHashElement *)calloc( sizeof( *element ), 1 ); - element->amount = itr->value.GetInt(); - element->key = atoi(itr->name.GetString()); - HASH_ADD_INT(_kerningDictionary,key, element); - } - - return validCharsString; -} - -std::set* BMFontConfiguration::parseConfigFile(const std::string& fntDataString) -{ - std::string data = fntDataString; - - if (data.size() >= (sizeof("BMP") - 1) - && memcmp("BMF", data.c_str(), sizeof("BMP") - 1) == 0) { - // Handle fnt file of binary format - std::set* ret = parseBinaryConfigFile((unsigned char*)&data.front(), data.size(), fntDataString); - return ret; - } - if (data[0] == 0) - { - CCLOG("cocos2d: Error parsing FNTfile %s", fntDataString.c_str()); - return nullptr; - } - auto contents = data.c_str(); - if(contents[0] == '\xEF' && contents[1] == '\xBB' && contents[2] == '\xBF') { - CCLOG("Detect your fnt file contains BOM header! "); - contents = contents + 3; - } - std::set *validCharsString = new (std::nothrow) std::set(); - - auto contentsLen = strlen(contents); - char line[512] = {0}; - - auto next = strchr(contents, '\n'); - auto base = contents; - size_t lineLength = 0; - size_t parseCount = 0; - while (next) - { - lineLength = ((int)(next - base)); - memcpy(line, contents + parseCount, lineLength); - line[lineLength] = 0; - - parseCount += lineLength + 1; - if (parseCount < contentsLen) - { - base = next + 1; - next = strchr(base, '\n'); - } - else - { - next = nullptr; - } - - if (memcmp(line, "info face", 9) == 0) - { - // FIXME: info parsing is incomplete - // Not needed for the Hiero editors, but needed for the AngelCode editor - // [self parseInfoArguments:line]; - this->parseInfoArguments(line); - } - // Check to see if the start of the line is something we are interested in - else if (memcmp(line, "common lineHeight", 17) == 0) - { - this->parseCommonArguments(line); - } - else if (memcmp(line, "page id", 7) == 0) - { - this->parseImageFileName(line, fntDataString); - } - else if (memcmp(line, "chars c", 7) == 0) - { - // Ignore this line - } - else if (memcmp(line, "char", 4) == 0) - { - // Parse the current line and create a new CharDef - tFontDefHashElement* element = (tFontDefHashElement*)malloc( sizeof(*element) ); - this->parseCharacterDefinition(line, &element->fontDef); - - element->key = element->fontDef.charID; - HASH_ADD_INT(_fontDefDictionary, key, element); - - validCharsString->insert(element->fontDef.charID); - } - else if (memcmp(line, "kerning first", 13) == 0) - { - this->parseKerningEntry(line); - } - } - - return validCharsString; -} - -std::set* BMFontConfiguration::parseBinaryConfigFile(unsigned char* pData, unsigned long size, const std::string& controlFile) -{ - /* based on http://www.angelcode.com/products/bmfont/doc/file_format.html file format */ - - set *validCharsString = new (std::nothrow) set(); - - unsigned long remains = size; - - CCASSERT(pData[3] == 3, "Only version 3 is supported"); - - pData += 4; remains -= 4; - - while (remains > 0) - { - unsigned char blockId = pData[0]; pData += 1; remains -= 1; - uint32_t blockSize = 0; memcpy(&blockSize, pData, 4); - - pData += 4; remains -= 4; - - if (blockId == 1) - { - /* - fontSize 2 int 0 - bitField 1 bits 2 bit 0: smooth, bit 1: unicode, bit 2: italic, bit 3: bold, bit 4: fixedHeight, bits 5-7: reserved - charSet 1 uint 3 - stretchH 2 uint 4 - aa 1 uint 6 - paddingUp 1 uint 7 - paddingRight 1 uint 8 - paddingDown 1 uint 9 - paddingLeft 1 uint 10 - spacingHoriz 1 uint 11 - spacingVert 1 uint 12 - outline 1 uint 13 added with version 2 - fontName n+1 string 14 null terminated string with length n - */ - - memcpy(&_fontSize, pData, 2); - _padding.top = (unsigned char)pData[7]; - _padding.right = (unsigned char)pData[8]; - _padding.bottom = (unsigned char)pData[9]; - _padding.left = (unsigned char)pData[10]; - } - else if (blockId == 2) - { - /* - lineHeight 2 uint 0 - base 2 uint 2 - scaleW 2 uint 4 - scaleH 2 uint 6 - pages 2 uint 8 - bitField 1 bits 10 bits 0-6: reserved, bit 7: packed - alphaChnl 1 uint 11 - redChnl 1 uint 12 - greenChnl 1 uint 13 - blueChnl 1 uint 14 - */ - - uint16_t lineHeight = 0; memcpy(&lineHeight, pData, 2); - _commonHeight = lineHeight; - - uint16_t scaleW = 0; memcpy(&scaleW, pData + 4, 2); - uint16_t scaleH = 0; memcpy(&scaleH, pData + 6, 2); - - CCASSERT(scaleW <= Configuration::getInstance()->getMaxTextureSize() && scaleH <= Configuration::getInstance()->getMaxTextureSize(), "CCLabelBMFont: page can't be larger than supported"); - - uint16_t pages = 0; memcpy(&pages, pData + 8, 2); - CCASSERT(pages == 1, "CCBitfontAtlas: only supports 1 page"); - } - else if (blockId == 3) - { - /* - pageNames p*(n+1) strings 0 p null terminated strings, each with length n - */ - - const char *value = (const char *)pData; - CCASSERT(strlen(value) < blockSize, "Block size should be less then string"); - - _atlasName = FileUtils::getInstance()->fullPathFromRelativeFile(value, controlFile); - } - else if (blockId == 4) - { - /* - id 4 uint 0+c*20 These fields are repeated until all characters have been described - x 2 uint 4+c*20 - y 2 uint 6+c*20 - width 2 uint 8+c*20 - height 2 uint 10+c*20 - xoffset 2 int 12+c*20 - yoffset 2 int 14+c*20 - xadvance 2 int 16+c*20 - page 1 uint 18+c*20 - chnl 1 uint 19+c*20 - */ - - unsigned long count = blockSize / 20; - - for (unsigned long i = 0; i < count; i++) - { - tFontDefHashElement* element = (tFontDefHashElement*)malloc( sizeof(*element) ); - - uint32_t charId = 0; memcpy(&charId, pData + (i * 20), 4); - element->fontDef.charID = charId; - - uint16_t charX = 0; memcpy(&charX, pData + (i * 20) + 4, 2); - element->fontDef.rect.origin.x = charX; - - uint16_t charY = 0; memcpy(&charY, pData + (i * 20) + 6, 2); - element->fontDef.rect.origin.y = charY; - - uint16_t charWidth = 0; memcpy(&charWidth, pData + (i * 20) + 8, 2); - element->fontDef.rect.size.width = charWidth; - - uint16_t charHeight = 0; memcpy(&charHeight, pData + (i * 20) + 10, 2); - element->fontDef.rect.size.height = charHeight; - - int16_t xoffset = 0; memcpy(&xoffset, pData + (i * 20) + 12, 2); - element->fontDef.xOffset = xoffset; - - int16_t yoffset = 0; memcpy(&yoffset, pData + (i * 20) + 14, 2); - element->fontDef.yOffset = yoffset; - - int16_t xadvance = 0; memcpy(&xadvance, pData + (i * 20) + 16, 2); - element->fontDef.xAdvance = xadvance; - - element->key = element->fontDef.charID; - HASH_ADD_INT(_fontDefDictionary, key, element); - - validCharsString->insert(element->fontDef.charID); - } - } - else if (blockId == 5) { - /* - first 4 uint 0+c*10 These fields are repeated until all kerning pairs have been described - second 4 uint 4+c*10 - amount 2 int 8+c*10 - */ - - unsigned long count = blockSize / 20; - - for (unsigned long i = 0; i < count; i++) - { - uint32_t first = 0; memcpy(&first, pData + (i * 10), 4); - uint32_t second = 0; memcpy(&second, pData + (i * 10) + 4, 4); - int16_t amount = 0; memcpy(&amount, pData + (i * 10) + 8, 2); - - tKerningHashElement *element = (tKerningHashElement *)calloc( sizeof( *element ), 1 ); - element->amount = amount; - element->key = (first<<16) | (second&0xffff); - HASH_ADD_INT(_kerningDictionary,key, element); - } - } - - pData += blockSize; remains -= blockSize; - } - - return validCharsString; -} - -void BMFontConfiguration::parseImageFileName(const char* line, const std::string& fntFile) -{ - ////////////////////////////////////////////////////////////////////////// - // line to parse: - // page id=0 file="bitmapFontTest.png" - ////////////////////////////////////////////////////////////////////////// - - // page ID. Sanity check - int pageId; - sscanf(line, "page id=%d", &pageId); - CCASSERT(pageId == 0, "LabelBMFont file could not be found"); - // file - char fileName[255]; - sscanf(strchr(line,'"') + 1, "%[^\"]", fileName); - _atlasName = fntFile; -} - -void BMFontConfiguration::parseInfoArguments(const char* line) -{ - ////////////////////////////////////////////////////////////////////////// - // possible lines to parse: - // info face="Script" size=32 bold=0 italic=0 charset="" unicode=1 stretchH=100 smooth=1 aa=1 padding=1,4,3,2 spacing=0,0 outline=0 - // info face="Cracked" size=36 bold=0 italic=0 charset="" unicode=0 stretchH=100 smooth=1 aa=1 padding=0,0,0,0 spacing=1,1 - ////////////////////////////////////////////////////////////////////////// - sscanf(strstr(line, "size=") + 5, "%d", &_fontSize); - // padding - sscanf(strstr(line,"padding=") + 8, "%d,%d,%d,%d", &_padding.top, &_padding.right, &_padding.bottom, &_padding.left); - //CCLOG("cocos2d: padding: %d,%d,%d,%d", _padding.left, _padding.top, _padding.right, _padding.bottom); -} - -void BMFontConfiguration::parseCommonArguments(const char* line) -{ - ////////////////////////////////////////////////////////////////////////// - // line to parse: - // common lineHeight=104 base=26 scaleW=1024 scaleH=512 pages=1 packed=0 - ////////////////////////////////////////////////////////////////////////// - - // Height - auto tmp = strstr(line, "lineHeight=") + 11; - sscanf(tmp, "%d", &_commonHeight); - -#if COCOS2D_DEBUG > 0 - // scaleW. sanity check - int value; - tmp = strstr(tmp, "scaleW=") + 7; - sscanf(tmp, "%d", &value); - - int maxTextureSize = Configuration::getInstance()->getMaxTextureSize(); - CCASSERT(value <= maxTextureSize, "CCLabelBMFont: page can't be larger than supported"); - - // scaleH. sanity check - tmp = strstr(tmp, "scaleH=") + 7; - sscanf(tmp, "%d", &value); - CCASSERT(value <= maxTextureSize, "CCLabelBMFont: page can't be larger than supported"); - - // pages. sanity check - tmp = strstr(tmp, "pages=") + 6; - sscanf(tmp, "%d", &value); - CCASSERT(value == 1, "CCBitfontAtlas: only supports 1 page"); -#endif - // packed (ignore) What does this mean ?? -} - -void BMFontConfiguration::parseCharacterDefinition(const char* line, BMFontDef *characterDefinition) -{ - ////////////////////////////////////////////////////////////////////////// - // line to parse: - // char id=32 x=0 y=0 width=0 height=0 xoffset=0 yoffset=44 xadvance=14 page=0 chnl=0 - ////////////////////////////////////////////////////////////////////////// - - // Character ID - auto tmp = strstr(line, "id=") + 3; - sscanf(tmp, "%u", &characterDefinition->charID); - - // Character x - tmp = strstr(tmp, "x=") + 2; - sscanf(tmp, "%f", &characterDefinition->rect.origin.x); - // Character y - tmp = strstr(tmp, "y=") + 2; - sscanf(tmp, "%f", &characterDefinition->rect.origin.y); - // Character width - tmp = strstr(tmp, "width=") + 6; - sscanf(tmp, "%f", &characterDefinition->rect.size.width); - // Character height - tmp = strstr(tmp, "height=") + 7; - sscanf(tmp, "%f", &characterDefinition->rect.size.height); - // Character xoffset - tmp = strstr(tmp, "xoffset=") + 8; - sscanf(tmp, "%hd", &characterDefinition->xOffset); - // Character yoffset - tmp = strstr(tmp, "yoffset=") + 8; - sscanf(tmp, "%hd", &characterDefinition->yOffset); - // Character xadvance - tmp = strstr(tmp, "xadvance=") + 9; - sscanf(tmp, "%hd", &characterDefinition->xAdvance); -} - -void BMFontConfiguration::parseKerningEntry(const char* line) -{ - ////////////////////////////////////////////////////////////////////////// - // line to parse: - // kerning first=121 second=44 amount=-7 - ////////////////////////////////////////////////////////////////////////// - - int first, second, amount; - auto tmp = strstr(line, "first=") + 6; - sscanf(tmp, "%d", &first); - - tmp = strstr(tmp, "second=") + 7; - sscanf(tmp, "%d", &second); - - tmp = strstr(tmp, "amount=") + 7; - sscanf(tmp, "%d", &amount); - - tKerningHashElement *element = (tKerningHashElement *)calloc( sizeof( *element ), 1 ); - element->amount = amount; - element->key = (first<<16) | (second&0xffff); - HASH_ADD_INT(_kerningDictionary,key, element); -} - -FontFNT * FontFNT::create(const std::string& jsonString, - SpriteFrame* spriteFrame, - const Vec2& imageOffset /* = Vec2::ZERO */) -{ - BMFontConfiguration *newConf = FNTConfigLoadJson(jsonString, spriteFrame); - if (!newConf) - return nullptr; - - // add the texture - Texture2D *tempTexture = nullptr; - if (spriteFrame) { - tempTexture = spriteFrame->getTexture(); - } else { - tempTexture = Director::getInstance()->getTextureCache()->addImage(newConf->getAtlasName()); - } - - if (!tempTexture) - { - return nullptr; - } - - FontFNT *tempFont = new FontFNT(newConf,imageOffset); - tempFont->setFontSize(newConf->_fontSize); - if (!tempFont) - { - return nullptr; - } - tempFont->autorelease(); - return tempFont; -} - -FontFNT::FontFNT(BMFontConfiguration *theContfig, const Vec2& imageOffset /* = Vec2::ZERO */) -:_configuration(theContfig) -,_imageOffset(CC_POINT_PIXELS_TO_POINTS(imageOffset)) -{ - _configuration->retain(); -} - -FontFNT::~FontFNT() -{ - _configuration->release(); -} - -void FontFNT::purgeCachedData() -{ -} - -int * FontFNT::getHorizontalKerningForTextUTF16(const std::u16string& text, int &outNumLetters) const -{ - outNumLetters = static_cast(text.length()); - - if (!outNumLetters) - return nullptr; - - int *sizes = new (std::nothrow) int[outNumLetters]; - if (!sizes) - return nullptr; - - for (int c = 0; c < outNumLetters; ++c) - { - if (c < (outNumLetters-1)) - sizes[c] = getHorizontalKerningForChars(text[c], text[c+1]); - else - sizes[c] = 0; - } - - return sizes; -} - -int FontFNT::getHorizontalKerningForChars(unsigned short firstChar, unsigned short secondChar) const -{ - int ret = 0; - unsigned int key = (firstChar << 16) | (secondChar & 0xffff); - - if (_configuration->_kerningDictionary) - { - tKerningHashElement *element = nullptr; - HASH_FIND_INT(_configuration->_kerningDictionary, &key, element); - - if (element) - ret = element->amount; - } - - return ret; -} - -void FontFNT::setFontSize(float fontSize) -{ - _fontSize = fontSize; -} - -int FontFNT::getOriginalFontSize()const -{ - return _configuration->_fontSize; -} - -FontAtlas * FontFNT::createFontAtlas() -{ - // check that everything is fine with the BMFontCofniguration - if (!_configuration->_fontDefDictionary) - return nullptr; - - size_t numGlyphs = _configuration->_characterSet->size(); - if (numGlyphs == 0) - return nullptr; - - if (_configuration->_commonHeight == 0) - return nullptr; - - FontAtlas *tempAtlas = new (std::nothrow) FontAtlas(*this); - if (tempAtlas == nullptr) - return nullptr; - - // common height - int originalFontSize = _configuration->_fontSize; - float originalLineHeight = _configuration->_commonHeight; - float factor = 0.0f; - if (std::abs(_fontSize - originalFontSize) < FLT_EPSILON) { - factor = 1.0f; - }else { - factor = _fontSize / originalFontSize; - } - - tempAtlas->setLineHeight(originalLineHeight * factor); - - BMFontDef fontDef; - tFontDefHashElement *currentElement, *tmp; - // Purge uniform hash - HASH_ITER(hh, _configuration->_fontDefDictionary, currentElement, tmp) - { - - FontLetterDefinition tempDefinition; - - fontDef = currentElement->fontDef; - Rect tempRect; - tempRect = fontDef.rect; - tempRect = CC_RECT_PIXELS_TO_POINTS(tempRect); - - tempDefinition.offsetX = fontDef.xOffset; - tempDefinition.offsetY = fontDef.yOffset; - - tempDefinition.U = tempRect.origin.x + _imageOffset.x; - tempDefinition.V = tempRect.origin.y + _imageOffset.y; - - tempDefinition.width = tempRect.size.width; - tempDefinition.height = tempRect.size.height; - - //carloX: only one texture supported FOR NOW - tempDefinition.textureID = 0; - - tempDefinition.validDefinition = true; - tempDefinition.xAdvance = fontDef.xAdvance; - // add the new definition - if (65535 < fontDef.charID) { - CCLOGWARN("Warning: 65535 < fontDef.charID (%u), ignored", fontDef.charID); - } else { - tempAtlas->addLetterDefinition(fontDef.charID,tempDefinition); - } - } - - // add the texture (only one texture for now) - Texture2D *tempTexture = nullptr; - if(_configuration->_spriteFrame) { - tempTexture = _configuration->_spriteFrame->getTexture(); - } - - if (!tempTexture) { - CC_SAFE_RELEASE(tempAtlas); - return nullptr; - } - - // add the texture - tempAtlas->addTexture(tempTexture, 0); - - // done - return tempAtlas; -} - -NS_CC_END diff --git a/native/cocos/2d/CCFontFNT.h b/native/cocos/2d/CCFontFNT.h deleted file mode 100644 index 06dedaa4df..0000000000 --- a/native/cocos/2d/CCFontFNT.h +++ /dev/null @@ -1,78 +0,0 @@ -/**************************************************************************** - Copyright (c) 2013 Zynga Inc. - Copyright (c) 2013-2016 Chukong Technologies Inc. - Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - - http://www.cocos2d-x.org - - Permission is hereby granted, free of charge, to any person obtaining a copy - of this software and associated documentation files (the "Software"), to deal - in the Software without restriction, including without limitation the rights - to use, copy, modify, merge, publish, distribute, sublicense, and/or sell - copies of the Software, and to permit persons to whom the Software is - furnished to do so, subject to the following conditions: - - The above copyright notice and this permission notice shall be included in - all copies or substantial portions of the Software. - - THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN - THE SOFTWARE. - ****************************************************************************/ - -#ifndef _CCFontFNT_h_ -#define _CCFontFNT_h_ - -/// @cond DO_NOT_SHOW - -#include "2d/CCFont.h" - -NS_CC_BEGIN - -class BMFontConfiguration; -class SpriteFrame; - -class CC_DLL FontFNT : public Font -{ - -public: - - static FontFNT * create(const std::string& fntDataString, - SpriteFrame* spriteFrame, - const Vec2& imageOffset = Vec2::ZERO); - /** Purges the cached data. - Removes from memory the cached configurations and the atlas name dictionary. - */ - static void purgeCachedData(); - virtual int* getHorizontalKerningForTextUTF16(const std::u16string& text, int &outNumLetters) const override; - virtual FontAtlas *createFontAtlas() override; - void setFontSize(float fontSize); - int getOriginalFontSize()const; -protected: - - FontFNT(BMFontConfiguration *theContfig, const Vec2& imageOffset = Vec2::ZERO); - /** - * @js NA - * @lua NA - */ - virtual ~FontFNT(); - -private: - - int getHorizontalKerningForChars(unsigned short firstChar, unsigned short secondChar) const; - - BMFontConfiguration * _configuration; - Vec2 _imageOffset; - //User defined font size - float _fontSize; -}; - -/// @endcond - -NS_CC_END - -#endif /* defined(__cocos2d_libs__CCFontFNT__) */ diff --git a/native/cocos/2d/CCFontFreeType.cpp b/native/cocos/2d/CCFontFreeType.cpp deleted file mode 100644 index 5bb0e6afcf..0000000000 --- a/native/cocos/2d/CCFontFreeType.cpp +++ /dev/null @@ -1,660 +0,0 @@ -/**************************************************************************** -Copyright (c) 2013 Zynga Inc. -Copyright (c) 2013-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ - -#include "2d/CCFontFreeType.h" -#include FT_BBOX_H -#include "edtaa3func/edtaa3func.h" -#include "2d/CCFontAtlas.h" -#include "base/CCDirector.h" -#include "base/ccUTF8.h" -#include "platform/CCFileUtils.h" - -NS_CC_BEGIN - - -FT_Library FontFreeType::_FTlibrary; -bool FontFreeType::_FTInitialized = false; -const int FontFreeType::DistanceMapSpread = 3; - -const char* FontFreeType::_glyphASCII = "\"!#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_`abcdefghijklmnopqrstuvwxyz{|}~¡¢£¤¥¦§¨©ª«¬­®¯°±²³´µ¶·¸¹º»¼½¾¿ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖרÙÚÛÜÝÞßàáâãäåæçèéêëìíîïðñòóôõö÷øùúûüýþ "; -const char* FontFreeType::_glyphNEHE = "!\"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_`abcdefghijklmnopqrstuvwxyz{|}~ "; - -typedef struct _DataRef -{ - Data data; - unsigned int referenceCount; -}DataRef; - -static std::unordered_map s_cacheFontData; - -FontFreeType * FontFreeType::create(const std::string &fontName, float fontSize, GlyphCollection glyphs, const char *customGlyphs,bool distanceFieldEnabled /* = false */,int outline /* = 0 */) -{ - FontFreeType *tempFont = new FontFreeType(distanceFieldEnabled,outline); - - if (!tempFont) - return nullptr; - - tempFont->setGlyphCollection(glyphs, customGlyphs); - - if (!tempFont->createFontObject(fontName, fontSize)) - { - delete tempFont; - return nullptr; - } - return tempFont; -} - -bool FontFreeType::initFreeType() -{ - if (_FTInitialized == false) - { - // begin freetype - if (FT_Init_FreeType( &_FTlibrary )) - return false; - - _FTInitialized = true; - } - - return _FTInitialized; -} - -void FontFreeType::shutdownFreeType() -{ - if (_FTInitialized == true) - { - FT_Done_FreeType(_FTlibrary); - s_cacheFontData.clear(); - _FTInitialized = false; - } -} - -FT_Library FontFreeType::getFTLibrary() -{ - initFreeType(); - return _FTlibrary; -} - -FontFreeType::FontFreeType(bool distanceFieldEnabled /* = false */,int outline /* = 0 */) -: _fontRef(nullptr) -, _stroker(nullptr) -, _distanceFieldEnabled(distanceFieldEnabled) -, _outlineSize(0.0f) -, _lineHeight(0) -, _fontAtlas(nullptr) -, _encoding(FT_ENCODING_UNICODE) -, _usedGlyphs(GlyphCollection::ASCII) -{ - if (outline > 0) - { - _outlineSize = outline * CC_CONTENT_SCALE_FACTOR(); - FT_Stroker_New(FontFreeType::getFTLibrary(), &_stroker); - FT_Stroker_Set(_stroker, - (int)(_outlineSize * 64), - FT_STROKER_LINECAP_ROUND, - FT_STROKER_LINEJOIN_ROUND, - 0); - } -} - -bool FontFreeType::createFontObject(const std::string &fontName, float fontSize) -{ - FT_Face face; - // save font name locally - _fontName = fontName; - - auto it = s_cacheFontData.find(fontName); - if (it != s_cacheFontData.end()) - { - (*it).second.referenceCount += 1; - } - else - { - s_cacheFontData[fontName].referenceCount = 1; - s_cacheFontData[fontName].data = FileUtils::getInstance()->getDataFromFile(fontName); - - if (s_cacheFontData[fontName].data.isNull()) - { - return false; - } - } - - if (FT_New_Memory_Face(getFTLibrary(), s_cacheFontData[fontName].data.getBytes(), s_cacheFontData[fontName].data.getSize(), 0, &face )) - return false; - - if (FT_Select_Charmap(face, FT_ENCODING_UNICODE)) - { - int foundIndex = -1; - for (int charmapIndex = 0; charmapIndex < face->num_charmaps; charmapIndex++) - { - if (face->charmaps[charmapIndex]->encoding != FT_ENCODING_NONE) - { - foundIndex = charmapIndex; - break; - } - } - - if (foundIndex == -1) - { - return false; - } - - _encoding = face->charmaps[foundIndex]->encoding; - if (FT_Select_Charmap(face, _encoding)) - { - return false; - } - } - - // set the requested font size - int dpi = 72; - int fontSizePoints = (int)(64.f * fontSize * CC_CONTENT_SCALE_FACTOR()); - if (FT_Set_Char_Size(face, fontSizePoints, fontSizePoints, dpi, dpi)) - return false; - - // store the face globally - _fontRef = face; - _lineHeight = static_cast(_fontRef->size->metrics.height >> 6); - - // done and good - return true; -} - -FontFreeType::~FontFreeType() -{ - if (_FTInitialized) - { - if (_stroker) - { - FT_Stroker_Done(_stroker); - } - if (_fontRef) - { - FT_Done_Face(_fontRef); - } - } - - s_cacheFontData[_fontName].referenceCount -= 1; - if (s_cacheFontData[_fontName].referenceCount == 0) - { - s_cacheFontData.erase(_fontName); - } -} - -FontAtlas * FontFreeType::createFontAtlas() -{ - if (_fontAtlas == nullptr) - { - _fontAtlas = new (std::nothrow) FontAtlas(*this); - if (_fontAtlas && _usedGlyphs != GlyphCollection::DYNAMIC) - { - std::u16string utf16; - if (StringUtils::UTF8ToUTF16(getGlyphCollection(), utf16)) - { - _fontAtlas->prepareLetterDefinitions(utf16); - } - } - this->release(); - } - - return _fontAtlas; -} - -int * FontFreeType::getHorizontalKerningForTextUTF16(const std::u16string& text, int &outNumLetters) const -{ - if (!_fontRef) - return nullptr; - - outNumLetters = static_cast(text.length()); - - if (!outNumLetters) - return nullptr; - - int *sizes = new (std::nothrow) int[outNumLetters]; - if (!sizes) - return nullptr; - memset(sizes,0,outNumLetters * sizeof(int)); - - bool hasKerning = FT_HAS_KERNING( _fontRef ) != 0; - if (hasKerning) - { - for (int c = 1; c < outNumLetters; ++c) - { - sizes[c] = getHorizontalKerningForChars(text[c-1], text[c]); - } - } - - return sizes; -} - -int FontFreeType::getHorizontalKerningForChars(unsigned short firstChar, unsigned short secondChar) const -{ - // get the ID to the char we need - int glyphIndex1 = FT_Get_Char_Index(_fontRef, firstChar); - - if (!glyphIndex1) - return 0; - - // get the ID to the char we need - int glyphIndex2 = FT_Get_Char_Index(_fontRef, secondChar); - - if (!glyphIndex2) - return 0; - - FT_Vector kerning; - - if (FT_Get_Kerning( _fontRef, glyphIndex1, glyphIndex2, FT_KERNING_DEFAULT, &kerning)) - return 0; - - return (static_cast(kerning.x >> 6)); -} - -int FontFreeType::getFontAscender() const -{ - return (static_cast(_fontRef->size->metrics.ascender >> 6)); -} - -const char* FontFreeType::getFontFamily() const -{ - if (!_fontRef) - return nullptr; - - return _fontRef->family_name; -} - -unsigned char* FontFreeType::getGlyphBitmap(unsigned short theChar, long &outWidth, long &outHeight, Rect &outRect,int &xAdvance) -{ - bool invalidChar = true; - unsigned char* ret = nullptr; - - do - { - if (_fontRef == nullptr) - break; - - if (_distanceFieldEnabled) - { - if (FT_Load_Char(_fontRef, theChar, FT_LOAD_RENDER | FT_LOAD_NO_HINTING | FT_LOAD_NO_AUTOHINT)) - break; - } - else - { - if (FT_Load_Char(_fontRef, theChar, FT_LOAD_RENDER | FT_LOAD_NO_AUTOHINT)) - break; - } - - auto& metrics = _fontRef->glyph->metrics; - outRect.origin.x = metrics.horiBearingX >> 6; - outRect.origin.y = -(metrics.horiBearingY >> 6); - outRect.size.width = (metrics.width >> 6); - outRect.size.height = (metrics.height >> 6); - - xAdvance = (static_cast(_fontRef->glyph->metrics.horiAdvance >> 6)); - - outWidth = _fontRef->glyph->bitmap.width; - outHeight = _fontRef->glyph->bitmap.rows; - ret = _fontRef->glyph->bitmap.buffer; - - if (_outlineSize > 0) - { - auto copyBitmap = new (std::nothrow) unsigned char[outWidth * outHeight]; - memcpy(copyBitmap,ret,outWidth * outHeight * sizeof(unsigned char)); - - FT_BBox bbox; - auto outlineBitmap = getGlyphBitmapWithOutline(theChar,bbox); - if(outlineBitmap == nullptr) - { - ret = nullptr; - delete [] copyBitmap; - break; - } - - long glyphMinX = outRect.origin.x; - long glyphMaxX = outRect.origin.x + outWidth; - long glyphMinY = -outHeight - outRect.origin.y; - long glyphMaxY = -outRect.origin.y; - - auto outlineMinX = bbox.xMin >> 6; - auto outlineMaxX = bbox.xMax >> 6; - auto outlineMinY = bbox.yMin >> 6; - auto outlineMaxY = bbox.yMax >> 6; - auto outlineWidth = outlineMaxX - outlineMinX; - auto outlineHeight = outlineMaxY - outlineMinY; - - auto blendImageMinX = MIN(outlineMinX, glyphMinX); - auto blendImageMaxY = MAX(outlineMaxY, glyphMaxY); - auto blendWidth = MAX(outlineMaxX, glyphMaxX) - blendImageMinX; - auto blendHeight = blendImageMaxY - MIN(outlineMinY, glyphMinY); - - outRect.origin.x = blendImageMinX; - outRect.origin.y = -blendImageMaxY + _outlineSize; - - long index, index2; - auto blendImage = new (std::nothrow) unsigned char[blendWidth * blendHeight * 2]; - memset(blendImage, 0, blendWidth * blendHeight * 2); - - auto px = outlineMinX - blendImageMinX; - auto py = blendImageMaxY - outlineMaxY; - for (int x = 0; x < outlineWidth; ++x) - { - for (int y = 0; y < outlineHeight; ++y) - { - index = px + x + ((py + y) * blendWidth); - index2 = x + (y * outlineWidth); - blendImage[2 * index] = outlineBitmap[index2]; - } - } - - px = glyphMinX - blendImageMinX; - py = blendImageMaxY - glyphMaxY; - for (int x = 0; x < outWidth; ++x) - { - for (int y = 0; y < outHeight; ++y) - { - index = px + x + ((y + py) * blendWidth); - index2 = x + (y * outWidth); - blendImage[2 * index + 1] = copyBitmap[index2]; - } - } - - outRect.size.width = blendWidth; - outRect.size.height = blendHeight; - outWidth = blendWidth; - outHeight = blendHeight; - - delete [] outlineBitmap; - delete [] copyBitmap; - ret = blendImage; - } - - invalidChar = false; - } while (0); - - if (invalidChar) - { - outRect.size.width = 0; - outRect.size.height = 0; - xAdvance = 0; - - return nullptr; - } - else - { - return ret; - } -} - -unsigned char * FontFreeType::getGlyphBitmapWithOutline(unsigned short theChar, FT_BBox &bbox) -{ - unsigned char* ret = nullptr; - if (FT_Load_Char(_fontRef, theChar, FT_LOAD_NO_BITMAP) == 0) - { - if (_fontRef->glyph->format == FT_GLYPH_FORMAT_OUTLINE) - { - FT_Glyph glyph; - if (FT_Get_Glyph(_fontRef->glyph, &glyph) == 0) - { - FT_Glyph_StrokeBorder(&glyph, _stroker, 0, 1); - if (glyph->format == FT_GLYPH_FORMAT_OUTLINE) - { - FT_Outline *outline = &reinterpret_cast(glyph)->outline; - FT_Glyph_Get_CBox(glyph,FT_GLYPH_BBOX_GRIDFIT,&bbox); - long width = (bbox.xMax - bbox.xMin)>>6; - long rows = (bbox.yMax - bbox.yMin)>>6; - - FT_Bitmap bmp; - bmp.buffer = new (std::nothrow) unsigned char[width * rows]; - memset(bmp.buffer, 0, width * rows); - bmp.width = (int)width; - bmp.rows = (int)rows; - bmp.pitch = (int)width; - bmp.pixel_mode = FT_PIXEL_MODE_GRAY; - bmp.num_grays = 256; - - FT_Raster_Params params; - memset(¶ms, 0, sizeof (params)); - params.source = outline; - params.target = &bmp; - params.flags = FT_RASTER_FLAG_AA; - FT_Outline_Translate(outline,-bbox.xMin,-bbox.yMin); - FT_Outline_Render(_FTlibrary, outline, ¶ms); - - ret = bmp.buffer; - } - FT_Done_Glyph(glyph); - } - } - } - - return ret; -} - -unsigned char * makeDistanceMap( unsigned char *img, long width, long height) -{ - long pixelAmount = (width + 2 * FontFreeType::DistanceMapSpread) * (height + 2 * FontFreeType::DistanceMapSpread); - - short * xdist = (short *) malloc( pixelAmount * sizeof(short) ); - short * ydist = (short *) malloc( pixelAmount * sizeof(short) ); - double * gx = (double *) calloc( pixelAmount, sizeof(double) ); - double * gy = (double *) calloc( pixelAmount, sizeof(double) ); - double * data = (double *) calloc( pixelAmount, sizeof(double) ); - double * outside = (double *) calloc( pixelAmount, sizeof(double) ); - double * inside = (double *) calloc( pixelAmount, sizeof(double) ); - long i,j; - - // Convert img into double (data) rescale image levels between 0 and 1 - long outWidth = width + 2 * FontFreeType::DistanceMapSpread; - for (i = 0; i < width; ++i) - { - for (j = 0; j < height; ++j) - { - data[j * outWidth + FontFreeType::DistanceMapSpread + i] = img[j * width + i] / 255.0; - } - } - - width += 2 * FontFreeType::DistanceMapSpread; - height += 2 * FontFreeType::DistanceMapSpread; - - // Transform background (outside contour, in areas of 0's) - computegradient( data, (int)width, (int)height, gx, gy); - edtaa3(data, gx, gy, (int)width, (int)height, xdist, ydist, outside); - for( i=0; i< pixelAmount; i++) - if( outside[i] < 0.0 ) - outside[i] = 0.0; - - // Transform foreground (inside contour, in areas of 1's) - for( i=0; i< pixelAmount; i++) - data[i] = 1 - data[i]; - computegradient( data, (int)width, (int)height, gx, gy); - edtaa3(data, gx, gy, (int)width, (int)height, xdist, ydist, inside); - for( i=0; i< pixelAmount; i++) - if( inside[i] < 0.0 ) - inside[i] = 0.0; - - // The bipolar distance field is now outside-inside - double dist; - /* Single channel 8-bit output (bad precision and range, but simple) */ - unsigned char *out = (unsigned char *) malloc( pixelAmount * sizeof(unsigned char) ); - for( i=0; i < pixelAmount; i++) - { - dist = outside[i] - inside[i]; - dist = 128.0 - dist*16; - if( dist < 0 ) dist = 0; - if( dist > 255 ) dist = 255; - out[i] = (unsigned char) dist; - } - /* Dual channel 16-bit output (more complicated, but good precision and range) */ - /*unsigned char *out = (unsigned char *) malloc( pixelAmount * 3 * sizeof(unsigned char) ); - for( i=0; i< pixelAmount; i++) - { - dist = outside[i] - inside[i]; - dist = 128.0 - dist*16; - if( dist < 0.0 ) dist = 0.0; - if( dist >= 256.0 ) dist = 255.999; - // R channel is a copy of the original grayscale image - out[3*i] = img[i]; - // G channel is fraction - out[3*i + 1] = (unsigned char) ( 256 - (dist - floor(dist)* 256.0 )); - // B channel is truncated integer part - out[3*i + 2] = (unsigned char)dist; - }*/ - - free( xdist ); - free( ydist ); - free( gx ); - free( gy ); - free( data ); - free( outside ); - free( inside ); - - return out; -} - -void FontFreeType::renderCharAt(unsigned char *dest,int posX, int posY, unsigned char* bitmap,long bitmapWidth,long bitmapHeight) -{ - int iX = posX; - int iY = posY; - - if (_distanceFieldEnabled) - { - auto distanceMap = makeDistanceMap(bitmap,bitmapWidth,bitmapHeight); - - bitmapWidth += 2 * DistanceMapSpread; - bitmapHeight += 2 * DistanceMapSpread; - - for (long y = 0; y < bitmapHeight; ++y) - { - long bitmap_y = y * bitmapWidth; - - for (long x = 0; x < bitmapWidth; ++x) - { - /* Dual channel 16-bit output (more complicated, but good precision and range) */ - /*int index = (iX + ( iY * destSize )) * 3; - int index2 = (bitmap_y + x)*3; - dest[index] = out[index2]; - dest[index + 1] = out[index2 + 1]; - dest[index + 2] = out[index2 + 2];*/ - - //Single channel 8-bit output - dest[iX + ( iY * FontAtlas::CacheTextureWidth )] = distanceMap[bitmap_y + x]; - - iX += 1; - } - - iX = posX; - iY += 1; - } - free(distanceMap); - } - else if(_outlineSize > 0) - { - unsigned char tempChar; - for (long y = 0; y < bitmapHeight; ++y) - { - long bitmap_y = y * bitmapWidth; - - for (int x = 0; x < bitmapWidth; ++x) - { - tempChar = bitmap[(bitmap_y + x) * 2]; - dest[(iX + ( iY * FontAtlas::CacheTextureWidth ) ) * 2] = tempChar; - tempChar = bitmap[(bitmap_y + x) * 2 + 1]; - dest[(iX + ( iY * FontAtlas::CacheTextureWidth ) ) * 2 + 1] = tempChar; - - iX += 1; - } - - iX = posX; - iY += 1; - } - delete [] bitmap; - } - else - { - for (long y = 0; y < bitmapHeight; ++y) - { - long bitmap_y = y * bitmapWidth; - - for (int x = 0; x < bitmapWidth; ++x) - { - unsigned char cTemp = bitmap[bitmap_y + x]; - - // the final pixel - dest[(iX + ( iY * FontAtlas::CacheTextureWidth ) )] = cTemp; - - iX += 1; - } - - iX = posX; - iY += 1; - } - } -} - -void FontFreeType::setGlyphCollection(GlyphCollection glyphs, const char* customGlyphs /* = nullptr */) -{ - _usedGlyphs = glyphs; - if (glyphs == GlyphCollection::CUSTOM) - { - _customGlyphs = customGlyphs; - } -} - -const char* FontFreeType::getGlyphCollection() const -{ - const char* glyphCollection = nullptr; - switch (_usedGlyphs) - { - case cocos2d::GlyphCollection::DYNAMIC: - break; - case cocos2d::GlyphCollection::NEHE: - glyphCollection = _glyphNEHE; - break; - case cocos2d::GlyphCollection::ASCII: - glyphCollection = _glyphASCII; - break; - case cocos2d::GlyphCollection::CUSTOM: - glyphCollection = _customGlyphs.c_str(); - break; - default: - break; - } - - return glyphCollection; -} - -void FontFreeType::releaseFont(const std::string &fontName) -{ - auto item = s_cacheFontData.begin(); - while (s_cacheFontData.end() != item) - { - if (item->first.find(fontName) != std::string::npos) - item = s_cacheFontData.erase(item); - else - item++; - } -} - -NS_CC_END - diff --git a/native/cocos/2d/CCFontFreeType.h b/native/cocos/2d/CCFontFreeType.h deleted file mode 100644 index 294760444d..0000000000 --- a/native/cocos/2d/CCFontFreeType.h +++ /dev/null @@ -1,122 +0,0 @@ -/**************************************************************************** - Copyright (c) 2013 Zynga Inc. - Copyright (c) 2013-2016 Chukong Technologies Inc. - Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - - http://www.cocos2d-x.org - - Permission is hereby granted, free of charge, to any person obtaining a copy - of this software and associated documentation files (the "Software"), to deal - in the Software without restriction, including without limitation the rights - to use, copy, modify, merge, publish, distribute, sublicense, and/or sell - copies of the Software, and to permit persons to whom the Software is - furnished to do so, subject to the following conditions: - - The above copyright notice and this permission notice shall be included in - all copies or substantial portions of the Software. - - THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN - THE SOFTWARE. - ****************************************************************************/ - -#ifndef _FontFreetype_h_ -#define _FontFreetype_h_ - -/// @cond DO_NOT_SHOW - -#include "2d/CCFont.h" - -#include -#include - -#if (CC_TARGET_PLATFORM == CC_PLATFORM_WINRT) -#define generic GenericFromFreeTypeLibrary -#define internal InternalFromFreeTypeLibrary -#endif - -#include FT_FREETYPE_H -#include FT_STROKER_H - -#if (CC_TARGET_PLATFORM == CC_PLATFORM_WINRT) -#undef generic -#undef internal -#endif - -NS_CC_BEGIN - -class CC_DLL FontFreeType : public Font -{ -public: - static const int DistanceMapSpread; - - static FontFreeType* create(const std::string &fontName, float fontSize, GlyphCollection glyphs, - const char *customGlyphs,bool distanceFieldEnabled = false,int outline = 0); - - static void shutdownFreeType(); - - bool isDistanceFieldEnabled() const { return _distanceFieldEnabled;} - - float getOutlineSize() const { return _outlineSize; } - - void renderCharAt(unsigned char *dest,int posX, int posY, unsigned char* bitmap,long bitmapWidth,long bitmapHeight); - - FT_Encoding getEncoding() const { return _encoding; } - - int* getHorizontalKerningForTextUTF16(const std::u16string& text, int &outNumLetters) const override; - - unsigned char* getGlyphBitmap(unsigned short theChar, long &outWidth, long &outHeight, Rect &outRect,int &xAdvance); - - int getFontAscender() const; - - const char* getFontFamily() const; - - virtual FontAtlas* createFontAtlas() override; - virtual int getFontMaxHeight() const override { return _lineHeight; } - - static void releaseFont(const std::string &fontName); - -private: - static const char* _glyphASCII; - static const char* _glyphNEHE; - static FT_Library _FTlibrary; - static bool _FTInitialized; - - FontFreeType(bool distanceFieldEnabled = false, int outline = 0); - virtual ~FontFreeType(); - - bool createFontObject(const std::string &fontName, float fontSize); - - bool initFreeType(); - FT_Library getFTLibrary(); - - int getHorizontalKerningForChars(unsigned short firstChar, unsigned short secondChar) const; - unsigned char* getGlyphBitmapWithOutline(unsigned short code, FT_BBox &bbox); - - void setGlyphCollection(GlyphCollection glyphs, const char* customGlyphs = nullptr); - const char* getGlyphCollection() const; - - FT_Face _fontRef; - FT_Stroker _stroker; - FT_Encoding _encoding; - - std::string _fontName; - bool _distanceFieldEnabled; - float _outlineSize; - int _lineHeight; - FontAtlas* _fontAtlas; - - GlyphCollection _usedGlyphs; - std::string _customGlyphs; -}; - -/// @endcond - -NS_CC_END - -#endif - diff --git a/native/cocos/2d/CCGLBufferedNode.cpp b/native/cocos/2d/CCGLBufferedNode.cpp deleted file mode 100644 index 781f88bb07..0000000000 --- a/native/cocos/2d/CCGLBufferedNode.cpp +++ /dev/null @@ -1,98 +0,0 @@ -/**************************************************************************** -Copyright (c) 2013 Zynga Inc. -Copyright (c) 2013-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ - -#include "2d/CCGLBufferedNode.h" - -GLBufferedNode::GLBufferedNode() -{ - for(int i = 0; i < BUFFER_SLOTS; i++) - { - _bufferObject[i] = 0; - _bufferSize[i] = 0; - _indexBufferObject[i] = 0; - _indexBufferSize[i] = 0; - } -} - -GLBufferedNode::~GLBufferedNode() -{ - for(int i = 0; i < BUFFER_SLOTS; i++) - { - if(_bufferSize[i]) - { - glDeleteBuffers(1, &(_bufferObject[i])); - } - if(_indexBufferSize[i]) - { - glDeleteBuffers(1, &(_indexBufferObject[i])); - } - } -} - -void GLBufferedNode::setGLBufferData(void *buf, GLuint bufSize, int slot) -{ - // WebGL doesn't support client-side arrays, so generate a buffer and load the data first. - if(_bufferSize[slot] < bufSize) - { - if(_bufferObject[slot]) - { - glDeleteBuffers(1, &(_bufferObject[slot])); - } - glGenBuffers(1, &(_bufferObject[slot])); - _bufferSize[slot] = bufSize; - - glBindBuffer(GL_ARRAY_BUFFER, _bufferObject[slot]); - glBufferData(GL_ARRAY_BUFFER, bufSize, buf, GL_DYNAMIC_DRAW); - } - else - { - glBindBuffer(GL_ARRAY_BUFFER, _bufferObject[slot]); - glBufferSubData(GL_ARRAY_BUFFER, 0, bufSize, buf); - } -} - -void GLBufferedNode::setGLIndexData(void *buf, GLuint bufSize, int slot) -{ - // WebGL doesn't support client-side arrays, so generate a buffer and load the data first. - if(_indexBufferSize[slot] < bufSize) - { - if(_indexBufferObject[slot]) - { - glDeleteBuffers(1, &(_indexBufferObject[slot])); - } - glGenBuffers(1, &(_indexBufferObject[slot])); - _indexBufferSize[slot] = bufSize; - - glBindBuffer(GL_ELEMENT_ARRAY_BUFFER, _indexBufferObject[slot]); - glBufferData(GL_ELEMENT_ARRAY_BUFFER, bufSize, buf, GL_DYNAMIC_DRAW); - } - else - { - glBindBuffer(GL_ELEMENT_ARRAY_BUFFER, _indexBufferObject[slot]); - glBufferSubData(GL_ELEMENT_ARRAY_BUFFER, 0, bufSize, buf); - } -} - diff --git a/native/cocos/2d/CCGLBufferedNode.h b/native/cocos/2d/CCGLBufferedNode.h deleted file mode 100644 index d88aa7d304..0000000000 --- a/native/cocos/2d/CCGLBufferedNode.h +++ /dev/null @@ -1,65 +0,0 @@ -/**************************************************************************** -Copyright (c) 2013 Zynga Inc. -Copyright (c) 2013-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ -#ifndef __CC_GL_BUFFERED_NODE__ -#define __CC_GL_BUFFERED_NODE__ - -#include "platform/CCGL.h" - -/** -* @js NA -*/ -class GLBufferedNode -{ -public: - /** - * @js ctor - */ - GLBufferedNode(); - /** - * @js NA - * @lua NA - */ - virtual ~GLBufferedNode(); - - /**@{ - * Load the given data into this Node's GL Buffer. Needed for WebGL, as it does not support client-side arrays. - */ - void setGLBufferData(void *buf, GLuint bufSize, int slot); - void setGLIndexData(void *buf, GLuint bufSize, int slot); - /**@}*/ - /** Allocate 4 buffer objs per node, and index into them as slots.*/ - #define BUFFER_SLOTS 4 - /**Handle for vertex buffers.*/ - GLuint _bufferObject[BUFFER_SLOTS]; - /**Size in bytes for vertex buffers.*/ - GLuint _bufferSize[BUFFER_SLOTS]; - /**Handle for index buffers.*/ - GLuint _indexBufferObject[BUFFER_SLOTS]; - /**Size in bytes for index buffers.*/ - GLuint _indexBufferSize[BUFFER_SLOTS]; -}; -#endif // __CC_GL_BUFFERED_NODE__ - diff --git a/native/cocos/2d/CCGrabber.cpp b/native/cocos/2d/CCGrabber.cpp deleted file mode 100644 index 26f07dfffb..0000000000 --- a/native/cocos/2d/CCGrabber.cpp +++ /dev/null @@ -1,103 +0,0 @@ -/**************************************************************************** -Copyright (c) 2009 On-Core -Copyright (c) 2010-2012 cocos2d-x.org -Copyright (C) 2013-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ -#include "2d/CCGrabber.h" -#include "base/ccMacros.h" -#include "renderer/CCTexture2D.h" - -NS_CC_BEGIN - -Grabber::Grabber(void) - : _FBO(0) - , _oldFBO(0) -{ - memset(_oldClearColor, 0, sizeof(_oldClearColor)); - - // generate FBO - glGenFramebuffers(1, &_FBO); -} - -void Grabber::grab(Texture2D *texture) -{ - glGetIntegerv(GL_FRAMEBUFFER_BINDING, &_oldFBO); - - // bind - glBindFramebuffer(GL_FRAMEBUFFER, _FBO); - - // associate texture with FBO - glFramebufferTexture2D(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0, GL_TEXTURE_2D, texture->getName(), 0); - - // check if it worked (probably worth doing :) ) - GLuint status = glCheckFramebufferStatus(GL_FRAMEBUFFER); - if (status != GL_FRAMEBUFFER_COMPLETE) - { - CCASSERT(0, "Frame Grabber: could not attach texture to framebuffer"); - } - - glBindFramebuffer(GL_FRAMEBUFFER, _oldFBO); -} - -void Grabber::beforeRender(Texture2D *texture) -{ - CC_UNUSED_PARAM(texture); - - glGetIntegerv(GL_FRAMEBUFFER_BINDING, &_oldFBO); - glBindFramebuffer(GL_FRAMEBUFFER, _FBO); - - // save clear color - glGetFloatv(GL_COLOR_CLEAR_VALUE, _oldClearColor); - // FIXME: doesn't work with RGB565. - - glClearColor(0, 0, 0, 0); - - // BUG #631: To fix #631, uncomment the lines with #631 - // Warning: But it Grabber won't work with 2 effects at the same time -// glClearColor(0.0f,0.0f,0.0f,1.0f); // #631 - - glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT); - -// glColorMask(true, true, true, false); // #631 -} - -void Grabber::afterRender(cocos2d::Texture2D *texture) -{ - CC_UNUSED_PARAM(texture); - - glBindFramebuffer(GL_FRAMEBUFFER, _oldFBO); -// glColorMask(true, true, true, true); // #631 - - // Restore clear color - glClearColor(_oldClearColor[0], _oldClearColor[1], _oldClearColor[2], _oldClearColor[3]); -} - -Grabber::~Grabber() -{ - CCLOGINFO("deallocing Grabber: %p", this); - glDeleteFramebuffers(1, &_FBO); -} - -NS_CC_END - diff --git a/native/cocos/2d/CCGrabber.h b/native/cocos/2d/CCGrabber.h deleted file mode 100644 index 17af8df394..0000000000 --- a/native/cocos/2d/CCGrabber.h +++ /dev/null @@ -1,76 +0,0 @@ -/**************************************************************************** -Copyright (c) 2009 On-Core -Copyright (c) 2010-2012 cocos2d-x.org -Copyright (C) 2013-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ -#ifndef __EFFECTS_CCGRABBER_H__ -#define __EFFECTS_CCGRABBER_H__ - -#include "base/CCRef.h" -#include "platform/CCGL.h" - -NS_CC_BEGIN - -class Texture2D; - -/** - * @addtogroup _2d - * @{ - */ - -/** FBO class that grabs the contents of the screen */ -class Grabber : public Ref -{ -public: - /** - Constructor. - * @js ctor - */ - Grabber(void); - /** - Destructor. - * @js NA - * @lua NA - */ - ~Grabber(void); - /**Init the grab structure, will set the texture as the FBO color attachment.*/ - void grab(Texture2D *texture); - /**Begin capture the screen, which will save the old FBO, clear color, and set the new FBO, clear the background.*/ - void beforeRender(Texture2D *texture); - /**After capture, will reset the old FBO and clear color.*/ - void afterRender(Texture2D *texture); - -protected: - GLuint _FBO; - GLint _oldFBO; - GLfloat _oldClearColor[4]; -}; - -// end of effects group -/// @} - -NS_CC_END - -#endif // __EFFECTS_CCGRABBER_H__ - diff --git a/native/cocos/2d/CCGrid.cpp b/native/cocos/2d/CCGrid.cpp deleted file mode 100644 index 561e218130..0000000000 --- a/native/cocos/2d/CCGrid.cpp +++ /dev/null @@ -1,797 +0,0 @@ -/**************************************************************************** -Copyright (c) 2009 On-Core -Copyright (c) 2010-2012 cocos2d-x.org -Copyright (C) 2013-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ -#include "2d/CCGrid.h" - -#include "base/ccMacros.h" -#include "base/ccUtils.h" -#include "2d/CCNode.h" -#include "2d/CCGrabber.h" -#include "renderer/CCGLProgram.h" -#include "renderer/CCGLProgramCache.h" -#include "renderer/ccGLStateCache.h" -#include "renderer/CCRenderer.h" -#include "renderer/CCTexture2D.h" -#include "platform/CCGL.h" - -NS_CC_BEGIN -// implementation of GridBase - -GridBase* GridBase::create(const Size& gridSize) -{ - GridBase *pGridBase = new (std::nothrow) GridBase(); - - if (pGridBase) - { - if (pGridBase->initWithSize(gridSize)) - { - pGridBase->autorelease(); - } - else - { - CC_SAFE_RELEASE_NULL(pGridBase); - } - } - - return pGridBase; -} - -GridBase* GridBase::create(const Size& gridSize, Texture2D *texture, bool flipped) -{ - GridBase *pGridBase = new (std::nothrow) GridBase(); - - if (pGridBase) - { - if (pGridBase->initWithSize(gridSize, texture, flipped)) - { - pGridBase->autorelease(); - } - else - { - CC_SAFE_RELEASE_NULL(pGridBase); - } - } - - return pGridBase; -} - -bool GridBase::initWithSize(const Size& gridSize) -{ - return initWithSize(gridSize, Rect::ZERO); -} - -bool GridBase::initWithSize(const cocos2d::Size &gridSize, const cocos2d::Rect &rect) -{ - Director *director = Director::getInstance(); - Size s = director->getWinSizeInPixels(); - - auto POTWide = ccNextPOT((unsigned int)s.width); - auto POTHigh = ccNextPOT((unsigned int)s.height); - - // we only use rgba8888 - Texture2D::PixelFormat format = Texture2D::PixelFormat::RGBA8888; - - auto dataLen = POTWide * POTHigh * 4; - void *data = calloc(dataLen, 1); - if (! data) - { - CCLOG("cocos2d: Grid: not enough memory."); - this->release(); - return false; - } - - Texture2D *texture = new (std::nothrow) Texture2D(); - texture->initWithData(data, dataLen, format, POTWide, POTHigh, s); - - free(data); - - if (! texture) - { - CCLOG("cocos2d: Grid: error creating texture"); - return false; - } - - initWithSize(gridSize, texture, false, rect); - - texture->release(); - - return true; -} - -bool GridBase::initWithSize(const Size& gridSize, Texture2D *texture, bool flipped) -{ - return initWithSize(gridSize, texture, flipped, Rect::ZERO); -} - -bool GridBase::initWithSize(const Size& gridSize, Texture2D *texture, bool flipped, const Rect& rect) -{ - bool ret = true; - - _active = false; - _reuseGrid = 0; - _gridSize = gridSize; - - _texture = texture; - CC_SAFE_RETAIN(_texture); - _isTextureFlipped = flipped; - - if (rect.equals(Rect::ZERO)) { - auto size = _texture->getContentSize(); - _gridRect.setRect(0, 0, size.width, size.height); - } - else{ - _gridRect = rect; - } - _step.x = _gridRect.size.width/_gridSize.width; - _step.y = _gridRect.size.height/_gridSize.height; - - _grabber = new (std::nothrow) Grabber(); - if (_grabber) - { - _grabber->grab(_texture); - } - else - { - ret = false; - } - - _shaderProgram = GLProgramCache::getInstance()->getGLProgram(GLProgram::SHADER_NAME_POSITION_TEXTURE); - calculateVertexPoints(); - - return ret; -} - -GridBase::~GridBase(void) -{ - CCLOGINFO("deallocing GridBase: %p", this); - - //TODO: ? why 2.0 comments this line: setActive(false); - CC_SAFE_RELEASE(_texture); - CC_SAFE_RELEASE(_grabber); -} - -// properties -void GridBase::setActive(bool active) -{ - _active = active; - if (! active) - { - Director *pDirector = Director::getInstance(); - Director::Projection proj = pDirector->getProjection(); - pDirector->setProjection(proj); - } -} - -void GridBase::setTextureFlipped(bool flipped) -{ - if (_isTextureFlipped != flipped) - { - _isTextureFlipped = flipped; - calculateVertexPoints(); - } -} - -void GridBase::set2DProjection() -{ - Director *director = Director::getInstance(); - Size size = director->getWinSizeInPixels(); - glViewport(0, 0, (GLsizei)(size.width), (GLsizei)(size.height) ); - - director->loadIdentityMatrix(MATRIX_STACK_TYPE::MATRIX_STACK_PROJECTION); - - Mat4 orthoMatrix; - Mat4::createOrthographicOffCenter(0, size.width, 0, size.height, -1, 1, &orthoMatrix); - director->multiplyMatrix(MATRIX_STACK_TYPE::MATRIX_STACK_PROJECTION, orthoMatrix); - - director->loadIdentityMatrix(MATRIX_STACK_TYPE::MATRIX_STACK_MODELVIEW); - - GL::setProjectionMatrixDirty(); -} - -void GridBase::setGridRect(const cocos2d::Rect &rect) -{ - _gridRect = rect; -} - -void GridBase::beforeDraw(void) -{ - // save projection - Director *director = Director::getInstance(); - _directorProjection = director->getProjection(); - - // 2d projection - // [director setProjection:Director::Projection::_2D]; - set2DProjection(); - - Size size = director->getWinSizeInPixels(); - glViewport(0, 0, (GLsizei)(size.width), (GLsizei)(size.height) ); - _grabber->beforeRender(_texture); -} - -void GridBase::afterDraw(cocos2d::Node *target) -{ - _grabber->afterRender(_texture); - - // restore projection - Director *director = Director::getInstance(); - director->setProjection(_directorProjection); - - Size size = director->getWinSizeInPixels(); - glViewport(0, 0, (GLsizei)(size.width), (GLsizei)(size.height) ); -// if (target->getCamera()->isDirty()) -// { -// Vec2 offset = target->getAnchorPointInPoints(); -// -// // -// // FIXME: Camera should be applied in the AnchorPoint -// // -// kmGLTranslatef(offset.x, offset.y, 0); -// target->getCamera()->locate(); -// kmGLTranslatef(-offset.x, -offset.y, 0); -// } - - GL::bindTexture2D(_texture->getName()); - - // restore projection for default FBO .fixed bug #543 #544 - //TODO: Director::getInstance()->setProjection(Director::getInstance()->getProjection()); - //TODO: Director::getInstance()->applyOrientation(); - beforeBlit(); - blit(); - afterBlit(); -} - -void GridBase::blit(void) -{ - CCASSERT(0, "Subclass should implement it."); -} - -void GridBase::reuse(void) -{ - CCASSERT(0, "Subclass should implement it!"); -} - -void GridBase::calculateVertexPoints(void) -{ - CCASSERT(0, "Subclass should implement it."); -} - -// implementation of Grid3D - -Grid3D* Grid3D::create(const Size& gridSize) -{ - Grid3D *ret= new (std::nothrow) Grid3D(); - - if (ret) - { - if (ret->initWithSize(gridSize)) - { - ret->autorelease(); - } - else - { - delete ret; - ret = nullptr; - } - } - - return ret; -} - -Grid3D* Grid3D::create(const Size& gridSize, const Rect& rect) -{ - Grid3D *ret= new (std::nothrow) Grid3D(); - - if (ret) - { - if (ret->initWithSize(gridSize, rect)) - { - ret->autorelease(); - } - else - { - delete ret; - ret = nullptr; - } - } - - return ret; -} - -Grid3D* Grid3D::create(const Size& gridSize, Texture2D *texture, bool flipped) -{ - Grid3D *ret= new (std::nothrow) Grid3D(); - - if (ret) - { - if (ret->initWithSize(gridSize, texture, flipped)) - { - ret->autorelease(); - } - else - { - delete ret; - ret = nullptr; - } - } - - return ret; -} - -Grid3D* Grid3D::create(const Size& gridSize, Texture2D *texture, bool flipped, const Rect& rect) -{ - Grid3D *ret= new (std::nothrow) Grid3D(); - - if (ret) - { - if (ret->initWithSize(gridSize, texture, flipped, rect)) - { - ret->autorelease(); - } - else - { - delete ret; - ret = nullptr; - } - } - - return ret; -} - - -Grid3D::Grid3D() -: _texCoordinates(nullptr) -, _vertices(nullptr) -, _originalVertices(nullptr) -, _indices(nullptr) -, _needDepthTestForBlit(false) -{ - -} - -Grid3D::~Grid3D(void) -{ - CC_SAFE_FREE(_texCoordinates); - CC_SAFE_FREE(_vertices); - CC_SAFE_FREE(_indices); - CC_SAFE_FREE(_originalVertices); -} - -void Grid3D::beforeBlit() -{ - if(_needDepthTestForBlit) - { - _oldDepthTestValue = glIsEnabled(GL_DEPTH_TEST) != GL_FALSE; - GLboolean depthWriteMask; - glGetBooleanv(GL_DEPTH_WRITEMASK, &depthWriteMask); - _oldDepthWriteValue = depthWriteMask != GL_FALSE; - CHECK_GL_ERROR_DEBUG(); - - glEnable(GL_DEPTH_TEST); - - glDepthMask(true); - } -} - -void Grid3D::afterBlit() -{ - if(_needDepthTestForBlit) - { - if(_oldDepthTestValue) - glEnable(GL_DEPTH_TEST); - else - glDisable(GL_DEPTH_TEST); - - glDepthMask(_oldDepthWriteValue); - } -} - -void Grid3D::blit(void) -{ - int n = _gridSize.width * _gridSize.height; - - GL::enableVertexAttribs( GL::VERTEX_ATTRIB_FLAG_POSITION | GL::VERTEX_ATTRIB_FLAG_TEX_COORD ); - _shaderProgram->use(); - _shaderProgram->setUniformsForBuiltins();; - - // - // Attributes - // - - // position - glVertexAttribPointer(GLProgram::VERTEX_ATTRIB_POSITION, 3, GL_FLOAT, GL_FALSE, 0, _vertices); - - // texCoords - glVertexAttribPointer(GLProgram::VERTEX_ATTRIB_TEX_COORD, 2, GL_FLOAT, GL_FALSE, 0, _texCoordinates); - - glDrawElements(GL_TRIANGLES, (GLsizei) n*6, GL_UNSIGNED_SHORT, _indices); -} - -void Grid3D::calculateVertexPoints(void) -{ - float width = (float)_texture->getPixelsWide(); - float height = (float)_texture->getPixelsHigh(); - float imageH = _texture->getContentSizeInPixels().height; - - int x, y, i; - CC_SAFE_FREE(_vertices); - CC_SAFE_FREE(_originalVertices); - CC_SAFE_FREE(_texCoordinates); - CC_SAFE_FREE(_indices); - - unsigned int numOfPoints = (_gridSize.width+1) * (_gridSize.height+1); - - _vertices = malloc(numOfPoints * sizeof(Vec3)); - _originalVertices = malloc(numOfPoints * sizeof(Vec3)); - _texCoordinates = malloc(numOfPoints * sizeof(Vec2)); - _indices = (GLushort*)malloc(_gridSize.width * _gridSize.height * sizeof(GLushort) * 6); - - GLfloat *vertArray = (GLfloat*)_vertices; - GLfloat *texArray = (GLfloat*)_texCoordinates; - GLushort *idxArray = _indices; - - for (x = 0; x < _gridSize.width; ++x) - { - for (y = 0; y < _gridSize.height; ++y) - { - int idx = (y * _gridSize.width) + x; - - GLfloat x1 = x * _step.x + _gridRect.origin.x; - GLfloat x2 = x1 + _step.x; - GLfloat y1 = y * _step.y + _gridRect.origin.y; - GLfloat y2= y1 + _step.y; - - GLushort a = (GLushort)(x * (_gridSize.height + 1) + y); - GLushort b = (GLushort)((x + 1) * (_gridSize.height + 1) + y); - GLushort c = (GLushort)((x + 1) * (_gridSize.height + 1) + (y + 1)); - GLushort d = (GLushort)(x * (_gridSize.height + 1) + (y + 1)); - - GLushort tempidx[6] = {a, b, d, b, c, d}; - - memcpy(&idxArray[6*idx], tempidx, 6*sizeof(GLushort)); - - int l1[4] = {a*3, b*3, c*3, d*3}; - Vec3 e(x1, y1, 0); - Vec3 f(x2, y1, 0); - Vec3 g(x2, y2, 0); - Vec3 h(x1, y2, 0); - - Vec3 l2[4] = {e, f, g, h}; - - int tex1[4] = {a*2, b*2, c*2, d*2}; - Vec2 Tex2F[4] = {Vec2(x1, y1), Vec2(x2, y1), Vec2(x2, y2), Vec2(x1, y2)}; - - for (i = 0; i < 4; ++i) - { - vertArray[l1[i]] = l2[i].x; - vertArray[l1[i] + 1] = l2[i].y; - vertArray[l1[i] + 2] = l2[i].z; - - texArray[tex1[i]] = Tex2F[i].x / width; - if (_isTextureFlipped) - { - texArray[tex1[i] + 1] = (imageH - Tex2F[i].y) / height; - } - else - { - texArray[tex1[i] + 1] = Tex2F[i].y / height; - } - } - } - } - - memcpy(_originalVertices, _vertices, (_gridSize.width+1) * (_gridSize.height+1) * sizeof(Vec3)); -} - -Vec3 Grid3D::getVertex(const Vec2& pos) const -{ - CCASSERT( pos.x == (unsigned int)pos.x && pos.y == (unsigned int) pos.y , "Numbers must be integers"); - - int index = (pos.x * (_gridSize.height+1) + pos.y) * 3; - float *vertArray = (float*)_vertices; - - Vec3 vert(vertArray[index], vertArray[index+1], vertArray[index+2]); - - return vert; -} - -Vec3 Grid3D::getOriginalVertex(const Vec2& pos) const -{ - CCASSERT( pos.x == (unsigned int)pos.x && pos.y == (unsigned int) pos.y , "Numbers must be integers"); - - int index = (pos.x * (_gridSize.height+1) + pos.y) * 3; - float *vertArray = (float*)_originalVertices; - - Vec3 vert(vertArray[index], vertArray[index+1], vertArray[index+2]); - - return vert; -} - -void Grid3D::setVertex(const Vec2& pos, const Vec3& vertex) -{ - CCASSERT( pos.x == (unsigned int)pos.x && pos.y == (unsigned int) pos.y , "Numbers must be integers"); - int index = (pos.x * (_gridSize.height + 1) + pos.y) * 3; - float *vertArray = (float*)_vertices; - vertArray[index] = vertex.x; - vertArray[index+1] = vertex.y; - vertArray[index+2] = vertex.z; -} - -void Grid3D::reuse(void) -{ - if (_reuseGrid > 0) - { - memcpy(_originalVertices, _vertices, (_gridSize.width+1) * (_gridSize.height+1) * sizeof(Vec3)); - --_reuseGrid; - } -} - -// implementation of TiledGrid3D - -TiledGrid3D::TiledGrid3D() - : _texCoordinates(nullptr) - , _vertices(nullptr) - , _originalVertices(nullptr) - , _indices(nullptr) -{ - -} - -TiledGrid3D::~TiledGrid3D(void) -{ - CC_SAFE_FREE(_texCoordinates); - CC_SAFE_FREE(_vertices); - CC_SAFE_FREE(_originalVertices); - CC_SAFE_FREE(_indices); -} - -TiledGrid3D* TiledGrid3D::create(const Size& gridSize) -{ - TiledGrid3D *ret= new (std::nothrow) TiledGrid3D(); - - if (ret) - { - if (ret->initWithSize(gridSize)) - { - ret->autorelease(); - } - else - { - delete ret; - ret = nullptr; - } - } - - return ret; -} - -TiledGrid3D* TiledGrid3D::create(const Size& gridSize, const Rect& rect) -{ - TiledGrid3D *ret= new (std::nothrow) TiledGrid3D(); - - if (ret) - { - if (ret->initWithSize(gridSize, rect)) - { - ret->autorelease(); - } - else - { - delete ret; - ret = nullptr; - } - } - - return ret; -} - -TiledGrid3D* TiledGrid3D::create(const Size& gridSize, Texture2D *texture, bool flipped, const Rect& rect) -{ - TiledGrid3D *ret= new (std::nothrow) TiledGrid3D(); - - if (ret) - { - if (ret->initWithSize(gridSize, texture, flipped, rect)) - { - ret->autorelease(); - } - else - { - delete ret; - ret = nullptr; - } - } - - return ret; -} - -TiledGrid3D* TiledGrid3D::create(const Size& gridSize, Texture2D *texture, bool flipped) -{ - TiledGrid3D *ret= new (std::nothrow) TiledGrid3D(); - - if (ret) - { - if (ret->initWithSize(gridSize, texture, flipped)) - { - ret->autorelease(); - } - else - { - delete ret; - ret = nullptr; - } - } - - return ret; -} - -void TiledGrid3D::blit(void) -{ - int n = _gridSize.width * _gridSize.height; - - - _shaderProgram->use(); - _shaderProgram->setUniformsForBuiltins(); - - // - // Attributes - // - GL::enableVertexAttribs( GL::VERTEX_ATTRIB_FLAG_POSITION | GL::VERTEX_ATTRIB_FLAG_TEX_COORD ); - - // position - glVertexAttribPointer(GLProgram::VERTEX_ATTRIB_POSITION, 3, GL_FLOAT, GL_FALSE, 0, _vertices); - - // texCoords - glVertexAttribPointer(GLProgram::VERTEX_ATTRIB_TEX_COORD, 2, GL_FLOAT, GL_FALSE, 0, _texCoordinates); - - glDrawElements(GL_TRIANGLES, (GLsizei)n*6, GL_UNSIGNED_SHORT, _indices); - - CC_INCREMENT_GL_DRAWN_BATCHES_AND_VERTICES(1,n*6); -} - -void TiledGrid3D::calculateVertexPoints(void) -{ - float width = (float)_texture->getPixelsWide(); - float height = (float)_texture->getPixelsHigh(); - float imageH = _texture->getContentSizeInPixels().height; - - int numQuads = _gridSize.width * _gridSize.height; - CC_SAFE_FREE(_vertices); - CC_SAFE_FREE(_originalVertices); - CC_SAFE_FREE(_texCoordinates); - CC_SAFE_FREE(_indices); - - _vertices = malloc(numQuads*4*sizeof(Vec3)); - _originalVertices = malloc(numQuads*4*sizeof(Vec3)); - _texCoordinates = malloc(numQuads*4*sizeof(Vec2)); - _indices = (GLushort*)malloc(numQuads*6*sizeof(GLushort)); - - GLfloat *vertArray = (GLfloat*)_vertices; - GLfloat *texArray = (GLfloat*)_texCoordinates; - GLushort *idxArray = _indices; - - int x, y; - - for( x = 0; x < _gridSize.width; x++ ) - { - for( y = 0; y < _gridSize.height; y++ ) - { - float x1 = x * _step.x + _gridRect.origin.x; - float x2 = x1 + _step.x; - float y1 = y * _step.y + _gridRect.origin.y; - float y2 = y1 + _step.y; - - *vertArray++ = x1; - *vertArray++ = y1; - *vertArray++ = 0; - *vertArray++ = x2; - *vertArray++ = y1; - *vertArray++ = 0; - *vertArray++ = x1; - *vertArray++ = y2; - *vertArray++ = 0; - *vertArray++ = x2; - *vertArray++ = y2; - *vertArray++ = 0; - - float newY1 = y1; - float newY2 = y2; - - if (_isTextureFlipped) - { - newY1 = imageH - y1; - newY2 = imageH - y2; - } - - *texArray++ = x1 / width; - *texArray++ = newY1 / height; - *texArray++ = x2 / width; - *texArray++ = newY1 / height; - *texArray++ = x1 / width; - *texArray++ = newY2 / height; - *texArray++ = x2 / width; - *texArray++ = newY2 / height; - } - } - - for (x = 0; x < numQuads; x++) - { - idxArray[x*6+0] = (GLushort)(x * 4 + 0); - idxArray[x*6+1] = (GLushort)(x * 4 + 1); - idxArray[x*6+2] = (GLushort)(x * 4 + 2); - - idxArray[x*6+3] = (GLushort)(x * 4 + 1); - idxArray[x*6+4] = (GLushort)(x * 4 + 2); - idxArray[x*6+5] = (GLushort)(x * 4 + 3); - } - - memcpy(_originalVertices, _vertices, numQuads * 12 * sizeof(GLfloat)); -} - -void TiledGrid3D::setTile(const Vec2& pos, const Quad3& coords) -{ - CCASSERT( pos.x == (unsigned int)pos.x && pos.y == (unsigned int) pos.y , "Numbers must be integers"); - int idx = (_gridSize.height * pos.x + pos.y) * 4 * 3; - float *vertArray = (float*)_vertices; - memcpy(&vertArray[idx], &coords, sizeof(Quad3)); -} - -Quad3 TiledGrid3D::getOriginalTile(const Vec2& pos) const -{ - CCASSERT( pos.x == (unsigned int)pos.x && pos.y == (unsigned int) pos.y , "Numbers must be integers"); - int idx = (_gridSize.height * pos.x + pos.y) * 4 * 3; - float *vertArray = (float*)_originalVertices; - - Quad3 ret; - memcpy(&ret, &vertArray[idx], sizeof(Quad3)); - - return ret; -} - -Quad3 TiledGrid3D::getTile(const Vec2& pos) const -{ - CCASSERT( pos.x == (unsigned int)pos.x && pos.y == (unsigned int) pos.y , "Numbers must be integers"); - int idx = (_gridSize.height * pos.x + pos.y) * 4 * 3; - float *vertArray = (float*)_vertices; - - Quad3 ret; - memcpy(&ret, &vertArray[idx], sizeof(Quad3)); - - return ret; -} - -void TiledGrid3D::reuse(void) -{ - if (_reuseGrid > 0) - { - int numQuads = _gridSize.width * _gridSize.height; - - memcpy(_originalVertices, _vertices, numQuads * 12 * sizeof(GLfloat)); - --_reuseGrid; - } -} - -NS_CC_END - diff --git a/native/cocos/2d/CCGrid.h b/native/cocos/2d/CCGrid.h deleted file mode 100644 index 9d19498904..0000000000 --- a/native/cocos/2d/CCGrid.h +++ /dev/null @@ -1,284 +0,0 @@ -/**************************************************************************** -Copyright (c) 2009 On-Core -Copyright (c) 2010-2012 cocos2d-x.org -Copyright (C) 2013-2016 Chukong Technologies Inc. -Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ -#ifndef __EFFECTS_CCGRID_H__ -#define __EFFECTS_CCGRID_H__ - -#include "base/CCRef.h" -#include "base/ccTypes.h" -#include "base/CCDirector.h" - -NS_CC_BEGIN - -class Texture2D; -class Grabber; -class GLProgram; -class Node; - -/** - * @addtogroup _2d - * @{ - */ - -/** Base class for Other grid. -*/ -class CC_DLL GridBase : public Ref -{ -public: - /** create one Grid */ - static GridBase* create(const Size& gridSize, Texture2D *texture, bool flipped); - /** create one Grid */ - static GridBase* create(const Size& gridSize); - /** - Destructor. - * @js NA - * @lua NA - */ - virtual ~GridBase(void); - - /**@{ - Init the Grid base. - @param gridSize the size of the grid. - @param texture The texture used for grab. - @param flipped whether or not the grab texture should be flip by Y or not. - @param rect The effective grid rect. - */ - bool initWithSize(const Size& gridSize); - bool initWithSize(const Size& gridSize, const Rect& rect); - bool initWithSize(const Size& gridSize, Texture2D *texture, bool flipped); - bool initWithSize(const Size& gridSize, Texture2D *texture, bool flipped, const Rect& rect); - - /**@}*/ - /** @{ - Getter and setter of the active state of the grid. - */ - inline bool isActive(void) const { return _active; } - void setActive(bool active); - /**@}*/ - - /** Get number of times that the grid will be reused. */ - inline int getReuseGrid(void) const { return _reuseGrid; } - /** Set number of times that the grid will be reused. */ - inline void setReuseGrid(int reuseGrid) { _reuseGrid = reuseGrid; } - - /** Size of the grid. */ - inline const Size& getGridSize(void) const { return _gridSize; } - /**Set the size of the grid.*/ - inline void setGridSize(const Size& gridSize) { _gridSize = gridSize; } - - /** Pixels between the grids. */ - inline const Vec2& getStep(void) const { return _step; } - /**Get the pixels between the grids.*/ - inline void setStep(const Vec2& step) { _step = step; } - - /** is texture flipped. */ - inline bool isTextureFlipped(void) const { return _isTextureFlipped; } - /**Set the texture flipped or not.*/ - void setTextureFlipped(bool flipped); - - /**@{ - Init and reset the status when render effects by using the grid. - */ - void beforeDraw(void); - void afterDraw(Node *target); - /**@}*/ - - /**@{ - Interface for custom action when before or after draw. - @js NA - */ - virtual void beforeBlit() {} - virtual void afterBlit() {} - /**@}*/ - - /**Interface used to blit the texture with grid to screen.*/ - virtual void blit(void); - /**Interface, Reuse the grid vertices.*/ - virtual void reuse(void); - /**Interface, Calculate the vertices used for the blit.*/ - virtual void calculateVertexPoints(void); - - /**Change projection to 2D for grabbing.*/ - void set2DProjection(void); - - /** - * @brief Set the effect grid rect. - * @param rect The effect grid rect. - */ - void setGridRect(const Rect& rect); - /** - * @brief Get the effect grid rect. - * @return Return the effect grid rect. - */ - inline const Rect& getGridRect() const {return _gridRect;} - -protected: - bool _active; - int _reuseGrid; - Size _gridSize; - Texture2D *_texture; - Vec2 _step; - Grabber *_grabber; - bool _isTextureFlipped; - GLProgram* _shaderProgram; - Director::Projection _directorProjection; - Rect _gridRect; -}; - -/** - Grid3D is a 3D grid implementation. Each vertex has 3 dimensions: x,y,z - */ -class CC_DLL Grid3D : public GridBase -{ -public: - /** create one Grid. */ - static Grid3D* create(const Size& gridSize); - /** create one Grid. */ - static Grid3D* create(const Size& gridSize, const Rect& rect); - /** create one Grid. */ - static Grid3D* create(const Size& gridSize, Texture2D *texture, bool flipped); - /** create one Grid. */ - static Grid3D* create(const Size& gridSize, Texture2D *texture, bool flipped, const Rect& rect); - /** - Constructor. - * @js ctor - */ - Grid3D(); - /** - Destructor. - * @js NA - * @lua NA - */ - ~Grid3D(void); - - /** Returns the vertex at a given position. - * @js NA - * @lua NA - */ - Vec3 getVertex(const Vec2& pos) const; - - /** Returns the original (non-transformed) vertex at a given position. - * @js NA - * @lua NA - */ - Vec3 getOriginalVertex(const Vec2& pos) const; - - /** Sets a new vertex at a given position. - * @lua NA - */ - void setVertex(const Vec2& pos, const Vec3& vertex); - /**@{ - Implementations for interfaces in base class. - */ - virtual void beforeBlit() override; - virtual void afterBlit() override; - virtual void blit() override; - virtual void reuse() override; - virtual void calculateVertexPoints() override; - /**@}*/ - - /**@{ - Getter and Setter for depth test state when blit. - @js NA - */ - void setNeedDepthTestForBlit( bool neededDepthTest) { _needDepthTestForBlit = neededDepthTest; } - bool getNeedDepthTestForBlit() const { return _needDepthTestForBlit; } - /**@}*/ -protected: - GLvoid *_texCoordinates; - GLvoid *_vertices; - GLvoid *_originalVertices; - GLushort *_indices; - bool _needDepthTestForBlit; - bool _oldDepthTestValue; - bool _oldDepthWriteValue; -}; - -/** - TiledGrid3D is a 3D grid implementation. It differs from Grid3D in that - the tiles can be separated from the grid. -*/ -class CC_DLL TiledGrid3D : public GridBase -{ -public: - /** Create one Grid. */ - static TiledGrid3D* create(const Size& gridSize); - /** Create one Grid. */ - static TiledGrid3D* create(const Size& gridSize, const Rect& rect); - /** Create one Grid. */ - static TiledGrid3D* create(const Size& gridSize, Texture2D *texture, bool flipped); - /** Create one Grid. */ - static TiledGrid3D* create(const Size& gridSize, Texture2D *texture, bool flipped, const Rect& rect); - /** - Constructor. - * @js ctor - */ - TiledGrid3D(); - /** - Destructor. - * @js NA - * @lua NA - */ - ~TiledGrid3D(); - - /** Returns the tile at the given position. - * @js NA - * @lua NA - */ - Quad3 getTile(const Vec2& pos) const; - - /** Returns the original tile (untransformed) at the given position. - * @js NA - * @lua NA - */ - Quad3 getOriginalTile(const Vec2& pos) const; - - /** Sets a new tile. - * @lua NA - */ - void setTile(const Vec2& pos, const Quad3& coords); - - /**@{ - Implementations for interfaces in base class. - */ - virtual void blit() override; - virtual void reuse() override; - virtual void calculateVertexPoints() override; - /**@}*/ -protected: - GLvoid *_texCoordinates; - GLvoid *_vertices; - GLvoid *_originalVertices; - GLushort *_indices; -}; - -// end of effects group -/// @} - -NS_CC_END - -#endif // __EFFECTS_CCGRID_H__ - diff --git a/native/cocos/2d/CCLabel.cpp b/native/cocos/2d/CCLabel.cpp deleted file mode 100644 index cd5dd2a325..0000000000 --- a/native/cocos/2d/CCLabel.cpp +++ /dev/null @@ -1,2287 +0,0 @@ -/**************************************************************************** - Copyright (c) 2013 Zynga Inc. - Copyright (c) 2013-2016 Chukong Technologies Inc. - Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd. - - http://www.cocos2d-x.org - - Permission is hereby granted, free of charge, to any person obtaining a copy - of this software and associated documentation files (the "Software"), to deal - in the Software without restriction, including without limitation the rights - to use, copy, modify, merge, publish, distribute, sublicense, and/or sell - copies of the Software, and to permit persons to whom the Software is - furnished to do so, subject to the following conditions: - - The above copyright notice and this permission notice shall be included in - all copies or substantial portions of the Software. - - THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN - THE SOFTWARE. - ****************************************************************************/ - -#include "2d/CCLabel.h" - -#include -#include "2d/CCFont.h" -#include "2d/CCFontAtlasCache.h" -#include "2d/CCFontAtlas.h" -#include "2d/CCSprite.h" -#include "2d/CCSpriteBatchNode.h" -#include "2d/CCDrawNode.h" -#include "base/ccUTF8.h" -#include "platform/CCFileUtils.h" -#include "renderer/CCRenderer.h" -#include "renderer/ccGLStateCache.h" -#include "base/CCDirector.h" -#include "base/CCEventListenerCustom.h" -#include "base/CCEventDispatcher.h" -#include "base/CCEventCustom.h" -#include "2d/CCFontFNT.h" -#include "2d/CCSpriteFrame.h" - -NS_CC_BEGIN - -/** - * LabelLetter used to update the quad in texture atlas without SpriteBatchNode. - */ -class LabelLetter : public Sprite -{ -public: - LabelLetter() - { - _textureAtlas = nullptr; - _letterVisible = true; - } - - static LabelLetter* createWithTexture(Texture2D *texture, const Rect& rect, bool rotated = false) - { - auto letter = new (std::nothrow) LabelLetter(); - if (letter && letter->initWithTexture(texture, rect, rotated)) - { - letter->Sprite::setVisible(false); - letter->autorelease(); - return letter; - } - CC_SAFE_DELETE(letter); - return nullptr; - } - - CREATE_FUNC(LabelLetter); - - virtual void updateTransform() override - { - if (isDirty()) - { - _transformToBatch = getNodeToParentTransform(); - Size &size = _rect.size; - - float x1 = _offsetPosition.x; - float y1 = _offsetPosition.y; - float x2 = x1 + size.width; - float y2 = y1 + size.height; - if (_flippedX) - { - std::swap(x1, x2); - } - if (_flippedY) - { - std::swap(y1, y2); - } - - float x = _transformToBatch.m[12]; - float y = _transformToBatch.m[13]; - - float cr = _transformToBatch.m[0]; - float sr = _transformToBatch.m[1]; - float cr2 = _transformToBatch.m[5]; - float sr2 = -_transformToBatch.m[4]; - float ax = x1 * cr - y1 * sr2 + x; - float ay = x1 * sr + y1 * cr2 + y; - - float bx = x2 * cr - y1 * sr2 + x; - float by = x2 * sr + y1 * cr2 + y; - float cx = x2 * cr - y2 * sr2 + x; - float cy = x2 * sr + y2 * cr2 + y; - float dx = x1 * cr - y2 * sr2 + x; - float dy = x1 * sr + y2 * cr2 + y; - - _quad.bl.vertices.set(SPRITE_RENDER_IN_SUBPIXEL(ax), SPRITE_RENDER_IN_SUBPIXEL(ay), _positionZ); - _quad.br.vertices.set(SPRITE_RENDER_IN_SUBPIXEL(bx), SPRITE_RENDER_IN_SUBPIXEL(by), _positionZ); - _quad.tl.vertices.set(SPRITE_RENDER_IN_SUBPIXEL(dx), SPRITE_RENDER_IN_SUBPIXEL(dy), _positionZ); - _quad.tr.vertices.set(SPRITE_RENDER_IN_SUBPIXEL(cx), SPRITE_RENDER_IN_SUBPIXEL(cy), _positionZ); - - if (_textureAtlas) - { - _textureAtlas->updateQuad(&_quad, _atlasIndex); - } - - _recursiveDirty = false; - setDirty(false); - } - - Node::updateTransform(); - } - - virtual void updateColor() override - { - if (_textureAtlas == nullptr) - { - return; - } - - auto displayedOpacity = _displayedOpacity; - if(!_letterVisible) - { - displayedOpacity = 0.0f; - } - Color4B color4(_displayedColor.r, _displayedColor.g, _displayedColor.b, displayedOpacity); - // special opacity for premultiplied textures - if (_opacityModifyRGB) - { - color4.r *= displayedOpacity / 255.0f; - color4.g *= displayedOpacity / 255.0f; - color4.b *= displayedOpacity / 255.0f; - } - - _quad.bl.colors = color4; - _quad.br.colors = color4; - _quad.tl.colors = color4; - _quad.tr.colors = color4; - - _textureAtlas->updateQuad(&_quad, _atlasIndex); - } - - void setVisible(bool visible) override - { - _letterVisible = visible; - updateColor(); - } - - //LabelLetter doesn't need to draw directly. - void draw(Renderer *renderer, const Mat4 &transform, uint32_t flags) override - { - } - -private: - bool _letterVisible; -}; - -Label* Label::create() -{ - auto ret = new (std::nothrow) Label(); - - if (ret) - { - ret->autorelease(); - } - - return ret; -} - -Label* Label::createWithSystemFont(const std::string& text, const std::string& font, float fontSize, const Size& dimensions /* = Size::ZERO */, TextHAlignment hAlignment /* = TextHAlignment::LEFT */, TextVAlignment vAlignment /* = TextVAlignment::TOP */) -{ - auto ret = new (std::nothrow) Label(); - - if (ret) - { - ret->_hAlignment = hAlignment; - ret->_vAlignment = vAlignment; - ret->setSystemFontName(font); - ret->setSystemFontSize(fontSize); - ret->setDimensions(dimensions.width, dimensions.height); - ret->setString(text); - - ret->autorelease(); - - return ret; - } - - CC_SAFE_DELETE(ret); - return nullptr; -} - -Label* Label::createWithTTF(const std::string& text, const std::string& fontFile, float fontSize, const Size& dimensions /* = Size::ZERO */, TextHAlignment hAlignment /* = TextHAlignment::LEFT */, TextVAlignment vAlignment /* = TextVAlignment::TOP */) -{ - auto ret = new (std::nothrow) Label(); - - if (ret && ret->initWithTTF(text, fontFile, fontSize, dimensions, hAlignment, vAlignment)) - { - ret->autorelease(); - return ret; - } - - CC_SAFE_DELETE(ret); - return nullptr; -} - -Label* Label::createWithTTF(const TTFConfig& ttfConfig, const std::string& text, TextHAlignment hAlignment /* = TextHAlignment::CENTER */, int maxLineWidth /* = 0 */) -{ - auto ret = new (std::nothrow) Label(); - - if (ret && ret->initWithTTF(ttfConfig, text, hAlignment, maxLineWidth)) - { - ret->autorelease(); - return ret; - } - - CC_SAFE_DELETE(ret); - return nullptr; -} - -Label* Label::createWithBMFont(const std::string& fntDataString, - const std::string& text, - SpriteFrame* spriteFrame, - const TextHAlignment& hAlignment /* = TextHAlignment::LEFT */, - int maxLineWidth /* = 0 */, - const Vec2& imageOffset /* = Vec2::ZERO */) -{ - spriteFrame->autorelease(); //FIXME: Why to autorelease sprite frame here? - - auto ret = new (std::nothrow) Label(); - if (ret != nullptr) - { - ret->_hAlignment = hAlignment; - - if (ret->setBMFontFilePath(fntDataString, spriteFrame, imageOffset)) - { - ret->setMaxLineWidth(maxLineWidth); - ret->setString(text); - ret->autorelease(); - return ret; - } - } - - delete ret; - return nullptr; -} - -Label* Label::createWithCharMap(const std::string& plistFile) -{ - auto ret = new (std::nothrow) Label(); - - if (ret && ret->setCharMap(plistFile)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -Label* Label::createWithCharMap(Texture2D* texture, int itemWidth, int itemHeight, int startCharMap) -{ - auto ret = new (std::nothrow) Label(); - - if (ret && ret->setCharMap(texture,itemWidth,itemHeight,startCharMap)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -Label* Label::createWithCharMap(const std::string& charMapFile, int itemWidth, int itemHeight, int startCharMap) -{ - auto ret = new (std::nothrow) Label(); - - if (ret && ret->setCharMap(charMapFile,itemWidth,itemHeight,startCharMap)) - { - ret->autorelease(); - return ret; - } - - delete ret; - return nullptr; -} - -bool Label::setCharMap(const std::string& plistFile) -{ - auto newAtlas = FontAtlasCache::getFontAtlasCharMap(plistFile); - - if (!newAtlas) - { - reset(); - return false; - } - - _currentLabelType = LabelType::CHARMAP; - setFontAtlas(newAtlas); - - return true; -} - -bool Label::initWithTTF(const std::string& text, const std::string& fontFilePath, float fontSize, - const Size& dimensions, TextHAlignment hAlignment, TextVAlignment vAlignment) -{ - _hAlignment = hAlignment; - _vAlignment = vAlignment; - if (FileUtils::getInstance()->isFileExist(fontFilePath)) - { - TTFConfig ttfConfig(fontFilePath, fontSize, GlyphCollection::DYNAMIC); - if (setTTFConfig(ttfConfig)) - { - setDimensions(dimensions.width, dimensions.height); - setString(text); - } - return true; - } - return false; -} - -bool Label::initWithTTF(const TTFConfig& ttfConfig, const std::string& text, TextHAlignment hAlignment, int maxLineWidth) -{ - _hAlignment = hAlignment; - if (FileUtils::getInstance()->isFileExist(ttfConfig.fontFilePath) && setTTFConfig(ttfConfig)) - { - setMaxLineWidth(maxLineWidth); - setString(text); - return true; - } - return false; -} - -bool Label::setCharMap(Texture2D* texture, int itemWidth, int itemHeight, int startCharMap) -{ - auto newAtlas = FontAtlasCache::getFontAtlasCharMap(texture,itemWidth,itemHeight,startCharMap); - - if (!newAtlas) - { - reset(); - return false; - } - - _currentLabelType = LabelType::CHARMAP; - setFontAtlas(newAtlas); - - return true; -} - -bool Label::setCharMap(const std::string& charMapFile, int itemWidth, int itemHeight, int startCharMap) -{ - auto newAtlas = FontAtlasCache::getFontAtlasCharMap(charMapFile,itemWidth,itemHeight,startCharMap); - - if (!newAtlas) - { - reset(); - return false; - } - - _currentLabelType = LabelType::CHARMAP; - setFontAtlas(newAtlas); - - return true; -} - -Label::Label() -: _systemFont("Helvetica") -, _textSprite(nullptr) -, _shadowNode(nullptr) -, _fontAtlas(nullptr) -, _horizontalKernings(nullptr) -, _purgeTextureListener(nullptr) -, _resetTextureListener(nullptr) -#if CC_LABEL_DEBUG_DRAW -, _debugDrawNode(nullptr) -#endif -, _fntSpriteFrame(nullptr) -, _underlineNode(nullptr) -, _reusedLetter(nullptr) -, _effectColorF(Color4F::BLACK) -, _textColor(Color4B::WHITE) -, _textColorF(Color4F::WHITE) -, _uniformEffectColor(0) -, _uniformTextColor(0) -, _shadowOpacity(0) -, _blendFunc(BlendFunc::ALPHA_PREMULTIPLIED) -, _numberOfLines(0) -, _lengthOfString(0) -, _outlineSize(0.0f) -, _systemFontSize(12.0f) -, _lineHeight(0.0f) -, _lineSpacing(0.0f) -, _additionalKerning(0.0f) -, _maxLineWidth(0.0f) -, _labelWidth(0.0f) -, _labelHeight(0.0f) -, _textDesiredHeight(0.0f) -, _letterOffsetY(0.0f) -, _tailoredTopY(0.0f) -, _tailoredBottomY(0.0f) -, _shadowBlurRadius(0.0f) -, _bmFontSize(-1.0f) -, _bmfontScale(1.0f) -, _originalFontSize(0.0f) -, _currLabelEffect(LabelEffect::NORMAL) -, _currentLabelType(LabelType::STRING_TEXTURE) -, _overflow(Overflow::NONE) -, _hAlignment(TextHAlignment::LEFT) -, _vAlignment(TextVAlignment::TOP) -, _systemFontDirty(false) -, _contentDirty(false) -, _lineBreakWithoutSpaces(false) -, _boldEnabled(false) -, _italicsEnabled(false) -, _strikethroughEnabled(false) -, _insideBounds(true) -, _isOpacityModifyRGB(false) -, _enableWrap(true) -, _clipEnabled(false) -, _blendFuncDirty(false) -, _useDistanceField(false) -, _useA8Shader(false) -, _shadowDirty(false) -, _shadowEnabled(false) -{ - setAnchorPoint(Vec2::ANCHOR_MIDDLE); - setColor(Color3B::WHITE); - -#if CC_LABEL_DEBUG_DRAW - _debugDrawNode = DrawNode::create(); - addChild(_debugDrawNode); -#endif - - _purgeTextureListener = EventListenerCustom::create(FontAtlas::CMD_PURGE_FONTATLAS, [this](EventCustom* event){ - if (_fontAtlas && _currentLabelType == LabelType::TTF && event->getUserData() == _fontAtlas) - { - for (auto&& it : _letters) - { - it.second->setTexture(nullptr); - } - _batchNodes.clear(); - - if (_fontAtlas) - { - FontAtlasCache::releaseFontAtlas(_fontAtlas); - } - } - }); - _eventDispatcher->addEventListenerWithFixedPriority(_purgeTextureListener, 1); - - _resetTextureListener = EventListenerCustom::create(FontAtlas::CMD_RESET_FONTATLAS, [this](EventCustom* event){ - if (_fontAtlas && _currentLabelType == LabelType::TTF && event->getUserData() == _fontAtlas) - { - _fontAtlas = nullptr; - this->setTTFConfig(_fontConfig); - for (auto&& it : _letters) - { - getLetter(it.first); - } - } - }); - _eventDispatcher->addEventListenerWithFixedPriority(_resetTextureListener, 2); -} - -Label::~Label() -{ - delete [] _horizontalKernings; - _horizontalKernings = nullptr; - - if (_fontAtlas != nullptr) - { -// Node::removeAllChildrenWithCleanup(true); - CC_SAFE_RELEASE_NULL(_reusedLetter); - _batchNodes.clear(); - FontAtlasCache::releaseFontAtlas(_fontAtlas); - _fontAtlas = nullptr; - } - _eventDispatcher->removeEventListener(_purgeTextureListener); - _purgeTextureListener = nullptr; - _eventDispatcher->removeEventListener(_resetTextureListener); - _resetTextureListener = nullptr; - - CC_SAFE_RELEASE_NULL(_textSprite); - CC_SAFE_RELEASE_NULL(_shadowNode); - CC_SAFE_RELEASE_NULL(_fntSpriteFrame); -} - -void Label::reset() -{ - CC_SAFE_RELEASE_NULL(_textSprite); - CC_SAFE_RELEASE_NULL(_shadowNode); - Node::removeAllChildrenWithCleanup(true); - CC_SAFE_RELEASE_NULL(_reusedLetter); - - _letters.clear(); - _batchNodes.clear(); - _lettersInfo.clear(); - if (_fontAtlas) - { - FontAtlasCache::releaseFontAtlas(_fontAtlas); - _fontAtlas = nullptr; - } - - _currentLabelType = LabelType::STRING_TEXTURE; - _currLabelEffect = LabelEffect::NORMAL; - _contentDirty = false; - _numberOfLines = 0; - _lengthOfString = 0; - _utf16Text.clear(); - _utf8Text.clear(); - - TTFConfig temp; - _fontConfig = temp; - _outlineSize = 0.f; - _bmFontPath = ""; - _systemFontDirty = false; - _systemFont = "Helvetica"; - _systemFontSize = 12; - - if (_horizontalKernings) - { - delete[] _horizontalKernings; - _horizontalKernings = nullptr; - } - _additionalKerning = 0.f; - _lineHeight = 0.f; - _lineSpacing = 0.f; - _maxLineWidth = 0.f; - _labelDimensions.width = 0.f; - _labelDimensions.height = 0.f; - _labelWidth = 0.f; - _labelHeight = 0.f; - _lineBreakWithoutSpaces = false; - _hAlignment = TextHAlignment::LEFT; - _vAlignment = TextVAlignment::TOP; - - _effectColorF = Color4F::BLACK; - _textColor = Color4B::WHITE; - _textColorF = Color4F::WHITE; - setColor(Color3B::WHITE); - - _shadowDirty = false; - _shadowEnabled = false; - _shadowBlurRadius = 0.f; - - _useDistanceField = false; - _useA8Shader = false; - _clipEnabled = false; - _blendFuncDirty = false; - _blendFunc = BlendFunc::ALPHA_PREMULTIPLIED; - _isOpacityModifyRGB = false; - _insideBounds = true; - _enableWrap = true; - _bmFontSize = -1; - _bmfontScale = 1.0f; - _overflow = Overflow::NONE; - _originalFontSize = 0.0f; - _boldEnabled = false; - if (_underlineNode) - { - removeChild(_underlineNode); - _underlineNode = nullptr; - } - _strikethroughEnabled = false; - setRotationSkewX(0); // reverse italics -} - -// ETC1 ALPHA supports, for LabelType::BMFONT & LabelType::CHARMAP -static Texture2D* _getTexture(Label* label) -{ - struct _FontAtlasPub : public FontAtlas - { - Texture2D* getTexture() - { - if (!_atlasTextures.empty()) - return _atlasTextures.begin()->second; - return nullptr; - } - }; - - auto fontAtlas = label->getFontAtlas(); - Texture2D* texture = nullptr; - if (fontAtlas != nullptr) - texture = ((_FontAtlasPub*)(fontAtlas))->getTexture(); - return texture; -} -void Label::updateShaderProgram() -{ - switch (_currLabelEffect) - { - case cocos2d::LabelEffect::NORMAL: - if (_useDistanceField) - setGLProgramState(GLProgramState::getOrCreateWithGLProgramName(GLProgram::SHADER_NAME_LABEL_DISTANCEFIELD_NORMAL)); - else if (_useA8Shader) - setGLProgramState(GLProgramState::getOrCreateWithGLProgramName(GLProgram::SHADER_NAME_LABEL_NORMAL)); - else if (_shadowEnabled) - setGLProgramState(GLProgramState::getOrCreateWithGLProgramName(GLProgram::SHADER_NAME_POSITION_TEXTURE_COLOR)); - else - setGLProgramState(GLProgramState::getOrCreateWithGLProgramName(GLProgram::SHADER_NAME_POSITION_TEXTURE_COLOR_NO_MVP)); - - break; - case cocos2d::LabelEffect::OUTLINE: - setGLProgramState(GLProgramState::getOrCreateWithGLProgramName(GLProgram::SHADER_NAME_LABEL_OUTLINE)); - _uniformEffectColor = glGetUniformLocation(getGLProgram()->getProgram(), "u_effectColor"); - break; - case cocos2d::LabelEffect::GLOW: - if (_useDistanceField) - { - setGLProgramState(GLProgramState::getOrCreateWithGLProgramName(GLProgram::SHADER_NAME_LABEL_DISTANCEFIELD_GLOW)); - _uniformEffectColor = glGetUniformLocation(getGLProgram()->getProgram(), "u_effectColor"); - } - break; - default: - return; - } - - _uniformTextColor = glGetUniformLocation(getGLProgram()->getProgram(), "u_textColor"); -} - -void Label::setFontAtlas(FontAtlas* atlas,bool distanceFieldEnabled /* = false */, bool useA8Shader /* = false */) -{ - if(atlas) - { - _systemFontDirty = false; - } - - if (atlas == _fontAtlas) - { - FontAtlasCache::releaseFontAtlas(atlas); - return; - } - - if (_fontAtlas) - { - _batchNodes.clear(); - FontAtlasCache::releaseFontAtlas(_fontAtlas); - _fontAtlas = nullptr; - } - - _fontAtlas = atlas; - if (_reusedLetter == nullptr) - { - _reusedLetter = Sprite::create(); - _reusedLetter->setOpacityModifyRGB(_isOpacityModifyRGB); - _reusedLetter->retain(); - _reusedLetter->setAnchorPoint(Vec2::ANCHOR_TOP_LEFT); - } - - if (_fontAtlas) - { - _lineHeight = _fontAtlas->getLineHeight(); - _contentDirty = true; - _systemFontDirty = false; - } - _useDistanceField = distanceFieldEnabled; - _useA8Shader = useA8Shader; - - if (_currentLabelType != LabelType::TTF) - { - _currLabelEffect = LabelEffect::NORMAL; - updateShaderProgram(); - } -} - -bool Label::setTTFConfig(const TTFConfig& ttfConfig) -{ - _originalFontSize = ttfConfig.fontSize; - return setTTFConfigInternal(ttfConfig); -} - -bool Label::setBMFontFilePath(const std::string& fntDataString, - SpriteFrame* spriteFrame, - const Vec2& imageOffset, - float fontSize) -{ - FontAtlas *newAtlas = FontAtlasCache::getFontAtlasFNT(fntDataString, - spriteFrame, - imageOffset); - - if (!newAtlas) - { - reset(); - return false; - } - - //assign the default fontSize - if (std::abs(fontSize) < FLT_EPSILON) { - FontFNT *bmFont = (FontFNT*)newAtlas->getFont(); - if (bmFont) { - float originalFontSize = bmFont->getOriginalFontSize(); - _bmFontSize = originalFontSize / CC_CONTENT_SCALE_FACTOR(); - } - } - - if(fontSize > 0.0f){ - _bmFontSize = fontSize; - } - - _bmFontPath = fntDataString; - _fntSpriteFrame = spriteFrame; - CC_SAFE_RETAIN(_fntSpriteFrame); - - _currentLabelType = LabelType::BMFONT; - setFontAtlas(newAtlas); - - return true; -} - -void Label::setString(const std::string& text) -{ - if (text.compare(_utf8Text)) - { - _utf8Text = text; - _contentDirty = true; - - std::u16string utf16String; - if (StringUtils::UTF8ToUTF16(_utf8Text, utf16String)) - { - _utf16Text = utf16String; - } - } -} - -void Label::setAlignment(TextHAlignment hAlignment,TextVAlignment vAlignment) -{ - if (hAlignment != _hAlignment || vAlignment != _vAlignment) - { - _hAlignment = hAlignment; - _vAlignment = vAlignment; - - _contentDirty = true; - } -} - -void Label::setMaxLineWidth(float maxLineWidth) -{ - if (_labelWidth == 0 && _maxLineWidth != maxLineWidth) - { - _maxLineWidth = maxLineWidth; - _contentDirty = true; - } -} - -void Label::setDimensions(float width, float height) -{ - if(_overflow == Overflow::RESIZE_HEIGHT){ - height = 0; - } - - if (height != _labelHeight || width != _labelWidth) - { - _labelWidth = width; - _labelHeight = height; - _labelDimensions.width = width; - _labelDimensions.height = height; - - _maxLineWidth = width; - _contentDirty = true; - - if(_overflow == Overflow::SHRINK){ - if (_originalFontSize > 0) { - this->restoreFontSize(); - } - } - } -} - -void Label::restoreFontSize() -{ - if(_currentLabelType == LabelType::TTF){ - auto ttfConfig = this->getTTFConfig(); - ttfConfig.fontSize = _originalFontSize; - this->setTTFConfigInternal(ttfConfig); - }else if(_currentLabelType == LabelType::BMFONT){ - this->setBMFontSizeInternal(_originalFontSize); - }else if(_currentLabelType == LabelType::STRING_TEXTURE){ - this->setSystemFontSize(_originalFontSize); - } -} - -void Label::setLineBreakWithoutSpace(bool breakWithoutSpace) -{ - if (breakWithoutSpace != _lineBreakWithoutSpaces) - { - _lineBreakWithoutSpaces = breakWithoutSpace; - _contentDirty = true; - } -} - -void Label::updateLabelLetters() -{ - if (!_letters.empty()) - { - Rect uvRect; - LabelLetter* letterSprite; - int letterIndex; - - for (auto it = _letters.begin(); it != _letters.end();) - { - letterIndex = it->first; - letterSprite = (LabelLetter*)it->second; - - if (letterIndex >= _lengthOfString) - { - Node::removeChild(letterSprite, true); - it = _letters.erase(it); - } - else - { - auto& letterInfo = _lettersInfo[letterIndex]; - auto& letterDef = _fontAtlas->_letterDefinitions[letterInfo.utf16Char]; - uvRect.size.height = letterDef.height; - uvRect.size.width = letterDef.width; - uvRect.origin.x = letterDef.U; - uvRect.origin.y = letterDef.V; - - auto batchNode = _batchNodes.at(letterDef.textureID); - letterSprite->setTextureAtlas(batchNode->getTextureAtlas()); - letterSprite->setTexture(_fontAtlas->getTexture(letterDef.textureID)); - if (letterDef.width <= 0.f || letterDef.height <= 0.f) - { - letterSprite->setTextureAtlas(nullptr); - } - else - { - letterSprite->setTextureRect(uvRect, false, uvRect.size); - letterSprite->setTextureAtlas(_batchNodes.at(letterDef.textureID)->getTextureAtlas()); - letterSprite->setAtlasIndex(_lettersInfo[letterIndex].atlasIndex); - } - - auto px = letterInfo.positionX + letterDef.width / 2 + _linesOffsetX[letterInfo.lineIndex]; - auto py = letterInfo.positionY - letterDef.height / 2 + _letterOffsetY; - letterSprite->setPosition(px, py); - - this->updateLetterSpriteScale(letterSprite); - ++it; - } - } - } -} - -bool Label::alignText() -{ - if (_fontAtlas == nullptr || _utf16Text.empty()) - { - if(_overflow == Overflow::NONE) { - setContentSize(Size::ZERO); - } - return true; - } - - bool ret = true; - do { - _fontAtlas->prepareLetterDefinitions(_utf16Text); - auto& textures = _fontAtlas->getTextures(); - if (textures.size() > static_cast(_batchNodes.size())) - { - for (auto index = static_cast(_batchNodes.size()); index < textures.size(); ++index) - { - auto batchNode = SpriteBatchNode::createWithTexture(textures.at(index)); - if (batchNode) - { - _isOpacityModifyRGB = batchNode->getTexture()->hasPremultipliedAlpha(); - _blendFunc = batchNode->getBlendFunc(); - batchNode->setAnchorPoint(Vec2::ANCHOR_TOP_LEFT); - batchNode->setPosition(Vec2::ZERO); - _batchNodes.pushBack(batchNode); - } - } - } - if (_batchNodes.empty()) - { - return true; - } - _reusedLetter->setBatchNode(_batchNodes.at(0)); - - _lengthOfString = 0; - _textDesiredHeight = 0.f; - _linesWidth.clear(); - if (_maxLineWidth > 0.f && !_lineBreakWithoutSpaces) - { - multilineTextWrapByWord(); - } - else - { - multilineTextWrapByChar(); - } - computeAlignmentOffset(); - - if(_overflow == Overflow::SHRINK){ - float fontSize = this->getRenderingFontSize(); - - if(fontSize > 0 && isVerticalClamp()){ - this->shrinkLabelToContentSize(CC_CALLBACK_0(Label::isVerticalClamp, this)); - } - } - - if(!updateQuads()){ - ret = false; - if(_overflow == Overflow::SHRINK){ - this->shrinkLabelToContentSize(CC_CALLBACK_0(Label::isHorizontalClamp, this)); - } - break; - } - - updateLabelLetters(); - - updateColor(); - }while (0); - - return ret; -} - -bool Label::computeHorizontalKernings(const std::u16string& stringToRender) -{ - if (_horizontalKernings) - { - delete [] _horizontalKernings; - _horizontalKernings = nullptr; - } - - int letterCount = 0; - _horizontalKernings = _fontAtlas->getFont()->getHorizontalKerningForTextUTF16(stringToRender, letterCount); - - if(!_horizontalKernings) - return false; - else - return true; -} - -bool Label::isHorizontalClamped(float letterPositionX, int lineIndex) -{ - auto wordWidth = this->_linesWidth[lineIndex]; - bool letterOverClamp = (letterPositionX > _contentSize.width || letterPositionX < 0); - if (!_enableWrap) { - return letterOverClamp; - }else{ - return (wordWidth > this->_contentSize.width && letterOverClamp); - } -} - -bool Label::updateQuads() -{ - bool ret = true; - for (auto&& batchNode : _batchNodes) - { - batchNode->getTextureAtlas()->removeAllQuads(); - } - - bool letterClamp = false; - for (int ctr = 0; ctr < _lengthOfString; ++ctr) - { - if (_lettersInfo[ctr].valid) - { - auto& letterDef = _fontAtlas->_letterDefinitions[_lettersInfo[ctr].utf16Char]; - - _reusedRect.size.height = letterDef.height; - _reusedRect.size.width = letterDef.width; - _reusedRect.origin.x = letterDef.U; - _reusedRect.origin.y = letterDef.V; - - auto py = _lettersInfo[ctr].positionY + _letterOffsetY; - if (_labelHeight > 0.f) { - if (py > _tailoredTopY) - { - auto clipTop = py - _tailoredTopY; - _reusedRect.origin.y += clipTop; - _reusedRect.size.height -= clipTop; - py -= clipTop; - } - if (py - letterDef.height * _bmfontScale < _tailoredBottomY) - { - _reusedRect.size.height = (py < _tailoredBottomY) ? 0.f : (py - _tailoredBottomY); - } - } - - auto lineIndex = _lettersInfo[ctr].lineIndex; - auto px = _lettersInfo[ctr].positionX + letterDef.width/2 * _bmfontScale + _linesOffsetX[lineIndex]; - - if(_labelWidth > 0.f){ - if (this->isHorizontalClamped(px, lineIndex)) { - if(_overflow == Overflow::CLAMP){ - _reusedRect.size.width = 0; - }else if(_overflow == Overflow::SHRINK){ - if (_contentSize.width > letterDef.width) { - letterClamp = true; - ret = false; - break; - }else{ - _reusedRect.size.width = 0; - } - - } - } - } - - - if (_reusedRect.size.height > 0.f && _reusedRect.size.width > 0.f) - { - if(_currentLabelType == Label::LabelType::BMFONT) { - auto isRotated = _fntSpriteFrame->isRotated(); - auto spriteFrameRect = _fntSpriteFrame->getRect(); - auto originalSize = _fntSpriteFrame->getOriginalSize(); - auto offset = _fntSpriteFrame->getOffset(); - auto trimmedLeft = offset.x + (originalSize.width - spriteFrameRect.size.width) / 2; - auto trimmedTop = offset.y - (originalSize.height - spriteFrameRect.size.height) / 2; - - if (!isRotated) { - _reusedRect.origin.x += spriteFrameRect.origin.x - trimmedLeft; - _reusedRect.origin.y += spriteFrameRect.origin.y + trimmedTop; - } else { - auto originalX = _reusedRect.origin.x; - _reusedRect.origin.x = spriteFrameRect.origin.x + spriteFrameRect.size.height - _reusedRect.origin.y - _reusedRect.size.height - trimmedTop; - _reusedRect.origin.y = originalX + spriteFrameRect.origin.y - trimmedLeft; - if(_reusedRect.origin.y < 0) { - _reusedRect.size.height += trimmedTop; - } - } - - - _reusedLetter->setTextureRect(_reusedRect, isRotated, _reusedRect.size); - } else { - _reusedLetter->setTextureRect(_reusedRect, false, _reusedRect.size); - - } - - - - - float letterPositionX = _lettersInfo[ctr].positionX + _linesOffsetX[_lettersInfo[ctr].lineIndex]; - _reusedLetter->setPosition(letterPositionX, py); - auto index = static_cast(_batchNodes.at(letterDef.textureID)->getTextureAtlas()->getTotalQuads()); - _lettersInfo[ctr].atlasIndex = index; - - this->updateLetterSpriteScale(_reusedLetter); - - _batchNodes.at(letterDef.textureID)->insertQuadFromSprite(_reusedLetter, index); - } - } - } - - - return ret; -} - -bool Label::setTTFConfigInternal(const TTFConfig& ttfConfig) -{ - FontAtlas *newAtlas = FontAtlasCache::getFontAtlasTTF(&ttfConfig); - - if (!newAtlas) - { - reset(); - return false; - } - - _currentLabelType = LabelType::TTF; - setFontAtlas(newAtlas,ttfConfig.distanceFieldEnabled,true); - - _fontConfig = ttfConfig; - - if (_fontConfig.outlineSize > 0) - { - _fontConfig.distanceFieldEnabled = false; - _useDistanceField = false; - _useA8Shader = false; - _currLabelEffect = LabelEffect::OUTLINE; - updateShaderProgram(); - } - else - { - _currLabelEffect = LabelEffect::NORMAL; - updateShaderProgram(); - } - - if (_fontConfig.italics) - this->enableItalics(); - if (_fontConfig.bold) - this->enableBold(); - if (_fontConfig.underline) - this->enableUnderline(); - if (_fontConfig.strikethrough) - this->enableStrikethrough(); - - return true; -} - -void Label::setBMFontSizeInternal(float fontSize) -{ - if(_currentLabelType == LabelType::BMFONT){ - this->setBMFontFilePath(_bmFontPath, - _fntSpriteFrame, - Vec2::ZERO, fontSize); - _contentDirty = true; - } -} - -void Label::scaleFontSizeDown(float fontSize) -{ - bool shouldUpdateContent = true; - if(_currentLabelType == LabelType::TTF){ - auto ttfConfig = this->getTTFConfig(); - ttfConfig.fontSize = fontSize; - this->setTTFConfigInternal(ttfConfig); - }else if(_currentLabelType == LabelType::BMFONT){ - if (std::abs(fontSize) < FLT_EPSILON) { - fontSize = 0.1f; - shouldUpdateContent = false; - } - this->setBMFontSizeInternal(fontSize); - }else if (_currentLabelType == LabelType::STRING_TEXTURE){ - this->setSystemFontSize(fontSize); - } - - if (shouldUpdateContent) { - this->updateContent(); - } -} - -void Label::enableGlow(const Color4B& glowColor) -{ - if (_currentLabelType == LabelType::TTF) - { - if (_fontConfig.distanceFieldEnabled == false) - { - auto config = _fontConfig; - config.outlineSize = 0; - config.distanceFieldEnabled = true; - setTTFConfig(config); - _contentDirty = true; - } - _currLabelEffect = LabelEffect::GLOW; - _effectColorF.r = glowColor.r / 255.0f; - _effectColorF.g = glowColor.g / 255.0f; - _effectColorF.b = glowColor.b / 255.0f; - _effectColorF.a = glowColor.a / 255.0f; - updateShaderProgram(); - } -} - -void Label::enableOutline(const Color4B& outlineColor,int outlineSize /* = -1 */) -{ - CCASSERT(_currentLabelType == LabelType::STRING_TEXTURE - || _currentLabelType == LabelType::TTF, "Only supported system font and TTF!"); - - if (outlineSize > 0 || _currLabelEffect == LabelEffect::OUTLINE) - { - if (_currentLabelType == LabelType::TTF) - { - _effectColorF.r = outlineColor.r / 255.0f; - _effectColorF.g = outlineColor.g / 255.0f; - _effectColorF.b = outlineColor.b / 255.0f; - _effectColorF.a = outlineColor.a / 255.0f; - - if (outlineSize > 0 && _fontConfig.outlineSize != outlineSize) - { - _fontConfig.outlineSize = outlineSize; - setTTFConfig(_fontConfig); - } - } - else if (_effectColorF != outlineColor || _outlineSize != outlineSize || _currLabelEffect != LabelEffect::OUTLINE) - { - _effectColorF.r = outlineColor.r / 255.f; - _effectColorF.g = outlineColor.g / 255.f; - _effectColorF.b = outlineColor.b / 255.f; - _effectColorF.a = outlineColor.a / 255.f; - _currLabelEffect = LabelEffect::OUTLINE; - _contentDirty = true; - } - _outlineSize = outlineSize; - } -} - -void Label::enableShadow(const Color4B& shadowColor /* = Color4B::BLACK */,const Size &offset /* = Size(2 ,-2)*/, int blurRadius /* = 0 */) -{ - _shadowEnabled = true; - _shadowDirty = true; - - _shadowOffset.width = offset.width; - _shadowOffset.height = offset.height; - //TODO: support blur for shadow - - _shadowColor3B.r = shadowColor.r; - _shadowColor3B.g = shadowColor.g; - _shadowColor3B.b = shadowColor.b; - _shadowOpacity = shadowColor.a; - - if (!_systemFontDirty && !_contentDirty && _textSprite) - { - auto fontDef = _getFontDefinition(); - if (_shadowNode) - { - if (shadowColor != _shadowColor4F) - { - _shadowNode->release(); - _shadowNode = nullptr; - createShadowSpriteForSystemFont(fontDef); - } - else - { - _shadowNode->setPosition(_shadowOffset.width, _shadowOffset.height); - } - } - else - { - createShadowSpriteForSystemFont(fontDef); - } - } - - _shadowColor4F.r = shadowColor.r / 255.0f; - _shadowColor4F.g = shadowColor.g / 255.0f; - _shadowColor4F.b = shadowColor.b / 255.0f; - _shadowColor4F.a = shadowColor.a / 255.0f; - - if (_currentLabelType == LabelType::BMFONT || _currentLabelType == LabelType::CHARMAP) - { - setGLProgramState(GLProgramState::getOrCreateWithGLProgramName(_shadowEnabled ? GLProgram::SHADER_NAME_POSITION_TEXTURE_COLOR : GLProgram::SHADER_NAME_POSITION_TEXTURE_COLOR_NO_MVP)); - } -} - -void Label::enableItalics() -{ - setRotationSkewX(12); - _italicsEnabled = true; -} - -void Label::enableBold() -{ - if (!_boldEnabled && _currentLabelType != LabelType::STRING_TEXTURE) - { - // bold is implemented with outline - enableShadow(Color4B::WHITE, Size(0.9f, 0), 0); - // add one to kerning - setAdditionalKerning(_additionalKerning+1); - } - _boldEnabled = true; -} - -void Label::enableUnderline() -{ - // remove it, just in case to prevent adding two or more - if (!_underlineNode) - { - _underlineNode = DrawNode::create(); - addChild(_underlineNode, 100000); - _contentDirty = true; - } -} - -void Label::enableStrikethrough() -{ - if (!_strikethroughEnabled) - { - enableUnderline(); - _strikethroughEnabled = true; - } -} - -void Label::disableEffect() -{ - disableEffect(LabelEffect::ALL); -} - -void Label::disableEffect(LabelEffect effect) -{ - switch (effect) - { - case cocos2d::LabelEffect::NORMAL: - break; - case cocos2d::LabelEffect::OUTLINE: - if (_currLabelEffect == LabelEffect::OUTLINE) - { - if (_currentLabelType == LabelType::TTF) - { - _fontConfig.outlineSize = 0; - setTTFConfig(_fontConfig); - } - _currLabelEffect = LabelEffect::NORMAL; - _outlineSize = 0; - _contentDirty = true; - } - break; - case cocos2d::LabelEffect::SHADOW: - if (_shadowEnabled) - { - _shadowEnabled = false; - CC_SAFE_RELEASE_NULL(_shadowNode); - updateShaderProgram(); - } - break; - case cocos2d::LabelEffect::GLOW: - if (_currLabelEffect == LabelEffect::GLOW) - { - _currLabelEffect = LabelEffect::NORMAL; - updateShaderProgram(); - } - break; - case cocos2d::LabelEffect::ITALICS: - setRotationSkewX(0); - _italicsEnabled = false; - break; - case cocos2d::LabelEffect::BOLD: - if (_boldEnabled) - { - _boldEnabled = false; - _additionalKerning -= 1; - disableEffect(LabelEffect::SHADOW); - } - break; - case cocos2d::LabelEffect::UNDERLINE: - if (_underlineNode) { - removeChild(_underlineNode); - _underlineNode = nullptr; - } - break; - case cocos2d::LabelEffect::STRIKETHROUGH: - _strikethroughEnabled = false; - // since it is based on underline, disable it as well - disableEffect(LabelEffect::UNDERLINE); - break; - case LabelEffect::ALL: - { - disableEffect(LabelEffect::SHADOW); - disableEffect(LabelEffect::GLOW); - disableEffect(LabelEffect::OUTLINE); - disableEffect(LabelEffect::ITALICS); - disableEffect(LabelEffect::BOLD); - disableEffect(LabelEffect::UNDERLINE); - disableEffect(LabelEffect::STRIKETHROUGH); - } - break; - default: - break; - } -} - -void Label::createSpriteForSystemFont(const FontDefinition& fontDef) -{ - _currentLabelType = LabelType::STRING_TEXTURE; - - auto texture = new (std::nothrow) Texture2D; - texture->initWithString(_utf8Text.c_str(), fontDef); - - _textSprite = Sprite::createWithTexture(texture); - _textSprite->setGlobalZOrder(getGlobalZOrder()); - _textSprite->setAnchorPoint(Vec2::ANCHOR_BOTTOM_LEFT); - - auto newSize = _textSprite->getContentSize(); - if(_overflow == Overflow::RESIZE_HEIGHT) { - this->setContentSize(Size(_contentSize.width, newSize.height)); - } else { - this->setContentSize(newSize); - } - - texture->release(); - if (_blendFuncDirty) - { - _textSprite->setBlendFunc(_blendFunc); - } - - _textSprite->retain(); - _textSprite->updateDisplayedColor(_displayedColor); - _textSprite->updateDisplayedOpacity(_displayedOpacity); -} - -void Label::createShadowSpriteForSystemFont(const FontDefinition& fontDef) -{ - if (!fontDef._stroke._strokeEnabled && fontDef._fontFillColor == _shadowColor3B - && (fontDef._fontAlpha == _shadowOpacity)) - { - _shadowNode = Sprite::createWithTexture(_textSprite->getTexture()); - } - else - { - FontDefinition shadowFontDefinition = fontDef; - shadowFontDefinition._fontFillColor.r = _shadowColor3B.r; - shadowFontDefinition._fontFillColor.g = _shadowColor3B.g; - shadowFontDefinition._fontFillColor.b = _shadowColor3B.b; - shadowFontDefinition._fontAlpha = _shadowOpacity; - - shadowFontDefinition._stroke._strokeColor = shadowFontDefinition._fontFillColor; - shadowFontDefinition._stroke._strokeAlpha = shadowFontDefinition._fontAlpha; - - auto texture = new (std::nothrow) Texture2D; - texture->initWithString(_utf8Text.c_str(), shadowFontDefinition); - _shadowNode = Sprite::createWithTexture(texture); - texture->release(); - } - - if (_shadowNode) - { - if (_blendFuncDirty) - { - _shadowNode->setBlendFunc(_blendFunc); - } - _shadowNode->setGlobalZOrder(getGlobalZOrder()); - _shadowNode->setAnchorPoint(Vec2::ANCHOR_BOTTOM_LEFT); - _shadowNode->setPosition(_shadowOffset.width, _shadowOffset.height); - - _shadowNode->retain(); - _shadowNode->updateDisplayedColor(_displayedColor); - _shadowNode->updateDisplayedOpacity(_displayedOpacity); - } -} - -void Label::setFontDefinition(const FontDefinition& textDefinition) -{ - _systemFont = textDefinition._fontName; - _systemFontSize = textDefinition._fontSize; - _hAlignment = textDefinition._alignment; - _vAlignment = textDefinition._vertAlignment; - setDimensions(textDefinition._dimensions.width, textDefinition._dimensions.height); - Color4B textColor = Color4B(textDefinition._fontFillColor); - textColor.a = textDefinition._fontAlpha; - setTextColor(textColor); - -#if (CC_TARGET_PLATFORM != CC_PLATFORM_ANDROID) && (CC_TARGET_PLATFORM != CC_PLATFORM_IOS) - if (textDefinition._stroke._strokeEnabled) - { - CCLOGERROR("Stroke Currently only supported on iOS and Android!"); - } - _outlineSize = 0.f; -#else - if (textDefinition._stroke._strokeEnabled && textDefinition._stroke._strokeSize > 0.f) - { - Color4B outlineColor = Color4B(textDefinition._stroke._strokeColor); - outlineColor.a = textDefinition._stroke._strokeAlpha; - enableOutline(outlineColor, textDefinition._stroke._strokeSize); - } -#endif - - if (textDefinition._shadow._shadowEnabled) - { - enableShadow(Color4B(0, 0, 0, 255 * textDefinition._shadow._shadowOpacity), - textDefinition._shadow._shadowOffset, textDefinition._shadow._shadowBlur); - } -} - -void Label::updateContent() -{ - if (_systemFontDirty) - { - if (_fontAtlas) - { - _batchNodes.clear(); - - FontAtlasCache::releaseFontAtlas(_fontAtlas); - _fontAtlas = nullptr; - } - - _systemFontDirty = false; - } - - CC_SAFE_RELEASE_NULL(_textSprite); - CC_SAFE_RELEASE_NULL(_shadowNode); - bool updateFinished = true; - - if (_fontAtlas) - { - std::u16string utf16String; - if (StringUtils::UTF8ToUTF16(_utf8Text, utf16String)) - { - _utf16Text = utf16String; - } - - computeHorizontalKernings(_utf16Text); - updateFinished = alignText(); - } - else - { - auto fontDef = _getFontDefinition(); - createSpriteForSystemFont(fontDef); - if (_shadowEnabled) - { - createShadowSpriteForSystemFont(fontDef); - } - } - - if (_underlineNode) - { - _underlineNode->clear(); - - if(_currentLabelType == Label::LabelType::STRING_TEXTURE) { - // system font - const auto spriteSize = _textSprite->getContentSize(); - - this->computeStringNumLines(); - float startY = spriteSize.height / 2 - _lineHeight * (_numberOfLines - 1) / 2 - _systemFontSize / 2; - if (_numberOfLines > 0) { - // atlas font - _underlineNode->setLineWidth(_systemFontSize / 8); - for (int i=0; i<_numberOfLines; ++i) - { - if (_strikethroughEnabled) - startY += _systemFontSize / 2; - // FIXME: Might not work with different vertical alignments - _underlineNode->drawLine(Vec2(0, startY - 1), - Vec2(spriteSize.width, startY - 1), _textColorF); - } - } - - } - - else if(_numberOfLines) - { - const float charheight = (_textDesiredHeight / _numberOfLines); - _underlineNode->setLineWidth(charheight/6); - - // atlas font - for (int i=0; i<_numberOfLines; ++i) - { - float offsety = 0; - if (_strikethroughEnabled) - offsety += charheight / 2; - // FIXME: Might not work with different vertical alignments - float y = (_numberOfLines - i - 1) * charheight + offsety; - _underlineNode->drawLine(Vec2(_linesOffsetX[i],y), Vec2(_linesWidth[i] + _linesOffsetX[i],y), _textColorF); - } - } - } - - if(updateFinished){ - _contentDirty = false; - } - - if (_italicsEnabled) { - _contentSize.width += this->_originalFontSize * tan(6 * 0.0174532925); - } - -#if CC_LABEL_DEBUG_DRAW - _debugDrawNode->clear(); - Vec2 vertices[4] = - { - Vec2::ZERO, - Vec2(_contentSize.width, 0), - Vec2(_contentSize.width, _contentSize.height), - Vec2(0, _contentSize.height) - }; - _debugDrawNode->drawPoly(vertices, 4, true, Color4F::WHITE); -#endif -} - -void Label::setBMFontSize(float fontSize) -{ - this->setBMFontSizeInternal(fontSize); - _originalFontSize = fontSize; -} - -float Label::getBMFontSize()const -{ - return _bmFontSize; -} - -void Label::onDrawShadow(GLProgram* glProgram, const Color4F& shadowColor) -{ - if (_currentLabelType == LabelType::TTF) - { - glProgram->setUniformLocationWith4f(_uniformTextColor, - shadowColor.r, shadowColor.g, shadowColor.b, shadowColor.a); - if (_currLabelEffect == LabelEffect::OUTLINE || _currLabelEffect == LabelEffect::GLOW) - { - glProgram->setUniformLocationWith4f(_uniformEffectColor, - shadowColor.r, shadowColor.g, shadowColor.b, shadowColor.a); - } - - glProgram->setUniformsForBuiltins(_shadowTransform); - for (auto&& it : _letters) - { - it.second->updateTransform(); - } - for (auto&& batchNode : _batchNodes) - { - batchNode->getTextureAtlas()->drawQuads(); - } - } - else - { - Color3B oldColor = _realColor; - GLubyte oldOPacity = _displayedOpacity; - _displayedOpacity = shadowColor.a * 255; - setColor(Color3B(shadowColor)); - - glProgram->setUniformsForBuiltins(_shadowTransform); - for (auto&& it : _letters) - { - it.second->updateTransform(); - } - for (auto&& batchNode : _batchNodes) - { - batchNode->getTextureAtlas()->drawQuads(); - } - - _displayedOpacity = oldOPacity; - setColor(oldColor); - } -} - -void Label::onDraw(const Mat4& transform, bool transformUpdated) -{ - auto glprogram = getGLProgram(); - glprogram->use(); - GL::blendFunc(_blendFunc.src, _blendFunc.dst); - - if (_shadowEnabled) - { - if (_boldEnabled) - onDrawShadow(glprogram, _textColorF); - else - onDrawShadow(glprogram, _shadowColor4F); - } - - glprogram->setUniformsForBuiltins(transform); - for (auto&& it : _letters) - { - it.second->updateTransform(); - } - - if (_currentLabelType == LabelType::TTF) - { - switch (_currLabelEffect) { - case LabelEffect::OUTLINE: - //draw text with outline - glprogram->setUniformLocationWith4f(_uniformTextColor, - _textColorF.r, _textColorF.g, _textColorF.b, _textColorF.a); - glprogram->setUniformLocationWith4f(_uniformEffectColor, - _effectColorF.r, _effectColorF.g, _effectColorF.b, _effectColorF.a); - for (auto&& batchNode : _batchNodes) - { - batchNode->getTextureAtlas()->drawQuads(); - } - - //draw text without outline - glprogram->setUniformLocationWith4f(_uniformEffectColor, - _effectColorF.r, _effectColorF.g, _effectColorF.b, 0.f); - break; - case LabelEffect::GLOW: - glprogram->setUniformLocationWith4f(_uniformEffectColor, - _effectColorF.r, _effectColorF.g, _effectColorF.b, _effectColorF.a); - case LabelEffect::NORMAL: - glprogram->setUniformLocationWith4f(_uniformTextColor, - _textColorF.r, _textColorF.g, _textColorF.b, _textColorF.a); - break; - default: - break; - } - } - - for (auto&& batchNode : _batchNodes) - { - batchNode->getTextureAtlas()->drawQuads(); - } -} - -void Label::draw(Renderer *renderer, const Mat4 &transform, uint32_t flags) -{ - if (_batchNodes.empty() || _lengthOfString <= 0) - { - return; - } - - if (_director->isCullingEnabled()) { - // Don't calculate the culling if the transform was not updated - if (flags & FLAGS_TRANSFORM_DIRTY || flags & FLAGS_CULLING_DIRTY) { - _insideBounds = renderer->checkVisibility(transform, _contentSize); - } - } - else { - _insideBounds = true; - } - - if (_insideBounds) - { - if (!_shadowEnabled && (_currentLabelType == LabelType::BMFONT || _currentLabelType == LabelType::CHARMAP)) - { - for (auto&& it : _letters) - { - it.second->updateTransform(); - } - // ETC1 ALPHA supports for BMFONT & CHARMAP - auto textureAtlas = _batchNodes.at(0)->getTextureAtlas(); - auto texture = textureAtlas->getTexture(); - _quadCommand.init(_globalZOrder, texture, getGLProgramState(), - _blendFunc, textureAtlas->getQuads(), textureAtlas->getTotalQuads(), transform, flags); - renderer->addCommand(&_quadCommand); - } - else - { - _customCommand.init(_globalZOrder, transform, flags); - _customCommand.func = CC_CALLBACK_0(Label::onDraw, this, transform, flags & FLAGS_TRANSFORM_DIRTY); - - renderer->addCommand(&_customCommand); - } - } -} - -void Label::visit(Renderer *renderer, const Mat4 &parentTransform, uint32_t parentFlags) -{ - if (! _visible || (_utf8Text.empty() && _children.empty()) ) - { - return; - } - - if (_systemFontDirty || _contentDirty) - { - updateContent(); - } - - uint32_t flags = processParentFlags(parentTransform, parentFlags); - - if (!_utf8Text.empty() && _shadowEnabled && (_shadowDirty || (flags & FLAGS_DIRTY_MASK))) - { - _position.x += _shadowOffset.width; - _position.y += _shadowOffset.height; - _transformDirty = _inverseDirty = true; - - _shadowTransform = transform(parentTransform); - - _position.x -= _shadowOffset.width; - _position.y -= _shadowOffset.height; - _transformDirty = _inverseDirty = true; - - _shadowDirty = false; - } - - // IMPORTANT: - // To ease the migration to v3.0, we still support the Mat4 stack, - // but it is deprecated and your code should not rely on it - _director->pushMatrix(MATRIX_STACK_TYPE::MATRIX_STACK_MODELVIEW, _modelViewTransform); - - if (!_children.empty()) - { - sortAllChildren(); - - int i = 0; - // draw children zOrder < 0 - for (; i < _children.size(); i++) - { - auto node = _children.at(i); - - if (node && node->getLocalZOrder() < 0) - node->visit(renderer, _modelViewTransform, flags); - else - break; - } - - this->drawSelf(renderer, flags); - - for (auto it = _children.cbegin() + i; it != _children.cend(); ++it) - { - (*it)->visit(renderer, _modelViewTransform, flags); - } - } - else - { - this->drawSelf(renderer, flags); - } - - _director->popMatrix(MATRIX_STACK_TYPE::MATRIX_STACK_MODELVIEW); -} - -void Label::drawSelf(Renderer* renderer, uint32_t flags) -{ - if (_textSprite) - { - if (_shadowNode) - { - _shadowNode->visit(renderer, _modelViewTransform, flags); - } - _textSprite->visit(renderer, _modelViewTransform, flags); - } - else if (!_utf8Text.empty()) - { - draw(renderer, _modelViewTransform, flags); - } -} - -void Label::setSystemFontName(const std::string& systemFont) -{ - if (systemFont != _systemFont) - { - _systemFont = systemFont; - _currentLabelType = LabelType::STRING_TEXTURE; - _systemFontDirty = true; - } -} - -void Label::setSystemFontSize(float fontSize) -{ - if (_systemFontSize != fontSize) - { - _systemFontSize = fontSize; - _originalFontSize = fontSize; - _currentLabelType = LabelType::STRING_TEXTURE; - _systemFontDirty = true; - } -} - -///// PROTOCOL STUFF -Sprite* Label::getLetter(int letterIndex) -{ - Sprite* letter = nullptr; - do - { - if (_systemFontDirty || _currentLabelType == LabelType::STRING_TEXTURE) - { - break; - } - - auto contentDirty = _contentDirty; - if (contentDirty) - { - updateContent(); - } - - if (_textSprite == nullptr && letterIndex < _lengthOfString) - { - const auto &letterInfo = _lettersInfo[letterIndex]; - if (!letterInfo.valid) - { - break; - } - - if (_letters.find(letterIndex) != _letters.end()) - { - letter = _letters[letterIndex]; - } - - if (letter == nullptr) - { - auto& letterDef = _fontAtlas->_letterDefinitions[letterInfo.utf16Char]; - auto textureID = letterDef.textureID; - Rect uvRect; - uvRect.size.height = letterDef.height; - uvRect.size.width = letterDef.width; - uvRect.origin.x = letterDef.U; - uvRect.origin.y = letterDef.V; - - if (letterDef.width <= 0.f || letterDef.height <= 0.f) - { - letter = LabelLetter::create(); - } - else - { - letter = LabelLetter::createWithTexture(_fontAtlas->getTexture(textureID), uvRect); - letter->setTextureAtlas(_batchNodes.at(textureID)->getTextureAtlas()); - letter->setAtlasIndex(letterInfo.atlasIndex); - auto px = letterInfo.positionX + uvRect.size.width / 2 + _linesOffsetX[letterInfo.lineIndex]; - auto py = letterInfo.positionY - uvRect.size.height / 2 + _letterOffsetY; - letter->setPosition(px,py); - letter->setOpacity(_realOpacity); - } - - addChild(letter); - _letters[letterIndex] = letter; - } - } - } while (false); - - return letter; -} - -void Label::setLineHeight(float height) -{ - CCASSERT(_currentLabelType != LabelType::STRING_TEXTURE, "Not supported system font!"); - - if (_lineHeight != height) - { - _lineHeight = height; - _contentDirty = true; - } -} - -float Label::getLineHeight() const -{ - CCASSERT(_currentLabelType != LabelType::STRING_TEXTURE, "Not supported system font!"); - return _textSprite ? 0.0f : _lineHeight * _bmfontScale; -} - -void Label::setLineSpacing(float height) -{ - if (_lineSpacing != height) - { - _lineSpacing = height; - _contentDirty = true; - } -} - -float Label::getLineSpacing() const -{ - return _lineSpacing; -} - -void Label::setAdditionalKerning(float space) -{ - - if (_currentLabelType != LabelType::STRING_TEXTURE) - { - if (_additionalKerning != space) - { - _additionalKerning = space; - _contentDirty = true; - } - } - else - CCLOG("Label::setAdditionalKerning not supported on LabelType::STRING_TEXTURE"); -} - -float Label::getAdditionalKerning() const -{ - CCASSERT(_currentLabelType != LabelType::STRING_TEXTURE, "Not supported system font!"); - - return _additionalKerning; -} - -void Label::computeStringNumLines() -{ - int quantityOfLines = 1; - - if (_utf16Text.empty()) - { - _numberOfLines = 0; - return; - } - - // count number of lines - size_t stringLen = _utf16Text.length(); - for (size_t i = 0; i < stringLen - 1; ++i) - { - if (_utf16Text[i] == (char16_t)TextFormatter::NewLine) - { - quantityOfLines++; - } - } - - _numberOfLines = quantityOfLines; -} - -int Label::getStringNumLines() -{ - if (_contentDirty) - { - updateContent(); - } - - if (_currentLabelType == LabelType::STRING_TEXTURE) - { - computeStringNumLines(); - } - - return _numberOfLines; -} - -int Label::getStringLength() -{ - _lengthOfString = static_cast(_utf16Text.length()); - return _lengthOfString; -} - -// RGBA protocol -void Label::setOpacityModifyRGB(bool isOpacityModifyRGB) -{ - if (isOpacityModifyRGB != _isOpacityModifyRGB) - { - _isOpacityModifyRGB = isOpacityModifyRGB; - updateColor(); - } -} - -void Label::updateDisplayedColor(const Color3B& parentColor) -{ - Node::updateDisplayedColor(parentColor); - - if (_textSprite) - { - _textSprite->updateDisplayedColor(_displayedColor); - } - - if (_shadowNode) - { - _shadowNode->updateDisplayedColor(_displayedColor); - } - - if (_underlineNode) - { - _contentDirty = true; - } - - for (auto&& it : _letters) - { - it.second->updateDisplayedColor(_displayedColor);; - } -} - -void Label::updateDisplayedOpacity(GLubyte parentOpacity) -{ - Node::updateDisplayedOpacity(parentOpacity); - - if (_textSprite) - { - _textSprite->updateDisplayedOpacity(_displayedOpacity); - if (_shadowNode) - { - _shadowNode->updateDisplayedOpacity(_displayedOpacity); - } - } - - for (auto&& it : _letters) - { - it.second->updateDisplayedOpacity(_displayedOpacity);; - } - if (_underlineNode) { - _underlineNode->updateDisplayedOpacity(_displayedOpacity); - } -} - -void Label::setTextColor(const Color4B &color) -{ - CCASSERT(_currentLabelType == LabelType::TTF || _currentLabelType == LabelType::STRING_TEXTURE, "Only supported system font and ttf!"); - - if (_currentLabelType == LabelType::STRING_TEXTURE && _textColor != color) - { - _contentDirty = true; - } - - _textColor = color; - _textColorF.r = _textColor.r / 255.0f; - _textColorF.g = _textColor.g / 255.0f; - _textColorF.b = _textColor.b / 255.0f; - _textColorF.a = _textColor.a / 255.0f; -} - -void Label::updateColor() -{ - if (_batchNodes.empty()) - { - return; - } - - Color4B color4( _displayedColor.r, _displayedColor.g, _displayedColor.b, _displayedOpacity ); - - // special opacity for premultiplied textures - if (_isOpacityModifyRGB) - { - color4.r *= _displayedOpacity/255.0f; - color4.g *= _displayedOpacity/255.0f; - color4.b *= _displayedOpacity/255.0f; - } - - cocos2d::TextureAtlas* textureAtlas; - V3F_C4B_T2F_Quad *quads; - for (auto&& batchNode:_batchNodes) - { - textureAtlas = batchNode->getTextureAtlas(); - quads = textureAtlas->getQuads(); - auto count = textureAtlas->getTotalQuads(); - - for (int index = 0; index < count; ++index) - { - quads[index].bl.colors = color4; - quads[index].br.colors = color4; - quads[index].tl.colors = color4; - quads[index].tr.colors = color4; - textureAtlas->updateQuad(&quads[index], index); - } - } -} - -std::string Label::getDescription() const -{ - char tmp[50]; - sprintf(tmp, "