xref: /haiku/headers/private/interface/RegionSupport.h (revision 5c9e6a3953923a7c60c3d9c69c4f935492f26997)
1 // This file is distributed under the OpenBeOS license
2 
3 #ifndef __REGION_SUPPORT_H
4 #define __REGION_SUPPORT_H
5 
6 #include <Region.h>
7 
8 class BRegion::Support
9 {
10 public:
11 	static void ZeroRegion(BRegion *a_region);
12 	static void ClearRegion(BRegion *a_region);
13 	static void CopyRegion(BRegion *src_region, BRegion *dst_region);
14 	static void AndRegion(BRegion *first, BRegion *second, BRegion *dest);
15 	static void OrRegion(BRegion *first, BRegion *second, BRegion *dest);
16 	static void SubRegion(BRegion *first, BRegion *second, BRegion *dest);
17 
18 private:
19 	static void CleanupRegion(BRegion *region_in);
20 	static void CleanupRegionVertical(BRegion *region_in);
21 	static void CleanupRegionHorizontal(BRegion *region_in);
22 
23 	static void SortRects(clipping_rect *rects, long count);
24 	static void SortTrans(long *lptr1, long *lptr2, long count);
25 
26 	static void CopyRegionMore(BRegion*, BRegion*, long);
27 
28 	static void AndRegionComplex(BRegion*, BRegion*, BRegion*);
29 	static void AndRegion1ToN(BRegion*, BRegion*, BRegion*);
30 
31 	static void AppendRegion(BRegion*, BRegion*, BRegion*);
32 
33 	static void OrRegionComplex(BRegion*, BRegion*, BRegion*);
34 	static void OrRegion1ToN(BRegion*, BRegion*, BRegion*);
35 	static void OrRegionNoX(BRegion*, BRegion*, BRegion*);
36 	static void ROr(long, long, BRegion*, BRegion*, BRegion*, long*, long *);
37 
38 	static void SubRegionComplex(BRegion*, BRegion*, BRegion*);
39 	static void RSub(long , long, BRegion*, BRegion*, BRegion*, long*, long*);
40 };
41 
42 #endif // __REGION_SUPPORT_H
43