Memory Leak on export png????

Richard Gaskin ambassador at fourthworld.com
Fri Mar 16 15:59:47 CDT 2007


Dave wrote:

>> What suggests this crash is specifically a memory leak?
> 
> Just a guess really, I have had this kind of problem when my external  
> commands (not being used in this test) had a memory leak and the  
> performance went right down and RunRev acted in a similar way.
> 
> Not really sure if it is a leak, just seems like the most likely.  
> It's interesting that it works on you setup though. What version of  
> Mac OS are you using?

Mac OS X 10.4.8, MacBook Pro 2.16GHz Core Duo, 2GB RAM


> Richard reports that it works ok on his system, - Richard did you set  
> the Fill Color of the Graphic to Green? Actually any color seems to  
> cause it.

I just added a line to set the color of the group to a random color -- 
works just as well:

on mouseUp
   local tNum
   local twID
   local tFol
   local tDest

   put the colorNames into tColors  --< NEW

   put 500 into tNum
   put the windowID of this stack into twID
   put "/Users/rg/Desktop/untitled folder/" into tFol
   set the defaultfolder to tFol

   repeat with x = 1 to tNum
     if the mouse is down then
       exit to top
     end if
     put x & ".png" into tDest
     put x into fld "counter"
     set the backgroundColor of grp 1 to  any line of tColors --< NEW
     export snapshot from grp 1 to file tDest as PNG
   end repeat
   answer "Done!"
end mouseUp


Then I added a graphic in case there was something specific to that 
object type, changing the color of the graphic instead of the group. 
Same good result.

-- 
  Richard Gaskin
  Fourth World Media Corporation
  ___________________________________________________________
  Ambassador at FourthWorld.com       http://www.FourthWorld.com



More information about the use-livecode mailing list