Real Software Forums

The forum for Real Studio and other Real Software products.
[ REAL Software Website | Board Index ]
It is currently Fri Jul 21, 2017 5:35 pm
xojo

All times are UTC - 5 hours




Post new topic Reply to topic  [ 2 posts ] 
Author Message
 Post subject: Memory used for graphics - Carbon vs Cocoa
PostPosted: Tue May 28, 2013 10:56 pm 
Offline

Joined: Sun Jul 16, 2006 11:40 am
Posts: 5
Location: Peoria Illinois
I have a program that loads photos, creates and displays thumbnails. It runs much slower when compiled as a Cocoa app ... I understand Cocoa may not be fully optimized, and that's fine for now. However in Cocoa the program will run out of memory and quit. In Carbon it's fine. (RB2012-2 on a new mac pro with 12 gig memory)

I loaded the activity viewer utility to watch what's happening to memory as they execute. In Carbon it'll load 650 thumbnails and says it uses about 200 meg of real memory. Compiled in Cocoa, trying to open the same 650 it runs the memory up to a little over 3 gig and then quits after making about 500 thumbnails.

I sure hope Cocoa is more efficient with graphics when the new version of Xojo is out next week.

Thanks, Mike


Top
 Profile  
Reply with quote  
 Post subject: Re: Memory used for graphics - Carbon vs Cocoa
PostPosted: Wed May 29, 2013 2:02 am 
Offline
User avatar

Joined: Thu Jul 27, 2006 6:31 pm
Posts: 1698
Location: Monterey, CA
It sounds like you've found a memory leak of some sort. If you can isolate the issue in a new project then report it via the Feedback system so they can fix the specific problem.

I'd start by seeing what happens if you were to clear all reused variables before moving to the next file.

ie;
for each f in listOfFiles
p=Picture.open(f)
// do something with p
p=nil
next

_________________
ImagePlay Effects Library (40+ image effects in one open source module. No plugins, no dependencies, no restrictions.)
http://imageplay.sourceforge.net/


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 2 posts ] 

All times are UTC - 5 hours


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group