Merge branch 'v3' of github.com:cocos2d/cocos2d-x into v3

This commit is contained in:
zhangbin 2015-03-18 21:10:17 +08:00
commit f31a833df4
84 changed files with 3583 additions and 5269 deletions

View File

@ -40,12 +40,12 @@ class Node;
*/
/**
@brief Base class for Action objects.
* @brief Base class for Action objects.
*/
class CC_DLL Action : public Ref, public Clonable
{
public:
/// Default tag used for all the actions
/** Default tag used for all the actions. */
static const int INVALID_TAG = -1;
/**
* @js NA
@ -53,58 +53,94 @@ public:
*/
virtual std::string description() const;
/** returns a clone of action */
/** 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 exactly the reverse action */
/** Returns a new action that performs the exactly the reverse action.
*
* @return A new action that performs the exactly the reverse action.
*/
virtual Action* reverse() const
{
CC_ASSERT(0);
return nullptr;
}
//! return true if the action has finished
/** 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.
/** 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);"
*/
* 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.
/** 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
* 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
*/
* 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. */
/** 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
*/
/**
* 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; }
CC_CONSTRUCTOR_ACCESS:
@ -113,34 +149,40 @@ CC_CONSTRUCTOR_ACCESS:
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'.
*/
/**
* 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 */
/** The action tag. An identifier of the action. */
int _tag;
private:
CC_DISALLOW_COPY_AND_ASSIGN(Action);
};
/**
@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 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
/** 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
/** Set duration in seconds of the action.
*
* @param duration In seconds of the action.
*/
inline void setDuration(float duration) { _duration = duration; }
//
@ -164,7 +206,7 @@ CC_CONSTRUCTOR_ACCESS:
virtual ~FiniteTimeAction(){}
protected:
//! duration in seconds
//! Duration in seconds.
float _duration;
private:
@ -174,25 +216,41 @@ private:
class ActionInterval;
class RepeatForever;
/**
@brief Changes the speed of an action, making it take longer (speed>1)
or less (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 Speed
* @brief Changes the speed of an action, making it take longer (speed>1)
* or less (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 */
/** 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 */
/** 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; }
//
@ -206,12 +264,16 @@ public:
* @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 */
/** Initializes the action. */
bool initWithAction(ActionInterval *action, float speed);
protected:
@ -244,9 +306,9 @@ public:
* with no boundary.
*/
static Follow* create(Node *followedNode, const Rect& rect = Rect::ZERO);
/** Return boundarySet.*/
inline bool isBoundarySet() const { return _boundarySet; }
/** alter behavior - turn on/off boundary */
/** Alter behavior - turn on/off boundary. */
inline void setBoundarySet(bool value) { _boundarySet = value; }
CC_DEPRECATED_ATTRIBUTE inline void setBoudarySet(bool value) { setBoundarySet(value); }
@ -292,20 +354,20 @@ CC_CONSTRUCTOR_ACCESS:
bool initWithTarget(Node *followedNode, const Rect& rect = Rect::ZERO);
protected:
// node to follow
/** Node to follow. */
Node *_followedNode;
// whether camera should be limited to certain area
/** Whether camera should be limited to certain area. */
bool _boundarySet;
// if screen size is bigger than the boundary - update not needed
/** If screen size is bigger than the boundary - update not needed. */
bool _boundaryFullyCovered;
// fast access to the screen dimensions
/** Fast access to the screen dimensions. */
Vec2 _halfScreenSize;
Vec2 _fullScreenSize;
// world boundaries
/** World boundaries. */
float _leftBoundary;
float _rightBoundary;
float _topBoundary;

View File

