• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: NSView out of memory problem
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSView out of memory problem


  • Subject: Re: NSView out of memory problem
  • From: Gorazd Krosl <email@hidden>
  • Date: Tue, 1 Apr 2008 09:43:10 -0400 (EDT)

Hi Leslie,

NSView does not store any drawing. If the code bellow
is
executed in the loop as you are indicating and
possibly several thousand times, each time through the
loop you are creating a new autoreleased NSBezierPath.
If this is the case, you should include
NSAutoreleasePool and drain or free it every so often;
maybe every 100 iterations, to  get rid of accumulated
NSBezierPaths.

Hope that helps.
Gorazd

>p1 = [NSBezierPath bezierPath] ;
>[p1 moveToPoint: linebottom] ;
>[p1 lineToPoint: linetop] ; [p1 stroke] ;


      __________________________________________________________________
Be smarter than spam. See how smart SpamGuard is at giving junk email the boot with the All-new Yahoo! Mail.  Click on Options in Mail and switch to New Mail today or register for free at http://mail.yahoo.ca
_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: NSView out of memory problem
      • From: Andre Schnoor <email@hidden>
  • Prev by Date: Re: NSView out of memory problem
  • Next by Date: Re: Custom interface
  • Previous by thread: Re: NSView out of memory problem
  • Next by thread: Re: NSView out of memory problem
  • Index(es):
    • Date
    • Thread