[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: #_DrawPicture and the mac heap
- To: info-macl@cambridge.apple.com
- Subject: Re: #_DrawPicture and the mac heap
- From: lynch@aristotle.ils.nwu.edu
- Date: Wed, 10 Jun 1992 11:52:49 -0600
>Yes, I've noticed strange crashes when drawing very big pictures
>(say with 5000 lines in them).
>
>What precisely is the fix? How exactly does one lock things
>down in mmemory?
>
>Mark
I believe the following scheme may work (untested):
...[assume handle is, in fact, a handle to a PICT and you have set up
rect.]
(let* ((size (#_GetHandleSize handle))
(workspace (#_NewHandle (* size 2)))) ;may need to add a little
extra!
(if (handlep workspace)
(progn
(#_DisposeHandle workspace)
(#_DrawPicture handle rect))
[suitable error message or action]
))
"TANSTAAFL" Rich lynch@ils.nwu.edu