[comp.sys.sgi] move images

svec5@menudo.uh.edu (T.C. Zhao) (04/30/91)

Sorry for asking maybe a novice question:

I now have a need to move a rectangular frame around the screen.
I know of XOR but I also know it is not very portable. The way
I am now doing it is to save whatever underneath the frame before
putting the rectangular frame and restore it when the frame is moved.
It works nicely except it is slow(rectread and rectwrite.) I noticed
that when open a new window, moving the frame around is quite fast,
how is that done ? Any help would be appreciated.

Thanks in advance. 

msc@ramoth.esd.sgi.com (Mark Callow) (05/01/91)

In article <1991Apr29.182014.5178@menudo.uh.edu>, svec5@menudo.uh.edu (T.C. Zhao) writes:
|> Sorry for asking maybe a novice question:
|> 
|> It works nicely except it is slow(rectread and rectwrite.) I noticed
|> that when open a new window, moving the frame around is quite fast,
|> how is that done ? Any help would be appreciated.
|> 

The window manager draws the frame in the popup planes which provide a
separate frame buffer that is displayed on top of the main image buffer.
The popup planes are by convention reserved for system use.  An application
can accomplish the same thing using the overlay planes.

See the drawmode(3G) man page for details.
-- 
From the TARDIS of Mark Callow
msc@ramoth.sgi.com, ...{ames,decwrl}!sgi!msc
"Spirits of genius are always opposed by mediocre minds" - Albert Einstein