• Home
  • Raw
  • Download

Lines Matching refs:rect2

1103 bool isSameRect(const hwc_rect& rect1, const hwc_rect& rect2)  in isSameRect()  argument
1105 return ((rect1.left == rect2.left) && (rect1.top == rect2.top) && in isSameRect()
1106 (rect1.right == rect2.right) && (rect1.bottom == rect2.bottom)); in isSameRect()
1136 hwc_rect_t getIntersection(const hwc_rect_t& rect1, const hwc_rect_t& rect2) in getIntersection() argument
1140 if(!isValidRect(rect1) || !isValidRect(rect2)){ in getIntersection()
1145 res.left = max(rect1.left, rect2.left); in getIntersection()
1146 res.top = max(rect1.top, rect2.top); in getIntersection()
1147 res.right = min(rect1.right, rect2.right); in getIntersection()
1148 res.bottom = min(rect1.bottom, rect2.bottom); in getIntersection()
1157 hwc_rect_t getUnion(const hwc_rect &rect1, const hwc_rect &rect2) in getUnion() argument
1162 return rect2; in getUnion()
1165 if(!isValidRect(rect2)){ in getUnion()
1169 res.left = min(rect1.left, rect2.left); in getUnion()
1170 res.top = min(rect1.top, rect2.top); in getUnion()
1171 res.right = max(rect1.right, rect2.right); in getUnion()
1172 res.bottom = max(rect1.bottom, rect2.bottom); in getUnion()
1179 hwc_rect_t deductRect(const hwc_rect_t& rect1, const hwc_rect_t& rect2) { in deductRect() argument
1183 if((rect1.left == rect2.left) && (rect1.right == rect2.right)) { in deductRect()
1184 if((rect1.top == rect2.top) && (rect2.bottom <= rect1.bottom)) in deductRect()
1185 res.top = rect2.bottom; in deductRect()
1186 else if((rect1.bottom == rect2.bottom)&& (rect2.top >= rect1.top)) in deductRect()
1187 res.bottom = rect2.top; in deductRect()
1189 else if((rect1.top == rect2.top) && (rect1.bottom == rect2.bottom)) { in deductRect()
1190 if((rect1.left == rect2.left) && (rect2.right <= rect1.right)) in deductRect()
1191 res.left = rect2.right; in deductRect()
1192 else if((rect1.right == rect2.right)&& (rect2.left >= rect1.left)) in deductRect()
1193 res.right = rect2.left; in deductRect()