|
My Project
|
Public Member Functions | |
| CCRect () | |
| Constructor an empty Rect. More... | |
| CCRect (float x, float y, float width, float height) | |
| Constructor a rect. More... | |
| CCRect (const CCVector2 &pos, const Size &dimension) | |
| Constructor a rect. More... | |
| CCRect (const CCRect &other) | |
| Copy constructor. More... | |
| CCRect & | operator= (const CCRect &other) |
| NA NA | |
| void | setRect (float x, float y, float width, float height) |
| Set the x, y, width and height of Rect. More... | |
| float | getMinX () const |
| Get the left of the rect. More... | |
| float | getMidX () const |
| return the leftmost x-value of current rect More... | |
| float | getMaxX () const |
| return the midpoint x-value of current rect More... | |
| float | getMinY () const |
| return the rightmost x-value of current rect More... | |
| float | getMidY () const |
| return the bottommost y-value of current rect More... | |
| float | getMaxY () const |
| return the midpoint y-value of current rect More... | |
| bool | equals (const CCRect &rect) const |
| return the topmost y-value of current rect More... | |
| bool | containsPoint (const CCVector2 &point) const |
| Check if the points is contained in the rect. More... | |
| bool | intersectsRect (const CCRect &rect) const |
| Check the intersect status of two rects. More... | |
| bool | intersectsCircle (const CCVector2 ¢er, float radius) const |
| Check the intersect status of the rect and a circle. More... | |
| CCRect | unionWithRect (const CCRect &rect) const |
| Get the min rect which can contain this and rect. More... | |
| void | merge (const CCRect &rect) |
| Compute the min rect which can contain this and rect, assign it to this. More... | |
Public Attributes | |
| CCVector2 | origin |
| Low left point of rect. More... | |
| Size | size |
| Width and height of the rect. More... | |
Static Public Attributes | |
| static const CCRect | ZERO = CCRect(0, 0, 0, 0) |
| An empty Rect. More... | |
| CCRect::CCRect | ( | void | ) |
Constructor an empty Rect.
NA
| CCRect::CCRect | ( | float | x, |
| float | y, | ||
| float | width, | ||
| float | height | ||
| ) |
Constructor a rect.
NA
| CCRect::CCRect | ( | const CCRect & | other | ) |
Copy constructor.
NA NA
| bool CCRect::containsPoint | ( | const CCVector2 & | point | ) | const |
Check if the points is contained in the rect.
NA
| bool CCRect::equals | ( | const CCRect & | rect | ) | const |
return the topmost y-value of current rect
Compare two rects. NA
| float CCRect::getMaxX | ( | ) | const |
return the midpoint x-value of current rect
Get the right of rect. NA
| float CCRect::getMaxY | ( | ) | const |
return the midpoint y-value of current rect
Get top of rect. NA
| float CCRect::getMidX | ( | ) | const |
return the leftmost x-value of current rect
Get the X coordinate of center point. NA
| float CCRect::getMidY | ( | ) | const |
return the bottommost y-value of current rect
Get the Y coordinate of center point. NA
| float CCRect::getMinX | ( | ) | const |
Get the left of the rect.
NA
| float CCRect::getMinY | ( | ) | const |
return the rightmost x-value of current rect
Get the bottom of rect. NA
| bool CCRect::intersectsCircle | ( | const CCVector2 & | center, |
| float | radius | ||
| ) | const |
Check the intersect status of the rect and a circle.
NA
| bool CCRect::intersectsRect | ( | const CCRect & | rect | ) | const |
Check the intersect status of two rects.
NA
| void CCRect::merge | ( | const CCRect & | rect | ) |
Compute the min rect which can contain this and rect, assign it to this.
| void CCRect::setRect | ( | float | x, |
| float | y, | ||
| float | width, | ||
| float | height | ||
| ) |
Set the x, y, width and height of Rect.
NA NA
Get the min rect which can contain this and rect.
NA NA
| CCVector2 ParaEngine::CCRect::origin |
Low left point of rect.
| Size ParaEngine::CCRect::size |
Width and height of the rect.
1.8.12