Article View: comp.sys.atari.st
Article #2183Re: Flicker
From: Ken "Bezier" Soohoo
Date: Mon, 03 Jul 1989 15:08
Date: Mon, 03 Jul 1989 15:08
26 lines
2134 bytes
2134 bytes
In article <19890702230805.1.JRD@MOA.SCRC.Symbolics.COM> jrd@STONY-BROOK.SCRC.SYMBOLICS.COM (John R. Dunning) writes:
>I wrote a little hack (for viewing GIF files) that keeps a large image
>in memory, and bitblt's portions of it to the real screen memory. Which
>part of the image gets blt'ed depends on mouse coordinates, ie by waving
>the mouse around, you can move the screen around on the image. All this
>stuff works fine, but for one problem: there's a fair amount of hash
>displayed while the image is moving.
> {Calculations deleted, he's using a blitter}
Ok, here's the easiest way to get no-flicker image movement on an ST with
or without a BLiTTER... Reserve two areas in memory the size of the screen.
Show one area of memory while blitting into the other. Once the blit is
done, change the physical base of the screen so that the _next_ time the
screen redraws, it will draw itself from the new location. Now, be sure
that when you change the screen's physical base, you change it in a non-
critical area (specifically, don't be writing the register when the shifter
is reading it -- so use Vsync(), or stuff into a page 4 location)...
Now, one problem -- the blitter works alone, and so if you perform a blit
using GEM, you'll return _real_ quick... Thus you've got to wait for the
blitter to finish before you flip screens...
Hope this helps... ;-)
--Kenneth "kens" Soohoo (soohoo@cory.Berkeley.Edu)
Atari Hacker (Atari's Hacker...)
"It could be worse, you could get hit by a bus..."
My opinions are my OWN, _not_ necessarily Atari's. But "hey", who knows?
Technical Details
Message-ID:
<15140@pasteur.Berkeley.EDU>Path:
arc1-ca.pugleaf.net!utzoo!attcan!utgpu!jarvis.csri.toronto.edu!mailrus!tut.cis.ohio-state.edu!ucbvax!pasteur!cory.Berkeley.EDU!soohooReferences:
<19890702230805.1.JRD@MOA.SCRC.Symbolics.COM>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!attcan!utgpu!jarvis.csri.toronto.edu!mailrus!tut.cis.ohio-state.edu!ucbvax!pasteur!cory.Berkeley.EDU!soohoo From: soohoo@cory.Berkeley.EDU (Ken "Bezier" Soohoo) Newsgroups: comp.sys.atari.st Subject: Re: Flicker Message-ID: <15140@pasteur.Berkeley.EDU> Date: 3 Jul 89 15:08:13 GMT References: <19890702230805.1.JRD@MOA.SCRC.Symbolics.COM> Sender: news@pasteur.Berkeley.EDU Reply-To: soohoo@cory.Berkeley.EDU.UUCP (Ken "Bezier" Soohoo) Organization: University of California, Berkeley Lines: 26