Newsgroups: comp.windows.x Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!think.com!snorkelwacker.mit.edu!bloom-beacon!dont-send-mail-to-path-lines From: amotz@amil.co.il (Amotz Maimon) Subject: Re: How do you move a filled-rectangle without flickering? Message-ID: <9105150504.AA04311@amil.co.il> X-Unparsable-Date: Wed, 15 May 91 08:04:02 IDT Sender: daemon@athena.mit.edu (Mr Background) Organization: The Internet References: <1991May14.220025.28972@lynx.CS.ORST.EDU> Date: 15 May 91 08:24:25 GMT Lines: 28 >> I did it by first drawing a filled rectangle, drawing the rectangle >> in next location(one pixel ahead), and then erasing the old one. But >> it gives a flickering effect as it moves. >> >> I wonder if somebody out there knows a better way to do this without >> the flickering effect. >> In the MIT distribution there's a `multi buffer' extension of the server. The idea is the you draw in a hidden buffer(s) and switch the buffers. Since all that is handled by the server (Possibly using hardware support for it), it works pretty fast. We started using it lately, and early tests seems to be working fine. The extension is in: .../mit/extensions/server/multibuf.c Hope it helps. If you find any alternative solution, I'd like to hear about it. Amotz. ----------------------------------------------------------------------------- | Amotz Maimon Internet: amotz@amil.co.il | | Applied Materials (Israel) LTD. Fax: +972-3498-078 | | P.O. Box 58039 / M.S. 0033 Phone: +972-3498-201 | | Santa Clara, CA, 95052-8039 | -----------------------------------------------------------------------------