AWCTTYPA@UIAMVS.BITNET ("David A. Lyons") (03/14/89)
>Date: Fri, 10 Mar 89 10:31:00 CST >From: "LARRY MICHALEWICZ...VAX OPERATOR" <LARRY@VAXB.ACS.UNT.EDU> >Subject: Page flipping on IIgs > >First of I'm using the standalone version of TML Pascal. > >My first question is how can you do page flipping with the GS I know >it can be done, But I have never been able to draw off screen and >then display it to the screen. There's only one super-hires page, so you can't flip. You can certainly draw offscreen and then copy onto the screen, though. You need to understand a lot of QuickDraw concepts, including ports. Use NewHandle to get a fixed-location block of $AA bytes, and feed a _pointer_ to that block to OpenPort. Then allocate an off-screen pixel map for your port, set up an appropriate Loc Info record for your port, pointing to the pixel map you allocated, and then you can use SetPort to let QuickDraw draw to your offscreen port, and you can use stuff like CopyPixels, PaintPixels, etc, to copy images from your offscreen port to an on-screen port. >My second question...how can I create a background and then draw an >object over the background with changing the back ground. I've tried >some stuff using two windows, one with the backgound and one with the >object, but havn't had much luck. What did you try? PPToPort should do it with no problem. See the table on page 16-235 of TB Ref vol 2 for pen moes. It looks like you can use 1. PPToPort(sourcePort, srcRectangle, X, Y, 1). >Larry Michalewicz BitNet: LARRY@UNTVAX >Vax Programmer/Operator THENET: NTVAXB::LARRY >Student of computer Science Inter : LARRY@vaxb.acs.unt.edu >University of North Texas SPAN : UTSPAN::UTADNX::NTVAXB::LARRY >Denton, Texas 76203 AT&T : 1 (817) 565-5578
mcgurrin@MITRE.MITRE.ORG (03/15/89)
I confess considerable ignorance on this topic, but isn't there also a tool for copying memory blocks? If so, couldn't it be used to copy the offscreen bitmap into the memory used for display? This would seem much changing whole page displays (assuming one wasn't doing windows, menus, etc., in which case you could cause one heck of a lot of problems).