Merge pull request #7890 from minggo/compiling-optimize

Compiling optimize
This commit is contained in:
minggo 2014-08-27 15:39:08 +08:00
commit 491c32b705
57 changed files with 80 additions and 143 deletions

View File

@ -2342,8 +2342,6 @@
3EA3EDBB1991CDFA00645534 /* CCCamera.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCCamera.h; path = ../base/CCCamera.h; sourceTree = "<group>"; };
464AD6E3197EBB1400E502D8 /* pvr.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = pvr.cpp; path = ../base/pvr.cpp; sourceTree = "<group>"; };
464AD6E4197EBB1400E502D8 /* pvr.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = pvr.h; path = ../base/pvr.h; sourceTree = "<group>"; };
46633BC2199DDB2F00F6E838 /* CCModuleManager.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CCModuleManager.cpp; path = ../base/CCModuleManager.cpp; sourceTree = "<group>"; };
46633BC3199DDB2F00F6E838 /* CCModuleManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCModuleManager.h; path = ../base/CCModuleManager.h; sourceTree = "<group>"; };
46A15FCC1807A544005B8026 /* AUTHORS */ = {isa = PBXFileReference; lastKnownFileType = text; name = AUTHORS; path = ../AUTHORS; sourceTree = "<group>"; };
46A15FCE1807A544005B8026 /* README.md */ = {isa = PBXFileReference; lastKnownFileType = text; name = README.md; path = ../README.md; sourceTree = "<group>"; };
46A15FE11807A56F005B8026 /* Export.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = Export.h; sourceTree = "<group>"; };
@ -3066,8 +3064,6 @@
1A570095180BC5B00088DEC7 /* base-nodes */ = {
isa = PBXGroup;
children = (
46633BC2199DDB2F00F6E838 /* CCModuleManager.cpp */,
46633BC3199DDB2F00F6E838 /* CCModuleManager.h */,
15EFA20F198A2BB5000C57D3 /* CCProtectedNode.cpp */,
15EFA210198A2BB5000C57D3 /* CCProtectedNode.h */,
1A57009C180BC5D20088DEC7 /* CCNode.cpp */,

View File

@ -31,6 +31,7 @@
*/
#include "base/ccMacros.h"
#include "2d/CCActionCatmullRom.h"
#include "2d/CCNode.h"
using namespace std;

View File

@ -38,11 +38,12 @@
#include <vector>
#include "2d/CCActionInterval.h"
#include "2d/CCNode.h"
#include "math/CCGeometry.h"
NS_CC_BEGIN;
class Node;
/**
* @addtogroup actions
* @{

View File

@ -25,7 +25,6 @@ THE SOFTWARE.
****************************************************************************/
#include "2d/CCActionGrid3D.h"
#include "base/CCDirector.h"
#include <stdlib.h>
NS_CC_BEGIN
// implementation of Waves3D

View File

@ -28,7 +28,6 @@
#include "2d/CCActionInstant.h"
#include "2d/CCNode.h"
#include "2d/CCSprite.h"
#include "base/CCScriptSupport.h"
#if defined(__GNUC__) && ((__GNUC__ >= 4) || ((__GNUC__ == 3) && (__GNUC_MINOR__ >= 1)))
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"

View File

@ -28,10 +28,7 @@ THE SOFTWARE.
#ifndef __CCINSTANT_ACTION_H__
#define __CCINSTANT_ACTION_H__
#include <string>
#include <functional>
#include "CCStdC.h"
#include "2d/CCAction.h"
NS_CC_BEGIN

View File

@ -28,10 +28,12 @@ THE SOFTWARE.
#include "2d/CCActionInterval.h"
#include "2d/CCSprite.h"
#include "2d/CCNode.h"
#include "2d/CCSpriteFrame.h"
#include "CCStdC.h"
#include "2d/CCActionInstant.h"
#include "base/CCDirector.h"
#include "base/CCEventCustom.h"
#include "base/CCEventDispatcher.h"
#include <stdarg.h>

View File

@ -30,15 +30,17 @@ THE SOFTWARE.
#include <vector>
#include "2d/CCNode.h"
#include "2d/CCAction.h"
#include "2d/CCSpriteFrame.h"
#include "2d/CCAnimation.h"
#include "base/CCProtocols.h"
#include "base/CCVector.h"
NS_CC_BEGIN
class Node;
class SpriteFrame;
class EventCustom;
/**
* @addtogroup actions
* @{

View File

@ -28,6 +28,7 @@ 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"

View File

@ -35,6 +35,8 @@ THE SOFTWARE.
NS_CC_BEGIN
class Action;
struct _hashElement;
/**

View File

@ -28,7 +28,6 @@ THE SOFTWARE.
#include "2d/CCNodeGrid.h"
#include "base/CCDirector.h"
#include "base/ccMacros.h"
#include <stdlib.h>
NS_CC_BEGIN

View File

@ -32,9 +32,6 @@ THE SOFTWARE.
#include "renderer/CCTextureCache.h"
#include "renderer/CCRenderer.h"
#include "renderer/CCGLProgram.h"
#include "renderer/CCGLProgramState.h"
#include "renderer/ccGLStateCache.h"
#include "math/TransformUtils.h"
NS_CC_BEGIN

View File

@ -25,9 +25,8 @@
#include "CCGL.h"
#include "base/CCEventType.h"
#include "base/CCConfiguration.h"
#include "renderer/CCCustomCommand.h"
#include "renderer/CCRenderer.h"
#include "renderer/CCGLProgramState.h"
#include "renderer/ccGLStateCache.h"
#include "base/CCDirector.h"
#include "base/CCEventListenerCustom.h"
#include "base/CCEventDispatcher.h"

View File

@ -41,13 +41,10 @@ THE SOFTWARE.
#include <string.h>
#include <cmath>
#include "base/ccTypes.h"
#include "base/ccMacros.h"
#include "CCGL.h"
#include "base/CCDirector.h"
#include "renderer/ccGLStateCache.h"
#include "renderer/CCGLProgramCache.h"
#include "renderer/CCGLProgram.h"
#include "2d/CCActionCatmullRom.h"
#include "renderer/CCRenderer.h"

View File

@ -40,6 +40,7 @@ THE SOFTWARE.
#include "2d/CCSprite.h"
#include "renderer/CCTextureCache.h"
#include "renderer/CCGLProgramCache.h"
#include "renderer/ccGLStateCache.h"
#include "renderer/CCGLProgram.h"
#include "base/CCDirector.h"
#include "base/CCConfiguration.h"

View File

@ -27,11 +27,12 @@
#define _CCFont_h_
#include <string>
#include "2d/CCLabel.h"
NS_CC_BEGIN
class FontAtlas;
// fwd
class FontAtlas;

View File

@ -27,7 +27,7 @@
#include "base/CCPlatformMacros.h"
#include "base/CCRef.h"
#include "CCStdC.h"
#include "CCStdC.h" // ssize_t on windows
#include <string>
#include <unordered_map>

View File

@ -29,7 +29,8 @@
#include "2d/CCFontFNT.h"
#include "2d/CCFontFreeType.h"
#include "CCFontCharMap.h"
#include "2d/CCFontAtlas.h"
#include "2d/CCFontCharMap.h"
#include "base/CCDirector.h"
NS_CC_BEGIN

View File

@ -28,11 +28,12 @@
#include <unordered_map>
#include "2d/CCFontAtlas.h"
#include "2d/CCLabel.h"
NS_CC_BEGIN
class FontAtlas;
class CC_DLL FontAtlasCache
{
public:

View File

@ -23,10 +23,9 @@
THE SOFTWARE.
****************************************************************************/
#include "CCFontCharMap.h"
#include "2d/CCFontCharMap.h"
#include "2d/CCFontAtlas.h"
#include "platform/CCFileUtils.h"
#include "base/ccUTF8.h"
#include "base/CCDirector.h"
#include "renderer/CCTextureCache.h"

View File

@ -26,7 +26,7 @@
#ifndef _CCFontCharMap_h_
#define _CCFontCharMap_h_
#include "CCFont.h"
#include "2d/CCFont.h"
NS_CC_BEGIN

View File

@ -26,7 +26,6 @@
#include "2d/CCFontFNT.h"
#include "base/uthash.h"
#include "2d/CCFontAtlas.h"
#include "base/ccUTF8.h"
#include "platform/CCFileUtils.h"
#include "base/CCConfiguration.h"
#include "base/CCDirector.h"

View File

@ -25,8 +25,6 @@ THE SOFTWARE.
#include "2d/CCFontFreeType.h"
#include <stdio.h>
#include <algorithm>
#include "base/CCDirector.h"
#include "base/ccUTF8.h"
#include "platform/CCFileUtils.h"

View File

@ -27,7 +27,6 @@
#define _FontFreetype_h_
#include "CCFont.h"
#include "base/CCData.h"
#include <string>
#include <ft2build.h>

View File

@ -26,7 +26,6 @@ THE SOFTWARE.
#ifndef __EFFECTS_CCGRABBER_H__
#define __EFFECTS_CCGRABBER_H__
#include "base/CCConfiguration.h"
#include "base/CCRef.h"
#include "CCGL.h"

View File

@ -23,18 +23,18 @@ 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/CCDirector.h"
#include "2d/CCGrabber.h"
#include "base/ccUtils.h"
#include "2d/CCGrid.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 "CCGL.h"
#include "math/TransformUtils.h"
NS_CC_BEGIN
// implementation of GridBase
@ -321,21 +321,7 @@ void Grid3D::blit(void)
//
// Attributes
//
#ifdef EMSCRIPTEN
// Size calculations from calculateVertexPoints().
unsigned int numOfPoints = (_gridSize.width+1) * (_gridSize.height+1);
// position
setGLBufferData(_vertices, numOfPoints * sizeof(Vec3), 0);
glVertexAttribPointer(GLProgram::VERTEX_ATTRIB_POSITION, 3, GL_FLOAT, GL_FALSE, 0, 0);
// texCoords
setGLBufferData(_texCoordinates, numOfPoints * sizeof(Vec2), 1);
glVertexAttribPointer(GLProgram::VERTEX_ATTRIB_TEX_COORD, 2, GL_FLOAT, GL_FALSE, 0, 0);
setGLIndexData(_indices, n * 12, 0);
glDrawElements(GL_TRIANGLES, (GLsizei) n*6, GL_UNSIGNED_SHORT, 0);
#else
// position
glVertexAttribPointer(GLProgram::VERTEX_ATTRIB_POSITION, 3, GL_FLOAT, GL_FALSE, 0, _vertices);
@ -343,8 +329,6 @@ void Grid3D::blit(void)
glVertexAttribPointer(GLProgram::VERTEX_ATTRIB_TEX_COORD, 2, GL_FLOAT, GL_FALSE, 0, _texCoordinates);
glDrawElements(GL_TRIANGLES, (GLsizei) n*6, GL_UNSIGNED_SHORT, _indices);
#endif // EMSCRIPTEN
CC_INCREMENT_GL_DRAWN_BATCHES_AND_VERTICES(1,n*6);
}
void Grid3D::calculateVertexPoints(void)
@ -537,20 +521,7 @@ void TiledGrid3D::blit(void)
// Attributes
//
GL::enableVertexAttribs( GL::VERTEX_ATTRIB_FLAG_POSITION | GL::VERTEX_ATTRIB_FLAG_TEX_COORD );
#ifdef EMSCRIPTEN
int numQuads = _gridSize.width * _gridSize.height;
// position
setGLBufferData(_vertices, (numQuads*4*sizeof(Vec3)), 0);
glVertexAttribPointer(GLProgram::VERTEX_ATTRIB_POSITION, 3, GL_FLOAT, GL_FALSE, 0, 0);
// texCoords
setGLBufferData(_texCoordinates, (numQuads*4*sizeof(Vec2)), 1);
glVertexAttribPointer(GLProgram::VERTEX_ATTRIB_TEX_COORD, 2, GL_FLOAT, GL_FALSE, 0, 0);
setGLIndexData(_indices, n * 12, 0);
glDrawElements(GL_TRIANGLES, (GLsizei) n*6, GL_UNSIGNED_SHORT, 0);
#else
// position
glVertexAttribPointer(GLProgram::VERTEX_ATTRIB_POSITION, 3, GL_FLOAT, GL_FALSE, 0, _vertices);
@ -558,8 +529,6 @@ void TiledGrid3D::blit(void)
glVertexAttribPointer(GLProgram::VERTEX_ATTRIB_TEX_COORD, 2, GL_FLOAT, GL_FALSE, 0, _texCoordinates);
glDrawElements(GL_TRIANGLES, (GLsizei)n*6, GL_UNSIGNED_SHORT, _indices);
#endif // EMSCRIPTEN
CC_INCREMENT_GL_DRAWN_BATCHES_AND_VERTICES(1,n*6);
}

