Problem panning TCanvas w/CopyRect
I need a high-speed method for panning TCanvas for an on-screen
strip-chart recorder/grapher (like the paper that comes out of an EKG
machine). The only way that I've been able to concoct one that works
correctly is to do an ultra-slow nested loop like this :
For x := 0 to Width-DeltaX-1 do
For y := 0 to Height-1 do
Canvas.Pixels[x,y] := Canvas.Pixels[x+Delta,y];
This is too slow. So, I tried using CopyRect and was pleased to see
how fast it worked. But, CopyRect has this annoying habit of grabbing
the contents of overlapping windows (see example linked below). Is there
a way to create an invisible canvas, paint on it, and copy it onto a
visible canvas ? This would do it, I think.
Example :
http://personalweb.sierra.net/~bktahoe/PanCanvas/PanCanvas.html **
** Includes some extraneous objects that you may find useful as an
incentive to get your attention. "Oooh, rotating polygons. Pinch me."
Thanks in advance
BK
----------------------------------------------------------
BKTahoe a.k.a. Brad Kilmer
mailto:BKTa...@sierra.net
http://personalweb.sierra.net/~bktahoe/BKTahoe.html
----------------------------------------------------------
Accute thinker from Nevada's obtuse vertex.
----------------------------------------------------------