Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!wuarchive!zaphod.mps.ohio-state.edu!ub!uhura.cc.rochester.edu!rochester!pt.cs.cmu.edu!henry!hairston From: hairston@henry.ece.cmu.edu (David Hairston) Newsgroups: comp.sys.mac.programmer Subject: Re: distort bitmaps ... Message-ID: Date: 14 Dec 90 05:21:46 GMT References: <12279@hacgate.UUCP> Organization: Gaia II Lines: 18 In-reply-to: waung@rscene.hac.com's message of 14 Dec 90 02:06:07 GMT [waung@rscene.hac.com (Franklin Waung) writes:] [] I have a bit map of say 80 by 100 pixels 1 bit deep (black or white), [] and I want to expand the image on the bitmap to say 120 by 150 pixels. [] [] Does anyone know some short algorithms to do this? read about Copybits in IM-I, QuickDraw Bit Transfer Operations. Copybits gets better with age but ever since the beginning you could transfer an image from one bitmap to another and the image will be sized according to the source and destination rectangles. the trick in all this is to keep rowBytes even (review QuickDraw focussing on bitmap operations). if you want to look at some related tools then see also: ScalePt, MapPt and MapRect under QuickDraw Miscellaneous Routines. -dave- hairston@henry.ece.cmu.edu