axmol/tools/tolua++/CCGeometry.pkg

46 lines
941 B
Plaintext

typedef float CGFloat;
class CCPoint
{
float x;
float y;
CCPoint();
CCPoint(float x, float y);
bool equals(const CCPoint & target) const ;
};
class CCSize
{
float width;
float height;
CCSize();
CCSize(float width, float height);
bool equals(const CCSize & target) const;
};
class CCRect
{
CCPoint origin;
CCSize size;
CCRect();
CCRect(float x, float y, float width, float height);
float getMinX();
float getMidX();
float getMaxX();
float getMinY();
float getMidY();
float getMaxY();
bool equals(const CCRect & rect) const;
bool containsPoint(const CCPoint & point) const;
bool intersectsRect(const CCRect & rect) const;
};
CCPoint CCPointMake(float x, float y);
CCPoint CCPointMake @ ccp (float x, float y);
CCSize CCSizeMake(float width, float height);
CCRect CCRectMake(float x, float y, float width,float height);