Path: utzoo!utgpu!news-server.csri.toronto.edu!bonnie.concordia.ca!uunet!jarthur!nntp-server.caltech.edu!toddpw From: toddpw@nntp-server.caltech.edu (Todd P. Whitesel) Newsgroups: comp.sys.apple2 Subject: Re: off-screen grafports ... solved but more problems. Message-ID: <1991Feb23.081452.7593@nntp-server.caltech.edu> Date: 23 Feb 91 08:14:52 GMT References: <2585@kluge.fiu.edu> Organization: California Institute of Technology, Pasadena Lines: 27 WHAT SPECIFICALLY ARE YOU TRYING TO DO?? If you're trying to update a given window faster, then your best bet is to allocate an offscreen image, DRAW INTO IT, and COPY IT TO THE WINDOW in your window's update routine. DO NOT copy things FROM a window, all you will get is the visible region of your window and whatever else is on the screen. I'm mailing you a copy of IIgs tech note #80. In a nutshell, the Locinfo record describes the actual pixmap the grafport will draw into, and windows contain the Locinfo record of the screen. Quickdraw supports clipping so the window manager can exploit it to prevent multiple overlapping windows from drawing on top of each other on the same screeen. As was just posted by a guy from Apple, QD's biggest slowdown comes from trying to draw lots of objects without overwriting pixels outside your window's visRgn -- allocating an offscreen grafport and drawing into it avoids the clipping overhead except for the last step which is doing a pixel copy from the offscreen grafport to the window. If this is slower than your original update routine then you have two options: don't bother using an offscreen grafport Use your own drawing routines ON THE OFFSCREEN GRAFPORT and use QD to copy the image you drew into your window. Todd Whitesel toddpw @ tybalt.caltech.edu Brought to you by Super Global Mega Corp .com