@ -40,10 +40,10 @@ class Camera;
* @{
*/
/**
@brief Base class for Camera actions
@ingroup Actions
*/
/**
*@brief Base class for Camera actions.
*@ingroup Actions
*/
class CC_DLL ActionCamera : public ActionInterval //<NSCopying>
{
public:
@ -62,18 +62,36 @@ public:
virtual ActionCamera * reverse() const override;
virtual ActionCamera *clone() const override;
/* sets the Eye value of the Camera */
/* Sets the Eye value of the Camera.
*
* @param eye The Eye value of the Camera.
*/
void setEye(const Vec3 &eye);
void setEye(float x, float y, float z);
/* returns the Eye value of the Camera */
/* Returns the Eye value of the Camera.
*
* @return The Eye value of the Camera.
*/
const Vec3& getEye() const { return _eye; }
/* sets the Center value of the Camera */
/* Sets the Center value of the Camera.
*
* @param center The Center value of the Camera.
*/
void setCenter(const Vec3 &center);
/* returns the Center value of the Camera */
/* Returns the Center value of the Camera.
*
* @return The Center value of the Camera.
*/
const Vec3& getCenter() const { return _center; }
/* sets the Up value of the Camera */
/* Sets the Up value of the Camera.
*
* @param up The Up value of the Camera.
*/
void setUp(const Vec3 &up);
/* Returns the Up value of the Camera */
/* Returns the Up value of the Camera.
*
* @return The Up value of the Camera.
*/
const Vec3& getUp() const { return _up; }
protected:
@ -86,18 +104,34 @@ protected:
Vec3 _up;
};
/**
@brief OrbitCamera action
Orbits the camera around the center of the screen using spherical coordinates
@ingroup Actions
*/
/** @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 //<NSCopying>
{
public:
/** creates a OrbitCamera action with radius, delta-radius, z, deltaZ, x, deltaX */
/** 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 angelZ The start Angel in Z.
* @param deltaAngleZ The delta angle in Z.
* @param angelX The start Angel 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 */
/** 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
@ -116,7 +150,7 @@ CC_CONSTRUCTOR_ACCESS:
*/
virtual ~OrbitCamera();
/** initializes a OrbitCamera action with radius, delta-radius, z, deltaZ, x, deltaX */
/** 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:

View File

@ -50,15 +50,16 @@ class Node;
*/
/** An Array that contain control points.
Used by CardinalSplineTo and (By) and CatmullRomTo (and By) actions.
@ingroup Actions
* Used by CardinalSplineTo and (By) and CatmullRomTo (and By) actions.
* @ingroup Actions
*/
class CC_DLL PointArray : public Ref, public Clonable
{
public:
/** creates and initializes a Points array with capacity
/** Creates and initializes a Points array with capacity.
* @js NA
* @param capacity The size of the array.
*/
static PointArray* create(ssize_t capacity);
@ -73,47 +74,67 @@ public:
*/
PointArray();
/** initializes a Catmull Rom config with a capacity hint
/** 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
/** Appends a control point.
*
* @js NA
* @param controlPoint A control point.
*/
void addControlPoint(Vec2 controlPoint);
/** inserts a controlPoint at index
/** Inserts a controlPoint at index.
*
* @js NA
* @param controlPoint A control point.
* @param index Insert the point to array in index.
*/
void insertControlPoint(Vec2 &controlPoint, ssize_t index);
/** replaces an existing controlPoint at 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(Vec2 &controlPoint, ssize_t index);
/** get the value of a controlPoint at a given 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
/** 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
/** 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
/** 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
/** Reverse the current control point array inline, without generating a new one.
* @js NA
*/
void reverseInline();
@ -131,24 +152,27 @@ public:
*/
void setControlPoints(std::vector<Vec2*> *controlPoints);
private:
/** Array that contains the control points */
/** Array that contains the control points. */
std::vector<Vec2*> *_controlPoints;
};
/** Cardinal Spline path.
http://en.wikipedia.org/wiki/Cubic_Hermite_spline#Cardinal_spline
@ingroup Actions
/** @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
/** Creates an action with a Cardinal Spline array of points and tension.
* @param duration In seconds.
* @param point 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: lcaol create(local t, local table)
* When this function bound to js or lua,the input params are changed.
* In js: var create(var t,var table)
* In lua: lcaol create(local t, local table)
* @endcode
*/
static CardinalSplineTo* create(float duration, PointArray* points, float tension);
@ -164,13 +188,22 @@ public:
CardinalSplineTo();
/**
* initializes the action with a duration and an array of points
* @param duration in seconds
* Initializes the action with a duration and an array of points.
*
* @param duration In seconds.
* @param point 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(Vec2 &newPos);
/** Return a PointArray.
*
* @return A PointArray.
*/
inline PointArray* getPoints() { return _points; }
/**
* @js NA
@ -189,7 +222,7 @@ public:
virtual void startWithTarget(Node *target) override;
/**
* @param time in seconds.
* @param time In seconds.
*/
virtual void update(float time) override;
@ -202,19 +235,23 @@ protected:
Vec2 _accumulatedDiff;
};
/** Cardinal Spline path.
http://en.wikipedia.org/wiki/Cubic_Hermite_spline#Cardinal_spline
@ingroup Actions
/** @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
/** 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: lcaol create(local t, local table)
* When this function bound to js or lua,the input params are changed.
* In js: var create(var t,var table).
* In lua: lcaol 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);
@ -231,28 +268,32 @@ protected:
Vec2 _startPosition;
};
/** 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 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
/** 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: lcaol create(local dt, local table)
* When this function bound to js or lua,the input params are changed.
* In js: var create(var dt,var table).
* In lua: lcaol 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
* 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);
@ -261,25 +302,31 @@ public:
virtual CatmullRomTo *reverse() const override;
};
/** 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 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
/** 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: lcaol create(local dt, local table)
* When this function bound to js or lua,the input params are changed.
* In js: var create(var dt,var table).
* In lua: lcaol create(local dt, local table).
* @endcode
*/
static CatmullRomBy* create(float dt, PointArray* points);
/** initializes the action with a duration and an array of 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

View File

@ -46,17 +46,20 @@ class SpriteFrame;
*/
/** AnimationFrame
A frame of the animation. It contains information like:
- sprite frame name
- # of delay units.
- offset
*
* 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;
@ -64,13 +67,23 @@ public:
};
/**
* Creates the animation frame with a spriteframe, number of delay units and a notification user info
* 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);
@ -78,19 +91,30 @@ public:
_spriteFrame = frame;
}
/** Gets the units of time the frame takes */
/** 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 */
/** 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 infomation
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.
* 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 infomation */
/** Sets user infomation.
* @param userInfo A dictionary as UserInfo.
*/
void setUserInfo(const ValueMap& userInfo)
{
_userInfo = userInfo;
@ -131,89 +155,127 @@ private:
/** 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 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
/** 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
* 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<SpriteFrame*>& arrayOfSpriteFrameNames, float delay = 0.0f, unsigned int loops = 1);
/* Creates an animation with an array of AnimationFrame, the delay per units in seconds and and how many times it should be executed.
@since v2.0
* @since v2.0
* @js NA
* @param arrayOfAnimationFrameNames An animation with an array of AnimationFrame.
* @param delayPerUnit The delay per units in seconds and and how many times it should be executed.
* @param loops The times the animation is going to loop.
*/
static Animation* create(const Vector<AnimationFrame*>& arrayOfAnimationFrameNames, float delayPerUnit, unsigned int loops = 1);
/** Adds a SpriteFrame to a Animation.
The frame will be added with one "delay unit".
*
* @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.
* 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);
/**
@deprecated. Use addSpriteFrameWithFile() instead
* @deprecated. Use addSpriteFrameWithFile() instead.
*/
CC_DEPRECATED_ATTRIBUTE void addSpriteFrameWithFileName(const std::string& filename){ addSpriteFrameWithFile(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.
* 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. */
/** 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" */
/** Sets the delay in seconds of the "delay unit".
*
* @param setDelayPerUnit The delay in seconds of the "delay unit".
*/
void setDelayPerUnit(float delayPerUnit) { _delayPerUnit = delayPerUnit; };
/** Gets the delay in seconds of the "delay unit" */
/** 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 */
/** 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 */
/** Gets the array of AnimationFrames.
*
* @return The array of AnimationFrames.
*/
const Vector<AnimationFrame*>& getFrames() const { return _frames; };
/** Sets the array of AnimationFrames */
/** Sets the array of AnimationFrames.
*
* @param frames The array of AnimationFrames.
*/
void setFrames(const Vector<AnimationFrame*>& frames)
{
_frames = frames;
}
/** Checks whether to restore the original frame when animation finishes. */
/** 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 */
/** 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, ... */
/** 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, ... */
/** 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
@ -223,16 +285,16 @@ CC_CONSTRUCTOR_ACCESS:
Animation();
virtual ~Animation(void);
/** Initializes a Animation */
/** Initializes a Animation. */
bool init();
/** Initializes a Animation with frames and a delay between frames
@since v0.99.5
/** Initializes a Animation with frames and a delay between frames.
* @since v0.99.5
*/
bool initWithSpriteFrames(const Vector<SpriteFrame*>& arrayOfSpriteFrameNames, float delay = 0.0f, unsigned int loops = 1);
/** Initializes a Animation with AnimationFrame
@since v2.0
/** Initializes a Animation with AnimationFrame.
* @since v2.0
*/
bool initWithAnimationFrames(const Vector<AnimationFrame*>& arrayOfAnimationFrameNames, float delayPerUnit, unsigned int loops);
@ -240,16 +302,16 @@ protected:
/** total Delay units of the Animation. */
float _totalDelayUnits;
/** Delay in seconds of the "delay unit" */
/** Delay in seconds of the "delay unit". */
float _delayPerUnit;
/** duration in seconds of the whole animation. It is the result of totalDelayUnits * delayPerUnit */
/** duration in seconds of the whole animation. It is the result of totalDelayUnits * delayPerUnit. */
float _duration;
/** array of AnimationFrames */
/** array of AnimationFrames. */
Vector<AnimationFrame*> _frames;
/** whether or not it shall restore the original frame when the animation finishes */
/** 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, ... */

View File

@ -36,6 +36,7 @@ THE SOFTWARE.
NS_CC_BEGIN
class Animation;
/**
@ -44,12 +45,10 @@ class Animation;
*/
/** 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
*/
* 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
*/
class CC_DLL AnimationCache : public Ref
{
public:
@ -62,27 +61,33 @@ public:
* @lua NA
*/
~AnimationCache();
/** Returns the shared instance of the Animation cache */
/** Returns the shared instance of the Animation cache.
*
* @return The shared instance of the Animation cache.
*/
static AnimationCache* getInstance();
/** Purges the cache. It releases all the Animation objects and the shared instance.
*/
/** Purges the cache. It releases all the Animation objects and the shared instance. */
static void destroyInstance();
/** @deprecated Use getInstance() instead */
/** @deprecated Use getInstance() instead. */
CC_DEPRECATED_ATTRIBUTE static AnimationCache* sharedAnimationCache() { return AnimationCache::getInstance(); }
/** @deprecated Use destroyInstance() instead */
/** @deprecated Use destroyInstance() instead. */
CC_DEPRECATED_ATTRIBUTE static void purgeSharedAnimationCache() { return AnimationCache::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);
/** @deprecated. Use removeAnimation() instead
@ -92,29 +97,33 @@ public:
CC_DEPRECATED_ATTRIBUTE void removeAnimationByName(const std::string& name){ removeAnimation(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.
*/
* 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);
/**
@deprecated. Use getAnimation() instead
* @deprecated. Use getAnimation() instead
* @js NA
* @lua NA
*/
CC_DEPRECATED_ATTRIBUTE Animation* animationByName(const std::string& name){ return getAnimation(name); }
/** Adds an animation from an NSDictionary
Make sure that the frames were previously loaded in the SpriteFrameCache.
@param plist The path of the relative file,it use to find the plist path for load SpriteFrames.
@since v1.1
/** 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
*/
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
* 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);

View File

@ -42,26 +42,36 @@ NS_CC_BEGIN
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
*/
/** @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*/
/** 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
* 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);
@ -95,10 +105,10 @@ 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*/
/** 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*/
/** 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:
@ -109,30 +119,30 @@ protected:
friend class Director;
void setIgnoreContentScaleFactor(bool bIgnoreContentScaleFactor);
//! chars per row
/** Chars per row. */
int _itemsPerRow;
//! chars per column
/** Chars per column. */
int _itemsPerColumn;
//! width of each char
/** Width of each char. */
int _itemWidth;
//! height of each char
/** Height of each char. */
int _itemHeight;
Color3B _colorUnmodified;
TextureAtlas* _textureAtlas;
// protocol variables
/** Protocol variables. */
bool _isOpacityModifyRGB;
BlendFunc _blendFunc;
// quads to draw
/** Quads to draw. */
ssize_t _quadsToDraw;
// color uniform
/** Color uniform. */
GLint _uniformColor;
// This varible is only used for LabelAtlas FPS display. So plz don't modify its value.
/** This varible is only used for LabelAtlas FPS display. So plz don't modify its value. */
bool _ignoreContentScaleFactor;
// quad command
/** Quad command. */
QuadCommand _quadCommand;
private:

View File

@ -316,6 +316,14 @@ void ClippingNode::visit(Renderer *renderer, const Mat4 &parentTransform, uint32
director->popMatrix(MATRIX_STACK_TYPE::MATRIX_STACK_MODELVIEW);
}
void ClippingNode::setCameraMask(unsigned short mask, bool applyChildren)
{
Node::setCameraMask(mask, applyChildren);
if (_stencil)
_stencil->setCameraMask(mask, applyChildren);
}
Node* ClippingNode::getStencil() const
{
return _stencil;

View File

@ -104,6 +104,8 @@ public:
virtual void onExit() override;
virtual void visit(Renderer *renderer, const Mat4 &parentTransform, uint32_t parentFlags) override;
virtual void setCameraMask(unsigned short mask, bool applyChildren = true) override;
CC_CONSTRUCTOR_ACCESS:
ClippingNode();

View File

@ -910,6 +910,20 @@ void Label::draw(Renderer *renderer, const Mat4 &transform, uint32_t flags)
}
}
void Label::setCameraMask(unsigned short mask, bool applyChildren)
{
SpriteBatchNode::setCameraMask(mask, applyChildren);
if (_textSprite)
{
_textSprite->setCameraMask(mask, applyChildren);
}
if (_shadowNode)
{
_shadowNode->setCameraMask(mask, applyChildren);
}
}
void Label::createSpriteWithFontDefinition()
{
_currentLabelType = LabelType::STRING_TEXTURE;
@ -918,6 +932,8 @@ void Label::createSpriteWithFontDefinition()
texture->initWithString(_originalUTF8String.c_str(),_fontDefinition);
_textSprite = Sprite::createWithTexture(texture);
//set camera mask using label's camera mask, because _textSprite may be null when setting camera mask to label
_textSprite->setCameraMask(getCameraMask());
_textSprite->setAnchorPoint(Vec2::ANCHOR_BOTTOM_LEFT);
this->setContentSize(_textSprite->getContentSize());
texture->release();
@ -1059,6 +1075,8 @@ void Label::drawTextSprite(Renderer *renderer, uint32_t parentFlags)
{
_shadowNode->setBlendFunc(_blendFunc);
}
//set camera mask using label's mask. Because _shadowNode may be null when setting the label's camera mask
_shadowNode->setCameraMask(getCameraMask());
_shadowNode->setAnchorPoint(Vec2::ANCHOR_BOTTOM_LEFT);
_shadowNode->setColor(_shadowColor);
_shadowNode->setOpacity(_shadowOpacity * _displayedOpacity);

View File

@ -266,6 +266,8 @@ public:
virtual void visit(Renderer *renderer, const Mat4 &parentTransform, uint32_t parentFlags) override;
virtual void draw(Renderer *renderer, const Mat4 &transform, uint32_t flags) override;
virtual void setCameraMask(unsigned short mask, bool applyChildren = true) override;
CC_DEPRECATED_ATTRIBUTE static Label* create(const std::string& text, const std::string& font, float fontSize,
const Size& dimensions = Size::ZERO, TextHAlignment hAlignment = TextHAlignment::LEFT,
TextVAlignment vAlignment = TextVAlignment::TOP);

View File

@ -109,7 +109,7 @@
<AdditionalOptions>/Zm384 /bigobj %(AdditionalOptions)</AdditionalOptions>
<ForcedIncludeFiles>pch.h</ForcedIncludeFiles>
<AdditionalIncludeDirectories>$(EngineRoot)external\wp_8.1-specific\zlib\include;$(EngineRoot)external\freetype2\include\wp_8.1;$(EngineRoot)external\websockets\include\wp_8.1;$(EngineRoot)external\curl\include\wp_8.1;$(EngineRoot)external\tiff\include\wp_8.1;$(EngineRoot)external\jpeg\include\wp_8.1;$(EngineRoot)external\png\include\wp_8.1;$(EngineRoot)external\protobuf-lite\src;$(EngineRoot)external\protobuf-lite\win32;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<PreprocessorDefinitions>CC_NO_GL_POINTSIZE;_USRDLL;_LIB;COCOS2DXWIN32_EXPORTS;_USE3DDLL;_EXPORT_DLL_;_USRSTUDIODLL;_USREXDLL;_USEGUIDLL;CC_ENABLE_CHIPMUNK_INTEGRATION=1;_DEBUG;COCOS2D_DEBUG=1;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<PreprocessorDefinitions>_USRDLL;_LIB;COCOS2DXWIN32_EXPORTS;_USE3DDLL;_EXPORT_DLL_;_USRSTUDIODLL;_USREXDLL;_USEGUIDLL;CC_ENABLE_CHIPMUNK_INTEGRATION=1;_DEBUG;COCOS2D_DEBUG=1;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<SDLCheck>false</SDLCheck>
<DisableSpecificWarnings>%(DisableSpecificWarnings)</DisableSpecificWarnings>
</ClCompile>
@ -129,7 +129,7 @@
<AdditionalOptions>/Zm384 /bigobj %(AdditionalOptions)</AdditionalOptions>
<ForcedIncludeFiles>pch.h</ForcedIncludeFiles>
<AdditionalIncludeDirectories>$(EngineRoot)external\wp_8.1-specific\zlib\include;$(EngineRoot)external\freetype2\include\wp_8.1;$(EngineRoot)external\websockets\include\wp_8.1;$(EngineRoot)external\curl\include\wp_8.1;$(EngineRoot)external\tiff\include\wp_8.1;$(EngineRoot)external\jpeg\include\wp_8.1;$(EngineRoot)external\png\include\wp_8.1;$(EngineRoot)external\protobuf-lite\src;$(EngineRoot)external\protobuf-lite\win32;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<PreprocessorDefinitions>CC_NO_GL_POINTSIZE;_USRDLL;_LIB;COCOS2DXWIN32_EXPORTS;_USE3DDLL;_EXPORT_DLL_;_USRSTUDIODLL;_USREXDLL;_USEGUIDLL;CC_ENABLE_CHIPMUNK_INTEGRATION=1;NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<PreprocessorDefinitions>_USRDLL;_LIB;COCOS2DXWIN32_EXPORTS;_USE3DDLL;_EXPORT_DLL_;_USRSTUDIODLL;_USREXDLL;_USEGUIDLL;CC_ENABLE_CHIPMUNK_INTEGRATION=1;NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<SDLCheck>false</SDLCheck>
<DisableSpecificWarnings>%(DisableSpecificWarnings)</DisableSpecificWarnings>
</ClCompile>
@ -149,7 +149,7 @@
<AdditionalOptions>/Zm384 /bigobj %(AdditionalOptions)</AdditionalOptions>
<ForcedIncludeFiles>pch.h</ForcedIncludeFiles>
<AdditionalIncludeDirectories>$(EngineRoot)external\wp_8.1-specific\zlib\include;$(EngineRoot)external\freetype2\include\wp_8.1;$(EngineRoot)external\websockets\include\wp_8.1;$(EngineRoot)external\curl\include\wp_8.1;$(EngineRoot)external\tiff\include\wp_8.1;$(EngineRoot)external\jpeg\include\wp_8.1;$(EngineRoot)external\png\include\wp_8.1;$(EngineRoot)external\protobuf-lite\src;$(EngineRoot)external\protobuf-lite\win32;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<PreprocessorDefinitions>CC_NO_GL_POINTSIZE;_USRDLL;_LIB;COCOS2DXWIN32_EXPORTS;_USE3DDLL;_EXPORT_DLL_;_USRSTUDIODLL;_USREXDLL;_USEGUIDLL;CC_ENABLE_CHIPMUNK_INTEGRATION=1;_DEBUG;COCOS2D_DEBUG=1;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<PreprocessorDefinitions>_USRDLL;_LIB;COCOS2DXWIN32_EXPORTS;_USE3DDLL;_EXPORT_DLL_;_USRSTUDIODLL;_USREXDLL;_USEGUIDLL;CC_ENABLE_CHIPMUNK_INTEGRATION=1;_DEBUG;COCOS2D_DEBUG=1;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<SDLCheck>false</SDLCheck>
<DisableSpecificWarnings>%(DisableSpecificWarnings)</DisableSpecificWarnings>
</ClCompile>
@ -169,7 +169,7 @@
<AdditionalOptions>/Zm384 /bigobj %(AdditionalOptions)</AdditionalOptions>
<ForcedIncludeFiles>pch.h</ForcedIncludeFiles>
<AdditionalIncludeDirectories>$(EngineRoot)external\wp_8.1-specific\zlib\include;$(EngineRoot)external\freetype2\include\wp_8.1;$(EngineRoot)external\websockets\include\wp_8.1;$(EngineRoot)external\curl\include\wp_8.1;$(EngineRoot)external\tiff\include\wp_8.1;$(EngineRoot)external\jpeg\include\wp_8.1;$(EngineRoot)external\png\include\wp_8.1;$(EngineRoot)external\protobuf-lite\src;$(EngineRoot)external\protobuf-lite\win32;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<PreprocessorDefinitions>CC_NO_GL_POINTSIZE;_USRDLL;_LIB;COCOS2DXWIN32_EXPORTS;_USE3DDLL;_EXPORT_DLL_;_USRSTUDIODLL;_USREXDLL;_USEGUIDLL;CC_ENABLE_CHIPMUNK_INTEGRATION=1;NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<PreprocessorDefinitions>_USRDLL;_LIB;COCOS2DXWIN32_EXPORTS;_USE3DDLL;_EXPORT_DLL_;_USRSTUDIODLL;_USREXDLL;_USEGUIDLL;CC_ENABLE_CHIPMUNK_INTEGRATION=1;NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<SDLCheck>false</SDLCheck>
<DisableSpecificWarnings>%(DisableSpecificWarnings)</DisableSpecificWarnings>
</ClCompile>

View File

@ -370,7 +370,18 @@ Sprite3D* Sprite3D::createSprite3DNode(NodeData* nodedata,ModelData* modeldata,c
}
}
}
sprite->setAdditionalTransform(&nodedata->transform);
// set locale transform
Vec3 pos;
Quaternion qua;
Vec3 scale;
nodedata->transform.decompose(&scale, &qua, &pos);
sprite->setPosition3D(pos);
sprite->setRotationQuat(qua);
sprite->setScaleX(scale.x);
sprite->setScaleY(scale.y);
sprite->setScaleZ(scale.z);
sprite->addMesh(mesh);
sprite->autorelease();
sprite->genGLProgramState();
@ -527,7 +538,18 @@ void Sprite3D::createNode(NodeData* nodedata, Node* root, const MaterialDatas& m
if(node)
{
node->setName(nodedata->id);
node->setAdditionalTransform(&nodedata->transform);
// set locale transform
Vec3 pos;
Quaternion qua;
Vec3 scale;
nodedata->transform.decompose(&scale, &qua, &pos);
node->setPosition3D(pos);
node->setRotationQuat(qua);
node->setScaleX(scale.x);
node->setScaleY(scale.y);
node->setScaleZ(scale.z);
if(root)
{
root->addChild(node);
@ -687,15 +709,19 @@ void Sprite3D::draw(Renderer *renderer, const Mat4 &transform, uint32_t flags)
color.a = getDisplayedOpacity() / 255.0f;
//check light and determine the shader used
const auto& lights = Director::getInstance()->getRunningScene()->getLights();
bool usingLight = false;
for (const auto light : lights) {
usingLight = ((unsigned int)light->getLightFlag() & _lightMask) > 0;
if (usingLight)
break;
const auto& scene = Director::getInstance()->getRunningScene();
if (scene)
{
const auto& lights = scene->getLights();
bool usingLight = false;
for (const auto light : lights) {
usingLight = ((unsigned int)light->getLightFlag() & _lightMask) > 0;
if (usingLight)
break;
}
if (usingLight != _shaderUsingLight)
genGLProgramState(usingLight);
}
if (usingLight != _shaderUsingLight)
genGLProgramState(usingLight);
int i = 0;
for (auto& mesh : _meshes) {

View File

@ -40,7 +40,7 @@ class CC_DLL AutoreleasePool
{
public:
/**
* @warn Don't create an auto release pool in heap, create it in stack.
* @warn Don't create an autorelease pool in heap, create it in stack.
* @js NA
* @lua NA
*/
@ -48,6 +48,11 @@ public:
/**
* Create an autorelease pool with specific name. This name is useful for debugging.
* @warn Don't create an autorelease pool in heap, create it in stack.
* @js NA
* @lua NA
*
* @param name The name of created autorelease pool.
*/
AutoreleasePool(const std::string &name);
@ -58,13 +63,13 @@ public:
~AutoreleasePool();
/**
* Add a given object to this pool.
* Add a given object to this autorelease pool.
*
* The same object may be added several times to the same pool; When the
* pool is destructed, the object's Ref::release() method will be called
* for each time it was added.
* The same object may be added several times to an autorelease pool. When the
* pool is destructed, the object's `Ref::release()` method will be called
* the same times as it was added.
*
* @param object The object to add to the pool.
* @param object The object to be added into the autorelease pool.
* @js NA
* @lua NA
*/
@ -73,8 +78,8 @@ public:
/**
* Clear the autorelease pool.
*
* Ref::release() will be called for each time the managed object is
* added to the pool.
* It will invoke each element's `release()` function.
*
* @js NA
* @lua NA
*/
@ -82,22 +87,34 @@ public:
#if defined(COCOS2D_DEBUG) && (COCOS2D_DEBUG > 0)
/**
* Whether the pool is doing `clear` operation.
* Whether the autorelease pool is doing `clear` operation.
*
* @return True if autorelase pool is clearning, false if not.
*
* @js NA
* @lua NA
*/
bool isClearing() const { return _isClearing; };
#endif
/**
* Checks whether the pool contains the specified object.
* Checks whether the autorelease pool contains the specified object.
*
* @param object The object to be checked.
* @return True if the autorelease pool contains the object, false if not
* @js NA
* @lua NA
*/
bool contains(Ref* object) const;
/**
* Dump the objects that are put into autorelease pool. It is used for debugging.
* Dump the objects that are put into the autorelease pool. It is used for debugging.
*
* The result will look like:
* Object pointer address object id reference count
*
* @js NA
* @lua NA
*/
void dump();
@ -122,20 +139,16 @@ private:
#endif
};
/**
* @cond
*/
class CC_DLL PoolManager
{
public:
/**
* @js NA
* @lua NA
*/
CC_DEPRECATED_ATTRIBUTE static PoolManager* sharedPoolManager() { return getInstance(); }
static PoolManager* getInstance();
/**
* @js NA
* @lua NA
*/
CC_DEPRECATED_ATTRIBUTE static void purgePoolManager() { destroyInstance(); }
static void destroyInstance();
@ -147,10 +160,7 @@ public:
bool isObjectInPools(Ref* obj) const;
/**
* @js NA
* @lua NA
*/
friend class AutoreleasePool;
private:
@ -164,6 +174,9 @@ private:
std::vector<AutoreleasePool*> _releasePoolStack;
};
/**
* @endcond
*/
// end of base_nodes group
/// @}

View File

@ -33,28 +33,58 @@
NS_CC_BEGIN
/**
* @lua NA
*/
class CC_DLL Data
{
public:
/**
* This parameter is defined for convenient reference if a null Data object is needed.
*/
static const Data Null;
/**
* Constructor of Data.
*/
Data();
/**
* Copy constructor of Data.
*/
Data(const Data& other);
/**
* Copy constructor of Data.
*/
Data(Data&& other);
/**
* Destructor of Data.
*/
~Data();
// Assignment operator
/**
* Overroads of operator=.
*/
Data& operator= (const Data& other);
/**
* Overroads of operator=.
*/
Data& operator= (Data&& other);
/**
* @js NA
* @lua NA
* Gets internal bytes of Data. It will retrun the pointer directly used in Data, so don't delete it.
*
* @return Pointer of bytes used internal in Data.
*/
unsigned char* getBytes() const;
/**
* @js NA
* @lua NA
* Gets the size of the bytes.
*
* @return The size of bytes of Data.
*/
ssize_t getSize() const;
@ -74,10 +104,16 @@ public:
*/
void fastSet(unsigned char* bytes, const ssize_t size);
/** Clears data, free buffer and reset data size */
/**
* Clears data, free buffer and reset data size.
*/
void clear();
/** Check whether the data is null. */
/**
* Check whether the data is null.
*
* @return True if the the Data is null, false if not.
*/
bool isNull() const;
private:

View File

@ -41,8 +41,7 @@ class __Dictionary;
class __Set;
/**
* @addtogroup data_structures
* @{
* @cond
*/
/**
@ -106,8 +105,9 @@ private:
std::string _result;
};
// end of data_structure group
/// @}
/**
* @endcond
*/
NS_CC_END

View File

@ -145,6 +145,8 @@ bool Director::init(void)
_contentScaleFactor = 1.0f;
_console = new (std::nothrow) Console;
// scheduler
_scheduler = new (std::nothrow) Scheduler();
// action manager
@ -168,8 +170,6 @@ bool Director::init(void)
_renderer = new (std::nothrow) Renderer;
_console = new (std::nothrow) Console;
return true;
}
@ -248,8 +248,6 @@ void Director::setGLDefaultValues()
CCASSERT(_openGLView, "opengl view should not be null");
setAlphaBlending(true);
// FIXME: Fix me, should enable/disable depth test according the depth format as cocos2d-iphone did
// [self setDepthTest: view_.depthFormat];
setDepthTest(false);
setProjection(_projection);
}

View File

@ -62,67 +62,73 @@ class Camera;
class Console;
/**
@brief Class that creates and handles the main Window and manages how
and when to execute the Scenes.
The Director is also responsible for:
- initializing the OpenGL context
- setting the OpenGL pixel format (default on is RGB565)
- setting the OpenGL buffer depth (default one is 0-bit)
- setting the projection (default one is 3D)
- setting the orientation (default one is Portrait)
Since the Director is a singleton, the standard way to use it is by calling:
_ Director::getInstance()->methodName();
The Director also sets the default OpenGL context:
- GL_TEXTURE_2D is enabled
- GL_VERTEX_ARRAY is enabled
- GL_COLOR_ARRAY is enabled
- GL_TEXTURE_COORD_ARRAY is enabled
*/
* @brief Matrix stack type.
*/
enum class MATRIX_STACK_TYPE
{
/// Model view matrix stack
MATRIX_STACK_MODELVIEW,
/// projection matrix stack
MATRIX_STACK_PROJECTION,
/// texture matrix stack
MATRIX_STACK_TEXTURE
};
/**
@brief Class that creates and handles the main Window and manages how
and when to execute the Scenes.
The Director is also responsible for:
- initializing the OpenGL context
- setting the OpenGL buffer depth (default one is 0-bit)
- setting the projection (default one is 3D)
Since the Director is a singleton, the standard way to use it is by calling:
_ Director::getInstance()->methodName();
*/
class CC_DLL Director : public Ref
{
public:
/** Director will trigger an event when projection type is changed. */
static const char *EVENT_PROJECTION_CHANGED;
/** Director will trigger an event after Schedule::update() is invoked. */
static const char* EVENT_AFTER_UPDATE;
/** Director will trigger an event after Scene::render() is invoked. */
static const char* EVENT_AFTER_VISIT;
/** Director will trigger an event after a scene is drawn, the data is sent to GPU. */
static const char* EVENT_AFTER_DRAW;
/** @typedef ccDirectorProjection
Possible OpenGL projections used by director
/**
* @brief Possible OpenGL projections used by director
*/
enum class Projection
{
/// sets a 2D projection (orthogonal projection)
/// Sets a 2D projection (orthogonal projection).
_2D,
/// sets a 3D projection with a fovy=60, znear=0.5f and zfar=1500.
/// Sets a 3D projection with a fovy=60, znear=0.5f and zfar=1500.
_3D,
/// it calls "updateProjection" on the projection delegate.
/// It calls "updateProjection" on the projection delegate.
CUSTOM,
/// Default projection is 3D projection
/// Default projection is 3D projection.
DEFAULT = _3D,
};
/** returns a shared instance of the director */
/** Returns a shared instance of the director. */
static Director* getInstance();
/** @deprecated Use getInstance() instead */
/** @deprecated Use getInstance() instead. */
CC_DEPRECATED_ATTRIBUTE static Director* sharedDirector() { return Director::getInstance(); }
/**
* @js ctor
*/
Director(void);
Director();
/**
* @js NA
* @lua NA
@ -132,105 +138,128 @@ public:
// attribute
/** Get current running Scene. Director can only run one Scene at a time */
/** Gets current running Scene. Director can only run one Scene at a time. */
inline Scene* getRunningScene() { return _runningScene; }
/** Get the FPS value */
/** Gets the FPS value. */
inline double getAnimationInterval() { return _animationInterval; }
/** Set the FPS value. */
/** Sets the FPS value. FPS = 1/internal. */
virtual void setAnimationInterval(double interval) = 0;
/** Whether or not to display the FPS on the bottom-left corner */
/** Whether or not to display the FPS on the bottom-left corner. */
inline bool isDisplayStats() { return _displayStats; }
/** Display the FPS on the bottom-left corner */
/** Display the FPS on the bottom-left corner. */
inline void setDisplayStats(bool displayStats) { _displayStats = displayStats; }
/** seconds per frame */
/** Get seconds per frame. */
inline float getSecondsPerFrame() { return _secondsPerFrame; }
/** Get the GLView, where everything is rendered
* @js NA
* @lua NA
*/
/**
* Get the GLView.
* @js NA
* @lua NA
*/
inline GLView* getOpenGLView() { return _openGLView; }
/**
* Sets the GLView.
*
* @lua NA
* @js NA
*/
void setOpenGLView(GLView *openGLView);
/** Gets singleton of TextureCache. */
TextureCache* getTextureCache() const;
/** Whether or not `_nextDeltaTimeZero` is set to 0. */
inline bool isNextDeltaTimeZero() { return _nextDeltaTimeZero; }
/**
* Sets the detal time between current frame and next frame is 0.
* This value will be used in Schedule, and will affect all functions that are using frame detal time, such as Actions.
* This value will take effect only one time.
*/
void setNextDeltaTimeZero(bool nextDeltaTimeZero);
/** Whether or not the Director is paused */
/** Whether or not the Director is paused. */
inline bool isPaused() { return _paused; }
/** How many frames were called since the director started */
inline unsigned int getTotalFrames() { return _totalFrames; }
/** Sets an OpenGL projection
/** Gets an OpenGL projection.
@since v0.8.2
* @js NA
* @lua NA
*/
inline Projection getProjection() { return _projection; }
/** Sets OpenGL projection. */
void setProjection(Projection projection);
/** Sets the glViewport*/
/** Sets the glViewport.*/
void setViewport();
/** How many frames were called since the director started */
/** Whether or not the replaced scene will receive the cleanup message.
If the new scene is pushed, then the old scene won't receive the "cleanup" message.
If the new scene replaces the old one, the it will receive the "cleanup" message.
@since v0.99.0
* If the new scene is pushed, then the old scene won't receive the "cleanup" message.
* If the new scene replaces the old one, the it will receive the "cleanup" message.
* @since v0.99.0
*/
inline bool isSendCleanupToScene() { return _sendCleanupToScene; }
/** This object will be visited after the main scene is visited.
This object MUST implement the "visit" selector.
Useful to hook a notification object, like Notifications (http://github.com/manucorporat/CCNotifications)
@since v0.99.5
* This object MUST implement the "visit" function.
* Useful to hook a notification object, like Notifications (http://github.com/manucorporat/CCNotifications)
* @since v0.99.5
*/
Node* getNotificationNode() const { return _notificationNode; }
/**
* Sets the notification node.
* @see Director::getNotificationNode()
*/
void setNotificationNode(Node *node);
// window size
/** returns the size of the OpenGL view in points.
*/
/** Returns the size of the OpenGL view in points. */
const Size& getWinSize() const;
/** returns the size of the OpenGL view in pixels.
*/
/** Returns the size of the OpenGL view in pixels. */
Size getWinSizeInPixels() const;
/** returns visible size of the OpenGL view in points.
* the value is equal to getWinSize if don't invoke
* GLView::setDesignResolutionSize()
/**
* Returns visible size of the OpenGL view in points.
* The value is equal to `Director::getWinSize()` if don't invoke `GLView::setDesignResolutionSize()`.
*/
Size getVisibleSize() const;
/** returns visible origin of the OpenGL view in points.
*/
/** Returns visible origin coordinate of the OpenGL view in points. */
Vec2 getVisibleOrigin() const;
/** converts a UIKit coordinate to an OpenGL coordinate
Useful to convert (multi) touch coordinates to the current layout (portrait or landscape)
/**
* Converts a screen coordinate to an OpenGL coordinate.
* Useful to convert (multi) touch coordinates to the current layout (portrait or landscape).
*/
Vec2 convertToGL(const Vec2& point);
/** converts an OpenGL coordinate to a UIKit coordinate
Useful to convert node points to window points for calls such as glScissor
/**
* Converts an OpenGL coordinate to a screen coordinate.
* Useful to convert node points to window points for calls such as glScissor.
*/
Vec2 convertToUI(const Vec2& point);
/// FIXME: missing description
/**
* Gets the distance between camera and near clipping frane.
* It is correct for default camera that near clipping frane is the same as screen.
*/
float getZEye() const;
// Scene Management
/** Enters the Director's main loop with the given Scene.
/**
* Enters the Director's main loop with the given Scene.
* Call it to run only your FIRST scene.
* Don't call it if there is already a running scene.
*
@ -238,23 +267,26 @@ public:
*/
void runWithScene(Scene *scene);
/** Suspends the execution of the running scene, pushing it on the stack of suspended scenes.
/**
* Suspends the execution of the running scene, pushing it on the stack of suspended scenes.
* The new scene will be executed.
* Try to avoid big stacks of pushed scenes to reduce memory allocation.
* ONLY call it if there is a running scene.
*/
void pushScene(Scene *scene);
/** Pops out a scene from the stack.
/**
* Pops out a scene from the stack.
* This scene will replace the running one.
* The running scene will be deleted. If there are no more scenes in the stack the execution is terminated.
* ONLY call it if there is a running scene.
*/
void popScene();
/** Pops out all scenes from the stack until the root scene in the queue.
/**
* Pops out all scenes from the stack until the root scene in the queue.
* This scene will replace the running one.
* Internally it will call `popToSceneStackLevel(1)`
* Internally it will call `popToSceneStackLevel(1)`.
*/
void popToRootScene();
@ -271,132 +303,153 @@ public:
void replaceScene(Scene *scene);
/** Ends the execution, releases the running scene.
It doesn't remove the OpenGL view from its parent. You have to do it manually.
* @lua endToLua
*/
void end();
/** Pauses the running scene.
The running scene will be _drawed_ but all scheduled timers will be paused
While paused, the draw rate will be 4 FPS to reduce CPU consumption
* The running scene will be _drawed_ but all scheduled timers will be paused.
* While paused, the draw rate will be 4 FPS to reduce CPU consumption.
*/
void pause();
/** Resumes the paused scene
The scheduled timers will be activated again.
The "delta time" will be 0 (as if the game wasn't paused)
/** Resumes the paused scene.
* The scheduled timers will be activated again.
* The "delta time" will be 0 (as if the game wasn't paused).
*/
void resume();
/** Restart the director
*/
/** Restart the director. */
void restart();
/** Stops the animation. Nothing will be drawn. The main loop won't be triggered anymore.
If you don't want to pause your animation call [pause] instead.
* If you don't want to pause your animation call [pause] instead.
*/
virtual void stopAnimation() = 0;
/** The main loop is triggered again.
Call this function only if [stopAnimation] was called earlier
@warning Don't call this function to start the main loop. To run the main loop call runWithScene
* Call this function only if [stopAnimation] was called earlier.
* @warning Don't call this function to start the main loop. To run the main loop call runWithScene.
*/
virtual void startAnimation() = 0;
/** Draw the scene.
This method is called every frame. Don't call it manually.
*/
* This method is called every frame. Don't call it manually.
*/
void drawScene();
// Memory Helper
/** Removes all cocos2d cached data.
It will purge the TextureCache, SpriteFrameCache, LabelBMFont cache
@since v0.99.3
* It will purge the TextureCache, SpriteFrameCache, LabelBMFont cache
* @since v0.99.3
*/
void purgeCachedData();
/** sets the default values based on the Configuration info */
/** Sets the default values based on the Configuration info. */
void setDefaultValues();
// OpenGL Helper
/** sets the OpenGL default values */
/** Sets the OpenGL default values.
* It will enable alpha blending, disable depth test.
*/
void setGLDefaultValues();
/** enables/disables OpenGL alpha blending */
/** Enables/disables OpenGL alpha blending. */
void setAlphaBlending(bool on);
/** set clear values for the color buffers, value range of each element is [0.0, 1.0] */
/** Sets clear values for the color buffers, value range of each element is [0.0, 1.0]. */
void setClearColor(const Color4F& clearColor);
/** enables/disables OpenGL depth test */
/** Enables/disables OpenGL depth test. */
void setDepthTest(bool on);
virtual void mainLoop() = 0;
/** The size in pixels of the surface. It could be different than the screen size.
High-res devices might have a higher surface size than the screen size.
Only available when compiled using SDK >= 4.0.
@since v0.99.4
* High-res devices might have a higher surface size than the screen size.
* Only available when compiled using SDK >= 4.0.
* @since v0.99.4
*/
void setContentScaleFactor(float scaleFactor);
/**
* Gets content scale factor.
* @see Director::setContentScaleFactor()
*/
float getContentScaleFactor() const { return _contentScaleFactor; }
/** Gets the Scheduler associated with this director
@since v2.0
/** Gets the Scheduler associated with this director.
* @since v2.0
*/
Scheduler* getScheduler() const { return _scheduler; }
/** Sets the Scheduler associated with this director
@since v2.0
/** Sets the Scheduler associated with this director.
* @since v2.0
*/
void setScheduler(Scheduler* scheduler);
/** Gets the ActionManager associated with this director
@since v2.0
/** Gets the ActionManager associated with this director.
* @since v2.0
*/
ActionManager* getActionManager() const { return _actionManager; }
/** Sets the ActionManager associated with this director
@since v2.0
/** Sets the ActionManager associated with this director.
* @since v2.0
*/
void setActionManager(ActionManager* actionManager);
/** Gets the EventDispatcher associated with this director
@since v3.0
/** Gets the EventDispatcher associated with this director.
* @since v3.0
*/
EventDispatcher* getEventDispatcher() const { return _eventDispatcher; }
/** Sets the EventDispatcher associated with this director
@since v3.0
/** Sets the EventDispatcher associated with this director.
* @since v3.0
*/
void setEventDispatcher(EventDispatcher* dispatcher);
/** Returns the Renderer
@since v3.0
/** Returns the Renderer associated with this director.
* @since v3.0
*/
Renderer* getRenderer() const { return _renderer; }
/** Returns the Console
@since v3.0
/** Returns the Console associated with this director.
* @since v3.0
*/
Console* getConsole() const { return _console; }
/* Gets delta time since last tick to main loop */
/* Gets delta time since last tick to main loop. */
float getDeltaTime() const;
/**
* get Frame Rate
* Gets Frame Rate.
*/
float getFrameRate() const { return _frameRate; }
/** Clones a specified type matrix and put it to the top of specified type of matrix stack. */
void pushMatrix(MATRIX_STACK_TYPE type);
/** Pops the top matrix of the specified type of matrix stack. */
void popMatrix(MATRIX_STACK_TYPE type);
/** Adds an identity matrix to the top of specified type of matrxi stack. */
void loadIdentityMatrix(MATRIX_STACK_TYPE type);
/**
* Adds a matrix to the top of specified type of matrix stack.
*
* @param type Matrix type.
* @param mat The matrix that to be added.
*/
void loadMatrix(MATRIX_STACK_TYPE type, const Mat4& mat);
/**
* Multipies a matrix to the top of specified type of matrix stack.
*
* @param type Matrix type.
* @param mat The matrix that to be multipied.
*/
void multiplyMatrix(MATRIX_STACK_TYPE type, const Mat4& mat);
/** Gets the top matrix of specified type of matrix stack. */
const Mat4& getMatrix(MATRIX_STACK_TYPE type);
/** Cleras all types of matrix stack, and add indentity matrix to these matrix stacks. */
void resetMatrixStack();
protected:

View File

@ -40,20 +40,25 @@ NS_CC_BEGIN
class Ref;
/** Interface that defines how to clone an Ref */
/**
* Interface that defines how to clone an Ref.
* @lua NA
* @js NA
*/
class CC_DLL Clonable
{
public:
/** returns a copy of the Ref */
/** Returns a copy of the Ref. */
virtual Clonable* clone() const = 0;
/**
* @js NA
* @lua NA
*/
virtual ~Clonable() {};
/** returns a copy of the Ref.
* @deprecated Use clone() instead
/** Returns a copy of the Ref.
* @deprecated Use clone() instead.
*/
CC_DEPRECATED_ATTRIBUTE Ref* copy() const
{
@ -63,6 +68,10 @@ public:
}
};
/**
* Ref is used for reference count manangement. If a class inherits from Ref,
* then it is easy to be shared in different places.
*/
class CC_DLL Ref
{
public:
@ -125,6 +134,8 @@ protected:
public:
/**
* Destructor
*
* @js NA
* @lua NA
*/

View File

@ -46,11 +46,10 @@ NS_CC_BEGIN
class Scheduler;
typedef std::function<void(float)> ccSchedulerFunc;
//
// Timer
//
/** @brief Light-weight timer */
//
/**
* @cond
*/
class CC_DLL Timer : public Ref
{
protected:
@ -106,13 +105,9 @@ class CC_DLL TimerTargetCallback : public Timer
public:
TimerTargetCallback();
/** Initializes a timer with a target, a lambda and an interval in seconds, repeat in number of times to repeat, delay in seconds. */
// Initializes a timer with a target, a lambda and an interval in seconds, repeat in number of times to repeat, delay in seconds.
bool initWithCallback(Scheduler* scheduler, const ccSchedulerFunc& callback, void *target, const std::string& key, float seconds, unsigned int repeat, float delay);
/**
* @js NA
* @lua NA
*/
inline const ccSchedulerFunc& getCallback() const { return _callback; };
inline const std::string& getKey() const { return _key; };
@ -142,9 +137,11 @@ private:
#endif
//
// Scheduler
//
/**
* @endcond
*/
struct _listEntry;
struct _hashSelectorEntry;
struct _hashUpdateEntry;
@ -167,21 +164,39 @@ The 'custom selectors' should be avoided when possible. It is faster, and consum
class CC_DLL Scheduler : public Ref
{
public:
// Priority level reserved for system services.
/** Priority level reserved for system services.
* @lua NA
* @js NA
*/
static const int PRIORITY_SYSTEM;
// Minimum priority level for user scheduling.
/** Minimum priority level for user scheduling.
* Priority level of user scheduling should bigger then this value.
*
* @lua NA
* @js NA
*/
static const int PRIORITY_NON_SYSTEM_MIN;
/**
* Constructor
*
* @js ctor
*/
Scheduler();
/**
* Destructor
*
* @js NA
* @lua NA
*/
virtual ~Scheduler();
/**
* Gets the time scale of schedule callbacks.
* @see Scheduler::setTimeScale()
*/
inline float getTimeScale() { return _timeScale; }
/** Modifies the time of all scheduled callbacks.
You can use this property to create a 'slow motion' or 'fast forward' effect.
@ -193,7 +208,7 @@ public:
inline void setTimeScale(float timeScale) { _timeScale = timeScale; }
/** 'update' the scheduler.
You should NEVER call this method, unless you know what you are doing.
* You should NEVER call this method, unless you know what you are doing.
* @js NA
* @lua NA
*/
@ -208,30 +223,54 @@ public:
If 'interval' is 0, it will be called every frame, but if so, it's recommended to use 'scheduleUpdate' instead.
If the 'callback' is already scheduled, then only the interval parameter will be updated without re-scheduling it again.
repeat let the action be repeated repeat + 1 times, use CC_REPEAT_FOREVER to let the action run continuously
delay is the amount of time the action will wait before it'll start
@param key The key to identify the callback
delay is the amount of time the action will wait before it'll start.
@param callback The callback function.
@param target The target of the callback function.
@param interval The interval to schedule the callback. If the value is 0, then the callback will be scheduled every frame.
@param repeat repeat+1 times to schedule the callback.
@param delay Schedule call back after `delay` seconds. If the value is not 0, the first schedule will happen after `delay` seconds.
But it will only affect first schedule. After first schedule, the delay time is determined by `interval`.
@param paused Whether or not to pause the schedule.
@param key The key to identify the callback function, because there is not way to identify a std::function<>.
@since v3.0
*/
void schedule(const ccSchedulerFunc& callback, void *target, float interval, unsigned int repeat, float delay, bool paused, const std::string& key);
/** Calls scheduleCallback with CC_REPEAT_FOREVER and a 0 delay
/** The scheduled method will be called every 'interval' seconds for ever.
@param callback The callback function.
@param target The target of the callback function.
@param interval The interval to schedule the callback. If the value is 0, then the callback will be scheduled every frame.
@param paused Whether or not to pause the schedule.
@param key The key to identify the callback function, because there is not way to identify a std::function<>.
@since v3.0
*/
void schedule(const ccSchedulerFunc& callback, void *target, float interval, bool paused, const std::string& key);
/** The scheduled method will be called every 'interval' seconds.
/** The scheduled method will be called every `interval` seconds.
If paused is true, then it won't be called until it is resumed.
If 'interval' is 0, it will be called every frame, but if so, it's recommended to use 'scheduleUpdate' instead.
If the selector is already scheduled, then only the interval parameter will be updated without re-scheduling it again.
repeat let the action be repeated repeat + 1 times, use CC_REPEAT_FOREVER to let the action run continuously
delay is the amount of time the action will wait before it'll start
@since v3.0, repeat and delay added in v1.1
@param selector The callback function.
@param target The target of the callback function.
@param interval The interval to schedule the callback. If the value is 0, then the callback will be scheduled every frame.
@param repeat repeat+1 times to schedule the callback.
@param delay Schedule call back after `delay` seconds. If the value is not 0, the first schedule will happen after `delay` seconds.
But it will only affect first schedule. After first schedule, the delay time is determined by `interval`.
@param paused Whether or not to pause the schedule.
@since v3.0
*/
void schedule(SEL_SCHEDULE selector, Ref *target, float interval, unsigned int repeat, float delay, bool paused);
/** calls scheduleSelector with CC_REPEAT_FOREVER and a 0 delay */
/** The scheduled method will be called every `interval` seconds for ever.
@param selector The callback function.
@param target The target of the callback function.
@param interval The interval to schedule the callback. If the value is 0, then the callback will be scheduled every frame.
@param paused Whether or not to pause the schedule.
*/
void schedule(SEL_SCHEDULE selector, Ref *target, float interval, bool paused);
/** Schedules the 'update' selector for a given target with a given priority.
@ -249,11 +288,15 @@ public:
}
#if CC_ENABLE_SCRIPT_BINDING
// schedule for script bindings
// Schedule for script bindings.
/** The scheduled script callback will be called every 'interval' seconds.
If paused is true, then it won't be called until it is resumed.
If 'interval' is 0, it will be called every frame.
return schedule script entry ID, used for unscheduleScriptFunc().
@warn Don't invoke this function unless you know what you are doing.
@js NA
@lua NA
*/
unsigned int scheduleScriptFunc(unsigned int handler, float interval, bool paused);
#endif
@ -263,23 +306,29 @@ public:
/** Unschedules a callback for a key and a given target.
If you want to unschedule the 'callbackPerFrame', use unscheduleUpdate.
@param key The key to identify the callback function, because there is not way to identify a std::function<>.
@param target The target to be unscheduled.
@since v3.0
*/
void unschedule(const std::string& key, void *target);
/** Unschedule a selector for a given target.
If you want to unschedule the "update", use unscheudleUpdate.
/** Unschedules a selector for a given target.
If you want to unschedule the "update", use `unscheudleUpdate()`.
@param selector The selector that is unscheduled.
@param target The target of the unscheduled selector.
@since v3.0
*/
void unschedule(SEL_SCHEDULE selector, Ref *target);
/** Unschedules the update selector for a given target
@param target The target to be unscheduled.
@since v0.99.3
*/
void unscheduleUpdate(void *target);
/** Unschedules all selectors for a given target.
This also includes the "update" selector.
@param target The target to be unscheduled.
@since v0.99.3
@js unscheduleCallbackForTarget
@lua NA
@ -290,16 +339,22 @@ public:
You should NEVER call this method, unless you know what you are doing.
@since v0.99.3
*/
void unscheduleAll(void);
void unscheduleAll();
/** Unschedules all selectors from all targets with a minimum priority.
You should only call this with kPriorityNonSystemMin or higher.
You should only call this with `PRIORITY_NON_SYSTEM_MIN` or higher.
@param minPriority The minimum priority of selector to be unscheduled. Which means, all selectors which
priority is higher than minPriority will be unscheduled.
@since v2.0.0
*/
void unscheduleAllWithMinPriority(int minPriority);
#if CC_ENABLE_SCRIPT_BINDING
/** Unschedule a script entry. */
/** Unschedule a script entry.
* @warn Don't invoke this function unless you know what you are doing.
* @js NA
* @lua NA
*/
void unscheduleScriptEntry(unsigned int scheduleScriptEntryID);
#endif
@ -308,11 +363,17 @@ public:
// isScheduled
/** Checks whether a callback associated with 'key' and 'target' is scheduled.
@param key The key to identify the callback function, because there is not way to identify a std::function<>.
@param target The target of the callback.
@return True if the specified callback is invoked, false if not.
@since v3.0.0
*/
bool isScheduled(const std::string& key, void *target);
/** Checks whether a selector for a given taget is scheduled.
@param selector The selector to be checked.
@param target The target of the callback.
@return True if the specified selector is invoked, false if not.
@since v3.0
*/
bool isScheduled(SEL_SCHEDULE selector, Ref *target);
@ -322,6 +383,7 @@ public:
/** Pauses the target.
All scheduled selectors/update for a given target won't be 'ticked' until the target is resumed.
If the target is not present, nothing happens.
@param target The target to be paused.
@since v0.99.3
*/
void pauseTarget(void *target);
@ -329,15 +391,18 @@ public:
/** Resumes the target.
The 'target' will be unpaused, so all schedule selectors/update will be 'ticked' again.
If the target is not present, nothing happens.
@param target The target to be resumed.
@since v0.99.3
*/
void resumeTarget(void *target);
/** Returns whether or not the target is paused
@since v1.0.0
* In js: var isTargetPaused(var jsObject)
* @lua NA
*/
/** Returns whether or not the target is paused.
* @param target The target to be checked.
* @return True if the target is paused, false if not.
* @since v1.0.0
* @js isTargetPaused(var jsObject)
* @lua NA
*/
bool isTargetPaused(void *target);
/** Pause all selectors from all targets.
@ -347,19 +412,23 @@ public:
std::set<void*> pauseAllTargets();
/** Pause all selectors from all targets with a minimum priority.
You should only call this with kPriorityNonSystemMin or higher.
You should only call this with PRIORITY_NON_SYSTEM_MIN or higher.
@param minPriority The minimum priority of selector to be paused. Which means, all selectors which
priority is higher than minPriority will be paused.
@since v2.0.0
*/
std::set<void*> pauseAllTargetsWithMinPriority(int minPriority);
/** Resume selectors on a set of targets.
This can be useful for undoing a call to pauseAllSelectors.
@param targetsToResume The set of targets to be resumed.
@since v2.0.0
*/
void resumeTargets(const std::set<void*>& targetsToResume);
/** calls a function on the cocos2d thread. Useful when you need to call a cocos2d function from another thread.
/** Calls a function on the cocos2d thread. Useful when you need to call a cocos2d function from another thread.
This function is thread safe.
@param function The function to be run in cocos2d thread.
@since v3.0
*/
void performFunctionInCocosThread( const std::function<void()> &function);
@ -374,7 +443,7 @@ public:
If the selector is already scheduled, then only the interval parameter will be updated without re-scheduling it again.
repeat let the action be repeated repeat + 1 times, use CC_REPEAT_FOREVER to let the action run continuously
delay is the amount of time the action will wait before it'll start
@deprecated Please use 'Scheduler::schedule' instead.
@deprecated Please use `Scheduler::schedule` instead.
@since v0.99.3, repeat and delay added in v1.1
*/
CC_DEPRECATED_ATTRIBUTE void scheduleSelector(SEL_SCHEDULE selector, Ref *target, float interval, unsigned int repeat, float delay, bool paused)
@ -382,8 +451,8 @@ public:
schedule(selector, target, interval, repeat, delay, paused);
};
/** calls scheduleSelector with CC_REPEAT_FOREVER and a 0 delay
* @deprecated Please use 'Scheduler::schedule' instead.
/** Calls scheduleSelector with CC_REPEAT_FOREVER and a 0 delay.
* @deprecated Please use `Scheduler::schedule` instead.
*/
CC_DEPRECATED_ATTRIBUTE void scheduleSelector(SEL_SCHEDULE selector, Ref *target, float interval, bool paused)
{

View File

@ -31,7 +31,7 @@ NS_CC_BEGIN
CC_DLL const char* cocos2dVersion()
{
return "cocos2d-x 3.5rc0";
return "cocos2d-x 3.5";
}
NS_CC_END

View File

@ -1276,7 +1276,10 @@ Node* CSLoader::nodeWithFlatBuffersForSimulator(const flatbuffers::NodeTree *nod
readername.append("Reader");
NodeReaderProtocol* reader = dynamic_cast<NodeReaderProtocol*>(ObjectFactory::getInstance()->createObject(readername));
node = reader->createNodeWithFlatBuffers(options->data());
if (reader)
{
node = reader->createNodeWithFlatBuffers(options->data());
}
Widget* widget = dynamic_cast<Widget*>(node);
if (widget)

View File

@ -512,7 +512,6 @@ namespace cocostudio
node->setColor(color);
node->setTag(tag);
node->setUserObject(timeline::ActionTimelineData::create(actionTag));
ObjectExtensionData* extensionData = ObjectExtensionData::create();
extensionData->setCustomProperty(customProperty);

View File

@ -799,8 +799,6 @@ namespace cocostudio
extensionData->setActionTag(actionTag);
node->setUserObject(extensionData);
widget->setUserObject(timeline::ActionTimelineData::create(actionTag));
bool touchEnabled = options->touchEnabled() != 0;
widget->setTouchEnabled(touchEnabled);

View File

@ -67,7 +67,8 @@ enum class LanguageType
POLISH,
TURKISH,
UKRAINIAN,
ROMANIAN
ROMANIAN,
BULGARIAN
};
// END of platform group

View File

@ -188,6 +188,10 @@ LanguageType Application::getCurrentLanguage()
{
ret = LanguageType::ROMANIAN;
}
else if (0 == strcmp("bg", pLanguageName))
{
ret = LanguageType::BULGARIAN;
}
return ret;
}

View File

@ -161,6 +161,9 @@ LanguageType Application::getCurrentLanguage()
else if ([languageCode isEqualToString:@"ro"]){
ret = LanguageType::ROMANIAN;
}
else if ([languageCode isEqualToString:@"bg"]){
ret = LanguageType::BULGARIAN;
}
return ret;
}

View File

@ -257,6 +257,10 @@ LanguageType Application::getCurrentLanguage()
{
ret = LanguageType::ROMANIAN;
}
else if (0 == strcmp("bg", pLanguageName))
{
ret = LanguageType::BULGARIAN;
}
return ret;
}

View File

@ -215,6 +215,9 @@ LanguageType Application::getCurrentLanguage()
else if ([languageCode isEqualToString:@"ro"]){
ret = LanguageType::ROMANIAN;
}
else if ([languageCode isEqualToString:@"bg"]){
ret = LanguageType::BULGARIAN;
}
return ret;
}

View File

@ -194,6 +194,9 @@ LanguageType Application::getCurrentLanguage()
case LANG_ROMANIAN:
ret = LanguageType::ROMANIAN;
break;
case LANG_BULGARIAN:
ret = LanguageType::BULGARIAN;
break;
}
return ret;

View File

@ -82,7 +82,7 @@ void OpenGLES::Initialize()
// These attributes can be used to request D3D11 WARP.
// They are used if eglInitialize fails with both the default display attributes and the 9_3 display attributes.
EGL_PLATFORM_ANGLE_TYPE_ANGLE, EGL_PLATFORM_ANGLE_TYPE_D3D11_ANGLE,
EGL_PLATFORM_ANGLE_USE_WARP_ANGLE, EGL_TRUE,
EGL_PLATFORM_ANGLE_DEVICE_TYPE_ANGLE, EGL_PLATFORM_ANGLE_DEVICE_TYPE_WARP_ANGLE,
EGL_ANGLE_DISPLAY_ALLOW_RENDER_TO_BACK_BUFFER, EGL_TRUE,
EGL_NONE,
};

View File

@ -205,6 +205,10 @@ LanguageType Application::getCurrentLanguage()
{
ret = LanguageType::ROMANIAN;
}
else if (strncmp(code, "bg", 2) == 0)
{
ret = LanguageType::BULGARIAN;
}
return ret;
}

View File

@ -297,7 +297,8 @@ void MeshCommand::batchDraw()
_glProgramState->applyGLProgram(_mv);
_glProgramState->applyUniforms();
if (Director::getInstance()->getRunningScene()->getLights().size() > 0)
const auto& scene = Director::getInstance()->getRunningScene();
if (scene && scene->getLights().size() > 0)
setLightUniforms();
// Draw
@ -339,7 +340,8 @@ void MeshCommand::execute()
_glProgramState->apply(_mv);
if (Director::getInstance()->getRunningScene()->getLights().size() > 0)
const auto& scene = Director::getInstance()->getRunningScene();
if (scene && scene->getLights().size() > 0)
setLightUniforms();
glBindBuffer(GL_ELEMENT_ARRAY_BUFFER, _indexBuffer);

View File

@ -30,41 +30,68 @@
NS_CC_BEGIN
/** Command used to render one or more Quads */
/**
Command used to render one or more Quads, similar to TrianglesCommand.
Every QuadCommand will have generate material ID by give textureID, glProgramState, Blend function
if the material id is the same, these QuadCommands could be batched to save draw call.
*/
class CC_DLL QuadCommand : public RenderCommand
{
public:
/**Constructor.*/
QuadCommand();
/**Destructor.*/
~QuadCommand();
/** Initializes the command with a globalZOrder, a texture ID, a `GLProgram`, a blending function, a pointer to quads,
* quantity of quads, and the Model View transform to be used for the quads */
/** Initializes the command.
@param globalOrder GlobalZOrder of the command.
@param textureID The openGL handle of the used texture.
@param glProgramState The specified glProgram and its uniform.
@param blendType Blend function for the command.
@param quads Rendered quads for the command.
@param quadCount The number of quads when rendering.
@param mv ModelView matrix for the command.
@param flags to indicate that the command is using 3D rendering or not.
*/
void init(float globalOrder, GLuint textureID, GLProgramState* shader, const BlendFunc& blendType, V3F_C4B_T2F_Quad* quads, ssize_t quadCount,
const Mat4& mv, uint32_t flags);
/**Deprecated function, the params is similar as the upper init function, with flags equals 0.*/
CC_DEPRECATED_ATTRIBUTE void init(float globalOrder, GLuint textureID, GLProgramState* shader, const BlendFunc& blendType, V3F_C4B_T2F_Quad* quads, ssize_t quadCount,
const Mat4& mv);
/**Apply the texture, shaders, programs, blend functions to GPU pipeline.*/
void useMaterial() const;
/**Get the material id of command.*/
inline uint32_t getMaterialID() const { return _materialID; }
/**Get the openGL texture handle.*/
inline GLuint getTextureID() const { return _textureID; }
/**Get the pointer of the rendered quads.*/
inline V3F_C4B_T2F_Quad* getQuads() const { return _quads; }
/**Get the number of quads for rendering.*/
inline ssize_t getQuadCount() const { return _quadsCount; }
/**Get the glprogramstate.*/
inline GLProgramState* getGLProgramState() const { return _glProgramState; }
/**Get the blend function.*/
inline BlendFunc getBlendType() const { return _blendType; }
/**Get the model view matrix.*/
inline const Mat4& getModelView() const { return _mv; }
protected:
/**Generate the material ID by textureID, glProgramState, and blend function.*/
void generateMaterialID();
/**Generated material id.*/
uint32_t _materialID;
/**OpenGL handle for texture.*/
GLuint _textureID;
/**GLprogramstate for the commmand. encapsulate shaders and uniforms.*/
GLProgramState* _glProgramState;
/**Blend function when rendering the triangles.*/
BlendFunc _blendType;
/**The pointer to the rendered quads.*/
V3F_C4B_T2F_Quad* _quads;
/**The number of quads for rendering.*/
ssize_t _quadsCount;
/**Model view matrix when rendering the triangles.*/
Mat4 _mv;
};

View File

@ -29,47 +29,81 @@
#include "renderer/CCGLProgramState.h"
NS_CC_BEGIN
/**
Command used to render one or more Triangles, which is similar to QuadCommand.
Every TrianglesCommand will have generate material ID by give textureID, glProgramState, Blend function
if the material id is the same, these TrianglesCommands could be batched to save draw call.
*/
class CC_DLL TrianglesCommand : public RenderCommand
{
public:
/**The structure of Triangles. */
struct Triangles
{
/**Vertex data pointer.*/
V3F_C4B_T2F* verts;
/**Index data pointer.*/
unsigned short* indices;
/**The number of vertices.*/
ssize_t vertCount;
/**The number of indices.*/
ssize_t indexCount;
};
/**Construtor.*/
TrianglesCommand();
/**Destructor.*/
~TrianglesCommand();
/** Initializes the command with a globalZOrder, a texture ID, a `GLProgram`, a blending function, a pointer to triangles,
* quantity of quads, and the Model View transform to be used for the quads */
/** Initializes the command.
@param globalOrder GlobalZOrder of the command.
@param textureID The openGL handle of the used texture.
@param glProgramState The specified glProgram and its uniform.
@param blendType Blend function for the command.
@param triangles Rendered triangles for the command.
@param mv ModelView matrix for the command.
@param flags to indicate that the command is using 3D rendering or not.
*/
void init(float globalOrder, GLuint textureID, GLProgramState* glProgramState, BlendFunc blendType, const Triangles& triangles,const Mat4& mv, uint32_t flags);
/**Deprecated function, the params is similar as the upper init function, with flags equals 0.*/
CC_DEPRECATED_ATTRIBUTE void init(float globalOrder, GLuint textureID, GLProgramState* glProgramState, BlendFunc blendType, const Triangles& triangles,const Mat4& mv);
/**Apply the texture, shaders, programs, blend functions to GPU pipeline.*/
void useMaterial() const;
/**Get the material id of command.*/
inline uint32_t getMaterialID() const { return _materialID; }
/**Get the openGL texture handle.*/
inline GLuint getTextureID() const { return _textureID; }
/**Get a const reference of triangles.*/
inline const Triangles& getTriangles() const { return _triangles; }
/**Get the vertex count in the triangles.*/
inline ssize_t getVertexCount() const { return _triangles.vertCount; }
/**Get the index count of the triangles.*/
inline ssize_t getIndexCount() const { return _triangles.indexCount; }
/**Get the vertex data pointer.*/
inline const V3F_C4B_T2F* getVertices() const { return _triangles.verts; }
/**Get the index data pointer.*/
inline const unsigned short* getIndices() const { return _triangles.indices; }
/**Get the glprogramstate.*/
inline GLProgramState* getGLProgramState() const { return _glProgramState; }
/**Get the blend function.*/
inline BlendFunc getBlendType() const { return _blendType; }
/**Get the model view matrix.*/
inline const Mat4& getModelView() const { return _mv; }
protected:
/**Generate the material ID by textureID, glProgramState, and blend function.*/
void generateMaterialID();
/**Generated material id.*/
uint32_t _materialID;
/**OpenGL handle for texture.*/
GLuint _textureID;
/**GLprogramstate for the commmand. encapsulate shaders and uniforms.*/
GLProgramState* _glProgramState;
/**Blend function when rendering the triangles.*/
BlendFunc _blendType;
/**Rendered triangles.*/
Triangles _triangles;
/**Model view matrix when rendering the triangles.*/
Mat4 _mv;
};

View File

@ -33,85 +33,218 @@ NS_CC_BEGIN
class EventListenerCustom;
/**
VertexBuffer is an abstraction of low level openGL Vertex Buffer Object.
It is used to save an array of vertices.
*/
class CC_DLL VertexBuffer : public Ref
{
public:
/**
Create an instance of VertexBuffer.
@param sizePerVertex Size in bytes of one vertex.
@param vertexNumber The number of vertex.
@param usage A hint to indicate whether the vertexBuffer are updated frequently or not to let GL optimise it.
*/
static VertexBuffer* create(int sizePerVertex, int vertexNumber, GLenum usage = GL_STATIC_DRAW);
/**Get the size in bytes of one vertex.*/
int getSizePerVertex() const;
/**Get the number of vertices.*/
int getVertexNumber() const;
/**
Update all or part of vertice data, if the range specified exceeds the vertex buffer, it will be clipped.
@param verts The pointer of the vertex data.
@param count The number of vertices to update.
@param begin The first vertex to update.
*/
bool updateVertices(const void* verts, int count, int begin);
/**
Get the size of the vertex array in bytes, equals getSizePerVertex() * getVertexNumber().
*/
int getSize() const;
/**
Get the internal openGL handle.
*/
GLuint getVBO() const;
protected:
/**
Constructor.
*/
VertexBuffer();
/**
Destructor.
*/
virtual ~VertexBuffer();
/**
Init the storage of vertex buffer.
@param sizePerVertex Size in bytes of one vertex.
@param vertexNumber The number of vertex.
@param usage A hint to indicate whether the vertexBuffer are updated frequently or not to let GL optimise it.
*/
bool init(int sizePerVertex, int vertexNumber, GLenum usage = GL_STATIC_DRAW);
protected:
//event listener for foreground
/**
Event handler for foreground.
*/
void recreateVBO() const;
/**
Event listener for foreground.
*/
EventListenerCustom* _recreateVBOEventListener;
protected:
/**
Internal handle for openGL.
*/
mutable GLuint _vbo;
/**
Size in bytes for one vertex.
*/
int _sizePerVertex;
/**
Number of vertices.
*/
int _vertexNumber;
//buffer used for shadow copy
/**
Buffer used for shadow copy.
*/
std::vector<unsigned char> _shadowCopy;
/**
Hint for optimisation in GL.
*/
GLenum _usage;
protected:
/**
Static member to indicate that use _shadowCopy or not.
*/
static bool _enableShadowCopy;
public:
/**
Static getter for shadowCopy.
*/
static bool isShadowCopyEnabled() { return _enableShadowCopy; }
/**
Static setter for shadowCopy.
*/
static void enableShadowCopy(bool enabled) { _enableShadowCopy = enabled; }
};
/**
IndexBuffer is an abstraction of low level openGL Buffer Object.
It used to save an array of indices.
*/
class CC_DLL IndexBuffer : public Ref
{
public:
/**
Enum for the type of index, short indices and int indices could be used.
*/
enum class IndexType
{
/**Short index will be used.*/
INDEX_TYPE_SHORT_16,
/**Int index will be used.*/
INDEX_TYPE_UINT_32
};
public:
/**
Create an instance of IndexBuffer.
@param type type of index.
@param number The number of indices.
@param usage A hint to indicate whether the vertexBuffer are updated frequently or not to let GL optimise it.
*/
static IndexBuffer* create(IndexType type, int number, GLenum usage = GL_STATIC_DRAW);
/**
Getter for type of indices.
*/
IndexType getType() const;
/**
Get the size in bytes for one index, will be 2 for INDEX_TYPE_SHORT_16 and 4 for INDEX_TYPE_UINT_32.
*/
int getSizePerIndex() const;
/**
Get the number of indices.
*/
int getIndexNumber() const;
/**
Update all or part of indices data, if the range specified exceeds the vertex buffer, it will be clipped.
@param indices The pointer of the index data.
@param count The number of indices to update.
@param begin The start index to update.
*/
bool updateIndices(const void* indices, int count, int begin);
/**
Get the size in bytes of the array of indices.
*/
int getSize() const;
/**
Get the openGL handle for index buffer.
*/
GLuint getVBO() const;
protected:
/**
Constructor.
*/
IndexBuffer();
/**
Destructor.
*/
virtual ~IndexBuffer();
/**
Init the storageof IndexBuffer.
@param type type of index.
@param number The number of indices.
@param usage A hint to indicate whether the vertexBuffer are updated frequently or not to let GL optimise it.
*/
bool init(IndexType type, int number, GLenum usage = GL_STATIC_DRAW);
protected:
/**
Handle for openGL.
*/
mutable GLuint _vbo;
/**
Type for index.
*/
IndexType _type;
/**
Number of indices.
*/
int _indexNumber;
protected:
//event listener for foreground
/**
Event handler for foreground.
*/
void recreateVBO() const;
/**
Event listener for foreground.
*/
EventListenerCustom* _recreateVBOEventListener;
//buffer used for shadow copy
/**
Buffer used for shadow copy.
*/
std::vector<unsigned char> _shadowCopy;
/**
Hint for optimisation in GL.
*/
GLenum _usage;
protected:
/**
Static member to indicate that use _shadowCopy or not.
*/
static bool _enableShadowCopy;
public:
/**
Static getter for shadowCopy.
*/
static bool isShadowCopyEnabled() { return _enableShadowCopy; }
/**
Static setter for shadowCopy.
*/
static void enableShadowCopy(bool enabled) { _enableShadowCopy = enabled; }
};

View File

@ -31,55 +31,144 @@
NS_CC_BEGIN
class VertexBuffer;
/**
VertexStreamAttribute is used to specify the vertex attribute for drawing, which is correspondent to
glVertexAttribPointer(GLuint indx, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid* ptr).
_semantic -> index
_size -> size
_type -> type
_normalize -> normalized
_offset is used to compute the start offset in a interleaved array, take a V3F_C4B_T2F array,
offset of vertex will be 0, offset of color would be 0 + sizeof(float) * 3 = 12,
offset of texture coord would be 12 + sizeof(char) * 4 = 16.
*/
struct CC_DLL VertexStreamAttribute
{
/**
Constructor.
*/
VertexStreamAttribute()
: _normalize(false),_offset(0),_semantic(0),_type(0),_size(0)
{
}
/**
Constructor
@param offset The offset of the attribute.
@param semantic The semantic (Position, Texcoord, Color etc) of attribute.
@param type The type of attribute, could be GL_FLOAT, GL_UNSIGNED_BYTE etc.
@param size Describe how many elements of type in the attribute.
*/
VertexStreamAttribute(int offset, int semantic, int type, int size)
: _normalize(false),_offset(offset),_semantic(semantic),_type(type),_size(size)
{
}
/**
Constructor
@param offset The offset of the attribute.
@param semantic The semantic (Position, Texcoord, Color etc) of attribute.
@param type The type of attribute, could be GL_FLOAT, GL_UNSIGNED_BYTE etc.
@param size Describe how many elements of type in the attribute.
@param normalize If true, the data will be normalized by deviding 255.
*/
VertexStreamAttribute(int offset, int semantic, int type, int size, bool normalize)
: _normalize(normalize),_offset(offset),_semantic(semantic),_type(type),_size(size)
{
}
/**
Whether the attribute should be normalized or not.
*/
bool _normalize;
/**
The offset of the attribute in the buffer.
*/
int _offset;
/**
Describe that the attribute usage, could be Position, Color etc.
*/
int _semantic;
/**
Describe the type of attribute, could be GL_FLOAT, GL_UNSIGNED_BYTE etc.
*/
int _type;
/**
Describe how many elements of type in the attribute.
*/
int _size;
};
/**
VertexData is a class used for specify input streams for GPU rendering pipeline,
a VertexData will be composed by several streams, every stream will contain a VertexStreamAttribute
and the binding VertexBuffer. Streams will be identified by semantic.
*/
class CC_DLL VertexData : public Ref
{
public:
/**
Create function, used to create a instance of VertexData.
*/
static VertexData* create();
/**
Get the number of streams in the VertexData.
*/
size_t getVertexStreamCount() const;
/**
Set a stream to VertexData,given that stream is identified by semantic, so if the semantic is not
specified before, it will add a stream, or it will override the old one.
@param buffer The binding buffer of the stream.
@param stream The binding vertex attribute, its member semantic will be used as the identifier.
*/
bool setStream(VertexBuffer* buffer, const VertexStreamAttribute& stream);
/**
Remove the given streams.
@param semantic The semantic of the stream.
*/
void removeStream(int semantic);
/**
Get the attribute of stream, const version.
@param semantic The semantic of the stream.
*/
const VertexStreamAttribute* getStreamAttribute(int semantic) const;
/**
Get the attribute of stream.
@param semantic The semantic of the stream.
*/
VertexStreamAttribute* getStreamAttribute(int semantic);
/**
Get the binded buffer of the stream.
@param semantic The semantic of the stream.
*/
VertexBuffer* getStreamBuffer(int semantic) const;
/**
Called for rendering, it will bind the state of vertex data to current rendering pipeline.
*/
void use();
protected:
/**
Constructor.
*/
VertexData();
/**
Destructor.
*/
virtual ~VertexData();
protected:
/**
Simple struct to bundle buffer and attribute.
*/
struct BufferAttribute
{
VertexBuffer* _buffer;
VertexStreamAttribute _stream;
};
/**
Streams in the VertexData.
*/
std::map<int, BufferAttribute> _vertexStreams;
};

View File

@ -98,6 +98,7 @@ void main(void)
// Apply spot attenuation
attenuation *= smoothstep(u_SpotLightSourceOuterAngleCos[i], u_SpotLightSourceInnerAngleCos[i], spotCurrentAngleCos);
attenuation = clamp(attenuation, 0.0, 1.0);
combinedColor.xyz += computeLighting(normal, vertexToSpotLightDirection, u_SpotLightSourceColor[i], attenuation);
}
\n#endif\n

