jmunkki@santra.UUCP (Juri Munkki) (02/05/89)
I'm experimenting with vector animation on a Mac II with an apple graphics card. Just for fun, I write directly to the screen and try to make everything as fast as possible. I was surprised when I discovered that calling SetEntries takes about 1/60 seconds when called from a tight loop. I first thought that the color manager is trying to create inverse tables or do something foolish with the colors I gave it. It turned out that calling the device driver with PBControl was exactly as slow as calling SetEntries. The reason it takes about 1/60 seconds seems to be that the device driver always changes the clut during the vertical blanking interval of the screen. Putting a loop between two PBControl calls showed that the combined time changed from 1/60 seconds to 2/60 to 3/60 and so on. The question (to Apple) is: Is there a way to change the clut without waiting for the sync? In my case it's great that the call already handles the sync, but can I trust other cards to do the same thing? If I just ignore the SetEntries sync and do my own, I end up waiting up to 1/30 seconds. I intend to write a game where I have an unchanging background image on 2 bitplanes. I use the remaining 6 bitplanes as two 3-bit overlays for double buffering the animation. This gives me 4 background colors and 8 foreground colors. It should look quite a lot like the old Atari arcade games with vector displays. (Tempest, BattleZone, ...) -- _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._ | Juri Munkki jmunkki@hut.fi jmunkki@fingate.bitnet I Want Ne | | Helsinki University of Technology Computing Centre My Own XT | ~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~