View File

@ -29,17 +29,13 @@ THE SOFTWARE.
#include "base/CCRef.h"
#include "base/ccTypes.h"
#include "base/CCDirector.h"
#include "2d/CCNode.h"
#include "renderer/CCTexture2D.h"
#ifdef EMSCRIPTEN
#include "CCGLBufferedNode.h"
#endif // EMSCRIPTEN
NS_CC_BEGIN
class Texture2D;
class Grabber;
class GLProgram;
class Node;
/**
* @addtogroup effects
@ -108,9 +104,6 @@ protected:
Grid3D is a 3D grid implementation. Each vertex has 3 dimensions: x,y,z
*/
class CC_DLL Grid3D : public GridBase
#ifdef EMSCRIPTEN
, public GLBufferedNode
#endif // EMSCRIPTEN
{
public:
/** create one Grid */
@ -171,9 +164,6 @@ protected:
the tiles can be separated from the grid.
*/
class CC_DLL TiledGrid3D : public GridBase
#ifdef EMSCRIPTEN
, public GLBufferedNode
#endif // EMSCRIPTEN
{
public:
/** create one Grid */

View File

@ -28,17 +28,14 @@
#include "2d/CCSprite.h"
#include "2d/CCLabelTextFormatter.h"
#include "base/ccUTF8.h"
#include "2d/CCSpriteFrame.h"
#include "platform/CCFileUtils.h"
#include "2d/CCFont.h"
#include "renderer/CCGLProgramState.h"
#include "renderer/CCRenderer.h"
#include "renderer/ccGLStateCache.h"
#include "base/CCDirector.h"
#include "base/CCEventListenerCustom.h"
#include "base/CCEventDispatcher.h"
#include "base/CCEventType.h"
#include "base/CCEventCustom.h"
#include "base/CCProfiling.h"
#include "deprecated/CCString.h"

View File

@ -28,7 +28,6 @@
#define _COCOS2D_CCLABEL_H_
#include "2d/CCSpriteBatchNode.h"
#include "base/ccTypes.h"
#include "renderer/CCCustomCommand.h"
#include "2d/CCFontAtlas.h"

View File

@ -24,17 +24,11 @@ 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 "CCLabelAtlas.h"
#include "2d/CCLabelAtlas.h"
#include "renderer/CCTextureAtlas.h"
#include "2d/CCDrawingPrimitives.h"
#include "platform/CCFileUtils.h"
#include "base/ccConfig.h"
#include "base/CCDirector.h"
#include "renderer/CCTextureCache.h"
#include "renderer/CCGLProgramCache.h"
#include "renderer/CCGLProgram.h"
#include "renderer/ccGLStateCache.h"
#include "math/TransformUtils.h"
#include "deprecated/CCString.h"

View File

@ -31,8 +31,7 @@ http://slick.cokeandcode.com/demos/hiero.jnlp (Free, Java)
http://www.angelcode.com/products/bmfont/ (Free, Windows only)
****************************************************************************/
#include "CCLabelBMFont.h"
#include "2d/CCDrawingPrimitives.h"
#include "2d/CCLabelBMFont.h"
#include "deprecated/CCString.h"
#include "2d/CCSprite.h"

View File

@ -23,7 +23,7 @@ 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 "CCLabelTTF.h"
#include "2d/CCLabelTTF.h"
#include "2d/CCLabel.h"
#include "deprecated/CCString.h"

View File

@ -29,10 +29,6 @@ THE SOFTWARE.
#include "2d/CCLayer.h"
#include "base/CCScriptSupport.h"
#include "platform/CCDevice.h"
#include "2d/CCScene.h"
#include "renderer/CCGLProgramState.h"
#include "renderer/CCGLProgram.h"
#include "renderer/CCCustomCommand.h"
#include "renderer/CCRenderer.h"
#include "renderer/ccGLStateCache.h"
#include "base/CCDirector.h"
@ -43,7 +39,7 @@ THE SOFTWARE.
#include "base/CCEventListenerKeyboard.h"
#include "base/CCEventAcceleration.h"
#include "base/CCEventListenerAcceleration.h"
#include "math/TransformUtils.h"
#include "deprecated/CCString.h"

View File

@ -30,15 +30,8 @@ THE SOFTWARE.
#include "2d/CCNode.h"
#include "base/CCProtocols.h"
#include "base/CCEventTouch.h"
#ifdef EMSCRIPTEN
#include "CCGLBufferedNode.h"
#endif // EMSCRIPTEN
#include "base/CCEventKeyboard.h"
#include "renderer/CCCustomCommand.h"
#include "physics/CCPhysicsWorld.h"
NS_CC_BEGIN
@ -54,6 +47,8 @@ class EventListenerTouch;
class EventListenerKeyboard;
class EventListenerAcceleration;
class Touch;
//
// Layer
//
@ -246,9 +241,6 @@ All features from Layer are valid, plus the following new features:
- RGB colors
*/
class CC_DLL LayerColor : public Layer, public BlendProtocol
#ifdef EMSCRIPTEN
, public GLBufferedNode
#endif // EMSCRIPTEN
{
public:
/** creates a fullscreen black layer */

View File

@ -28,6 +28,7 @@ THE SOFTWARE.
#include "base/CCTouch.h"
#include "CCStdC.h"
#include "base/CCEventListenerTouch.h"
#include "base/CCEventDispatcher.h"
#include "deprecated/CCString.h"
#include <vector>

View File

@ -28,11 +28,10 @@ THE SOFTWARE.
#include "2d/CCMenuItem.h"
#include "2d/CCLayer.h"
#include "base/CCVector.h"
#include "base/CCEventTouch.h"
#include "base/CCValue.h"
NS_CC_BEGIN
class Touch;
/**
* @addtogroup GUI

View File

@ -1,3 +1,5 @@
/****************************************************************************
Copyright (c) 2008-2010 Ricardo Quesada
Copyright (c) 2009 Valentin Milea
@ -34,26 +36,20 @@ THE SOFTWARE.
#include "base/CCDirector.h"
#include "base/CCScheduler.h"
#include "base/CCTouch.h"
#include "base/CCEventDispatcher.h"
#include "base/CCEvent.h"
#include "base/CCEventTouch.h"
#include "base/ccCArray.h"
#include "base/CCCamera.h"
#include "2d/CCGrid.h"
#include "2d/CCActionManager.h"
#include "base/CCScriptSupport.h"
#include "2d/CCScene.h"
#include "2d/CCComponent.h"
#include "2d/CCComponentContainer.h"
#include "renderer/CCGLProgram.h"
#include "renderer/CCGLProgramState.h"
#include "math/TransformUtils.h"
#include "deprecated/CCString.h"
#if CC_USE_PHYSICS
#include "physics/CCPhysicsBody.h"
#include "physics/CCPhysicsWorld.h"
#endif

View File

@ -30,14 +30,11 @@
#define __CCNODE_H__
#include "base/ccMacros.h"
#include "base/CCEventDispatcher.h"
#include "base/CCVector.h"
#include "base/CCScriptSupport.h"
#include "base/CCProtocols.h"
#include "base/CCScriptSupport.h"
#include "math/CCAffineTransform.h"
#include "math/CCMath.h"
#include "renderer/ccGLStateCache.h"
#include "CCGL.h"
NS_CC_BEGIN

View File

@ -30,12 +30,12 @@ THE SOFTWARE.
#include "base/CCCamera.h"
#include "base/CCEventDispatcher.h"
#include "base/CCEventListenerCustom.h"
#include "2d/CCLayer.h"
#include "2d/CCSprite.h"
#include "2d/CCSpriteBatchNode.h"
#include "physics/CCPhysicsWorld.h"
#include "deprecated/CCString.h"
#if CC_USE_PHYSICS
#include "physics/CCPhysicsWorld.h"
#endif
NS_CC_BEGIN
Scene::Scene()
@ -116,6 +116,14 @@ Scene* Scene::getScene() const
return const_cast<Scene*>(this);
}
void Scene::onProjectionChanged(EventCustom* event)
{
if (_defaultCamera)
{
_defaultCamera->initDefault();
}
}
#if CC_USE_PHYSICS
void Scene::addChild(Node* child, int zOrder, int tag)
{
@ -195,12 +203,4 @@ void Scene::addChildToPhysicsWorld(Node* child)
#endif
void Scene::onProjectionChanged(EventCustom* event)
{
if (_defaultCamera)
{
_defaultCamera->initDefault();
}
}
NS_CC_END

View File

@ -30,11 +30,15 @@ THE SOFTWARE.
#include <string>
#include "2d/CCNode.h"
#include "physics/CCPhysicsWorld.h"
NS_CC_BEGIN
class Camera;
class EventListenerCustom;
class EventCustom;
#if CC_USE_PHYSICS
class PhysicsWorld;
#endif
/**
* @addtogroup scene
* @{

View File

@ -26,7 +26,6 @@ THE SOFTWARE.
****************************************************************************/
#include "2d/CCTransition.h"
#include "base/CCDirector.h"
#include "2d/CCActionInterval.h"
#include "2d/CCActionInstant.h"
#include "2d/CCActionEase.h"
@ -36,6 +35,8 @@ THE SOFTWARE.
#include "2d/CCLayer.h"
#include "2d/CCRenderTexture.h"
#include "2d/CCNodeGrid.h"
#include "base/CCDirector.h"
#include "base/CCEventDispatcher.h"
NS_CC_BEGIN

View File

@ -29,7 +29,6 @@ THE SOFTWARE.
#define __CCTRANSITION_H__
#include "2d/CCScene.h"
#include "base/ccTypes.h"
NS_CC_BEGIN

View File

@ -26,9 +26,6 @@ THE SOFTWARE.
#include "2d/CCTransitionPageTurn.h"
#include "base/CCDirector.h"
#include "2d/CCActionInterval.h"
#include "2d/CCActionInstant.h"
#include "2d/CCActionGrid.h"
#include "2d/CCActionPageTurn3D.h"
#include "2d/CCNodeGrid.h"
#include "renderer/CCRenderer.h"

View File

@ -30,7 +30,6 @@ THE SOFTWARE.
#include "base/CCDirector.h"
#include "2d/CCRenderTexture.h"
#include "2d/CCProgressTimer.h"
#include "2d/CCLayer.h"
#include "2d/CCActionInstant.h"
#include "2d/CCActionProgressTimer.h"

View File

@ -24,6 +24,10 @@ THE SOFTWARE.
#include "2d/CCTweenFunction.h"
#define _USE_MATH_DEFINES // needed for M_PI and M_PI2
#include <math.h> // M_PI
#undef _USE_MATH_DEFINES
NS_CC_BEGIN
namespace tweenfunc {

View File

@ -26,8 +26,6 @@ THE SOFTWARE.
#define __CCTWEENFUNCTION_H__
#include "base/CCPlatformMacros.h"
#include "base/ccMacros.h"
#include <math.h>
NS_CC_BEGIN

View File

@ -5,3 +5,7 @@
#ifdef __OBJC__
#import <Foundation/Foundation.h>
#endif
#ifdef __cplusplus
#include "cocos2d.h"
#endif

View File

@ -28,6 +28,7 @@ THE SOFTWARE.
#include "base/CCEventListenerTouch.h"
#include "base/CCEventListenerAcceleration.h"
#include "base/CCEventListenerKeyboard.h"
#include "base/CCEventDispatcher.h"
using namespace cocos2d;

View File

@ -29,8 +29,10 @@ THE SOFTWARE.
#include "base/CCDirector.h"
#include "base/CCEventCustom.h"
#include "base/CCEventType.h"
#include "base/CCEventDispatcher.h"
#include "renderer/CCGLProgramCache.h"
#include "renderer/CCTextureCache.h"
#include "renderer/ccGLStateCache.h"
#include "2d/CCDrawingPrimitives.h"
#include "CCGLViewImpl.h"
#include "platform/android/jni/JniHelper.h"

View File

@ -2,6 +2,7 @@
#include "base/CCDirector.h"
#include "base/CCEventType.h"
#include "base/CCEventCustom.h"
#include "base/CCEventDispatcher.h"
#include "../CCApplication.h"
#include "platform/CCFileUtils.h"
#include "JniHelper.h"

View File

@ -23,6 +23,7 @@ THE SOFTWARE.
****************************************************************************/
#include "base/CCDirector.h"
#include "base/CCEventKeyboard.h"
#include "base/CCEventDispatcher.h"
#include "CCGLViewImpl.h"
#include <android/log.h>

View File

@ -37,6 +37,7 @@ THE SOFTWARE.
#include "base/CCEventListenerCustom.h"
#include "base/CCEventType.h"
#include "base/CCDirector.h"
#include "base/CCEventDispatcher.h"
NS_CC_BEGIN

View File

@ -25,6 +25,7 @@
#include "renderer/CCVertexIndexBuffer.h"
#include "base/CCEventType.h"
#include "base/CCEventListenerCustom.h"
#include "base/CCEventDispatcher.h"
NS_CC_BEGIN

View File

@ -23,6 +23,8 @@
****************************************************************************/
#include "renderer/CCVertexIndexData.h"
#include "renderer/ccGLStateCache.h"
#include "base/CCEventDispatcher.h"
NS_CC_BEGIN
VertexData* VertexData::create()

View File

@ -29,6 +29,7 @@ THE SOFTWARE.
#include "base/CCEventListenerKeyboard.h"
#include "base/CCDirector.h"
#include "base/CCEventFocus.h"
#include "base/CCEventDispatcher.h"
NS_CC_BEGIN

View File

@ -29,6 +29,7 @@
#include "2d/CCActionInterval.h"
#include "2d/CCActionTween.h"
#include "base/CCDirector.h"
#include "base/CCEventDispatcher.h"
#include "renderer/CCRenderer.h"
#include <algorithm>

View File

@ -29,6 +29,7 @@
#include "renderer/CCCustomCommand.h"
#include "renderer/CCRenderer.h"
#include "renderer/CCGLProgramState.h"
#include "renderer/ccGLStateCache.h"
#include "base/CCDirector.h"
#include "base/CCEventListenerCustom.h"
#include "base/CCEventDispatcher.h"