View File

@ -98,6 +98,7 @@ void main(void)
// Apply spot attenuation
attenuation *= smoothstep(u_SpotLightSourceOuterAngleCos[i], u_SpotLightSourceInnerAngleCos[i], spotCurrentAngleCos);
attenuation = clamp(attenuation, 0.0, 1.0);
combinedColor.xyz += computeLighting(normal, vertexToSpotLightDirection, u_SpotLightSourceColor[i], attenuation);
}
\n#endif\n

View File

@ -1,42 +0,0 @@
/*
* Copyright (c) 2013-2015 Chukong Technologies Inc.
*
* 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.
*/
const char* ccPositionColorTextureAsPointsize_vert = STRINGIFY(
attribute vec4 a_position;
attribute vec4 a_color;
attribute vec2 a_texCoord;
\n#ifdef GL_ES\n
varying lowp vec4 v_fragmentColor;
\n#else\n
varying vec4 v_fragmentColor;
\n#endif\n
void main()
{
gl_Position = CC_MVPMatrix * a_position;
v_fragmentColor = a_color;
}
);

View File

@ -1,43 +0,0 @@
/*
* cocos2d for iPhone: http://www.cocos2d-iphone.org
*
* Copyright (c) 2011 Ricardo Quesada
* Copyright (c) 2012 Zynga Inc.
*
* 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.
*/
const char* ccPosition_uColor_vert = STRINGIFY(
attribute vec4 a_position;
uniform vec4 u_color;
uniform float u_pointSize;
\n#ifdef GL_ES\n
varying lowp vec4 v_fragmentColor;
\n#else\n
varying vec4 v_fragmentColor;
\n#endif\n
void main()
{
gl_Position = CC_MVPMatrix * a_position;
v_fragmentColor = u_color;
}
);

