Newsgroups: comp.sys.amiga.programmer Path: utzoo!utgpu!watserv1!watdragon!rose!ccplumb From: ccplumb@rose.uwaterloo.ca (Colin Plumb) Subject: Re: SuperBitMap Layers, etc. Message-ID: <1991Mar6.193942.1842@watdragon.waterloo.edu> Keywords: SuperBitMap, Layers, Graphics Sender: daemon@watdragon.waterloo.edu (Owner of Many System Processes) Organization: University of Waterloo References: <27D2B7A7.3CE7@ibma0.cs.uiuc.edu> Date: Wed, 6 Mar 1991 19:39:42 GMT Lines: 43 menelli@sunc7.cs.uiuc.edu (Ron Menelli) wrote: >I've got a bit of a dilemma that I hope someone can assist me with. Here is >some background... > >I need to have four completely borderless, full screen windows on a custom >screen. They are intended to act as "pseudo screens". Also, I need to write >pixel by pixel onto this screen. I tried WritePixel(), which worked but >was abysmally slow. I've spent much time attempting to replace it with >something of my own that is faster... Since you say later this is a SMART_REFRESH window, why not just go to 4 separate screens? The 4 windows take up as much memory and are, as you've observed, less efficient to work with. >What I did was write a bit of code that writes directly to a BitMap structure >in hopes that this was what I was looking for. It turned out to be a good >four or five times faster than WritePixel(), but unfortunately, due to my >lack of knowledge of the workings of low-level Amiga graphics, I was quite >surprised to find out that writing to any of the four stacked windows resulted >in the image being displayed on the frontmost window. This, of course, does >me no good. Of course; the primary BitMap structure points to the screen; the information about what's obscured is hidden in the bowels of the layers.library and you should go through the graphics.library to get at it. >So, my question to everyone is, how can I solve this problem? Apparently >CopySBitMap must attempt to 'refresh' (for lack of a better word) the >ENTIRE screen, whereas I'm only dealing with a few pixels (usually 7 at a >time). Can I tell it to update everything it needs to based on the small >changes I make instead of the whole (mostly static) screen? Any suggestions >are most appreciated. Well, if the pixels are widely scattered, you're stuck with WritePixel(). If they're clumped, you can write them into a temporary buffer and use one blit to write them, which might be faster than WritePixel(), although just 7 pixels isn't much. I don't see how to do what you're trying to do. If you described your application, maybe I could suggest something else you might try which would be faster. -- -Colin