Xref: utzoo comp.sys.mac.programmer:6018 comp.sys.mac:31356 Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!ncar!ames!oliveb!apple!applelink.apple.com!MAC.ROMOS From: MAC.ROMOS@applelink.apple.com (Ian Hendry) Newsgroups: comp.sys.mac.programmer,comp.sys.mac Subject: Re: CopyBits in MPW C 3.0 Message-ID: <1458@internal.Apple.COM> Date: 20 Apr 89 02:01:06 GMT Sender: usenet@Apple.COM Distribution: na Organization: Yeah, I'm organized. Lines: 31 References:<225@uw-apl.UUCP> <2403@helios.ee.lbl.gov> In article <8904171804.AA00203@vs03csc.UMD.EDU> russotto@wam.UMD.EDU writes: > I've never had any problem passing dereferenced handles to CopyBits-- > I don't believe it is a routine that moves or purges memory (I believe > it's temp buffers are on the stack) Actually, this almost has to be > for VBL tasks to be able to draw... WRONG! Copybits generally does not affect memory, but in some cases it does! DO NOT pass unlocked dereference handles! There are cases where QD may make memory calls during copybits (which would screw up a dereferenced handle) and even if I didn't know actual cases I sure wouldn't count on being able to pass dereferenced handles and have future compatability! For example the (very) newly announced 32-Bit extensions to color quckdraw have more such cases than the unextended color quickdraw versions, but even the older versions do have cases. Sorry (but not too sorry) if the above is phrased strongly. :-) The point is that the cases exist and Apple has said this trap may move memory so this is definately a case in which you should follow Apple's guidelines. Ian Hendry MAC.ROMOS@applelink.apple.com Make sure my name is in the subject of any Email, or post replies to network. TE: 408-974-4737 Disclaimer: It was all HIS idea anyway! Nothing I say reflects anything my employer means... or anything I mean for that matter.