View File

@ -31,24 +31,14 @@ THE SOFTWARE.
NS_CC_BEGIN
//
#include "ccShader_Position_uColor.frag"
#ifdef CC_NO_GL_POINTSIZE
#include "ccShader_Position_uColor-no-gl_PointSize.vert"
#else
#include "ccShader_Position_uColor.vert"
#endif
//
#include "ccShader_PositionColor.frag"
#include "ccShader_PositionColor.vert"
//
#ifdef CC_NO_GL_POINTSIZE
#include "ccShader_PositionColorPointsize-no-gl_PointSize.vert"
#else
#include "ccShader_PositionColorTextureAsPointsize.vert"
#endif
//
#include "ccShader_PositionTexture.frag"

View File

@ -10,37 +10,6 @@
-- @param self
-- @return float#float ret (return value: float)
--------------------------------
-- Pause the Process
-- @function [parent=#ArmatureAnimation] pause
-- @param self
-- @return ArmatureAnimation#ArmatureAnimation self (return value: ccs.ArmatureAnimation)
--------------------------------
-- Scale animation play speed.<br>
-- param animationScale Scale value
-- @function [parent=#ArmatureAnimation] setSpeedScale
-- @param self
-- @param #float speedScale
-- @return ArmatureAnimation#ArmatureAnimation self (return value: ccs.ArmatureAnimation)
--------------------------------
-- Init with a Armature<br>
-- param armature The Armature ArmatureAnimation will bind to
-- @function [parent=#ArmatureAnimation] init
-- @param self
-- @param #ccs.Armature armature
-- @return bool#bool ret (return value: bool)
--------------------------------
--
-- @function [parent=#ArmatureAnimation] playWithIndexes
-- @param self
-- @param #array_table movementIndexes
-- @param #int durationTo
-- @param #bool loop
-- @return ArmatureAnimation#ArmatureAnimation self (return value: ccs.ArmatureAnimation)
--------------------------------
-- Play animation by animation name.<br>
-- param animationName The animation name you want to play<br>
@ -66,22 +35,27 @@
-- @return ArmatureAnimation#ArmatureAnimation self (return value: ccs.ArmatureAnimation)
--------------------------------
-- Resume the Process
-- @function [parent=#ArmatureAnimation] resume
-- @param self
-- @return ArmatureAnimation#ArmatureAnimation self (return value: ccs.ArmatureAnimation)
--------------------------------
-- Stop the Process
-- @function [parent=#ArmatureAnimation] stop
--
-- @function [parent=#ArmatureAnimation] playWithIndexes
-- @param self
-- @param #array_table movementIndexes
-- @param #int durationTo
-- @param #bool loop
-- @return ArmatureAnimation#ArmatureAnimation self (return value: ccs.ArmatureAnimation)
--------------------------------
--
-- @function [parent=#ArmatureAnimation] update
-- @function [parent=#ArmatureAnimation] setAnimationData
-- @param self
-- @param #float dt
-- @param #ccs.AnimationData data
-- @return ArmatureAnimation#ArmatureAnimation self (return value: ccs.ArmatureAnimation)
--------------------------------
-- Scale animation play speed.<br>
-- param animationScale Scale value
-- @function [parent=#ArmatureAnimation] setSpeedScale
-- @param self
-- @param #float speedScale
-- @return ArmatureAnimation#ArmatureAnimation self (return value: ccs.ArmatureAnimation)
--------------------------------
@ -90,6 +64,42 @@
-- @param self
-- @return AnimationData#AnimationData ret (return value: ccs.AnimationData)
--------------------------------
-- Go to specified frame and play current movement.<br>
-- You need first switch to the movement you want to play, then call this function.<br>
-- example : playByIndex(0);<br>
-- gotoAndPlay(0);<br>
-- playByIndex(1);<br>
-- gotoAndPlay(0);<br>
-- gotoAndPlay(15);
-- @function [parent=#ArmatureAnimation] gotoAndPlay
-- @param self
-- @param #int frameIndex
-- @return ArmatureAnimation#ArmatureAnimation self (return value: ccs.ArmatureAnimation)
--------------------------------
-- Init with a Armature<br>
-- param armature The Armature ArmatureAnimation will bind to
-- @function [parent=#ArmatureAnimation] init
-- @param self
-- @param #ccs.Armature armature
-- @return bool#bool ret (return value: bool)
--------------------------------
--
-- @function [parent=#ArmatureAnimation] playWithNames
-- @param self
-- @param #array_table movementNames
-- @param #int durationTo
-- @param #bool loop
-- @return ArmatureAnimation#ArmatureAnimation self (return value: ccs.ArmatureAnimation)
--------------------------------
-- Get movement count
-- @function [parent=#ArmatureAnimation] getMovementCount
-- @param self
-- @return long#long ret (return value: long)
--------------------------------
--
-- @function [parent=#ArmatureAnimation] playWithIndex
@ -106,41 +116,6 @@
-- @param self
-- @return string#string ret (return value: string)
--------------------------------
--
-- @function [parent=#ArmatureAnimation] setAnimationData
-- @param self
-- @param #ccs.AnimationData data
-- @return ArmatureAnimation#ArmatureAnimation self (return value: ccs.ArmatureAnimation)
--------------------------------
-- Go to specified frame and play current movement.<br>
-- You need first switch to the movement you want to play, then call this function.<br>
-- example : playByIndex(0);<br>
-- gotoAndPlay(0);<br>
-- playByIndex(1);<br>
-- gotoAndPlay(0);<br>
-- gotoAndPlay(15);
-- @function [parent=#ArmatureAnimation] gotoAndPlay
-- @param self
-- @param #int frameIndex
-- @return ArmatureAnimation#ArmatureAnimation self (return value: ccs.ArmatureAnimation)
--------------------------------
--
-- @function [parent=#ArmatureAnimation] playWithNames
-- @param self
-- @param #array_table movementNames
-- @param #int durationTo
-- @param #bool loop
-- @return ArmatureAnimation#ArmatureAnimation self (return value: ccs.ArmatureAnimation)
--------------------------------
-- Get movement count
-- @function [parent=#ArmatureAnimation] getMovementCount
-- @param self
-- @return long#long ret (return value: long)
--------------------------------
-- Create with a Armature<br>
-- param armature The Armature ArmatureAnimation will bind to
@ -149,6 +124,31 @@
-- @param #ccs.Armature armature
-- @return ArmatureAnimation#ArmatureAnimation ret (return value: ccs.ArmatureAnimation)
--------------------------------
-- Pause the Process
-- @function [parent=#ArmatureAnimation] pause
-- @param self
-- @return ArmatureAnimation#ArmatureAnimation self (return value: ccs.ArmatureAnimation)
--------------------------------
-- Stop the Process
-- @function [parent=#ArmatureAnimation] stop
-- @param self
-- @return ArmatureAnimation#ArmatureAnimation self (return value: ccs.ArmatureAnimation)
--------------------------------
--
-- @function [parent=#ArmatureAnimation] update
-- @param self
-- @param #float dt
-- @return ArmatureAnimation#ArmatureAnimation self (return value: ccs.ArmatureAnimation)
--------------------------------
-- Resume the Process
-- @function [parent=#ArmatureAnimation] resume
-- @param self
-- @return ArmatureAnimation#ArmatureAnimation self (return value: ccs.ArmatureAnimation)
--------------------------------
-- js ctor
-- @function [parent=#ArmatureAnimation] ArmatureAnimation

View File

@ -10,15 +10,6 @@
-- @param self
-- @return int#int ret (return value: int)
--------------------------------
-- update billboard's transform and turn it towards camera
-- @function [parent=#BillBoard] visit
-- @param self
-- @param #cc.Renderer renderer
-- @param #mat4_table parentTransform
-- @param #unsigned int parentFlags
-- @return BillBoard#BillBoard self (return value: cc.BillBoard)
--------------------------------
-- Set the billboard rotation mode.
-- @function [parent=#BillBoard] setMode
@ -48,4 +39,13 @@
-- @param #int mode
-- @return BillBoard#BillBoard ret (return value: cc.BillBoard)
--------------------------------
-- update billboard's transform and turn it towards camera
-- @function [parent=#BillBoard] visit
-- @param self
-- @param #cc.Renderer renderer
-- @param #mat4_table parentTransform
-- @param #unsigned int parentFlags
-- @return BillBoard#BillBoard self (return value: cc.BillBoard)
return nil

View File

@ -67,6 +67,14 @@
-- @param #cc.Node stencil
-- @return ClippingNode#ClippingNode ret (return value: cc.ClippingNode)
--------------------------------
--
-- @function [parent=#ClippingNode] setCameraMask
-- @param self
-- @param #unsigned short mask
-- @param #bool applyChildren
-- @return ClippingNode#ClippingNode self (return value: cc.ClippingNode)
--------------------------------
--
-- @function [parent=#ClippingNode] visit

View File

@ -11,28 +11,12 @@
-- @param #bool bEnabled
-- @return Control#Control self (return value: cc.Control)
--------------------------------
--
-- @function [parent=#Control] onTouchMoved
-- @param self
-- @param #cc.Touch touch
-- @param #cc.Event event
-- @return Control#Control self (return value: cc.Control)
--------------------------------
--
-- @function [parent=#Control] getState
-- @param self
-- @return int#int ret (return value: int)
--------------------------------
--
-- @function [parent=#Control] onTouchEnded
-- @param self
-- @param #cc.Touch touch
-- @param #cc.Event event
-- @return Control#Control self (return value: cc.Control)
--------------------------------
-- Sends action messages for the given control events.<br>
-- param controlEvents A bitmask whose set flags specify the control events for<br>
@ -55,28 +39,12 @@
-- @param self
-- @return bool#bool ret (return value: bool)
--------------------------------
--
-- @function [parent=#Control] onTouchCancelled
-- @param self
-- @param #cc.Touch touch
-- @param #cc.Event event
-- @return Control#Control self (return value: cc.Control)
--------------------------------
-- Updates the control layout using its current internal state.
-- @function [parent=#Control] needsLayout
-- @param self
-- @return Control#Control self (return value: cc.Control)
--------------------------------
--
-- @function [parent=#Control] onTouchBegan
-- @param self
-- @param #cc.Touch touch
-- @param #cc.Event event
-- @return bool#bool ret (return value: bool)
--------------------------------
--
-- @function [parent=#Control] hasVisibleParents
@ -127,6 +95,14 @@
-- @param self
-- @return Control#Control ret (return value: cc.Control)
--------------------------------
--
-- @function [parent=#Control] onTouchMoved
-- @param self
-- @param #cc.Touch touch
-- @param #cc.Event event
-- @return Control#Control self (return value: cc.Control)
--------------------------------
--
-- @function [parent=#Control] isOpacityModifyRGB
@ -140,4 +116,28 @@
-- @param #bool bOpacityModifyRGB
-- @return Control#Control self (return value: cc.Control)
--------------------------------
--
-- @function [parent=#Control] onTouchCancelled
-- @param self
-- @param #cc.Touch touch
-- @param #cc.Event event
-- @return Control#Control self (return value: cc.Control)
--------------------------------
--
-- @function [parent=#Control] onTouchEnded
-- @param self
-- @param #cc.Touch touch
-- @param #cc.Event event
-- @return Control#Control self (return value: cc.Control)
--------------------------------
--
-- @function [parent=#Control] onTouchBegan
-- @param self
-- @param #cc.Touch touch
-- @param #cc.Event event
-- @return bool#bool ret (return value: bool)
return nil

View File

@ -10,13 +10,6 @@
-- @param self
-- @return bool#bool ret (return value: bool)
--------------------------------
--
-- @function [parent=#ControlButton] setSelected
-- @param self
-- @param #bool enabled
-- @return ControlButton#ControlButton self (return value: cc.ControlButton)
--------------------------------
-- Sets the title label to use for the specified state.<br>
-- If a property is not specified for a state, the default is to use<br>
@ -37,20 +30,6 @@
-- @param #bool adjustBackgroundImage
-- @return ControlButton#ControlButton self (return value: cc.ControlButton)
--------------------------------
--
-- @function [parent=#ControlButton] setHighlighted
-- @param self
-- @param #bool enabled
-- @return ControlButton#ControlButton self (return value: cc.ControlButton)
--------------------------------
--
-- @function [parent=#ControlButton] setZoomOnTouchDown
-- @param self
-- @param #bool var
-- @return ControlButton#ControlButton self (return value: cc.ControlButton)
--------------------------------
-- Sets the title string to use for the specified state.<br>
-- If a property is not specified for a state, the default is to use<br>
@ -122,9 +101,9 @@
--------------------------------
--
-- @function [parent=#ControlButton] setEnabled
-- @function [parent=#ControlButton] setZoomOnTouchDown
-- @param self
-- @param #bool enabled
-- @param #bool var
-- @return ControlButton#ControlButton self (return value: cc.ControlButton)
--------------------------------
@ -143,18 +122,16 @@
-- @return int#int ret (return value: int)
--------------------------------
--
-- @function [parent=#ControlButton] needsLayout
-- Sets the font of the label, changes the label to a BMFont if neccessary.<br>
-- param fntFile The name of the font to change to<br>
-- param state The state that uses the specified fntFile. The values are described<br>
-- in "CCControlState".
-- @function [parent=#ControlButton] setTitleBMFontForState
-- @param self
-- @param #string fntFile
-- @param #int state
-- @return ControlButton#ControlButton self (return value: cc.ControlButton)
--------------------------------
-- @overload self
-- @overload self
-- @function [parent=#ControlButton] getCurrentTitle
-- @param self
-- @return string#string ret (return value: string)
--------------------------------
--
-- @function [parent=#ControlButton] getScaleRatio
@ -274,16 +251,12 @@
-- @return ControlButton#ControlButton self (return value: cc.ControlButton)
--------------------------------
-- Sets the font of the label, changes the label to a BMFont if neccessary.<br>
-- param fntFile The name of the font to change to<br>
-- param state The state that uses the specified fntFile. The values are described<br>
-- in "CCControlState".
-- @function [parent=#ControlButton] setTitleBMFontForState
-- @overload self
-- @overload self
-- @function [parent=#ControlButton] getCurrentTitle
-- @param self
-- @param #string fntFile
-- @param #int state
-- @return ControlButton#ControlButton self (return value: cc.ControlButton)
-- @return string#string ret (return value: string)
--------------------------------
--
-- @function [parent=#ControlButton] getTitleBMFontForState
@ -321,10 +294,9 @@
--------------------------------
--
-- @function [parent=#ControlButton] onTouchMoved
-- @function [parent=#ControlButton] setEnabled
-- @param self
-- @param #cc.Touch touch
-- @param #cc.Event event
-- @param #bool enabled
-- @return ControlButton#ControlButton self (return value: cc.ControlButton)
--------------------------------
@ -342,6 +314,21 @@
-- @param #color3b_table
-- @return ControlButton#ControlButton self (return value: cc.ControlButton)
--------------------------------
--
-- @function [parent=#ControlButton] onTouchMoved
-- @param self
-- @param #cc.Touch touch
-- @param #cc.Event event
-- @return ControlButton#ControlButton self (return value: cc.ControlButton)
--------------------------------
--
-- @function [parent=#ControlButton] setSelected
-- @param self
-- @param #bool enabled
-- @return ControlButton#ControlButton self (return value: cc.ControlButton)
--------------------------------
--
-- @function [parent=#ControlButton] onTouchCancelled
@ -352,11 +339,18 @@
--------------------------------
--
-- @function [parent=#ControlButton] setOpacity
-- @function [parent=#ControlButton] needsLayout
-- @param self
-- @param #unsigned char var
-- @return ControlButton#ControlButton self (return value: cc.ControlButton)
--------------------------------
--
-- @function [parent=#ControlButton] onTouchBegan
-- @param self
-- @param #cc.Touch touch
-- @param #cc.Event event
-- @return bool#bool ret (return value: bool)
--------------------------------
--
-- @function [parent=#ControlButton] updateDisplayedOpacity
@ -364,6 +358,13 @@
-- @param #unsigned char parentOpacity
-- @return ControlButton#ControlButton self (return value: cc.ControlButton)
--------------------------------
--
-- @function [parent=#ControlButton] setHighlighted
-- @param self
-- @param #bool enabled
-- @return ControlButton#ControlButton self (return value: cc.ControlButton)
--------------------------------
--
-- @function [parent=#ControlButton] updateDisplayedColor
@ -373,10 +374,9 @@
--------------------------------
--
-- @function [parent=#ControlButton] onTouchBegan
-- @function [parent=#ControlButton] setOpacity
-- @param self
-- @param #cc.Touch touch
-- @param #cc.Event event
-- @return bool#bool ret (return value: bool)
-- @param #unsigned char var
-- @return ControlButton#ControlButton self (return value: cc.ControlButton)
return nil

View File

@ -6,9 +6,10 @@
--------------------------------
--
-- @function [parent=#ControlColourPicker] setEnabled
-- @function [parent=#ControlColourPicker] hueSliderValueChanged
-- @param self
-- @param #bool bEnabled
-- @param #cc.Ref sender
-- @param #int controlEvent
-- @return ControlColourPicker#ControlColourPicker self (return value: cc.ControlColourPicker)
--------------------------------
@ -17,21 +18,6 @@
-- @param self
-- @return ControlHuePicker#ControlHuePicker ret (return value: cc.ControlHuePicker)
--------------------------------
--
-- @function [parent=#ControlColourPicker] setColor
-- @param self
-- @param #color3b_table colorValue
-- @return ControlColourPicker#ControlColourPicker self (return value: cc.ControlColourPicker)
--------------------------------
--
-- @function [parent=#ControlColourPicker] hueSliderValueChanged
-- @param self
-- @param #cc.Ref sender
-- @param #int controlEvent
-- @return ControlColourPicker#ControlColourPicker self (return value: cc.ControlColourPicker)
--------------------------------
--
-- @function [parent=#ControlColourPicker] getcolourPicker
@ -85,6 +71,20 @@
-- @param self
-- @return ControlColourPicker#ControlColourPicker ret (return value: cc.ControlColourPicker)
--------------------------------
--
-- @function [parent=#ControlColourPicker] setEnabled
-- @param self
-- @param #bool bEnabled
-- @return ControlColourPicker#ControlColourPicker self (return value: cc.ControlColourPicker)
--------------------------------
--
-- @function [parent=#ControlColourPicker] setColor
-- @param self
-- @param #color3b_table colorValue
-- @return ControlColourPicker#ControlColourPicker self (return value: cc.ControlColourPicker)
--------------------------------
-- js ctor
-- @function [parent=#ControlColourPicker] ControlColourPicker

View File

@ -4,13 +4,6 @@
-- @extend Control
-- @parent_module cc
--------------------------------
--
-- @function [parent=#ControlHuePicker] setEnabled
-- @param self
-- @param #bool enabled
-- @return ControlHuePicker#ControlHuePicker self (return value: cc.ControlHuePicker)
--------------------------------
--
-- @function [parent=#ControlHuePicker] initWithTargetAndPos
@ -85,6 +78,13 @@
-- @param #vec2_table pos
-- @return ControlHuePicker#ControlHuePicker ret (return value: cc.ControlHuePicker)
--------------------------------
--
-- @function [parent=#ControlHuePicker] setEnabled
-- @param self
-- @param #bool enabled
-- @return ControlHuePicker#ControlHuePicker self (return value: cc.ControlHuePicker)
--------------------------------
--
-- @function [parent=#ControlHuePicker] onTouchMoved

View File

@ -30,13 +30,6 @@
-- @param self
-- @return Sprite#Sprite ret (return value: cc.Sprite)
--------------------------------
--
-- @function [parent=#ControlSaturationBrightnessPicker] setEnabled
-- @param self
-- @param #bool enabled
-- @return ControlSaturationBrightnessPicker#ControlSaturationBrightnessPicker self (return value: cc.ControlSaturationBrightnessPicker)
--------------------------------
--
-- @function [parent=#ControlSaturationBrightnessPicker] getSlider
@ -69,6 +62,13 @@
-- @param #vec2_table pos
-- @return ControlSaturationBrightnessPicker#ControlSaturationBrightnessPicker ret (return value: cc.ControlSaturationBrightnessPicker)
--------------------------------
--
-- @function [parent=#ControlSaturationBrightnessPicker] setEnabled
-- @param self
-- @param #bool enabled
-- @return ControlSaturationBrightnessPicker#ControlSaturationBrightnessPicker self (return value: cc.ControlSaturationBrightnessPicker)
--------------------------------
-- js ctor
-- @function [parent=#ControlSaturationBrightnessPicker] ControlSaturationBrightnessPicker

View File

@ -6,27 +6,7 @@
--------------------------------
--
-- @function [parent=#ControlSlider] getSelectedThumbSprite
-- @param self
-- @return Sprite#Sprite ret (return value: cc.Sprite)
--------------------------------
--
-- @function [parent=#ControlSlider] locationFromTouch
-- @param self
-- @param #cc.Touch touch
-- @return vec2_table#vec2_table ret (return value: vec2_table)
--------------------------------
--
-- @function [parent=#ControlSlider] setSelectedThumbSprite
-- @param self
-- @param #cc.Sprite var
-- @return ControlSlider#ControlSlider self (return value: cc.ControlSlider)
--------------------------------
--
-- @function [parent=#ControlSlider] setProgressSprite
-- @function [parent=#ControlSlider] setBackgroundSprite
-- @param self
-- @param #cc.Sprite var
-- @return ControlSlider#ControlSlider self (return value: cc.ControlSlider)
@ -37,12 +17,49 @@
-- @param self
-- @return float#float ret (return value: float)
--------------------------------
-- @overload self, cc.Sprite, cc.Sprite, cc.Sprite, cc.Sprite
-- @overload self, cc.Sprite, cc.Sprite, cc.Sprite
-- @function [parent=#ControlSlider] initWithSprites
-- @param self
-- @param #cc.Sprite backgroundSprite
-- @param #cc.Sprite progressSprite
-- @param #cc.Sprite thumbSprite
-- @param #cc.Sprite selectedThumbSprite
-- @return bool#bool ret (return value: bool)
--------------------------------
--
-- @function [parent=#ControlSlider] getMinimumAllowedValue
-- @param self
-- @return float#float ret (return value: float)
--------------------------------
--
-- @function [parent=#ControlSlider] getMaximumValue
-- @param self
-- @return float#float ret (return value: float)
--------------------------------
--
-- @function [parent=#ControlSlider] getSelectedThumbSprite
-- @param self
-- @return Sprite#Sprite ret (return value: cc.Sprite)
--------------------------------
--
-- @function [parent=#ControlSlider] setProgressSprite
-- @param self
-- @param #cc.Sprite var
-- @return ControlSlider#ControlSlider self (return value: cc.ControlSlider)
--------------------------------
--
-- @function [parent=#ControlSlider] setMaximumValue
-- @param self
-- @param #float val
-- @return ControlSlider#ControlSlider self (return value: cc.ControlSlider)
--------------------------------
--
-- @function [parent=#ControlSlider] getMinimumValue
@ -56,6 +73,38 @@
-- @param #cc.Sprite var
-- @return ControlSlider#ControlSlider self (return value: cc.ControlSlider)
--------------------------------
--
-- @function [parent=#ControlSlider] getValue
-- @param self
-- @return float#float ret (return value: float)
--------------------------------
--
-- @function [parent=#ControlSlider] getBackgroundSprite
-- @param self
-- @return Sprite#Sprite ret (return value: cc.Sprite)
--------------------------------
--
-- @function [parent=#ControlSlider] getThumbSprite
-- @param self
-- @return Sprite#Sprite ret (return value: cc.Sprite)
--------------------------------
--
-- @function [parent=#ControlSlider] setValue
-- @param self
-- @param #float val
-- @return ControlSlider#ControlSlider self (return value: cc.ControlSlider)
--------------------------------
--
-- @function [parent=#ControlSlider] locationFromTouch
-- @param self
-- @param #cc.Touch touch
-- @return vec2_table#vec2_table ret (return value: vec2_table)
--------------------------------
--
-- @function [parent=#ControlSlider] setMinimumValue
@ -70,75 +119,6 @@
-- @param #float var
-- @return ControlSlider#ControlSlider self (return value: cc.ControlSlider)
--------------------------------
--
-- @function [parent=#ControlSlider] setEnabled
-- @param self
-- @param #bool enabled
-- @return ControlSlider#ControlSlider self (return value: cc.ControlSlider)
--------------------------------
--
-- @function [parent=#ControlSlider] setValue
-- @param self
-- @param #float val
-- @return ControlSlider#ControlSlider self (return value: cc.ControlSlider)
--------------------------------
--
-- @function [parent=#ControlSlider] setMaximumValue
-- @param self
-- @param #float val
-- @return ControlSlider#ControlSlider self (return value: cc.ControlSlider)
--------------------------------
--
-- @function [parent=#ControlSlider] needsLayout
-- @param self
-- @return ControlSlider#ControlSlider self (return value: cc.ControlSlider)
--------------------------------
--
-- @function [parent=#ControlSlider] getBackgroundSprite
-- @param self
-- @return Sprite#Sprite ret (return value: cc.Sprite)
--------------------------------
-- @overload self, cc.Sprite, cc.Sprite, cc.Sprite, cc.Sprite
-- @overload self, cc.Sprite, cc.Sprite, cc.Sprite
-- @function [parent=#ControlSlider] initWithSprites
-- @param self
-- @param #cc.Sprite backgroundSprite
-- @param #cc.Sprite progressSprite
-- @param #cc.Sprite thumbSprite
-- @param #cc.Sprite selectedThumbSprite
-- @return bool#bool ret (return value: bool)
--------------------------------
--
-- @function [parent=#ControlSlider] getMaximumValue
-- @param self
-- @return float#float ret (return value: float)
--------------------------------
--
-- @function [parent=#ControlSlider] isTouchInside
-- @param self
-- @param #cc.Touch touch
-- @return bool#bool ret (return value: bool)
--------------------------------
--
-- @function [parent=#ControlSlider] getValue
-- @param self
-- @return float#float ret (return value: float)
--------------------------------
--
-- @function [parent=#ControlSlider] getThumbSprite
-- @param self
-- @return Sprite#Sprite ret (return value: cc.Sprite)
--------------------------------
--
-- @function [parent=#ControlSlider] getProgressSprite
@ -147,7 +127,7 @@
--------------------------------
--
-- @function [parent=#ControlSlider] setBackgroundSprite
-- @function [parent=#ControlSlider] setSelectedThumbSprite
-- @param self
-- @param #cc.Sprite var
-- @return ControlSlider#ControlSlider self (return value: cc.ControlSlider)
@ -172,6 +152,26 @@
-- @param #cc.Sprite selectedThumbSprite
-- @return ControlSlider#ControlSlider ret (return value: cc.ControlSlider)
--------------------------------
--
-- @function [parent=#ControlSlider] isTouchInside
-- @param self
-- @param #cc.Touch touch
-- @return bool#bool ret (return value: bool)
--------------------------------
--
-- @function [parent=#ControlSlider] setEnabled
-- @param self
-- @param #bool enabled
-- @return ControlSlider#ControlSlider self (return value: cc.ControlSlider)
--------------------------------
--
-- @function [parent=#ControlSlider] needsLayout
-- @param self
-- @return ControlSlider#ControlSlider self (return value: cc.ControlSlider)
--------------------------------
-- js ctor
-- @function [parent=#ControlSlider] ControlSlider

View File

@ -4,92 +4,12 @@
-- @extend Control
-- @parent_module cc
--------------------------------
--
-- @function [parent=#ControlStepper] setMinusSprite
-- @param self
-- @param #cc.Sprite var
-- @return ControlStepper#ControlStepper self (return value: cc.ControlStepper)
--------------------------------
--
-- @function [parent=#ControlStepper] getMinusLabel
-- @param self
-- @return Label#Label ret (return value: cc.Label)
--------------------------------
--
-- @function [parent=#ControlStepper] setWraps
-- @param self
-- @param #bool wraps
-- @return ControlStepper#ControlStepper self (return value: cc.ControlStepper)
--------------------------------
--
-- @function [parent=#ControlStepper] isContinuous
-- @param self
-- @return bool#bool ret (return value: bool)
--------------------------------
--
-- @function [parent=#ControlStepper] getMinusSprite
-- @param self
-- @return Sprite#Sprite ret (return value: cc.Sprite)
--------------------------------
-- Update the layout of the stepper with the given touch location.
-- @function [parent=#ControlStepper] updateLayoutUsingTouchLocation
-- @param self
-- @param #vec2_table location
-- @return ControlStepper#ControlStepper self (return value: cc.ControlStepper)
--------------------------------
-- Set the numeric value of the stepper. If send is true, the Control::EventType::VALUE_CHANGED is sent.
-- @function [parent=#ControlStepper] setValueWithSendingEvent
-- @param self
-- @param #double value
-- @param #bool send
-- @return ControlStepper#ControlStepper self (return value: cc.ControlStepper)
--------------------------------
--
-- @function [parent=#ControlStepper] getPlusLabel
-- @param self
-- @return Label#Label ret (return value: cc.Label)
--------------------------------
-- Stop the autorepeat.
-- @function [parent=#ControlStepper] stopAutorepeat
-- @param self
-- @return ControlStepper#ControlStepper self (return value: cc.ControlStepper)
--------------------------------
--
-- @function [parent=#ControlStepper] setMinimumValue
-- @param self
-- @param #double minimumValue
-- @return ControlStepper#ControlStepper self (return value: cc.ControlStepper)
--------------------------------
--
-- @function [parent=#ControlStepper] getPlusSprite
-- @param self
-- @return Sprite#Sprite ret (return value: cc.Sprite)
--------------------------------
--
-- @function [parent=#ControlStepper] setPlusSprite
-- @param self
-- @param #cc.Sprite var
-- @return ControlStepper#ControlStepper self (return value: cc.ControlStepper)
--------------------------------
--
-- @function [parent=#ControlStepper] setMinusLabel
-- @param self
-- @param #cc.Label var
-- @return ControlStepper#ControlStepper self (return value: cc.ControlStepper)
--------------------------------
--
-- @function [parent=#ControlStepper] setValue
@ -104,6 +24,22 @@
-- @param #double stepValue
-- @return ControlStepper#ControlStepper self (return value: cc.ControlStepper)
--------------------------------
--
-- @function [parent=#ControlStepper] initWithMinusSpriteAndPlusSprite
-- @param self
-- @param #cc.Sprite minusSprite
-- @param #cc.Sprite plusSprite
-- @return bool#bool ret (return value: bool)
--------------------------------
-- Set the numeric value of the stepper. If send is true, the Control::EventType::VALUE_CHANGED is sent.
-- @function [parent=#ControlStepper] setValueWithSendingEvent
-- @param self
-- @param #double value
-- @param #bool send
-- @return ControlStepper#ControlStepper self (return value: cc.ControlStepper)
--------------------------------
--
-- @function [parent=#ControlStepper] setMaximumValue
@ -113,9 +49,28 @@
--------------------------------
--
-- @function [parent=#ControlStepper] update
-- @function [parent=#ControlStepper] getMinusLabel
-- @param self
-- @param #float dt
-- @return Label#Label ret (return value: cc.Label)
--------------------------------
--
-- @function [parent=#ControlStepper] getPlusLabel
-- @param self
-- @return Label#Label ret (return value: cc.Label)
--------------------------------
--
-- @function [parent=#ControlStepper] setWraps
-- @param self
-- @param #bool wraps
-- @return ControlStepper#ControlStepper self (return value: cc.ControlStepper)
--------------------------------
--
-- @function [parent=#ControlStepper] setMinusLabel
-- @param self
-- @param #cc.Label var
-- @return ControlStepper#ControlStepper self (return value: cc.ControlStepper)
--------------------------------
@ -125,13 +80,38 @@
-- @return ControlStepper#ControlStepper self (return value: cc.ControlStepper)
--------------------------------
--
-- @function [parent=#ControlStepper] initWithMinusSpriteAndPlusSprite
-- Update the layout of the stepper with the given touch location.
-- @function [parent=#ControlStepper] updateLayoutUsingTouchLocation
-- @param self
-- @param #vec2_table location
-- @return ControlStepper#ControlStepper self (return value: cc.ControlStepper)
--------------------------------
--
-- @function [parent=#ControlStepper] isContinuous
-- @param self
-- @param #cc.Sprite minusSprite
-- @param #cc.Sprite plusSprite
-- @return bool#bool ret (return value: bool)
--------------------------------
-- Stop the autorepeat.
-- @function [parent=#ControlStepper] stopAutorepeat
-- @param self
-- @return ControlStepper#ControlStepper self (return value: cc.ControlStepper)
--------------------------------
--
-- @function [parent=#ControlStepper] setMinimumValue
-- @param self
-- @param #double minimumValue
-- @return ControlStepper#ControlStepper self (return value: cc.ControlStepper)
--------------------------------
--
-- @function [parent=#ControlStepper] setPlusLabel
-- @param self
-- @param #cc.Label var
-- @return ControlStepper#ControlStepper self (return value: cc.ControlStepper)
--------------------------------
--
-- @function [parent=#ControlStepper] getValue
@ -140,9 +120,22 @@
--------------------------------
--
-- @function [parent=#ControlStepper] setPlusLabel
-- @function [parent=#ControlStepper] getPlusSprite
-- @param self
-- @param #cc.Label var
-- @return Sprite#Sprite ret (return value: cc.Sprite)
--------------------------------
--
-- @function [parent=#ControlStepper] setPlusSprite
-- @param self
-- @param #cc.Sprite var
-- @return ControlStepper#ControlStepper self (return value: cc.ControlStepper)
--------------------------------
--
-- @function [parent=#ControlStepper] setMinusSprite
-- @param self
-- @param #cc.Sprite var
-- @return ControlStepper#ControlStepper self (return value: cc.ControlStepper)
--------------------------------
@ -169,6 +162,13 @@
-- @param #cc.Event pEvent
-- @return ControlStepper#ControlStepper self (return value: cc.ControlStepper)
--------------------------------
--
-- @function [parent=#ControlStepper] update
-- @param self
-- @param #float dt
-- @return ControlStepper#ControlStepper self (return value: cc.ControlStepper)
--------------------------------
--
-- @function [parent=#ControlStepper] onTouchBegan

View File

@ -4,13 +4,6 @@
-- @extend Control
-- @parent_module cc
--------------------------------
--
-- @function [parent=#ControlSwitch] setEnabled
-- @param self
-- @param #bool enabled
-- @return ControlSwitch#ControlSwitch self (return value: cc.ControlSwitch)
--------------------------------
-- @overload self, bool
-- @overload self, bool, bool
@ -20,6 +13,13 @@
-- @param #bool animated
-- @return ControlSwitch#ControlSwitch self (return value: cc.ControlSwitch)
--------------------------------
--
-- @function [parent=#ControlSwitch] locationFromTouch
-- @param self
-- @param #cc.Touch touch
-- @return vec2_table#vec2_table ret (return value: vec2_table)
--------------------------------
--
-- @function [parent=#ControlSwitch] isOn
@ -45,13 +45,6 @@
-- @param self
-- @return bool#bool ret (return value: bool)
--------------------------------
--
-- @function [parent=#ControlSwitch] locationFromTouch
-- @param self
-- @param #cc.Touch touch
-- @return vec2_table#vec2_table ret (return value: vec2_table)
--------------------------------
-- @overload self, cc.Sprite, cc.Sprite, cc.Sprite, cc.Sprite
-- @overload self, cc.Sprite, cc.Sprite, cc.Sprite, cc.Sprite, cc.Label, cc.Label
@ -65,6 +58,13 @@
-- @param #cc.Label offLabel
-- @return ControlSwitch#ControlSwitch ret (return value: cc.ControlSwitch)
--------------------------------
--
-- @function [parent=#ControlSwitch] setEnabled
-- @param self
-- @param #bool enabled
-- @return ControlSwitch#ControlSwitch self (return value: cc.ControlSwitch)
--------------------------------
--
-- @function [parent=#ControlSwitch] onTouchMoved

View File

@ -17,13 +17,6 @@
-- @param self
-- @return EventFrame#EventFrame self (return value: ccs.EventFrame)
--------------------------------
--
-- @function [parent=#EventFrame] setNode
-- @param self
-- @param #cc.Node node
-- @return EventFrame#EventFrame self (return value: ccs.EventFrame)
--------------------------------
--
-- @function [parent=#EventFrame] getEvent
@ -42,6 +35,13 @@
-- @param self
-- @return Frame#Frame ret (return value: ccs.Frame)
--------------------------------
--
-- @function [parent=#EventFrame] setNode
-- @param self
-- @param #cc.Node node
-- @return EventFrame#EventFrame self (return value: ccs.EventFrame)
--------------------------------
--
-- @function [parent=#EventFrame] EventFrame

View File

@ -4,14 +4,6 @@
-- @extend FadeOutTRTiles
-- @parent_module cc
--------------------------------
--
-- @function [parent=#FadeOutUpTiles] transformTile
-- @param self
-- @param #vec2_table pos
-- @param #float distance
-- @return FadeOutUpTiles#FadeOutUpTiles self (return value: cc.FadeOutUpTiles)
--------------------------------
-- creates the action with the grid size and the duration <br>
-- param duration in seconds
@ -27,6 +19,14 @@
-- @param self
-- @return FadeOutUpTiles#FadeOutUpTiles ret (return value: cc.FadeOutUpTiles)
--------------------------------
--
-- @function [parent=#FadeOutUpTiles] transformTile
-- @param self
-- @param #vec2_table pos
-- @param #float distance
-- @return FadeOutUpTiles#FadeOutUpTiles self (return value: cc.FadeOutUpTiles)
--------------------------------
--
-- @function [parent=#FadeOutUpTiles] testFunc

View File

@ -4,16 +4,16 @@
-- @extend GridAction
-- @parent_module cc
--------------------------------
-- returns the grid
-- @function [parent=#Grid3DAction] getGrid
-- @param self
-- @return GridBase#GridBase ret (return value: cc.GridBase)
--------------------------------
--
-- @function [parent=#Grid3DAction] clone
-- @param self
-- @return Grid3DAction#Grid3DAction ret (return value: cc.Grid3DAction)
--------------------------------
-- returns the grid
-- @function [parent=#Grid3DAction] getGrid
-- @param self
-- @return GridBase#GridBase ret (return value: cc.GridBase)
return nil

View File

@ -478,4 +478,12 @@
-- @param #color3b_table parentColor
-- @return Label#Label self (return value: cc.Label)
--------------------------------
--
-- @function [parent=#Label] setCameraMask
-- @param self
-- @param #unsigned short mask
-- @param #bool applyChildren
-- @return Label#Label self (return value: cc.Label)
return nil

View File

@ -24,12 +24,6 @@
-- @param #int startCharMap
-- @return bool#bool ret (return value: bool)
--------------------------------
--
-- @function [parent=#LabelAtlas] updateAtlasValues
-- @param self
-- @return LabelAtlas#LabelAtlas self (return value: cc.LabelAtlas)
--------------------------------
--
-- @function [parent=#LabelAtlas] getString
@ -49,6 +43,12 @@
-- @param #int startCharMap
-- @return LabelAtlas#LabelAtlas ret (return value: cc.LabelAtlas)
--------------------------------
--
-- @function [parent=#LabelAtlas] updateAtlasValues
-- @param self
-- @return LabelAtlas#LabelAtlas self (return value: cc.LabelAtlas)
--------------------------------
--
-- @function [parent=#LabelAtlas] getDescription

View File

@ -57,18 +57,20 @@
-- @param #string name
-- @return Menu#Menu self (return value: cc.Menu)
--------------------------------
--
-- @function [parent=#Menu] isOpacityModifyRGB
-- @param self
-- @return bool#bool ret (return value: bool)
--------------------------------
--
-- @function [parent=#Menu] getDescription
-- @param self
-- @return string#string ret (return value: string)
--------------------------------
--
-- @function [parent=#Menu] removeChild
-- @param self
-- @param #cc.Node child
-- @param #bool cleanup
-- @return Menu#Menu self (return value: cc.Menu)
--------------------------------
--
-- @function [parent=#Menu] setOpacityModifyRGB
@ -78,10 +80,8 @@
--------------------------------
--
-- @function [parent=#Menu] removeChild
-- @function [parent=#Menu] isOpacityModifyRGB
-- @param self
-- @param #cc.Node child
-- @param #bool cleanup
-- @return Menu#Menu self (return value: cc.Menu)
-- @return bool#bool ret (return value: bool)
return nil

View File

@ -4,12 +4,6 @@
-- @extend Grid3DAction
-- @parent_module cc
--------------------------------
--
-- @function [parent=#PageTurn3D] getGrid
-- @param self
-- @return GridBase#GridBase ret (return value: cc.GridBase)
--------------------------------
-- create the action
-- @function [parent=#PageTurn3D] create
@ -24,6 +18,12 @@
-- @param self
-- @return PageTurn3D#PageTurn3D ret (return value: cc.PageTurn3D)
--------------------------------
--
-- @function [parent=#PageTurn3D] getGrid
-- @param self
-- @return GridBase#GridBase ret (return value: cc.GridBase)
--------------------------------
-- param time in seconds
-- @function [parent=#PageTurn3D] update

View File

@ -79,13 +79,6 @@
-- @param self
-- @return float#float ret (return value: float)
--------------------------------
--
-- @function [parent=#ParticleSystem] setRotation
-- @param self
-- @param #float newRotation
-- @return ParticleSystem#ParticleSystem self (return value: cc.ParticleSystem)
--------------------------------
--
-- @function [parent=#ParticleSystem] setTangentialAccel
@ -93,20 +86,6 @@
-- @param #float t
-- @return ParticleSystem#ParticleSystem self (return value: cc.ParticleSystem)
--------------------------------
--
-- @function [parent=#ParticleSystem] setScaleY
-- @param self
-- @param #float newScaleY
-- @return ParticleSystem#ParticleSystem self (return value: cc.ParticleSystem)
--------------------------------
--
-- @function [parent=#ParticleSystem] setScaleX
-- @param self
-- @param #float newScaleX
-- @return ParticleSystem#ParticleSystem self (return value: cc.ParticleSystem)
--------------------------------
--
-- @function [parent=#ParticleSystem] getRadialAccel
@ -309,12 +288,6 @@
-- @param self
-- @return float#float ret (return value: float)
--------------------------------
--
-- @function [parent=#ParticleSystem] isOpacityModifyRGB
-- @param self
-- @return bool#bool ret (return value: bool)
--------------------------------
--
-- @function [parent=#ParticleSystem] isActive
@ -527,13 +500,6 @@
-- @param self
-- @return bool#bool ret (return value: bool)
--------------------------------
--
-- @function [parent=#ParticleSystem] setScale
-- @param self
-- @param #float s
-- @return ParticleSystem#ParticleSystem self (return value: cc.ParticleSystem)
--------------------------------
-- emission rate of the particles
-- @function [parent=#ParticleSystem] getEmissionRate
@ -559,13 +525,6 @@
-- @param #float sizeVar
-- @return ParticleSystem#ParticleSystem self (return value: cc.ParticleSystem)
--------------------------------
-- does the alpha value modify color
-- @function [parent=#ParticleSystem] setOpacityModifyRGB
-- @param self
-- @param #bool opacityModifyRGB
-- @return ParticleSystem#ParticleSystem self (return value: cc.ParticleSystem)
--------------------------------
-- Add a particle to the emitter
-- @function [parent=#ParticleSystem] addParticle
@ -677,6 +636,40 @@
-- @param #int numberOfParticles
-- @return ParticleSystem#ParticleSystem ret (return value: cc.ParticleSystem)
--------------------------------
--
-- @function [parent=#ParticleSystem] setScaleY
-- @param self
-- @param #float newScaleY
-- @return ParticleSystem#ParticleSystem self (return value: cc.ParticleSystem)
--------------------------------
--
-- @function [parent=#ParticleSystem] setScaleX
-- @param self
-- @param #float newScaleX
-- @return ParticleSystem#ParticleSystem self (return value: cc.ParticleSystem)
--------------------------------
--
-- @function [parent=#ParticleSystem] isOpacityModifyRGB
-- @param self
-- @return bool#bool ret (return value: bool)
--------------------------------
-- does the alpha value modify color
-- @function [parent=#ParticleSystem] setOpacityModifyRGB
-- @param self
-- @param #bool opacityModifyRGB
-- @return ParticleSystem#ParticleSystem self (return value: cc.ParticleSystem)
--------------------------------
--
-- @function [parent=#ParticleSystem] setScale
-- @param self
-- @param #float s
-- @return ParticleSystem#ParticleSystem self (return value: cc.ParticleSystem)
--------------------------------
--
-- @function [parent=#ParticleSystem] update
@ -684,4 +677,11 @@
-- @param #float dt
-- @return ParticleSystem#ParticleSystem self (return value: cc.ParticleSystem)
--------------------------------
--
-- @function [parent=#ParticleSystem] setRotation
-- @param self
-- @param #float newRotation
-- @return ParticleSystem#ParticleSystem self (return value: cc.ParticleSystem)
return nil

View File

@ -12,13 +12,6 @@
-- @param #int index
-- @return RichText#RichText self (return value: ccui.RichText)
--------------------------------
--
-- @function [parent=#RichText] setAnchorPoint
-- @param self
-- @param #vec2_table pt
-- @return RichText#RichText self (return value: ccui.RichText)
--------------------------------
--
-- @function [parent=#RichText] pushBackElement
@ -26,13 +19,6 @@
-- @param #ccui.RichElement element
-- @return RichText#RichText self (return value: ccui.RichText)
--------------------------------
--
-- @function [parent=#RichText] ignoreContentAdaptWithSize
-- @param self
-- @param #bool ignore
-- @return RichText#RichText self (return value: ccui.RichText)
--------------------------------
--
-- @function [parent=#RichText] setVerticalSpace
@ -60,6 +46,13 @@
-- @param self
-- @return RichText#RichText ret (return value: ccui.RichText)
--------------------------------
--
-- @function [parent=#RichText] setAnchorPoint
-- @param self
-- @param #vec2_table pt
-- @return RichText#RichText self (return value: ccui.RichText)
--------------------------------
--
-- @function [parent=#RichText] getDescription
@ -72,6 +65,13 @@
-- @param self
-- @return size_table#size_table ret (return value: size_table)
--------------------------------
--
-- @function [parent=#RichText] ignoreContentAdaptWithSize
-- @param self
-- @param #bool ignore
-- @return RichText#RichText self (return value: ccui.RichText)
--------------------------------
--
-- @function [parent=#RichText] RichText

View File

@ -21,7 +21,7 @@
-- @return Sprite#Sprite self (return value: cc.Sprite)
--------------------------------
-- returns the Texture2D object used by the sprite
-- Returns the Texture2D object used by the sprite.
-- @function [parent=#Sprite] getTexture
-- @param self
-- @return Texture2D#Texture2D ret (return value: cc.Texture2D)
@ -43,7 +43,7 @@
-- @return Sprite#Sprite self (return value: cc.Sprite)
--------------------------------
-- Returns the batch node object if this sprite is rendered by SpriteBatchNode<br>
-- Returns the batch node object if this sprite is rendered by SpriteBatchNode.<br>
-- return The SpriteBatchNode object if this sprite is rendered by SpriteBatchNode,<br>
-- nullptr if the sprite isn't used batch node.
-- @function [parent=#Sprite] getBatchNode
@ -63,12 +63,6 @@
-- @param #bool cleanup
-- @return Sprite#Sprite self (return value: cc.Sprite)
--------------------------------
-- Updates the quad according the rotation, position, scale values.
-- @function [parent=#Sprite] updateTransform
-- @param self
-- @return Sprite#Sprite self (return value: cc.Sprite)
--------------------------------
-- @overload self, rect_table, bool, size_table
-- @overload self, rect_table
@ -80,7 +74,7 @@
-- @return Sprite#Sprite self (return value: cc.Sprite)
--------------------------------
-- Returns whether or not a SpriteFrame is being displayed
-- Returns whether or not a SpriteFrame is being displayed.
-- @function [parent=#Sprite] isFrameDisplayed
-- @param self
-- @param #cc.SpriteFrame frame
@ -116,7 +110,7 @@
--------------------------------
-- / @{/ @name Animation methods<br>
-- Changes the display frame with animation name and index.<br>
-- The animation name will be get from the AnimationCache
-- The animation name will be get from the AnimationCache.
-- @function [parent=#Sprite] setDisplayFrameWithAnimationName
-- @param self
-- @param #string animationName
@ -124,7 +118,7 @@
-- @return Sprite#Sprite self (return value: cc.Sprite)
--------------------------------
-- Sets the weak reference of the TextureAtlas when the sprite is rendered using via SpriteBatchNode
-- Sets the weak reference of the TextureAtlas when the sprite is rendered using via SpriteBatchNode.
-- @function [parent=#Sprite] setTextureAtlas
-- @param self
-- @param #cc.TextureAtlas textureAtlas
@ -145,7 +139,7 @@
--------------------------------
-- Sets the index used on the TextureAtlas.<br>
-- warning Don't modify this value unless you know what you are doing
-- warning Don't modify this value unless you know what you are doing.
-- @function [parent=#Sprite] setAtlasIndex
-- @param self
-- @param #long atlasIndex
@ -165,7 +159,7 @@
-- @return bool#bool ret (return value: bool)
--------------------------------
-- Returns the rect of the Sprite in points
-- Returns the rect of the Sprite in points.
-- @function [parent=#Sprite] getTextureRect
-- @param self
-- @return rect_table#rect_table ret (return value: rect_table)
@ -173,7 +167,7 @@
--------------------------------
-- / @{/ @name Functions inherited from TextureProtocol<br>
-- code<br>
-- When this function bound into js or lua,the parameter will be changed<br>
-- When this function bound into js or lua,the parameter will be changed.<br>
-- In js: var setBlendFunc(var src, var dst)<br>
-- In lua: local setBlendFunc(local src, local dst)<br>
-- endcode
@ -183,7 +177,7 @@
-- @return Sprite#Sprite self (return value: cc.Sprite)
--------------------------------
-- Gets the weak reference of the TextureAtlas when the sprite is rendered using via SpriteBatchNode
-- Gets the weak reference of the TextureAtlas when the sprite is rendered using via SpriteBatchNode.
-- @function [parent=#Sprite] getTextureAtlas
-- @param self
-- @return TextureAtlas#TextureAtlas ret (return value: cc.TextureAtlas)
@ -245,7 +239,7 @@
-- A SpriteFrame will be fetched from the SpriteFrameCache by spriteFrameName param.<br>
-- If the SpriteFrame doesn't exist it will raise an exception.<br>
-- param spriteFrameName A null terminated string which indicates the sprite frame name.<br>
-- return An autoreleased sprite object
-- return An autoreleased sprite object.
-- @function [parent=#Sprite] createWithSpriteFrameName
-- @param self
-- @param #string spriteFrameName
@ -253,22 +247,13 @@
--------------------------------
-- Creates a sprite with an sprite frame.<br>
-- param spriteFrame A sprite frame which involves a texture and a rect<br>
-- return An autoreleased sprite object
-- param spriteFrame A sprite frame which involves a texture and a rect.<br>
-- return An autoreleased sprite object.
-- @function [parent=#Sprite] createWithSpriteFrame
-- @param self
-- @param #cc.SpriteFrame spriteFrame
-- @return Sprite#Sprite ret (return value: cc.Sprite)
--------------------------------
--
-- @function [parent=#Sprite] draw
-- @param self
-- @param #cc.Renderer renderer
-- @param #mat4_table transform
-- @param #unsigned int flags
-- @return Sprite#Sprite self (return value: cc.Sprite)
--------------------------------
-- @overload self, cc.Node, int, string
-- @overload self, cc.Node, int, int
@ -279,33 +264,6 @@
-- @param #int tag
-- @return Sprite#Sprite self (return value: cc.Sprite)
--------------------------------
--
-- @function [parent=#Sprite] setScaleY
-- @param self
-- @param #float scaleY
-- @return Sprite#Sprite self (return value: cc.Sprite)
--------------------------------
-- / @{/ @name Functions inherited from Node
-- @function [parent=#Sprite] setScaleX
-- @param self
-- @param #float scaleX
-- @return Sprite#Sprite self (return value: cc.Sprite)
--------------------------------
--
-- @function [parent=#Sprite] isOpacityModifyRGB
-- @param self
-- @return bool#bool ret (return value: bool)
--------------------------------
--
-- @function [parent=#Sprite] setPositionZ
-- @param self
-- @param #float positionZ
-- @return Sprite#Sprite self (return value: cc.Sprite)
--------------------------------
--
-- @function [parent=#Sprite] setAnchorPoint
@ -320,17 +278,11 @@
-- @param #float rotationX
-- @return Sprite#Sprite self (return value: cc.Sprite)
--------------------------------
-- / @}
-- @function [parent=#Sprite] getDescription
-- @param self
-- @return string#string ret (return value: string)
--------------------------------
--
-- @function [parent=#Sprite] setRotationSkewY
-- @function [parent=#Sprite] setScaleY
-- @param self
-- @param #float rotationY
-- @param #float scaleY
-- @return Sprite#Sprite self (return value: cc.Sprite)
--------------------------------
@ -344,25 +296,9 @@
--------------------------------
--
-- @function [parent=#Sprite] reorderChild
-- @function [parent=#Sprite] isOpacityModifyRGB
-- @param self
-- @param #cc.Node child
-- @param #int zOrder
-- @return Sprite#Sprite self (return value: cc.Sprite)
--------------------------------
--
-- @function [parent=#Sprite] removeChild
-- @param self
-- @param #cc.Node child
-- @param #bool cleanup
-- @return Sprite#Sprite self (return value: cc.Sprite)
--------------------------------
--
-- @function [parent=#Sprite] sortAllChildren
-- @param self
-- @return Sprite#Sprite self (return value: cc.Sprite)
-- @return bool#bool ret (return value: bool)
--------------------------------
--
@ -378,6 +314,84 @@
-- @param #float rotation
-- @return Sprite#Sprite self (return value: cc.Sprite)
--------------------------------
--
-- @function [parent=#Sprite] draw
-- @param self
-- @param #cc.Renderer renderer
-- @param #mat4_table transform
-- @param #unsigned int flags
-- @return Sprite#Sprite self (return value: cc.Sprite)
--------------------------------
-- / @{/ @name Functions inherited from Node.
-- @function [parent=#Sprite] setScaleX
-- @param self
-- @param #float scaleX
-- @return Sprite#Sprite self (return value: cc.Sprite)
--------------------------------
-- / @}
-- @function [parent=#Sprite] getDescription
-- @param self
-- @return string#string ret (return value: string)
--------------------------------
--
-- @function [parent=#Sprite] setRotationSkewY
-- @param self
-- @param #float rotationY
-- @return Sprite#Sprite self (return value: cc.Sprite)
--------------------------------
--
-- @function [parent=#Sprite] sortAllChildren
-- @param self
-- @return Sprite#Sprite self (return value: cc.Sprite)
--------------------------------
--
-- @function [parent=#Sprite] reorderChild
-- @param self
-- @param #cc.Node child
-- @param #int zOrder
-- @return Sprite#Sprite self (return value: cc.Sprite)
--------------------------------
--
-- @function [parent=#Sprite] ignoreAnchorPointForPosition
-- @param self
-- @param #bool value
-- @return Sprite#Sprite self (return value: cc.Sprite)
--------------------------------
--
-- @function [parent=#Sprite] setPositionZ
-- @param self
-- @param #float positionZ
-- @return Sprite#Sprite self (return value: cc.Sprite)
--------------------------------
--
-- @function [parent=#Sprite] removeChild
-- @param self
-- @param #cc.Node child
-- @param #bool cleanup
-- @return Sprite#Sprite self (return value: cc.Sprite)
--------------------------------
-- Updates the quad according the rotation, position, scale values.
-- @function [parent=#Sprite] updateTransform
-- @param self
-- @return Sprite#Sprite self (return value: cc.Sprite)
--------------------------------
--
-- @function [parent=#Sprite] setSkewX
-- @param self
-- @param #float sx
-- @return Sprite#Sprite self (return value: cc.Sprite)
--------------------------------
--
-- @function [parent=#Sprite] setSkewY
@ -392,18 +406,4 @@
-- @param #bool bVisible
-- @return Sprite#Sprite self (return value: cc.Sprite)
--------------------------------
--
-- @function [parent=#Sprite] setSkewX
-- @param self
-- @param #float sx
-- @return Sprite#Sprite self (return value: cc.Sprite)
--------------------------------
--
-- @function [parent=#Sprite] ignoreAnchorPointForPosition
-- @param self
-- @param #bool value
-- @return Sprite#Sprite self (return value: cc.Sprite)
return nil

View File

@ -233,13 +233,6 @@
-- @param #bool enable
-- @return TextField#TextField self (return value: ccui.TextField)
--------------------------------
--
-- @function [parent=#TextField] hitTest
-- @param self
-- @param #vec2_table pt
-- @return bool#bool ret (return value: bool)
--------------------------------
--
-- @function [parent=#TextField] setMaxLength
@ -295,6 +288,13 @@
-- @param #float dt
-- @return TextField#TextField self (return value: ccui.TextField)
--------------------------------
--
-- @function [parent=#TextField] hitTest
-- @param self
-- @param #vec2_table pt
-- @return bool#bool ret (return value: bool)
--------------------------------
--
-- @function [parent=#TextField] getVirtualRendererSize

View File

@ -10,13 +10,6 @@
-- @param self
-- @return string#string ret (return value: string)
--------------------------------
--
-- @function [parent=#TextureFrame] setNode
-- @param self
-- @param #cc.Node node
-- @return TextureFrame#TextureFrame self (return value: ccs.TextureFrame)
--------------------------------
--
-- @function [parent=#TextureFrame] setTextureName
@ -36,6 +29,13 @@
-- @param self
-- @return Frame#Frame ret (return value: ccs.Frame)
--------------------------------
--
-- @function [parent=#TextureFrame] setNode
-- @param self
-- @param #cc.Node node
-- @return TextureFrame#TextureFrame self (return value: ccs.TextureFrame)
--------------------------------
--
-- @function [parent=#TextureFrame] TextureFrame

View File

@ -4,16 +4,16 @@
-- @extend GridAction
-- @parent_module cc
--------------------------------
-- returns the grid
-- @function [parent=#TiledGrid3DAction] getGrid
-- @param self
-- @return GridBase#GridBase ret (return value: cc.GridBase)
--------------------------------
--
-- @function [parent=#TiledGrid3DAction] clone
-- @param self
-- @return TiledGrid3DAction#TiledGrid3DAction ret (return value: cc.TiledGrid3DAction)
--------------------------------
-- returns the grid
-- @function [parent=#TiledGrid3DAction] getGrid
-- @param self
-- @return GridBase#GridBase ret (return value: cc.GridBase)
return nil

View File

@ -4,12 +4,6 @@
-- @extend TransitionSlideInL
-- @parent_module cc
--------------------------------
-- returns the action that will be performed by the incoming and outgoing scene
-- @function [parent=#TransitionSlideInB] action
-- @param self
-- @return ActionInterval#ActionInterval ret (return value: cc.ActionInterval)
--------------------------------
--
-- @function [parent=#TransitionSlideInB] create
@ -18,4 +12,10 @@
-- @param #cc.Scene scene
-- @return TransitionSlideInB#TransitionSlideInB ret (return value: cc.TransitionSlideInB)
--------------------------------
-- returns the action that will be performed by the incoming and outgoing scene
-- @function [parent=#TransitionSlideInB] action
-- @param self
-- @return ActionInterval#ActionInterval ret (return value: cc.ActionInterval)
return nil

View File

@ -4,12 +4,6 @@
-- @extend TransitionSlideInL
-- @parent_module cc
--------------------------------
-- returns the action that will be performed by the incoming and outgoing scene
-- @function [parent=#TransitionSlideInR] action
-- @param self
-- @return ActionInterval#ActionInterval ret (return value: cc.ActionInterval)
--------------------------------
--
-- @function [parent=#TransitionSlideInR] create
@ -18,4 +12,10 @@
-- @param #cc.Scene scene
-- @return TransitionSlideInR#TransitionSlideInR ret (return value: cc.TransitionSlideInR)
--------------------------------
-- returns the action that will be performed by the incoming and outgoing scene
-- @function [parent=#TransitionSlideInR] action
-- @param self
-- @return ActionInterval#ActionInterval ret (return value: cc.ActionInterval)
return nil

View File

@ -4,12 +4,6 @@
-- @extend TransitionSlideInL
-- @parent_module cc
--------------------------------
-- returns the action that will be performed by the incoming and outgoing scene
-- @function [parent=#TransitionSlideInT] action
-- @param self
-- @return ActionInterval#ActionInterval ret (return value: cc.ActionInterval)
--------------------------------
--
-- @function [parent=#TransitionSlideInT] create
@ -18,4 +12,10 @@
-- @param #cc.Scene scene
-- @return TransitionSlideInT#TransitionSlideInT ret (return value: cc.TransitionSlideInT)
--------------------------------
-- returns the action that will be performed by the incoming and outgoing scene
-- @function [parent=#TransitionSlideInT] action
-- @param self
-- @return ActionInterval#ActionInterval ret (return value: cc.ActionInterval)
return nil

View File

@ -2733,62 +2733,6 @@ int lua_cocos2dx_3d_BillBoard_getMode(lua_State* tolua_S)
return 0;
}
int lua_cocos2dx_3d_BillBoard_visit(lua_State* tolua_S)
{
int argc = 0;
cocos2d::BillBoard* cobj = nullptr;
bool ok = true;
#if COCOS2D_DEBUG >= 1
tolua_Error tolua_err;
#endif
#if COCOS2D_DEBUG >= 1
if (!tolua_isusertype(tolua_S,1,"cc.BillBoard",0,&tolua_err)) goto tolua_lerror;
#endif
cobj = (cocos2d::BillBoard*)tolua_tousertype(tolua_S,1,0);
#if COCOS2D_DEBUG >= 1
if (!cobj)
{
tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_3d_BillBoard_visit'", nullptr);
return 0;
}
#endif
argc = lua_gettop(tolua_S)-1;
if (argc == 3)
{
cocos2d::Renderer* arg0;
cocos2d::Mat4 arg1;
unsigned int arg2;
ok &= luaval_to_object<cocos2d::Renderer>(tolua_S, 2, "cc.Renderer",&arg0);
ok &= luaval_to_mat4(tolua_S, 3, &arg1, "cc.BillBoard:visit");
ok &= luaval_to_uint32(tolua_S, 4,&arg2, "cc.BillBoard:visit");
if(!ok)
{
tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_3d_BillBoard_visit'", nullptr);
return 0;
}
cobj->visit(arg0, arg1, arg2);
lua_settop(tolua_S, 1);
return 1;
}
luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.BillBoard:visit",argc, 3);
return 0;
#if COCOS2D_DEBUG >= 1
tolua_lerror:
tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_3d_BillBoard_visit'.",&tolua_err);
#endif
return 0;
}
int lua_cocos2dx_3d_BillBoard_setMode(lua_State* tolua_S)
{
int argc = 0;
@ -3012,7 +2956,6 @@ int lua_register_cocos2dx_3d_BillBoard(lua_State* tolua_S)
tolua_beginmodule(tolua_S,"BillBoard");
tolua_function(tolua_S,"getMode",lua_cocos2dx_3d_BillBoard_getMode);
tolua_function(tolua_S,"visit",lua_cocos2dx_3d_BillBoard_visit);
tolua_function(tolua_S,"setMode",lua_cocos2dx_3d_BillBoard_setMode);
tolua_function(tolua_S,"create", lua_cocos2dx_3d_BillBoard_create);
tolua_function(tolua_S,"createWithTexture", lua_cocos2dx_3d_BillBoard_createWithTexture);

View File

@ -74,7 +74,6 @@ int register_all_cocos2dx_3d(lua_State* tolua_S);
#endif // __cocos2dx_3d_h__

View File

@ -29401,53 +29401,6 @@ int lua_register_cocos2dx_GridAction(lua_State* tolua_S)
return 1;
}
int lua_cocos2dx_Grid3DAction_getGrid(lua_State* tolua_S)
{
int argc = 0;
cocos2d::Grid3DAction* cobj = nullptr;
bool ok = true;
#if COCOS2D_DEBUG >= 1
tolua_Error tolua_err;
#endif
#if COCOS2D_DEBUG >= 1
if (!tolua_isusertype(tolua_S,1,"cc.Grid3DAction",0,&tolua_err)) goto tolua_lerror;
#endif
cobj = (cocos2d::Grid3DAction*)tolua_tousertype(tolua_S,1,0);
#if COCOS2D_DEBUG >= 1
if (!cobj)
{
tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Grid3DAction_getGrid'", nullptr);
return 0;
}
#endif
argc = lua_gettop(tolua_S)-1;
if (argc == 0)
{
if(!ok)
{
tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Grid3DAction_getGrid'", nullptr);
return 0;
}
cocos2d::GridBase* ret = cobj->getGrid();
object_to_luaval<cocos2d::GridBase>(tolua_S, "cc.GridBase",(cocos2d::GridBase*)ret);
return 1;
}
luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Grid3DAction:getGrid",argc, 0);
return 0;
#if COCOS2D_DEBUG >= 1
tolua_lerror:
tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Grid3DAction_getGrid'.",&tolua_err);
#endif
return 0;
}
static int lua_cocos2dx_Grid3DAction_finalize(lua_State* tolua_S)
{
printf("luabindings: finalizing LUA object (Grid3DAction)");
@ -29460,7 +29413,6 @@ int lua_register_cocos2dx_Grid3DAction(lua_State* tolua_S)
tolua_cclass(tolua_S,"Grid3DAction","cc.Grid3DAction","cc.GridAction",nullptr);
tolua_beginmodule(tolua_S,"Grid3DAction");
tolua_function(tolua_S,"getGrid",lua_cocos2dx_Grid3DAction_getGrid);
tolua_endmodule(tolua_S);
std::string typeName = typeid(cocos2d::Grid3DAction).name();
g_luaType[typeName] = "cc.Grid3DAction";
@ -29468,53 +29420,6 @@ int lua_register_cocos2dx_Grid3DAction(lua_State* tolua_S)
return 1;
}
int lua_cocos2dx_TiledGrid3DAction_getGrid(lua_State* tolua_S)
{
int argc = 0;
cocos2d::TiledGrid3DAction* cobj = nullptr;
bool ok = true;
#if COCOS2D_DEBUG >= 1
tolua_Error tolua_err;
#endif
#if COCOS2D_DEBUG >= 1
if (!tolua_isusertype(tolua_S,1,"cc.TiledGrid3DAction",0,&tolua_err)) goto tolua_lerror;
#endif
cobj = (cocos2d::TiledGrid3DAction*)tolua_tousertype(tolua_S,1,0);
#if COCOS2D_DEBUG >= 1
if (!cobj)
{
tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TiledGrid3DAction_getGrid'", nullptr);
return 0;
}
#endif
argc = lua_gettop(tolua_S)-1;
if (argc == 0)
{
if(!ok)
{
tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TiledGrid3DAction_getGrid'", nullptr);
return 0;
}
cocos2d::GridBase* ret = cobj->getGrid();
object_to_luaval<cocos2d::GridBase>(tolua_S, "cc.GridBase",(cocos2d::GridBase*)ret);
return 1;
}
luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TiledGrid3DAction:getGrid",argc, 0);
return 0;
#if COCOS2D_DEBUG >= 1
tolua_lerror:
tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TiledGrid3DAction_getGrid'.",&tolua_err);
#endif
return 0;
}
static int lua_cocos2dx_TiledGrid3DAction_finalize(lua_State* tolua_S)
{
printf("luabindings: finalizing LUA object (TiledGrid3DAction)");
@ -29527,7 +29432,6 @@ int lua_register_cocos2dx_TiledGrid3DAction(lua_State* tolua_S)
tolua_cclass(tolua_S,"TiledGrid3DAction","cc.TiledGrid3DAction","cc.GridAction",nullptr);
tolua_beginmodule(tolua_S,"TiledGrid3DAction");
tolua_function(tolua_S,"getGrid",lua_cocos2dx_TiledGrid3DAction_getGrid);
tolua_endmodule(tolua_S);
std::string typeName = typeid(cocos2d::TiledGrid3DAction).name();
g_luaType[typeName] = "cc.TiledGrid3DAction";
@ -31638,53 +31542,6 @@ int lua_register_cocos2dx_Twirl(lua_State* tolua_S)
return 1;
}
int lua_cocos2dx_PageTurn3D_getGrid(lua_State* tolua_S)
{
int argc = 0;
cocos2d::PageTurn3D* cobj = nullptr;
bool ok = true;
#if COCOS2D_DEBUG >= 1
tolua_Error tolua_err;
#endif
#if COCOS2D_DEBUG >= 1
if (!tolua_isusertype(tolua_S,1,"cc.PageTurn3D",0,&tolua_err)) goto tolua_lerror;
#endif
cobj = (cocos2d::PageTurn3D*)tolua_tousertype(tolua_S,1,0);
#if COCOS2D_DEBUG >= 1
if (!cobj)
{
tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_PageTurn3D_getGrid'", nullptr);
return 0;
}
#endif
argc = lua_gettop(tolua_S)-1;
if (argc == 0)
{
if(!ok)
{
tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_PageTurn3D_getGrid'", nullptr);
return 0;
}
cocos2d::GridBase* ret = cobj->getGrid();
object_to_luaval<cocos2d::GridBase>(tolua_S, "cc.GridBase",(cocos2d::GridBase*)ret);
return 1;
}
luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.PageTurn3D:getGrid",argc, 0);
return 0;
#if COCOS2D_DEBUG >= 1
tolua_lerror:
tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_PageTurn3D_getGrid'.",&tolua_err);
#endif
return 0;
}
int lua_cocos2dx_PageTurn3D_create(lua_State* tolua_S)
{
int argc = 0;
@ -31735,7 +31592,6 @@ int lua_register_cocos2dx_PageTurn3D(lua_State* tolua_S)
tolua_cclass(tolua_S,"PageTurn3D","cc.PageTurn3D","cc.Grid3DAction",nullptr);
tolua_beginmodule(tolua_S,"PageTurn3D");
tolua_function(tolua_S,"getGrid",lua_cocos2dx_PageTurn3D_getGrid);
tolua_function(tolua_S,"create", lua_cocos2dx_PageTurn3D_create);
tolua_endmodule(tolua_S);
std::string typeName = typeid(cocos2d::PageTurn3D).name();
@ -32423,59 +32279,6 @@ int lua_register_cocos2dx_FadeOutBLTiles(lua_State* tolua_S)
return 1;
}
int lua_cocos2dx_FadeOutUpTiles_transformTile(lua_State* tolua_S)
{
int argc = 0;
cocos2d::FadeOutUpTiles* cobj = nullptr;
bool ok = true;
#if COCOS2D_DEBUG >= 1
tolua_Error tolua_err;
#endif
#if COCOS2D_DEBUG >= 1
if (!tolua_isusertype(tolua_S,1,"cc.FadeOutUpTiles",0,&tolua_err)) goto tolua_lerror;
#endif
cobj = (cocos2d::FadeOutUpTiles*)tolua_tousertype(tolua_S,1,0);
#if COCOS2D_DEBUG >= 1
if (!cobj)
{
tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FadeOutUpTiles_transformTile'", nullptr);
return 0;
}
#endif
argc = lua_gettop(tolua_S)-1;
if (argc == 2)
{
cocos2d::Vec2 arg0;
double arg1;
ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.FadeOutUpTiles:transformTile");
ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.FadeOutUpTiles:transformTile");
if(!ok)
{
tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FadeOutUpTiles_transformTile'", nullptr);
return 0;
}
cobj->transformTile(arg0, arg1);
lua_settop(tolua_S, 1);
return 1;
}
luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FadeOutUpTiles:transformTile",argc, 2);
return 0;
#if COCOS2D_DEBUG >= 1
tolua_lerror:
tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FadeOutUpTiles_transformTile'.",&tolua_err);
#endif
return 0;
}
int lua_cocos2dx_FadeOutUpTiles_create(lua_State* tolua_S)
{
int argc = 0;
@ -32526,7 +32329,6 @@ int lua_register_cocos2dx_FadeOutUpTiles(lua_State* tolua_S)
tolua_cclass(tolua_S,"FadeOutUpTiles","cc.FadeOutUpTiles","cc.FadeOutTRTiles",nullptr);
tolua_beginmodule(tolua_S,"FadeOutUpTiles");
tolua_function(tolua_S,"transformTile",lua_cocos2dx_FadeOutUpTiles_transformTile);
tolua_function(tolua_S,"create", lua_cocos2dx_FadeOutUpTiles_create);
tolua_endmodule(tolua_S);
std::string typeName = typeid(cocos2d::FadeOutUpTiles).name();
@ -37348,53 +37150,6 @@ int lua_cocos2dx_LabelAtlas_initWithString(lua_State* tolua_S)
return 0;
}
int lua_cocos2dx_LabelAtlas_updateAtlasValues(lua_State* tolua_S)
{
int argc = 0;
cocos2d::LabelAtlas* cobj = nullptr;
bool ok = true;
#if COCOS2D_DEBUG >= 1
tolua_Error tolua_err;
#endif
#if COCOS2D_DEBUG >= 1
if (!tolua_isusertype(tolua_S,1,"cc.LabelAtlas",0,&tolua_err)) goto tolua_lerror;
#endif
cobj = (cocos2d::LabelAtlas*)tolua_tousertype(tolua_S,1,0);
#if COCOS2D_DEBUG >= 1
if (!cobj)
{
tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_LabelAtlas_updateAtlasValues'", nullptr);
return 0;
}
#endif
argc = lua_gettop(tolua_S)-1;
if (argc == 0)
{
if(!ok)
{
tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_LabelAtlas_updateAtlasValues'", nullptr);
return 0;
}
cobj->updateAtlasValues();
lua_settop(tolua_S, 1);
return 1;
}
luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.LabelAtlas:updateAtlasValues",argc, 0);
return 0;
#if COCOS2D_DEBUG >= 1
tolua_lerror:
tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_LabelAtlas_updateAtlasValues'.",&tolua_err);
#endif
return 0;
}
int lua_cocos2dx_LabelAtlas_getString(lua_State* tolua_S)
{
int argc = 0;
@ -37529,7 +37284,6 @@ int lua_register_cocos2dx_LabelAtlas(lua_State* tolua_S)
tolua_beginmodule(tolua_S,"LabelAtlas");
tolua_function(tolua_S,"setString",lua_cocos2dx_LabelAtlas_setString);
tolua_function(tolua_S,"initWithString",lua_cocos2dx_LabelAtlas_initWithString);
tolua_function(tolua_S,"updateAtlasValues",lua_cocos2dx_LabelAtlas_updateAtlasValues);
tolua_function(tolua_S,"getString",lua_cocos2dx_LabelAtlas_getString);
tolua_function(tolua_S,"_create", lua_cocos2dx_LabelAtlas_create);
tolua_endmodule(tolua_S);
@ -43367,53 +43121,6 @@ int lua_register_cocos2dx_TransitionSlideInL(lua_State* tolua_S)
return 1;
}
int lua_cocos2dx_TransitionSlideInR_action(lua_State* tolua_S)
{
int argc = 0;
cocos2d::TransitionSlideInR* cobj = nullptr;
bool ok = true;
#if COCOS2D_DEBUG >= 1
tolua_Error tolua_err;
#endif
#if COCOS2D_DEBUG >= 1
if (!tolua_isusertype(tolua_S,1,"cc.TransitionSlideInR",0,&tolua_err)) goto tolua_lerror;
#endif
cobj = (cocos2d::TransitionSlideInR*)tolua_tousertype(tolua_S,1,0);
#if COCOS2D_DEBUG >= 1
if (!cobj)
{
tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TransitionSlideInR_action'", nullptr);
return 0;
}
#endif
argc = lua_gettop(tolua_S)-1;
if (argc == 0)
{
if(!ok)
{
tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionSlideInR_action'", nullptr);
return 0;
}
cocos2d::ActionInterval* ret = cobj->action();
object_to_luaval<cocos2d::ActionInterval>(tolua_S, "cc.ActionInterval",(cocos2d::ActionInterval*)ret);
return 1;
}
luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionSlideInR:action",argc, 0);
return 0;
#if COCOS2D_DEBUG >= 1
tolua_lerror:
tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionSlideInR_action'.",&tolua_err);
#endif
return 0;
}
int lua_cocos2dx_TransitionSlideInR_create(lua_State* tolua_S)
{
int argc = 0;
@ -43464,7 +43171,6 @@ int lua_register_cocos2dx_TransitionSlideInR(lua_State* tolua_S)
tolua_cclass(tolua_S,"TransitionSlideInR","cc.TransitionSlideInR","cc.TransitionSlideInL",nullptr);
tolua_beginmodule(tolua_S,"TransitionSlideInR");
tolua_function(tolua_S,"action",lua_cocos2dx_TransitionSlideInR_action);
tolua_function(tolua_S,"create", lua_cocos2dx_TransitionSlideInR_create);
tolua_endmodule(tolua_S);
std::string typeName = typeid(cocos2d::TransitionSlideInR).name();
@ -43473,53 +43179,6 @@ int lua_register_cocos2dx_TransitionSlideInR(lua_State* tolua_S)
return 1;
}
int lua_cocos2dx_TransitionSlideInB_action(lua_State* tolua_S)
{
int argc = 0;
cocos2d::TransitionSlideInB* cobj = nullptr;
bool ok = true;
#if COCOS2D_DEBUG >= 1
tolua_Error tolua_err;
#endif
#if COCOS2D_DEBUG >= 1
if (!tolua_isusertype(tolua_S,1,"cc.TransitionSlideInB",0,&tolua_err)) goto tolua_lerror;
#endif
cobj = (cocos2d::TransitionSlideInB*)tolua_tousertype(tolua_S,1,0);
#if COCOS2D_DEBUG >= 1
if (!cobj)
{
tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TransitionSlideInB_action'", nullptr);
return 0;
}
#endif
argc = lua_gettop(tolua_S)-1;
if (argc == 0)
{
if(!ok)
{
tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionSlideInB_action'", nullptr);
return 0;
}
cocos2d::ActionInterval* ret = cobj->action();
object_to_luaval<cocos2d::ActionInterval>(tolua_S, "cc.ActionInterval",(cocos2d::ActionInterval*)ret);
return 1;
}
luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionSlideInB:action",argc, 0);
return 0;
#if COCOS2D_DEBUG >= 1
tolua_lerror:
tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionSlideInB_action'.",&tolua_err);
#endif
return 0;
}
int lua_cocos2dx_TransitionSlideInB_create(lua_State* tolua_S)
{
int argc = 0;
@ -43570,7 +43229,6 @@ int lua_register_cocos2dx_TransitionSlideInB(lua_State* tolua_S)
tolua_cclass(tolua_S,"TransitionSlideInB","cc.TransitionSlideInB","cc.TransitionSlideInL",nullptr);
tolua_beginmodule(tolua_S,"TransitionSlideInB");
tolua_function(tolua_S,"action",lua_cocos2dx_TransitionSlideInB_action);
tolua_function(tolua_S,"create", lua_cocos2dx_TransitionSlideInB_create);
tolua_endmodule(tolua_S);
std::string typeName = typeid(cocos2d::TransitionSlideInB).name();
@ -43579,53 +43237,6 @@ int lua_register_cocos2dx_TransitionSlideInB(lua_State* tolua_S)
return 1;
}
int lua_cocos2dx_TransitionSlideInT_action(lua_State* tolua_S)
{
int argc = 0;
cocos2d::TransitionSlideInT* cobj = nullptr;
bool ok = true;
#if COCOS2D_DEBUG >= 1
tolua_Error tolua_err;
#endif
#if COCOS2D_DEBUG >= 1
if (!tolua_isusertype(tolua_S,1,"cc.TransitionSlideInT",0,&tolua_err)) goto tolua_lerror;
#endif
cobj = (cocos2d::TransitionSlideInT*)tolua_tousertype(tolua_S,1,0);
#if COCOS2D_DEBUG >= 1
if (!cobj)
{
tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TransitionSlideInT_action'", nullptr);
return 0;
}
#endif
argc = lua_gettop(tolua_S)-1;
if (argc == 0)
{
if(!ok)
{
tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionSlideInT_action'", nullptr);
return 0;
}
cocos2d::ActionInterval* ret = cobj->action();
object_to_luaval<cocos2d::ActionInterval>(tolua_S, "cc.ActionInterval",(cocos2d::ActionInterval*)ret);
return 1;
}
luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionSlideInT:action",argc, 0);
return 0;
#if COCOS2D_DEBUG >= 1
tolua_lerror:
tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionSlideInT_action'.",&tolua_err);
#endif
return 0;
}
int lua_cocos2dx_TransitionSlideInT_create(lua_State* tolua_S)
{
int argc = 0;
@ -43676,7 +43287,6 @@ int lua_register_cocos2dx_TransitionSlideInT(lua_State* tolua_S)
tolua_cclass(tolua_S,"TransitionSlideInT","cc.TransitionSlideInT","cc.TransitionSlideInL",nullptr);
tolua_beginmodule(tolua_S,"TransitionSlideInT");
tolua_function(tolua_S,"action",lua_cocos2dx_TransitionSlideInT_action);
tolua_function(tolua_S,"create", lua_cocos2dx_TransitionSlideInT_create);
tolua_endmodule(tolua_S);
std::string typeName = typeid(cocos2d::TransitionSlideInT).name();
@ -50164,53 +49774,6 @@ int lua_cocos2dx_Sprite_removeAllChildrenWithCleanup(lua_State* tolua_S)
return 0;
}
int lua_cocos2dx_Sprite_updateTransform(lua_State* tolua_S)
{
int argc = 0;
cocos2d::Sprite* cobj = nullptr;
bool ok = true;
#if COCOS2D_DEBUG >= 1
tolua_Error tolua_err;
#endif
#if COCOS2D_DEBUG >= 1
if (!tolua_isusertype(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror;
#endif
cobj = (cocos2d::Sprite*)tolua_tousertype(tolua_S,1,0);
#if COCOS2D_DEBUG >= 1
if (!cobj)
{
tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Sprite_updateTransform'", nullptr);
return 0;
}
#endif
argc = lua_gettop(tolua_S)-1;
if (argc == 0)
{
if(!ok)
{
tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Sprite_updateTransform'", nullptr);
return 0;
}
cobj->updateTransform();
lua_settop(tolua_S, 1);
return 1;
}
luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sprite:updateTransform",argc, 0);
return 0;
#if COCOS2D_DEBUG >= 1
tolua_lerror:
tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_updateTransform'.",&tolua_err);
#endif
return 0;
}
int lua_cocos2dx_Sprite_setTextureRect(lua_State* tolua_S)
{
int argc = 0;
@ -51323,7 +50886,6 @@ int lua_register_cocos2dx_Sprite(lua_State* tolua_S)
tolua_function(tolua_S,"getBatchNode",lua_cocos2dx_Sprite_getBatchNode);
tolua_function(tolua_S,"getOffsetPosition",lua_cocos2dx_Sprite_getOffsetPosition);
tolua_function(tolua_S,"removeAllChildrenWithCleanup",lua_cocos2dx_Sprite_removeAllChildrenWithCleanup);
tolua_function(tolua_S,"updateTransform",lua_cocos2dx_Sprite_updateTransform);
tolua_function(tolua_S,"setTextureRect",lua_cocos2dx_Sprite_setTextureRect);
tolua_function(tolua_S,"isFrameDisplayed",lua_cocos2dx_Sprite_isFrameDisplayed);
tolua_function(tolua_S,"getAtlasIndex",lua_cocos2dx_Sprite_getAtlasIndex);
@ -54949,56 +54511,6 @@ int lua_cocos2dx_ParticleSystem_getEndSizeVar(lua_State* tolua_S)
return 0;
}
int lua_cocos2dx_ParticleSystem_setRotation(lua_State* tolua_S)
{
int argc = 0;
cocos2d::ParticleSystem* cobj = nullptr;
bool ok = true;
#if COCOS2D_DEBUG >= 1
tolua_Error tolua_err;
#endif
#if COCOS2D_DEBUG >= 1
if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror;
#endif
cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0);
#if COCOS2D_DEBUG >= 1
if (!cobj)
{
tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setRotation'", nullptr);
return 0;
}
#endif
argc = lua_gettop(tolua_S)-1;
if (argc == 1)
{
double arg0;
ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ParticleSystem:setRotation");
if(!ok)
{
tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setRotation'", nullptr);
return 0;
}
cobj->setRotation(arg0);
lua_settop(tolua_S, 1);
return 1;
}
luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setRotation",argc, 1);
return 0;
#if COCOS2D_DEBUG >= 1
tolua_lerror:
tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setRotation'.",&tolua_err);
#endif
return 0;
}
int lua_cocos2dx_ParticleSystem_setTangentialAccel(lua_State* tolua_S)
{
int argc = 0;
@ -55049,106 +54561,6 @@ int lua_cocos2dx_ParticleSystem_setTangentialAccel(lua_State* tolua_S)
return 0;
}
int lua_cocos2dx_ParticleSystem_setScaleY(lua_State* tolua_S)
{
int argc = 0;
cocos2d::ParticleSystem* cobj = nullptr;
bool ok = true;
#if COCOS2D_DEBUG >= 1
tolua_Error tolua_err;
#endif
#if COCOS2D_DEBUG >= 1
if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror;
#endif
cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0);
#if COCOS2D_DEBUG >= 1
if (!cobj)
{
tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setScaleY'", nullptr);
return 0;
}
#endif
argc = lua_gettop(tolua_S)-1;
if (argc == 1)
{
double arg0;
ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ParticleSystem:setScaleY");
if(!ok)
{
tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setScaleY'", nullptr);
return 0;
}
cobj->setScaleY(arg0);
lua_settop(tolua_S, 1);
return 1;
}
luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setScaleY",argc, 1);
return 0;
#if COCOS2D_DEBUG >= 1
tolua_lerror:
tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setScaleY'.",&tolua_err);
#endif
return 0;
}
int lua_cocos2dx_ParticleSystem_setScaleX(lua_State* tolua_S)
{
int argc = 0;
cocos2d::ParticleSystem* cobj = nullptr;
bool ok = true;
#if COCOS2D_DEBUG >= 1
tolua_Error tolua_err;
#endif
#if COCOS2D_DEBUG >= 1
if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror;
#endif
cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0);
#if COCOS2D_DEBUG >= 1
if (!cobj)
{
tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setScaleX'", nullptr);
return 0;
}
#endif
argc = lua_gettop(tolua_S)-1;
if (argc == 1)
{
double arg0;
ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ParticleSystem:setScaleX");
if(!ok)
{
tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setScaleX'", nullptr);
return 0;
}
cobj->setScaleX(arg0);
lua_settop(tolua_S, 1);
return 1;
}
luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setScaleX",argc, 1);
return 0;
#if COCOS2D_DEBUG >= 1
tolua_lerror:
tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setScaleX'.",&tolua_err);
#endif
return 0;
}
int lua_cocos2dx_ParticleSystem_getRadialAccel(lua_State* tolua_S)
{
int argc = 0;
@ -56654,53 +56066,6 @@ int lua_cocos2dx_ParticleSystem_getEndRadius(lua_State* tolua_S)
return 0;
}
int lua_cocos2dx_ParticleSystem_isOpacityModifyRGB(lua_State* tolua_S)
{
int argc = 0;
cocos2d::ParticleSystem* cobj = nullptr;
bool ok = true;
#if COCOS2D_DEBUG >= 1
tolua_Error tolua_err;
#endif
#if COCOS2D_DEBUG >= 1
if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror;
#endif
cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0);
#if COCOS2D_DEBUG >= 1
if (!cobj)
{
tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_isOpacityModifyRGB'", nullptr);
return 0;
}
#endif
argc = lua_gettop(tolua_S)-1;
if (argc == 0)
{
if(!ok)
{
tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_isOpacityModifyRGB'", nullptr);
return 0;
}
bool ret = cobj->isOpacityModifyRGB();
tolua_pushboolean(tolua_S,(bool)ret);
return 1;
}
luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:isOpacityModifyRGB",argc, 0);
return 0;
#if COCOS2D_DEBUG >= 1
tolua_lerror:
tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_isOpacityModifyRGB'.",&tolua_err);
#endif
return 0;
}
int lua_cocos2dx_ParticleSystem_isActive(lua_State* tolua_S)
{
int argc = 0;
@ -58259,56 +57624,6 @@ int lua_cocos2dx_ParticleSystem_getRotationIsDir(lua_State* tolua_S)
return 0;
}
int lua_cocos2dx_ParticleSystem_setScale(lua_State* tolua_S)
{
int argc = 0;
cocos2d::ParticleSystem* cobj = nullptr;
bool ok = true;
#if COCOS2D_DEBUG >= 1
tolua_Error tolua_err;
#endif
#if COCOS2D_DEBUG >= 1
if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror;
#endif
cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0);
#if COCOS2D_DEBUG >= 1
if (!cobj)
{
tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setScale'", nullptr);
return 0;
}
#endif
argc = lua_gettop(tolua_S)-1;
if (argc == 1)
{
double arg0;
ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ParticleSystem:setScale");
if(!ok)
{
tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setScale'", nullptr);
return 0;
}
cobj->setScale(arg0);
lua_settop(tolua_S, 1);
return 1;
}
luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setScale",argc, 1);
return 0;
#if COCOS2D_DEBUG >= 1
tolua_lerror:
tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setScale'.",&tolua_err);
#endif
return 0;
}
int lua_cocos2dx_ParticleSystem_getEmissionRate(lua_State* tolua_S)
{
int argc = 0;
@ -58500,56 +57815,6 @@ int lua_cocos2dx_ParticleSystem_setStartSizeVar(lua_State* tolua_S)
return 0;
}
int lua_cocos2dx_ParticleSystem_setOpacityModifyRGB(lua_State* tolua_S)
{
int argc = 0;
cocos2d::ParticleSystem* cobj = nullptr;
bool ok = true;
#if COCOS2D_DEBUG >= 1
tolua_Error tolua_err;
#endif
#if COCOS2D_DEBUG >= 1
if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror;
#endif
cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0);
#if COCOS2D_DEBUG >= 1
if (!cobj)
{
tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setOpacityModifyRGB'", nullptr);
return 0;
}
#endif
argc = lua_gettop(tolua_S)-1;
if (argc == 1)
{
bool arg0;
ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.ParticleSystem:setOpacityModifyRGB");
if(!ok)
{
tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setOpacityModifyRGB'", nullptr);
return 0;
}
cobj->setOpacityModifyRGB(arg0);
lua_settop(tolua_S, 1);
return 1;
}
luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setOpacityModifyRGB",argc, 1);
return 0;
#if COCOS2D_DEBUG >= 1
tolua_lerror:
tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setOpacityModifyRGB'.",&tolua_err);
#endif
return 0;
}
int lua_cocos2dx_ParticleSystem_addParticle(lua_State* tolua_S)
{
int argc = 0;
@ -59319,10 +58584,7 @@ int lua_register_cocos2dx_ParticleSystem(lua_State* tolua_S)
tolua_function(tolua_S,"getStartSpinVar",lua_cocos2dx_ParticleSystem_getStartSpinVar);
tolua_function(tolua_S,"getRadialAccelVar",lua_cocos2dx_ParticleSystem_getRadialAccelVar);
tolua_function(tolua_S,"getEndSizeVar",lua_cocos2dx_ParticleSystem_getEndSizeVar);
tolua_function(tolua_S,"setRotation",lua_cocos2dx_ParticleSystem_setRotation);
tolua_function(tolua_S,"setTangentialAccel",lua_cocos2dx_ParticleSystem_setTangentialAccel);
tolua_function(tolua_S,"setScaleY",lua_cocos2dx_ParticleSystem_setScaleY);
tolua_function(tolua_S,"setScaleX",lua_cocos2dx_ParticleSystem_setScaleX);
tolua_function(tolua_S,"getRadialAccel",lua_cocos2dx_ParticleSystem_getRadialAccel);
tolua_function(tolua_S,"setStartRadius",lua_cocos2dx_ParticleSystem_setStartRadius);
tolua_function(tolua_S,"setRotatePerSecond",lua_cocos2dx_ParticleSystem_setRotatePerSecond);
@ -59354,7 +58616,6 @@ int lua_register_cocos2dx_ParticleSystem(lua_State* tolua_S)
tolua_function(tolua_S,"setTangentialAccelVar",lua_cocos2dx_ParticleSystem_setTangentialAccelVar);
tolua_function(tolua_S,"setEndRadiusVar",lua_cocos2dx_ParticleSystem_setEndRadiusVar);
tolua_function(tolua_S,"getEndRadius",lua_cocos2dx_ParticleSystem_getEndRadius);
tolua_function(tolua_S,"isOpacityModifyRGB",lua_cocos2dx_ParticleSystem_isOpacityModifyRGB);
tolua_function(tolua_S,"isActive",lua_cocos2dx_ParticleSystem_isActive);
tolua_function(tolua_S,"setRadialAccelVar",lua_cocos2dx_ParticleSystem_setRadialAccelVar);
tolua_function(tolua_S,"setStartSize",lua_cocos2dx_ParticleSystem_setStartSize);
@ -59387,12 +58648,10 @@ int lua_register_cocos2dx_ParticleSystem(lua_State* tolua_S)
tolua_function(tolua_S,"setEmissionRate",lua_cocos2dx_ParticleSystem_setEmissionRate);
tolua_function(tolua_S,"getEndColorVar",lua_cocos2dx_ParticleSystem_getEndColorVar);
tolua_function(tolua_S,"getRotationIsDir",lua_cocos2dx_ParticleSystem_getRotationIsDir);
tolua_function(tolua_S,"setScale",lua_cocos2dx_ParticleSystem_setScale);
tolua_function(tolua_S,"getEmissionRate",lua_cocos2dx_ParticleSystem_getEmissionRate);
tolua_function(tolua_S,"getEndColor",lua_cocos2dx_ParticleSystem_getEndColor);
tolua_function(tolua_S,"getLifeVar",lua_cocos2dx_ParticleSystem_getLifeVar);
tolua_function(tolua_S,"setStartSizeVar",lua_cocos2dx_ParticleSystem_setStartSizeVar);
tolua_function(tolua_S,"setOpacityModifyRGB",lua_cocos2dx_ParticleSystem_setOpacityModifyRGB);
tolua_function(tolua_S,"addParticle",lua_cocos2dx_ParticleSystem_addParticle);
tolua_function(tolua_S,"getStartRadius",lua_cocos2dx_ParticleSystem_getStartRadius);
tolua_function(tolua_S,"getParticleCount",lua_cocos2dx_ParticleSystem_getParticleCount);

View File

@ -1619,21 +1619,6 @@ int register_all_cocos2dx(lua_State* tolua_S);

View File

@ -311,27 +311,6 @@ int register_all_cocos2dx_extension(lua_State* tolua_S);

View File

@ -504,12 +504,6 @@ int register_all_cocos2dx_studio(lua_State* tolua_S);

View File

@ -16913,56 +16913,6 @@ int lua_cocos2dx_ui_TextField_setTouchAreaEnabled(lua_State* tolua_S)
return 0;
}
int lua_cocos2dx_ui_TextField_hitTest(lua_State* tolua_S)
{
int argc = 0;
cocos2d::ui::TextField* cobj = nullptr;
bool ok = true;
#if COCOS2D_DEBUG >= 1
tolua_Error tolua_err;
#endif
#if COCOS2D_DEBUG >= 1
if (!tolua_isusertype(tolua_S,1,"ccui.TextField",0,&tolua_err)) goto tolua_lerror;
#endif
cobj = (cocos2d::ui::TextField*)tolua_tousertype(tolua_S,1,0);
#if COCOS2D_DEBUG >= 1
if (!cobj)
{
tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ui_TextField_hitTest'", nullptr);
return 0;
}
#endif
argc = lua_gettop(tolua_S)-1;
if (argc == 1)
{
cocos2d::Vec2 arg0;
ok &= luaval_to_vec2(tolua_S, 2, &arg0, "ccui.TextField:hitTest");
if(!ok)
{
tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ui_TextField_hitTest'", nullptr);
return 0;
}
bool ret = cobj->hitTest(arg0);
tolua_pushboolean(tolua_S,(bool)ret);
return 1;
}
luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "ccui.TextField:hitTest",argc, 1);
return 0;
#if COCOS2D_DEBUG >= 1
tolua_lerror:
tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ui_TextField_hitTest'.",&tolua_err);
#endif
return 0;
}
int lua_cocos2dx_ui_TextField_setMaxLength(lua_State* tolua_S)
{
int argc = 0;
@ -17280,7 +17230,6 @@ int lua_register_cocos2dx_ui_TextField(lua_State* tolua_S)
tolua_function(tolua_S,"isMaxLengthEnabled",lua_cocos2dx_ui_TextField_isMaxLengthEnabled);
tolua_function(tolua_S,"setDetachWithIME",lua_cocos2dx_ui_TextField_setDetachWithIME);
tolua_function(tolua_S,"setTouchAreaEnabled",lua_cocos2dx_ui_TextField_setTouchAreaEnabled);
tolua_function(tolua_S,"hitTest",lua_cocos2dx_ui_TextField_hitTest);
tolua_function(tolua_S,"setMaxLength",lua_cocos2dx_ui_TextField_setMaxLength);
tolua_function(tolua_S,"setTouchSize",lua_cocos2dx_ui_TextField_setTouchSize);
tolua_function(tolua_S,"getTouchSize",lua_cocos2dx_ui_TextField_getTouchSize);
@ -19469,56 +19418,6 @@ int lua_cocos2dx_ui_RichText_insertElement(lua_State* tolua_S)
return 0;
}
int lua_cocos2dx_ui_RichText_setAnchorPoint(lua_State* tolua_S)
{
int argc = 0;
cocos2d::ui::RichText* cobj = nullptr;
bool ok = true;
#if COCOS2D_DEBUG >= 1
tolua_Error tolua_err;
#endif
#if COCOS2D_DEBUG >= 1
if (!tolua_isusertype(tolua_S,1,"ccui.RichText",0,&tolua_err)) goto tolua_lerror;
#endif
cobj = (cocos2d::ui::RichText*)tolua_tousertype(tolua_S,1,0);
#if COCOS2D_DEBUG >= 1
if (!cobj)
{
tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ui_RichText_setAnchorPoint'", nullptr);
return 0;
}
#endif
argc = lua_gettop(tolua_S)-1;
if (argc == 1)
{
cocos2d::Vec2 arg0;
ok &= luaval_to_vec2(tolua_S, 2, &arg0, "ccui.RichText:setAnchorPoint");
if(!ok)
{
tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ui_RichText_setAnchorPoint'", nullptr);
return 0;
}
cobj->setAnchorPoint(arg0);
lua_settop(tolua_S, 1);
return 1;
}
luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "ccui.RichText:setAnchorPoint",argc, 1);
return 0;
#if COCOS2D_DEBUG >= 1
tolua_lerror:
tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ui_RichText_setAnchorPoint'.",&tolua_err);
#endif
return 0;
}
int lua_cocos2dx_ui_RichText_pushBackElement(lua_State* tolua_S)
{
int argc = 0;
@ -19569,56 +19468,6 @@ int lua_cocos2dx_ui_RichText_pushBackElement(lua_State* tolua_S)
return 0;
}
int lua_cocos2dx_ui_RichText_ignoreContentAdaptWithSize(lua_State* tolua_S)
{
int argc = 0;
cocos2d::ui::RichText* cobj = nullptr;
bool ok = true;
#if COCOS2D_DEBUG >= 1
tolua_Error tolua_err;
#endif
#if COCOS2D_DEBUG >= 1
if (!tolua_isusertype(tolua_S,1,"ccui.RichText",0,&tolua_err)) goto tolua_lerror;
#endif
cobj = (cocos2d::ui::RichText*)tolua_tousertype(tolua_S,1,0);
#if COCOS2D_DEBUG >= 1
if (!cobj)
{
tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ui_RichText_ignoreContentAdaptWithSize'", nullptr);
return 0;
}
#endif
argc = lua_gettop(tolua_S)-1;
if (argc == 1)
{
bool arg0;
ok &= luaval_to_boolean(tolua_S, 2,&arg0, "ccui.RichText:ignoreContentAdaptWithSize");
if(!ok)
{
tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ui_RichText_ignoreContentAdaptWithSize'", nullptr);
return 0;
}
cobj->ignoreContentAdaptWithSize(arg0);
lua_settop(tolua_S, 1);
return 1;
}
luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "ccui.RichText:ignoreContentAdaptWithSize",argc, 1);
return 0;
#if COCOS2D_DEBUG >= 1
tolua_lerror:
tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ui_RichText_ignoreContentAdaptWithSize'.",&tolua_err);
#endif
return 0;
}
int lua_cocos2dx_ui_RichText_setVerticalSpace(lua_State* tolua_S)
{
int argc = 0;
@ -19856,9 +19705,7 @@ int lua_register_cocos2dx_ui_RichText(lua_State* tolua_S)
tolua_beginmodule(tolua_S,"RichText");
tolua_function(tolua_S,"new",lua_cocos2dx_ui_RichText_constructor);
tolua_function(tolua_S,"insertElement",lua_cocos2dx_ui_RichText_insertElement);
tolua_function(tolua_S,"setAnchorPoint",lua_cocos2dx_ui_RichText_setAnchorPoint);
tolua_function(tolua_S,"pushBackElement",lua_cocos2dx_ui_RichText_pushBackElement);
tolua_function(tolua_S,"ignoreContentAdaptWithSize",lua_cocos2dx_ui_RichText_ignoreContentAdaptWithSize);
tolua_function(tolua_S,"setVerticalSpace",lua_cocos2dx_ui_RichText_setVerticalSpace);
tolua_function(tolua_S,"formatText",lua_cocos2dx_ui_RichText_formatText);
tolua_function(tolua_S,"removeElement",lua_cocos2dx_ui_RichText_removeElement);

View File

@ -544,9 +544,6 @@ int register_all_cocos2dx_ui(lua_State* tolua_S);

View File

@ -51,11 +51,13 @@ void PUDoAffectorEventHandler::handle (PUParticleSystem3D* particleSystem, PUPar
auto children = system->getChildren();
for(auto iter : children)
{
technique = static_cast<PUParticleSystem3D *>(iter);
affector = technique->getAffector(_affectorName);
if (affector)
{
break;
technique = dynamic_cast<PUParticleSystem3D *>(iter);
if (technique){
affector = technique->getAffector(_affectorName);
if (affector)
{
break;
}
}
}
}

View File

@ -138,8 +138,8 @@ void PUDoEnableComponentEventHandler::handle (PUParticleSystem3D* particleSystem
if (system){
auto children = system->getChildren();
for (auto iter : children){
PUParticleSystem3D *child = static_cast<PUParticleSystem3D *>(iter);
if (child->getName() == _componentName){
PUParticleSystem3D *child = dynamic_cast<PUParticleSystem3D *>(iter);
if (child && child->getName() == _componentName){
child->setEnabled(_componentEnabled);
break;
}

View File

@ -80,7 +80,7 @@ void PUDoPlacementParticleEventHandler::handle (PUParticleSystem3D* particleSyst
auto children = parentSystem->getChildren();
for(auto iter : children)
{
PUParticleSystem3D *child = static_cast<PUParticleSystem3D *>(iter);
PUParticleSystem3D *child = dynamic_cast<PUParticleSystem3D *>(iter);
if (child){
system = child;
emitter = system->getEmitter(_forceEmitterName);

View File

@ -1,5 +1,5 @@
{
"version":"v3-deps-34",
"version":"v3-deps-35",
"zip_file_size":"87419231",
"repo_name":"cocos2d-x-3rd-party-libs-bin",
"repo_parent":"https://github.com/cocos2d/",

View File

@ -217,6 +217,7 @@
"cocos/2d/cocos2d.def",
"cocos/2d/cocos2d_headers.props",
"cocos/2d/cocos2dx.props",
"cocos/2d/doxygen_modules.h",
"cocos/2d/libcocos2d.vcxproj",
"cocos/2d/libcocos2d.vcxproj.filters",
"cocos/2d/libcocos2d_8_1/libcocos2d_8_1.sln",
@ -494,6 +495,7 @@
"cocos/deprecated/CCString.cpp",
"cocos/deprecated/CCString.h",
"cocos/deprecated/CMakeLists.txt",
"cocos/doxygen_modules.h",
"cocos/editor-support/cocosbuilder/Android.mk",
"cocos/editor-support/cocosbuilder/CCBAnimationManager.cpp",
"cocos/editor-support/cocosbuilder/CCBAnimationManager.h",
@ -1126,7 +1128,6 @@
"cocos/renderer/ccShader_PositionColor.vert",
"cocos/renderer/ccShader_PositionColorLengthTexture.frag",
"cocos/renderer/ccShader_PositionColorLengthTexture.vert",
"cocos/renderer/ccShader_PositionColorPointsize-no-gl_PointSize.vert",
"cocos/renderer/ccShader_PositionColorTextureAsPointsize.vert",
"cocos/renderer/ccShader_PositionTexture.frag",
"cocos/renderer/ccShader_PositionTexture.vert",
@ -1139,7 +1140,6 @@
"cocos/renderer/ccShader_PositionTextureColor_noMVP.vert",
"cocos/renderer/ccShader_PositionTexture_uColor.frag",
"cocos/renderer/ccShader_PositionTexture_uColor.vert",
"cocos/renderer/ccShader_Position_uColor-no-gl_PointSize.vert",
"cocos/renderer/ccShader_Position_uColor.frag",
"cocos/renderer/ccShader_Position_uColor.vert",
"cocos/renderer/ccShaders.cpp",
@ -1243,6 +1243,7 @@
"docs/RELEASE_NOTES.md",
"docs/cocos2dx_portrait.png",
"docs/doxygen.config",
"docs/doxygen_white_book.config",
"download-deps.py",
"extensions/Android.mk",
"extensions/CMakeLists.txt",
@ -3033,6 +3034,8 @@
"external/winrt_8.1-specific/angle/include/KHR/khrplatform.h",
"external/winrt_8.1-specific/angle/include/angle_gl.h",
"external/winrt_8.1-specific/angle/include/angle_windowsstore.h",
"external/winrt_8.1-specific/angle/include/export.h",
"external/winrt_8.1-specific/angle/include/platform/Platform.h",
"external/winrt_8.1-specific/angle/prebuilt/arm/libEGL.dll",
"external/winrt_8.1-specific/angle/prebuilt/arm/libEGL.lib",
"external/winrt_8.1-specific/angle/prebuilt/arm/libGLESv2.dll",
@ -3086,6 +3089,8 @@
"external/wp_8.1-specific/angle/include/KHR/khrplatform.h",
"external/wp_8.1-specific/angle/include/angle_gl.h",
"external/wp_8.1-specific/angle/include/angle_windowsstore.h",
"external/wp_8.1-specific/angle/include/export.h",
"external/wp_8.1-specific/angle/include/platform/Platform.h",
"external/wp_8.1-specific/angle/prebuilt/arm/libEGL.dll",
"external/wp_8.1-specific/angle/prebuilt/arm/libEGL.lib",
"external/wp_8.1-specific/angle/prebuilt/arm/libGLESv2.dll",

View File

@ -82,7 +82,7 @@ void OpenGLES::Initialize()
// These attributes can be used to request D3D11 WARP.
// They are used if eglInitialize fails with both the default display attributes and the 9_3 display attributes.
EGL_PLATFORM_ANGLE_TYPE_ANGLE, EGL_PLATFORM_ANGLE_TYPE_D3D11_ANGLE,
EGL_PLATFORM_ANGLE_USE_WARP_ANGLE, EGL_TRUE,
EGL_PLATFORM_ANGLE_DEVICE_TYPE_ANGLE, EGL_PLATFORM_ANGLE_DEVICE_TYPE_WARP_ANGLE,
EGL_ANGLE_DISPLAY_ALLOW_RENDER_TO_BACK_BUFFER, EGL_TRUE,
EGL_NONE,
};