|
Igor Delovski Board My Own Personal Slashdot!
|
General Programming |
Author |
Message |
XNote Kapetan
Joined: 16 Jun 2006 Posts: 532
|
Posted: Sat Oct 14, 2006 11:45 pm Post subject: Regions |
|
|
CreateRectRgnIndirect - creates a rectangular region.
Code: | HRGN CreateRectRgnIndirect(
CONST RECT *lprc // rectangle
); |
CombineRgn - combines two regions and stores the result in a third
region. The two regions are combined according to the specified mode.
Code: | int CombineRgn(
HRGN hrgnDest, // handle to destination region
HRGN hrgnSrc1, // handle to source region
HRGN hrgnSrc2, // handle to source region
int fnCombineMode // region combining mode
); |
The three regions need not be distinct. For example, the hrgnSrc1
parameter can equal the hrgnDest parameter.
* RGN_AND Creates the intersection of the two combined regions.
* RGN_COPY Creates a copy of the region identified by hrgnSrc1.
* RGN_DIFF Combines the parts of hrgnSrc1 that are not part of hrgnSrc2.
* RGN_OR Creates the union of two combined regions.
* RGN_XOR Creates the union of two combined regions except for any overlapping areas.
SelectClipRgn - selects a region as the current clipping region for
the specified device context.
Code: | int SelectClipRgn(
HDC hdc, // handle to DC
HRGN hrgn // handle to region
); |
Only a copy of the selected region is used. The region itself can be
selected for any number of other device contexts or it can be deleted. |
|
Back to top |
|
|
delovski
Joined: 14 Jun 2006 Posts: 3524 Location: Zagreb
|
Posted: Sun Oct 15, 2006 10:13 pm Post subject: |
|
|
Folklore: I Still Remember Regions, by Andy Hertzfeld
"The single most significant component of the original Macintosh technology
was QuickDraw, the graphics package written by Bill Atkinson. Most importantly,
all of the QuickDraw drawing primitives clipped to the intersection of three
different regions, to allow drawing into obscured windows. We considered
QuickDraw's speed and deftness at region handling to be the most significant
"crown jewel" in Apple's entire arsenal." |
|
Back to top |
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|