[Xorg] Region Routines in the ScreenRect

Deron Johnson Deron.Johnson at Sun.COM
Wed Aug 11 13:44:05 PDT 2004


No. A region is a LIST of rectangles. Regions are typically used to 
describe the shapes of windows, or where it is legal to draw within
a window, but regions are sometimes used for other things as well.

Here is an example of a complex region which contains many rectangles.


		**
	       ****
	      ******
	     ********
	      ******
	       ****
		**

Each line in this diagram represents one of the rectangles in the
region list. In this case, all of the rectangles are 1 pixel high.
(A 1 pixel high rectangle is called a "span" in the X server).


> Region has value 0 or 1. The purpose of this is that we could control the
> viewable parts of screen.

No. What you are describing is a pixmap input specification to the shape
extension, which consists of 0's and 1's. The shape extension also takes
a region input specification, which consists of a list of rectangles.
  When X, Y position of a Region is 1, then that
> pixel can me filled. Most of GC Operation use Region to simplify the
> operations.




More information about the xorg mailing list