Rect and Point

Source: Internet
Author: User

1) cgrectcontainspoint (); Whether the point is in the rectangle

2) Cgrectcontainsrect ();     Returns whether the first rectangle contains a second rectangle of 3) cgrectintersectsrect ();        Returns whether two rectangles intersect 4) cgrectintersection ();     Two rectangular area of intersection of rectangles 5) cgpointequaltopoint ();       Whether the two points are a point 6) cgsizeequaltosize (); Two size is the same as 8) Cgrectinset creates rectangles based on the center point of a rectangle, positive values create smaller rectangles, negative values create larger rectangles cgrect r1 = CGRectMake (50,100,200,150); CGRect r2 = Cgrectinset (r1,60,10), R1 to the center of the point of 60, respectively, the 10来 to create the rectangle is the coordinates of the R2 is (110,110,80,130), calculated as (50+60, 100+10, 200-(60*2), 150-(10*2));

Rect and Point

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.