B.BSK@MACBETH.STANFORD.EDU (Brian Keller) (10/29/89)
I'm trying to use SetPortBits to draw off screen so I can then use CopyBits to dump on the screen. However, when I try to set the active port back to the window, I can't draw anything new in it. Basically the procedure is as follows: procedure UpKeep; var UPDRect,ARect : Rect; WinBits,OldPtr : BitPtr; SavePort : GrafPtr; begin GetPort(SavePort); UPDRect:=SavePort^.portRect; New(WinBits); WinBits^.rowBytes:=SavePort^.portBits.rowBytes; WinBits^.bounds:=SavePort^.portBits.bounds; OldPtr:=@SavePort^.portBits; SetPortBits(WinBits^); SetPortBits(OldPtr^); <<<< ... draw stuff - it never appears?? ... If I take out the line with "<<<<" the picture gets drawn to the screen as expected. I've tried setting OldPtr to everything I can think of, but I never seem to be able to get back to the original screen. Help!!!!!!! -------